Humanities Science Mathematics Computing/IT Language Miscellaneous Archives
The page you are currently viewing is an archive page. While you can leave answers for any questions shown below, please ask new questions at one of the pages linked to above.

< July 1 Mathematics desk archive July 3 >


Summation with additional condition in Maple

edit

I'd like to compute

 

for some positive integer n and some function f in Maple. How do I do this? Mon4 21:25, 2 July 2006 (UTC)[reply]

Could you clarify the sum? Do you mean sum from x=1 to n only for x relatively prime to n? And are you looking for a numerical solution or a closed form solution? I expect that a closed form solution does not exist (could be wrong). I would suggest not trying to use the sum command and just writing a for loop that first checks values from 1 to n, and then keeps a running sum for values where the gcd is 1. 128.197.81.223 23:30, 2 July 2006 (UTC)[reply]
I think the summation is of the values of the function which have, as a parameter, a prime number within the range [1,n) (since n cannot be used, because  ). I don't know Maple, so what I say may not work, but try creating a list or vector of prime values within that range, and using that as your value set in the sum function. --JB Adder | Talk 00:33, 3 July 2006 (UTC)[reply]
You could try the Iverson bracket trick. Create a function say g(x,n) that is 1 if its arguments are coprime and 0 otherwise. Then calculate the sum from 1 to n of f(x)g(x,n). Dysprosia 00:33, 3 July 2006 (UTC)[reply]
I don't know a really clever way to do it. If n is not very large, use
                        add(f(i),i in select(x->gcd(x,n)=1,{$1..n}));
McKay 02:51, 3 July 2006 (UTC)[reply]

Replacing Pi with another number

edit

What would be the effect of changing Pi to another rational? Would a circle change its appearance?

First of all, pi is irrational, so it doesn't make sense to say "another rational". Second of all, the question as a whole doesn't make sense. It's like asking "What would be the effect of changing 2 to another integer?". However, check out Non-Euclidean geometry for examples of spaces in which the circumference of a circle is no longer pi times its diameter (although pi is still pi). —Keenan Pepper 22:52, 2 July 2006 (UTC)[reply]
The question is meaningless, revealing fundamental confusion. As noted, π is not rational. More to the point, π is defined as the ratio of circumference to diameter of a circle in Euclidean space; its value is fixed by the laws of mathematics.
If we feel creative, we can change what it means to be a circle, but that will not change π. For example:
  • One way to define a circle is as the locus of points equidistant from a fixed point, the center. The Euclidean definition of distance says that a point with Cartesian coordinates (x,y) is at a distance from the origin of (|x|2+|y|2)1/2. We can replace each "2" by "p" to give different ways to measure distance, leading to a family of different geometries and different shapes for a "circle".
  • We can use spherical geometry instead of Euclidean plane geometry. Then the equator is a "circle" around the North Pole. On a unit sphere the "circumference" of such a circle is 2π and the "diameter" is π, so the ratio is 2. With different circles we can make the ratio as small as we like.
These investigations are entertaining, but they do not change the definition nor the value of π. --KSmrqT 23:22, 2 July 2006 (UTC)[reply]
I believe this person is defining pi as the perimeter/circumference of any shape over 2 times its radius (I suppose the shape would have to be a regular polygon). For example, the "pi" of a square is  . The more sides the polygon has, the closer the "pi" gets to the constant pi. --Tuvwxyz 17:33, 3 July 2006 (UTC)[reply]
It could be that the person was just wondering what the universe would be like if fundamental constants had different values. Whilst pi isn't technically a fundamental physical constant, near enough is good enough, so maybe they are saying "What if the fundamental constants that appear to be responsible for the universe working how it is had values different to those they have now?" To which the answer is, of course, who knows? Your guess is probably as good as anybody's. It's a bit hard to imagine a universe in which circles had circumferences 10 times their radius (π = 5), but good luck.

Another point, a circle's appearance is not defined by pi, pi is difined by the circle. If a circle's appearance changed at all, it would simply no longer be a circle. Also, pi cannot exist in polygons, because it has infinite different radii at different angles. I think you meant a ratio of perimiter to the distance between the center and the point farthest away from the center. -- He Who Is[ Talk ] 04:17, 9 July 2006 (UTC)[reply]

Physics and calculus together, hooray!

edit

I'm trying to find the total amount of energy lost when a block travels completely around a frictional loop-the-loop. What I've been albe to figure out so far is below (illustrated here):

N=m(v2/r + g cos θ)

E lost to friction = r∫0θ N μk

½ m (v0)2 = ½ m v2 + mgr(1 - cos θ) + r∫0θ [(v2/r + g cos θ) m μk] dθ

½ (v0)2 = ½ v2 + gr(1 - cos θ) + μk r∫0θ (v2/r + g cos θ) dθ

½ v2 = ½ (v0)2 - gr(1 - cos θ) - μk r∫0θ (v2/r + g cos θ) dθ

[v(θ)]2 = (v0)2 - 2gr(1 - cos θ) - 2μk r∫0θ ([v(θ)]2/r + g cos θ) dθ

...

help? Daniel Olsen 22:59, 2 July 2006 (UTC) [reply]

Hopefully someone will check my math, because I'm honestly surprised with the simplicity of the result, but here we are: start over entirely and notice that   so  . You're correct that   (although you chose a positive sign for energy lost), so we have  , since the cosine integrates to 0. Then differentiate both sides with respect to θ:  , so (from basic DEs)  , so (using  )   (multiply by -1 to get energy lost). Hope this helps. --Tardis 20:42, 3 July 2006 (UTC)[reply]
Actually, let me go back on this a bit.  , as you implied, taking   when  . Moreover, I can't say that the cosine integrates out for all θ; I was thinking too much about the eventual  . Done more carefully, we get  , which is a lot harder to solve. It might be possible to salvage this approach via a clever substitution, possibly involving the solution to the simpler (wrong) equation; alternatively, one might attack the equations of motion more directly, but I find  , which looks no friendlier (being nonlinear and all). Ideas, anyone? --Tardis 22:41, 3 July 2006 (UTC)[reply]