Tuesday, August 31, 2010

SHM Solution W/O Small Angle!

for some time now, the small angle approximation has been a pet peeve of mine.
don't get me wrong, i greatly appreciate its uses! there are countless problems which would be unsolvable without it.
but i have always tried to get around using it, or when i have to, get approximate solutions.

i'm actually not positive on how much work has been done on solving the Harmonic Motion equation WITHOUT the small angle approximation. i do know that has no closed-form solution, but approximations have been done. and, in fact, i have one to present today!

it was actually not as much work as i thought it would be to get it into a form which could be approximated, but it definitely was more than is usually called for in a physics class i've been in.

so here goes. first, consider the free-body diagram of a swinging pendulum, and hopefully arrive at this equation:

-Lmg sinθ = Iα
where L is the length of the string, m is the mass of the object attached to it, g is the acceleration of gravity, I is the moment of inertia for the pendulum, and α is the rotational acceleration.
rearrange this and put it into the familiar differential equation form:

θ'' + c²sinθ = 0, where c² = Lmg/I

now let ω' = θ'' = -c²sinθ, then
dω/dt = -c²sinθ
also note that dθ/dt = ω. and we can combine the previous two equations to arrive at the following:

ω dω/dθ = -c²sinθ
ω dω = -c²sinθ dθ
∫ω dω = ∫-c²sinθ dθ + C₁
½ ω² = c² cosθ + C₁
ω² = 2c² cosθ + C₂

now to find C₂:
we know that at time t = 0, dθ/dt = ω(0) = 0, and θ(0) = θmax = θ₀
0² = 2c² cos(θ₀) + C₂
C₂ = -2c² cos(θ₀)

there so now we have:
ω² = 2c² cosθ - 2c² cos(θ₀)
... skipping a few steps now in the interest of space:
dθ/dt = ± c(√2)√[ cos(θ) - cos(θ₀) ]
this D.E. is separable and leads to the following integral:

∫dθ/√[ cos(θ) - cos(θ₀) ] = ± c(√2) t + C₃
unfortunately, this is an elliptic integral and cannot be solved explicitly. so i will just call it I and solve for t:
I = ± c(√2) t
t = I/(± c(√2)) + C₄.

you can, however, approximate this integral with a Taylor Series. i'll give the first few terms here. but note that  the rest can be found by plugging the integral into Wolfram Alpha's solver. and in the interest of clarity, i will post a picture instead of writing the terms out:
∫dx/√[ cos(x) - a ] ≈ ...


it is nice to see this solution compared to the solution of the equation WITH the small angle approximation. we can write an expression for t of this equation as such:
t = arccos(θ/θ₀)/c
(much simpler than the other form!)

i would have liked to graph these two functions and see how accurately the small angle approximation approximates the actual function, but i couldn't find a grapher that was accurate enough, nor enough terms of the integral to get it sufficiently accurate.
i will, however, tell you that it actually approximates the true solution VERY well, and is alright in my book.
if you are interested in plotting or graphing these values, the Wolfram Alpha site will let you get copy-able text to paste into your software by clicking on the picture.
i found this website convenient for quick graphing for anyone who wants it:
(not very accurate though)

http://www.livephysics.com/ptools/online-function-grapher.php

Tuesday, August 24, 2010

Random Walk!

This is something that I discovered in my lab manual for lower div Thermodynamics - we didn't do it in class at all, in fact it's horrible that it wasn't even mentioned (not only because it's very interesting, but because it plays a major role in thermodynamics)!

It is known as the Random Walk "experiment" or "hypothesis".

The experiment is this:
You are standing on a city block in a city such as Philadelphia (so that all the streets are in a rectangular grid), and you hold a coin in your hand.
You flip the coin: if it comes up heads, you walk a block West; if it comes tails, you walk a block East. (And it is assumed that all the blocks are of equal length).
So you do this a great number of times (or until you get tired).

Where are you?

Think about this. Most people would think - rather logically - that you will end up in your original place! This seems logical because you could make the argument that the coin will come up heads and equal number of times that it will come up tails. And therefore, you will walk the same number of blocks West as you will East, with the net result being that you will end up exactly where you began!

Unfortunately, and very surprisingly, this is NOT the case.
You do not end up in the same place. Would you be surprised if I told you that you will end up approximately the square root of the number of flips away from your origin? (As the number of flips and trials you do becomes large).

How can this be? Well there is a mathematical proof which i will present for you. But I also ecnourage you to run some tests of this phenomenon! (You don't actually have to go outside and do this, a simple coin and pencil will do - or a computer program, which would be much faster).

Here is the python code that I used to test this:


Try it yourself! And if you don't have Python, it is extremely easy to download from phython.org (I use version 2.6.5)
A good way to see the results is to do manyRandWalk(1000,10000). It'll take a few seconds, but you can see that it is very accurate.

And I actually should note that, on average, it is computed that this will not exactly approach sqrt(n), where n is the number of flips. It is, for statistical reasons about 4/5 of that, so 0.8*sqrt(n) is actually correct. Which you will see if you run the program! i got about 81.43 and 77.876 on my first couple tries. and the exact answer should be around 80!

and, if you were wondering, here is the mathematical proof. this was actually a proof by Feynman from his Lectures on Physics. and if you're wondering how this pertains to physics, i'll write a little about that after the short proof:

let D(n) be the distance travelled after n coin tosses. and let a + number be distance travelled west, and - be distance traveled east.
then D(1) is guaranteed to be ±1. or we can say
D(1)² = 1

we also know, by the same logic, that
D(n+1) = D(n) ± 1, then
D(n+1)² = D(n)² ± 2D(n) + 1

here, feynman uses some arguement (which escapes me at the moment) as to why the "± 2D(n)" can be ignored or eliminated. as best as i can remember, it had to do with the two forms cancelling out for large n, which would seem reasonable. but anyway, continuing thusly (and trusting Feynman at this point):
[edit: i did some work on this, not too long after publishing this post, and it is very clear that, on the average, the ± 2D(n) term will be zero. it's actually just painfully obvious and should be intuitive. but note that making this simplification means that you accept that all the following work is only on the average. that is to say, when i will show that D(2)² = 2, it seems contradictory to say that D(2) = ±1.414... (an irrational number) because it should obviously be either 0 or ±2! this is an average! so while this may have been a little too detailed, i just thought it was interesting! and now the proof:]

D(n+1)² = D(n)² + 1
and since we know that D(1)² = 1, we can find D(2)²:
D(2)² = D(1)² + 1 = 1 + 1 = 2
and D(3)²:
D(3)² = D(2)² + 1 = 2 + 1 = 3
and D(4)²:
D(4)² = D(3)² + 1 = 3 + 1 = 4
etc...
doing this, we find that
D(n)² = n, or
D(n) = √n

and that is how it is done! i do encourage you to try it out on your computer (or it is even easy enough to program on your calculator).

now just a little bit as to why this is physically relevant. imagine a random walk - not back and forth in 1 dimension - but all around space in 3 dimensions. consider also that a gaseous molecule travels roughly randomly through space. you should now see that a random walk in 3 dimensions is actually useful for estimating the path - or displacement - of a gas!
while this may not necessarily be as exciting a revelation, random walks are referenced in a variety of other topics such as Path Integration - very Feynman!

anyway, i hope you found this topic as curious and stimulating as i did!

Y!A: String and Quantum Theory

This is a question i answered for someone who seemed to be having some problem conceptualizing both String Theory and Quantum Mechanics in the same context. i can't say that i completely understood what he was asking, but i hope i gave him a good idea that these two concepts are very well related.

http://answers.yahoo.com/question/index?qid=20100824133230AAGX5rj&r=w#OpBoM23EKWK18mDD9Dq0

Q:
Simultaniously Conceptualizing String & Quantum Theory?
String theory says there are strings that are 1-dimensional slices of a 2-dimensional membrane vibrating in 11-dimensional space with variations in their vibrations resulting in the creation of all light, matter, gravity etc... in the universe. Quantum Mechanics says particles can exist in a super position until the wave function is collapsed, part of the particle wave duality. How can one stitch these two theories together conceptually? Are all strings in some type of super position as well until collapsed? Or another way of asking; If a particle is in super position, is the string also in a kind of superposition? 


Maybe the question is illogical. Like asking what's the marital status of the number nine. 


Help with conceptualizing this would be much appreciated!

A:
first of all, i think you know very well what strings and string theory are, and i compliment you on that knowledge!
one thing i want to clarify is how these strings create, as you say, "all light, matter, gravity etc... in the universe." the only thing that a variation in a string vibration produces is a different fundamental particle. that is, one specific vibration of a string is an up quark, while another is the gluon. then the interactions between these particles create light, gravity, etc... (and even mass, itself!)
but this i'm sure you know, and i just wanted to clarify.

these two ideas can be easily conceptualized as follows:
quantum theory does state that particles exist in a state of uncertainty until they are 'observed'. so, in short, yes, you can think of the strings being in a sort of quantum state as well. but remember that this quantum state applies only to properties of the particle like position, speed, etc... so it is essentially no different than thinking of the particles in this superposition. since these basic particles are, more fundamentally strings, it is just fine to thing of the strings adhering to the same rules as the particles! although i don't necessarily know what great insight this approach would yield.

one thing which would be wrong to say is that the vibration of the string is also in superposition. that is, the string can be vibrating in many different ways - and thus be many different particles - at the same time. although this may seem theoretically possible, remember that a particle remains in superposition only as long as it is not observed or measured. i would think that the universe is constantly checking on which particle a certain string is behaving as. i may be wrong however, but i have never heard of quarks suddenly turning into leptons and then turning into photons.

Sunday, August 22, 2010

Alternate Derivation of SHM Equation

here is a derivation of the SHM equation in a slightly simpler form that might be easier to understand for those who don't want to go through all linear operations and auxiliary equations that comes with the other proof.
so here is a different proof where i've just used a few substitutions and a couple integrations.

we all know the basic condition for SHM:
F = -kx
and Newton's Second Law:
F = ma

and from these we construct our differential equation (look to the previous blog post if you need to see how this is put together):
d²c/dt² + c²x = 0,
where c² = k/m

now, let v = dx/dt. then also, d²x/dt² = v * dv/dx (this is a substitution often used for solving differential equations)
v * dv/dx = -c² x
v dv = -c² x dx
∫v dv = -c² ∫x dx + C₁
½ v² = -c² ½ x² + C₁
v² = -c² x² + C₂ ... (C₂ = 2C₁)
(dx/dt)² = -c² x² + C₂

let us now find C₂:
we assume that at time t = 0, the oscillating object is at its maximum displacement, A, and has no velocity. no velocity means that x(0) = A, x'(0) = 0:
x'(0) = -c² x(0)² + C₂
0² = -c² A² + C₂
C₂ = c²A²

now back to the differential equation:
(dx/dt)² = -c²x² + c²A²
dx/dt = ±√[-c²x² + c²A²]
dx/dt = ± c√[ A² - x²]
dx / √[ A² - x²] = ± c dt
∫dx / √[ A² - x²] = ± c ∫dt + C₃

here we use a trigonometric substitution x = A sinθ to solve the integral. this makes:
√[ A² - x² ] = √[ A² - A² sin²θ ] = A √ (1 - sin²θ) = A √ (cos²θ) = A cosθ
and,
dx = A cosθ dθ
lastly,
sinθ = x/A => θ = arcsin[x/A]

∫A cosθ dθ/ A cosθ = ± c ∫dt + C₃
∫dθ = ± c ∫dt + C₃
θ = ± ct + C₃
arcsin[x/A] = ± ct + C₃
x/A = sin( ±ct + C₃ )
x = A sin( ±ct + C₃ )

now, to find C₃:
recall that at time t = 0, x is a maximum of A:
x(0) = A sin( ±c*0 + C₃)
A = A sin(C₃)
1 = sin(C₃)
C₃ = π/2

then our equation becomes:
x = A sin( ±ct + π/2 ), but know from trigonometry that sin(θ + π/2) = cos(θ)
x = A cos( ±ct)
and remember also that cos(-θ) = cos(θ), which gives:
x(t) = A cos(ct)

THERE WE GO!
see, that wasn't so difficult! it was actually probably easier to follow than the previous derivation.
and i wrote out literally ALL the steps necessary. a physics textbook wouldn't have to show half of this stuff, and it's not that difficult to put in the back in an appendix or something, come on!

Derivation of SHM equation

every time i read a physics book (especially the textbooks) and i get to the part about simple harmonic motion (SHM), i get nervous. this is because every single time i have read the section, the author NEVER explains how to - or says it is too difficult to - derive the equation for SHM! everyone knows that it is
x(t) = A cos(ωt) ,
or some of its other variants (like with the +φ, or the sin or what-have-you). but this is just GIVEN to us! and the author never tells us how we got there! sure, we know that it is simple enough to show that it satisfies Hooke's condition:
F = -kx, and can be equated with Newton's Second Law:
F = ma = m (d²x/dt²), yielding:
m (d²x/dt²) = -kx, or
x'' + (k/m) x = 0, and letting k/m = c²
x'' + c²x = 0

but NO ONE has ever explained the process of deriving this! and i know that, at this level of physics, that sort of mathematics isn't necessary, but it shouldn't be difficult to whip together a part in the appendix which has the solution for those who are curious!

it is also worth noting that, way before i could solve these differential equations myself, i found another solution to this one. it was actually because i had been staring so long and so hard at this solution and the equation, trying to find out how it was done, but i came with it (which, with some small effort, can actually be seen as equivalent to the more common solution):
x = A e^(±ict). taking derivatives, we see that
x' = ±icA e^(±ict), and
x'' = -c²A e^(±ict), or
x'' = -c²x, which satisfies our condition!

so this was one cool (and complex!) solution the differential equation which, although not very useful (because of the imaginary component) was still exciting at the time!

so naturally i, not being able to find the solution anywhere, had to derive it myself.
i did this a couple ways (and at different times). the first time was in the infancy of my Diff. equ. class when we had just learned how to handle differential equation with second order derivatives. PERFECT! i made the necessary substitutions and solved the equation that way. it actually was not that difficult and could have easily been done in one section (or appendix) and have been understandable by anyone with a calculus background.
but this isn't the solution i'm going to present today; the one i have was derived with some knowledge of linear operators and some more basic calculus (and, of course, our dear friend Euler). i might also post my first solution up here if i get around to re-working that proof.

so here goes!
we start with our fundamental differential equation derived from Hooke's Law:
F = -kx = ma = m d²x/dt²
rearranging, we get:
d²x/dt² + (k/m) x = 0, and i will make the substitution c² = k/m
d²x/dt² + c²x = 0
note that this is a homogeneous differential equation with constant coefficients. it can also be written this way:
D²x + c²x = 0, or
(D² + c²)(x) = 0

now recall what we learned about in the last post about these types of differential equations. we have to write the auxiliary equation and find the roots:
r² + c² = 0, solving this for r:
r² = -c²
r = ±√(-c²)
r = ± ic, where i = √(-1). so we have
r₁ = ic, r₂ = -ic.
note that this is of the more general form r = α ± iβ (where α = 0, β = c)

now that we have this solution, we find that our solution for this case is of the form:
x = e^(αt) [ C₁e^(iβt) + C₂e^(-iβt) ],
where C₁ and C₂ are constants of integration.

and don't think, for a second, that i would just present an esoteric solution to a complicated problem and expect you to blindly accept it! remember that i did post how to arrive at this solution in my previous post. so if you have any questions about how we got there, go one blog post back.

and so, substituting our results into the solution, we get:
x = C₁e^(ict) + C₂e^(-ict).
but this doesn't look at all like the solution we know and love! but if we are just patient, we can do something very interesting with 'i' in the exponent of 'e' - where, again, Euler will save us. and i'm sure you've seen it before. it is the identity:
e^(iθ) = cosθ + i sinθ.
substituting ct (and -ct) for θ, we get:
e^(ict) = cos(ct) + i sin(ct), and
e^(-ict) = cos(-ct) + i sin(-ct). but we can actually use our knowledge of the odd and even qualities of sin and cos, to simplify this second equation. we will use the fact that cos(-θ) = cos(θ), and sin(-θ) = -sin(θ):
e^(-ict) = cos(ct) - i sin(ct)

so then, substituting back in, our solution looks like this:
x = C₁[ cos(ict) + i sin(ict) ]+ C₂[ cos(ict) - i sin(ict) ]. and rearranging, we can write it this way:
x(t) = (C₁ + C₂) cos(ct) + i (C₁ - C₂) sin(ct)

huzzah! this is our general solution! wonderful, isn't it? we can simplify it a little bit by giving the initial value conditions that x(0) = A, and x'(0) = 0. where A is the amplitude, or maximum value of the oscillation. by doing this we've said that at time t=0, the pendulum (or spring, or what-have-you) is at it's maximum displacement, and that it has 0 velocity at that time and place (which logically, would have to be the case).
this gives us the following:
x(0) = (C₁ + C₂) cos(0) + i (C₁ - C₂) sin(0) = (C₁ + C₂) = A
x'(0) = -c(C₁ + C₂)sin(0) + ci(C₁ - C₂)cos(0) = ci(C₁ - C₂) = 0

solving this system of C₁ and C₂, we get:
C₁ = C₂ = A/2
and plugging these into out equation:

x(t) = A cos(ct), c² = k/m
it is obvious now that this solution is EQUIVALENT to the commonly known solution! so not only have we derived it completely, we have derived it correctly! and with all steps shown and no gimmicks! it's hard to imagine that a physics textbook couldn't fit this somewhere into the text! even a mention in the appendix is not that hard to do!

i hope that, at the very least, people now have some idea that this equation CAN be derived - and rather simply too! (i've actually realized that first solution i worked out for this problem might be even simpler and easier to see than this one, so i will go ahead and post that one too).

Saturday, August 21, 2010

Derivation of D.E. solution


i'm writing this post mostly to show how we will arrive at the solution to the differential equation (D.E.) that we will encounter for SHM (Simple Harmonic Motion) in my next post. this is so that nothing is left out of the proof and my reader(s?) will not feel lost at all! with this proof and the following post, you should have everything you need to solve the SHM differential equation.

but this is not just used to solve the SHM equation! do note that this solution can be applied to many differential equations, and really rather easily! maybe you'll come across one and this post will have helped you solve it! (well, i can only dream).

there probably will not be as much step-by-step explanation in this post, mostly just math. but if you follow carefully, and i don't make any mistakes, the math should speak for itself.
so here goes:

first we need to mention that this is a homogeneous linear D.E. with constant coefficients which can have any order derivative.
i will present mine as a D.E. with a 2nd order derivative because that is the most basic and relevant example, and it can easily be expanded to any higher derivatives with little (or no) extra work.

consider, then the D.E.:
d²x/dt² + 2a* dx/dt + bx = 0, or
x'' + 2ax' + bx = 0, where a and b are constants. this can be written in operator notation as:
(D² + 2aD + b) x = 0
and if my convention for operator notation is different that your, D is the differential operator, d/dt. and so dx/dt is written Dx or D(x).

now, in order to proceed, we need to know something about linear D.E.s with constant coefficients - which is where Euler will come in and help us. something known as an 'auxiliary equation' is used to classify this D.E. and quickly arrive at its solution. the aux. equ. is simply:
r² + 2ar + b = 0
regardless of the particular solutions, this quadratic has 2 roots, r₁ and r₂, such that
(r - r₁) (r - r₂) = 0
(and it may have more for a higher order differential)

it follows then that our D.E. can be written as:
(D - r₁) (D - r₂) x = 0

now, let u = (D - r₂) x, and we can write our equation as:
(D - r₁) u = 0, and solve for u
du/dt - r₁u = 0
du/dt = r₁u
du/u = r₁dt, and integrating...
∫du/u = ∫ r₁dt + C₁''
ln|u| = r₁t + C₁''
|u| = e^( r₁t + C₁''), and let |C₁'| = e^C₁''
u = C₁' e^( r₁t)

then, since:
(D - r₂) x = u
dx/dt - r₂x = C₁' e^(r₁t), or
dx/dt + (- r₂) x = C₁' e^(r₁t), which is of a form which has a known solution. but i'm not going to even cut any corners there. i'll walk through it.

let p(t) = -r₂, q(t) = C₁' e^(r₁t), such that our equation is:
x' + px = q
now let μ = e^[∫p(t)dt] = e^[∫-r₂dt] = e^(-r₂t)
note also that dμ/dt = -r₂ e^(-r₂t) = μp
now multiply through our equation with μ (which is okay since μ ≠ 0 ∀t):
μx' + μpx = μq, or
μ (dx/dt) + x (dμ/dt) = μq, which should look like the product rule for differentiation to you, thus:
d(μx)/dt = μq, or
d(μx) = μqdt, and integrating:
∫d(μx) = ∫μqdt + C₂
μx = ∫μqdt + C₂, and substituting back in:
e^(-r₂t) x = ∫ e^(-r₂t) C₁' e^(r₁t) dt + C₂
e^(-r₂t) x = C₁' ∫ e^[(r₁ - r₂) t] dt + C₂

here, we will observe 3 special cases for evaluating the integral ∫ e^[(r₁ - r₂) t] dt:
CASE 1: r₁ = r₂ = r
e^(-rt) x = C₁' ∫ e^[0 t] dt + C₂
e^(-rt) x = C₁'t + C₂, (and let C₁ = C₁')
x(t) = e^(rt) (C₁t + C₂)

CASE 2: r₁ ≠ r₂
e^(-r₂t) x = C₁' ∫ e^[(r₁ - r₂) t] dt + C₂
e^(-r₂t) x = C₁'/(r₁ - r₂) * e^[(r₁ - r₂) t] + C₂, (and let C₁ = C₁'/(r₁ - r₂))
e^(-r₂t) x = C₁ e^[(r₁ - r₂) t] + C₂
x(t) = C₁ e^(r₁t) + C₂ e^(r₂t)

CASE 3: r = α ± iβ (the case for complex roots of the aux. equ.)
let r₁ = α + iβ, r₂ = α - iβ
e^[-(α - iβ) t] x = C₁' ∫ e^[(2iβ) t] dt + C₂
e^[-(α - iβ) t] x = C₁'/2iβ * e^[(2iβ) t] + C₂, (and let C₁ = C₁'/2iβ)
e^[-(α - iβ) t] x = C₁ e^[(2iβ) t] + C₂
x = e^[(α - iβ) t] * C₁ e^[(2iβ) t] + e^[(α - iβ) t] * C₂
x(t) = e^(αt) [ C₁e^(iβt) + C₂e^(-iβt) ]
(to make things a little more interesting still, convert this to sin and cos using Euler's formula! i'll have to do this in the next post anyway)
(hint: just call (C₁ + C₂) and (C₁ - C₂), C₁* and C₂*, respectively)

and there we go! 3 comprehensive solutions to ANY homogeneous linear D.E. with constant coefficients. but what if you have higher order derivatives and more roots in your aux. equ., you say? well, those can simply be handled like so:
CASE 1 will become:
x(t) = e^(rt) (C₁t² + C₂t + C₃), and so forth for more roots...
CASE 2 will (easily) become:
x(t) = C₁ e^(r₁t) + C₂ e^(r₂t) + C₃ e^(r₃t) ... for more roots
and CASE 3 you don't really have to worry about because you will never have complex roots that don't come in pairs (unless your coefficients are complex)

what'll really get you is more multiplicities in your roots! consider the equation:
(D² + 3D + 2)² x = 0, which you can write:
(D + 2)² (D + 1)² x = 0. the solutions for this turn out to be a combination of CASE 1 and CASE 2:
x(t) = e^(-2t) (C₄t + C₃) + e^(-t) (C₂t + C₁)
verify yourself!
the cool part is that, with practice, you should be able to solve these differential equations in 5 or 10 seconds in your head! amaze your friends! trust me, it's very fun :] all you need to know how to do is factor polynomials!

what about the following?:
(D² + 4D + 5)² (D² - 5D + 4)³ x = 0
well, it may take you more than 5 or 10 seconds to actually write it, but you should have no problem coming up with an answer very quickly!

also, something else to note as we go through these examples: always make sure the number of constants matches up with the order of differentials in your D.E.! if there is a 2nd order derivative in your D.E., you should have a C₁ and a C₂. this is, of course, easily understandable since you would normally have to do 6 integrations for a D.E. with a 6th order derivative, and thus giving you 6 constants of integration.

so there, i hope that this will completely resolve the question of how to solve the SHM equation and even some general solutions for a plethora of differential equations! enjoy! (challenge: solve the differential equation which governs a dampened oscillation!)

Tuesday, August 10, 2010

Y!A: Newton's Second Law

this was a very nice question and i actually enjoyed answering it very much! it is a conceptual and experimental derivation (or confirmation) of Newton's Second Law. i think the asker really enjoyed my response and gained a good base for understanding the law.


Q:
If work is: force x distance... as well as: mass x acceleration, how can I relate these two ideas and think of?
force? Okay - let's break it down - we multiply mass by acceleration to get a force, which makes sense. I can think of it as an acceleration per mass, which takes force (and hence energy supplied). But if I have W = force x distance or W = Fd, I can equivalently say: F = W/d. So force equals work done per unit of distance. Which makes sense to me if I think of the fact that the two equations I have pointed out here require energy, that is again: mg and W/d.

Am I over analyzing this too much, or how can I really understand force? What throws me off is that I have two different equations for force - one is a product of two variables and the other is a quotient of two variables. Why couldn't I say F = m/g?? Or also say: F = Wd????
Additional Details
or instead of F = m/a say:
F = a/m

A:
a good way to think about these things and really get a good conceptual idea for what these equations mean is to create examples for yourself. sure, they wont get you the exact form of the equation, but they'll give you a rough idea of what needs needs to go where (like why mass is *multiplied* by acceleration to get force).
so first, think of newton's equation F=ma. what this says is that in order to move an object of mass 'm' with an acceleration 'a', you need a force 'F' equal to their product. so how does this make sense? well it'll be easy once you think of a few examples that you run into in everyday life!

imagine you are trying to push (or pull) a box along the ground. in your experience, does it matter if the box is REALLY heavy? of course! if the box weighs 2000 pounds, there's no way you're going to be able to move (or accelerate) it! you would need a much larger force to push it along! so then in our formulation of newton's law, we know that if you *increase* the mass of the object, you should also have to *increase* the force it takes to move it, right? well that makes sense, and it seems kind of obvious now! because it is certainly easier to move a feather than it is to move car - and the car even has wheels! so where should we have to put the 'm' if we want 'F' to increase as 'm' increases? well, certainly not in the denominator! if we did that, the force would *decrease* as mass increased! now that would be a sight! so we know 'm' has to be somewhere in the numerator!

now onto acceleration. again, let's use something we're familiar with! let's look at that box again. let's say you want to get it going up to 1/12 of a foot per second (an inch per second) in 1 minute. so you have all of 60 seconds to accelerate this box to a final speed of an inch per second. do you really think it takes a huge amount of force to move something that slow (about 0.0014 ft/s² or 23000 times slower than the acceleration of gravity!)? no, your baby sister could easily do that! but what if someone told you that they need to get this box going 100 miles per hour in the span of 1 second. could you do it? is that even possible?! (assuming the box isn't moving when you start, that would mean the acceleration would be 147 ft/s², or about 4.6 times greater than the acceleration of gravity!). well yes it can be done, but could *you* do it? it's nothing personal, but i don't really think you - or anyone else for that matter! - is that strong. it would require some very massive force to do it! (keep in mind the best cars can go from 0-60 mph in about 3 or 4 seconds, which is pitiful compared to what i'm asking you to do! and they've huge 500hp motors to do it!). so the conclusion is that the bigger acceleration you want to give to the box, the bigger the force you have to impart on it will need to be! and we know - from the previous example - that this requires 'a' to be in the numerator! therefore, F=ma, and there's no other way it can go!

so there you go! this was a rather simple method, but the power of this analysis is incredible! see if you can apply the same thinking to your work/energy problem and get the correct answer!
remember, all that physics is trying to do is describe the world around you. so all you have to do in order to understand it is play around with it! it's right at your fingertips :]

so try this same method with the other problem and i think you'll be pleasantly surprised at how physics describes the world. and if you have any other questions, i'd love to help you out some more! :]
happy hunting!

Tuesday, August 3, 2010

Y!A: Power series

This was a question i very much enjoyed answering because many people have trouble with - and actually absolutely hate! - power series and convergence and whatnot. but it is exactly the opposite! i LOVED the subject! (don't even get me started on Taylor Series!) and so i feel that this is an area in which i can do a lot of good and help clarify some subjects that some people have trouble with and dislike for no good reason at all!

and i'll also say that one of things that i think makes this subject hard for some people is that it requires the ability to really understand the mathematics and be able to draw conclusions and meaning from the equations. this is something A LOT of people lack, and it is not even something that is emphasized in schools! and this is a terrible circumstance, which i battle frequently, and i hope that i am doing my part to give people this familiarity with mathematics which is really useful and, above all, FUN!

it is also good to see that the asker was very pleased by my answer, and i really hope i was able to make a difference in the way he/she thinks about these subjects.


Q:
Calculus: Power Series?
I thought that determining weather series converged or diverged was easy, but I seem to be having some problems figuring out how to do that with power series, so can you help me with this problem. Thanks :)

Find the interval of convergence for the given power series:

∑ (n=1 to ∞) [((x-9)^n) / (n(-7)^n)]

Additional Details [the asker posted this after someone else had posted a response with just the answer and nothing else. really pathetic in my opinion...]
I already knew that the answer was (2,16] so you haven't helped me at all. I want to see the steps taken to get to the answer because that is the part that I need help with.

A:
the key you need to solving this problem is to use the ratio test. most of the time, the ratio test will get you the answer you need to convergence problems.
if you recall, the ratio test is the limit (as n approaches ∞) of the absolute value of the ratio of the n+1th term to the nth term of the sequence. or in a different language:
lim(n-->∞) | (a_n+1) / (a_n) |

in this case, the nth term of your sequence is a_n = (x-9)ⁿ / n*(-7)ⁿ.
it follows that the next term (the n+1th term) is a_n+1 = (x-9)ⁿ⁺¹ / (n+1)*(-7)ⁿ⁺¹.
it also happens that our sequence is a function of another variable (x), but this is of no consequence when we consider a limit whose parameter is n (and n and x are in no way related).

so now we need to take the ratio of these as n goes to infinity. we write:
lim(n-->∞) | [ (x-9)ⁿ⁺¹ / (n+1)*(-7)ⁿ⁺¹ ] / [ (x-9)ⁿ / n*(-7)ⁿ ] |
this looks ugly, so we simplify the fractions:

lim(n-->∞) | [ n*(x-9)ⁿ⁺¹ (-7)ⁿ ] / [ (n+1) (x-9)ⁿ (-7)ⁿ⁺¹ ] |
as you can see, some nice things cancel here (since Aⁿ⁺¹ = Aⁿ A¹)

[at this point i highly suggest you write this out as you read it because it become much easier to read and see for yourself what i mean]

now that we've cancelled, our limit looks as follows:
lim(n-->∞) | n*(x-9) / (n+1)*(-7) |

now, if we wish (and we do), we can take things which do not depend on n out of the limit.
notice that x-9 does not depend on n (it only depends on x) and -7 doesn't really depend on anything (especially n!) so we can take these both out of the limit. but the absolute value signs stay on! (don't forget those!)

so, our limit now looks like this:
|(x-9)/(-7)| lim(n-->∞) | n / (n+1) |

the next step is to evaluate this rather simple limit. note also that you can just take those absolute value signs right off of the n/(n+1). this is because everything inside them is guaranteed to be positive, so the signs are superfluous. (but don't take them off of the (x-9)/(-7)! those aren't guaranteed to be positive!)
so, we know that n/(n+1) approaches 1 as n approaches infinity, and so the value of the limit is 1.

our expression now looks simply like:
|(x-9)/(-7)|
now, i've been neglecting it, but the point of the ratio test is to see of the value of the ratio is less than 1 because this is where the series converges (and don't forget that it is inconclusive when it equals 1!)

so we really have to solve this problem:
|(x-9)/(-7)| < 1
also note that that -7 on the bottom can be written as just a 7 and taken out of the absolute value signs. (because |-7| = 7)
so now let's solve
|x-9| / 7 < 1
|x-9| < 7
as you know, you can write this 2 ways and get rid of the absolute value signs as:
x-9 < 7, -(x-9) < 7
solving these (finally), we get:
x < 16, x > 2
(don't forget that when you multiply by a negative in an inequality, you flip the sign)

so we're done right? almost. remember that the ratio test inconclusive when it equals 1. so we have to manually check those possibilities. we do this by checking convergence of the original series at a particular value of x. recall the original series:
∑ [ (x-9)ⁿ / n*(-7)ⁿ ]
the 2 we have to check now are x = 16 and x = 2. notice that at x = 2, the (-7)ⁿs cancel on the top and bottom and you are left with 1/n. as you should know, ∑ 1/n diverges. so, x = 2 does not yield a series which converges.
at x = 16, you get a different series. i'll actually leave it to you to check this one for convergence (hint: use the ratio test again). but if you have problems with it, just let me know, and i'll walk you through it again.

i hope this has helped! and i'm always happy to answer more questions if you have any :]

Y!A: Heisenberg's principle

this is a question i answered about basic knowledge of Heisenberg's principle. but i also tried to give the asker a good background on the subject and even a nice illustration of the meaning of the results at the end.


Q:
At a baseball game, a radar gun measures the speed of a 140 g baseball to be 137.32 ± 0.05 km/h.
(a) What is the minimum uncertainty of the position of the baseball?
answer in m

(b) If the speed of a proton is measured to the same precision, what is the minimum uncertainty in its position?
answer in m

please help me out i'm stuck it would be greatly apprieciated if you help me out..thanks


A:
a ) here you need the relationship between uncertainty in position and uncertainty in speed. unfortunately, no such one exists, but there's an equally useful one which relates uncertainty in position to uncertainty in momentum. it is one of Heisenberg's equations:
∆x * ∆p ≥ ħ/2
(where ħ is "h-bar" or h/2π)
(and ∆ means "uncertainty in")
it is good then that you are given the mass of the ball, so that p can be written as mv, with those 2 values given in the problem.

now, all that is left to do is solve for ∆x (or the uncertainty in position):
∆x ≥ ħ / (2*∆mv)
note that since there is no uncertainty in the mass, we can take it out of the ∆ operator - not a necessary step, but still worth noting.
∆x ≥ ħ / (2m*∆v)

so now all we have to do is plug in our known values for m, ∆v, and ħ (in the correct mks units, of course)
m = 140 g = 0.140 kg
∆v = 0.05 km/hr = 50 m/hr = 0.0139 m/s
ħ = 1.0546 * 10^-34 J*s = 1.0546 * 10^-34 kg*m²/s

thus we have:
∆x ≥ (1.0546 * 10^-34 kg*m²/s) / (2 * 0.140 kg *0.0139 m/s)
cancelling units and evaluating, we get:
∆x ≥ 2.71 * 10^-32 meters <<<<<<<<<<<<<<< (answer part a)

you'll notice that this is so small, it is not even perceptible - or anywhere near that! that is why you don't notice this phenomenon while watching a game of baseball.


b) for this problem, we need the same uncertainty relationship. ∆v is again 0.05 km/hr (or 0.0139 m/s). and the mass of the proton can be looked up and is approximately 1.6726 * 10^-27 kg (much much smaller than the baseball)
starting again with the basic relationship
∆x * ∆p ≥ ħ/2, and rearranging:
∆x ≥ ħ / (2m*∆v)
plugging in values exactly the same as last time:
∆x ≥ (1.0546 * 10^-34 kg*m²/s) / (2 * 1.6726 * 10^-27 kg * 0.0139 m/s)

again, all we are left with is meters, and the value of the expression is
∆x ≥ 2.269 * 10^-6 meters <<<<<<<<<<< (answer part b)


although this is still relatively small, it is many many many orders of magnitudes larger than the ∆x of the baseball.
consider also that it is roughly 2.27 * 10^-6 meters (2 micrometers). it is interesting to see this value compared to the approximate size of of an atom, which has a diameter of roughly 100 PICOmeters (a picometer is 10^-12 meters. or 100 of them is 10^-10 meters).
so the uncertainty in the position of this moving proton is almost 4000 times larger than the diameter of an atom!! so forget about it if you wanted to pinpoint the location of this particular proton among other atoms.

i hope this was helpful! and i'm always happy to answer more questions :]

Thursday, May 27, 2010

Y!A: time and relativity

an interesting question from Y!Answers about Einstein's relativity and the constant nature of time. this was a nice conceptual question to answer, which is refreshing from time to time.
i also very much enjoy helping people (especially those who have not had much exposure to the topics) about these complicated subjects in ways that are easy for anyone to understand. i find this is often difficult, but it is an extremely worthwhile endeavor. and nothing beats a strong conceptual understanding base from which to build your knowledge of a subject - it is immensely useful. so that is what i tried to give when answering this question...


Q:
How do we know that time is what is what we believe it to be?
Basically I would like to know whether time is what class it as i.e. that how do we know that a second or an hour lasts the duration that we say a second or an hour lasts. Also will the strength of gravity change the speed at which time travels (and if so is time therefore not a constant and as Einstein said only "Relative") I hope that makes sense I'm not really fully sure what I mean myself, i know that the theory of relativity says that space and time are relative but relative to what?

A:
a second or an hour lasts as long as it does because that is the way that we defined it. for example, a second is defined (in modern terms) as the time it takes light to travel 299,792,458 meters. other modern measurements include the time it takes cesium-133 to radiate a certain number of times.
in other words, the universe did not invent the duration of the second, we did. we are using universal constant to define it now, which will never vary so that we can accurately measure time in any circumstance!

regarding your gravity question, no the speed of light will never vary! but it is interesting that you brought this up! let's analyze this situation. if we have light traveling against a gravitational field, the light will need to expend or lose energy. however, the energy it loses will not come out of its speed, but rather, its wavelength. there is a property of waves which relate their wavelengths (or frequencies) to their energy. so, light will expend energy from its wavelength rather than its speed to travel in a gravitational field. this will result in the wavelength of light getting longer or shorter (depending on which way it is traveling) and also changing its apparent color! (this property is partially responsible for the phenomenon known as red-shifting).

yes, einstein's theory of relativity states that everything is relative, well almost everything (the exception being light). the actual title of his paper on what we now call 'special relativity' was actually called something along the lines of "On the Invariance of the Speed of Light", which tells us what einstein really had in mind when he was developing his theory.

in any case, in order to illustrate this 'invariance', we'll look at two similar examples (which i'm sure you may have seen before):
example 1:
you are at one end a train which is moving at a constant velocity, let's say 30 km/hr. and your friend is standing at the other end (let's say he's at the front and you're at the back of the train). now, you have a frisbee and you throw it to your friend at 5 km/hr. both you and your friend see the frisbee traveling at 5 km/hr. however, an observer who is outside the train (on the ground) will observe the frisbee traveling forward at 35 km/hr! (and the train is still moving at 30 km/hr to him as well).
so how is it possible that we have 2 different measured speeds for an object? is the object actually traveling at 2 different speeds? is there an objective way to measure the absolute speed of an object, such that it has one speed all the time? this is where einstein comes in! einstein said that there is no way to objectively measure the speed of the frisbee. he says that it's speed is always measured relative to some other stationary object. for you and your friend, you measured the speed relative to the train (which you considered stationary because you were in it). for the outside observer, he measured the speed relative to the ground (which was stationary to him). (also, imagine the apparent speeds and path that the frisbee would seem to travel to someone on mars or on the moon! they would be very complicated indeed!)

now, example 2:
you are again on a train moving at a constant velocity, 30 km/hr again. but this time, you have a flashlight instead. so, from inside the train, you turn on your flashlight and you observe the light coming out the end of it. this light is traveling at a velocity c (about 300,000 km/sec). and this light will hit the front wall of the train in some time t (based on the length of the train). now, there is also an observer who is outside of the train. at what speed does he see the light travel? does the light travel at 300,000 km/s + 30 km/hr? no! again, einstein comes in and says that the light will travel at the same apparent speed regardless of the observer! so, the light will travel at c, but how long will it take to strike the end of the train? will it be the same time t? well this is a complicated answer, and this gives rise to the phenomenon known as time-dilation. this states that in order for the speed of light to be kept constant (to any observer), time will actually shorten to allow light to make the distance.

so, in short, what einstein is saying is that space and time (and velocities) are relative to their observers. however, the speed of light (the universal constant) is the only thing which will never vary (due to complex phenomena like time dilation and many others).

i know that i have introduced a lot of complicated topics here, and i hope that i haven't confused you (relativity is a very confusing topic anyway). but i hope that you've gained something from this!

please ask questions if i wasn't clear about something (which is likely the case haha)!

Wednesday, April 21, 2010

Y!A: College Algebra Question

this is another question that i answered on Y!Answers, which can be found at this url:


Q:
John owns a hotdog stand. He has found that his profit is represented by the function p(x)=-x^2+66x+81, with p(x) being profits and x the number of hotdogs sold. How many hotdogs must he sell to earn the most profit.

my answer would be a million bajillion hot dogs lol. but my answer key says 33. help please

A:
haha yes, it would be nice if he could sell a million bajillion hot dogs, but look at your equation, do you notice that -x^2 term? that means that when he sells a lot of hot dogs, he'll be subtracting that huge number squared from his profits! that's really really bad for his profits!

also, if you'll notice, the formula for his profits is the equation of a parabola! not just any parabola, but one that is opening downwards. this means that there is maximum height that his parabola reaches, corresponding to his maximum profit, which makes this a maximization/minimization problem!

now, all that analysis aside, here's how you solve it:
since the slope (derivative, in other words) of his profits curve (the parabola) is zero at its maximim, we can take the dervative of the profits curve and set that equal to zero to solve the number of hot dogs:

P(x) = -x^2 +66x +81
so the derivative, P'(x) is
P'(x) = -2x +66
now we set that equal to zero (for the reasons mentioned above),
0 = -2x + 66
and solve for x (the number of hot dogs),
2x = 66
x= 33
voila!

to solve these problems in the future, try to analyze the problem as i did in the first two paragraphs. this will really help you get a grasp of the mathematics, and make solving these kinds of problems a breeze

Sunday, April 4, 2010

Y!A: BIGGER IS ELECTRICITY!

this is a question i answered for some guy on Y!Answers who had this CRAZY theory that gravity was somehow based on electromagnetism and the E&M forces were somehow giving rise to mass... and some weird other stuff. (i think he was trying desperately to unify E&M and gravity, but not succeeding very well! oh well, at least he's got GUTS!). but i answered his question to try to give him some idea of why that wouldn't work, and so i thought i'd post it.
[also note that at some point before i answered there were some other responses which he apparently got rather peeved about, and he responded in the "Additional details section". so that's what that is in case you were wondering. and i did not include the other responses, but his additional explanation was, at the least, interesting and relevant, so i included that.]

http://answers.yahoo.com/question/index;_ylt=Aqg4W49nJOBNV0qoLYrfJ8Pty6IX;_ylv=3?qid=20091019134800AAooDPq&show=7#profile-info-UMVkZmYOaa

Q:
How does gravity really work?
I just want to know if there is a DEFINITE theory or property that says how gravity works. We know it is there, we know certain properties, but how EXACTLY does it work. I have asked around a little, and nobody knows. I have my own little thought that i think is wrong, however if so, i want somebody to prove me wrong. What if gravity is actually a subset of the force of electromagnetism. We know for a fact that atoms have charges (or at least ions do) but even when they are neutral, they still have charges, they just balance each other out. What if these charges of the protons and electrons still individually have a field/charge of their own that is able to reach out to other atoms. Meaning, that if you have one pos magnet, and on neg magnet, they would attract. However, if you have 10 magnets trying to pick up 10 other magnets, the force is much greater. Same goes with gravity, the more mass/matter you have, the stronger the force of gravity. So my question is, can gravity be a subset or sub-something of electromagnetism? it seems to have similar properties to it, just molded and applied differently.

Additional Details
No, sorry, apparently, people didn't get what i'm saying. I didn't say that you need an electric charge for gravity to work, i said you need mass. How this mass has gravity? i said the electric charges FROM THE PROTONS and ELECTRONS that make up this mass have a charge, and these charges COULD induce gravity e.g. the more matter/mass you have, the stronger the gravitational/magnetic pull. And please don't say this is not possible just because there is another theory saying gravity is already this, that. Ignore those theories, or better yet, incorporate this one, and say if it is possible that gravity is caused by these charges at the molecular (and maybe smaller ) level. Basically can gravity be a subset of MAGNETISM, not electromagnetism, and don't say it is not because modern science says so.

A:
i think i understand what you are saying. here goes:

are you trying to just identify an analogy between electromagnetism and gravity, or are you trying to say that gravity is created by some charges (whether they are on a charged particle or even inside a neutral one, like a neutron)?

judging by your reaction to the first two posts, i'm going to guess that you don't mean the second.

if this is the case, you are right in your thinking when you said that "the more matter/mass you have, the stronger the gravitational/magnetic pull is". this is a good analogy. in electromagnetism, the more charge you have, the bigger the electric/magnetic pull is; similarly, in gravitation, the more matter/mass you have, the more pull there is. if this is all you are trying to identify, you are correct.

however, there is no correlation between how much charge there is inside the atom (or particle) and how much gravitational attraction it experiences.
for example, let's consider a proton and a neutron. they have almost exactly the same mass, but there is no charge on the neutron and there is a +1 charge on the proton. no matter how much charge is on these two particles, they will still exhibit exactly the same gravitational pull.
let's look at another example on the atomic scale.
let's say you have some heavy atom - let's say it's Krypton for now. Krypton has 36 protons, 36 electrons, and 48 neutrons (in one of it's most stable isotopes). we'll call this Kr-84 (for it's mass number). now let's also consider an ion of Kr with all of its electrons stripped away, which would also be Kr-84. if we were to put both of these atoms in a stable environment with one other insignificant mass, they would both feel exactly the same gravitational attraction to it (because the masses of both Kr atoms are the same).
however, consider a similar scenario. if we place both of these atoms again in a controlled environment with one electron, the Kr ion would feel a very large attractive force towards it. on the other hand, the Kr atom (with all 36 of its electrons) would feel no attractive or repulsive force (assuming it was far enough away such that the electrons on the outside of the Kr atom won't repel the electron much more than its protons will).

as you can see, there is no correlation between how much charge an atom (or particle) has and how much gravitational force it experiences. although your theory is very innovative and cleaver, we did not find that the gravitational attraction increased when the charge increased.

note that this is true for magnetic as well as electric charges, but it is just much more difficult to give an example for magnetism because you can never have an isolated magnetic charge.

i hope this answers your question about your theory of gravity! although it is not correct in this case, i would still write to einstein to see if he has any ideas on it :P!


but to answer you first question about the theory of gravity, we still do not know exactly how gravity acts and behaves. physicists today are working very vigorously on this problem and we have an idea of what it should be like.
first of all, there is a theory in physics (more specifically, particle physics) which states that every force is carried by a particle (this law is called the force-particle duality). in electromagnetism's case, it is the photon; the strong nuclear force is carried by the gluon; etc... . if you do not know much about modern particle physics, some of these ideas may seem very foreign and strange to you, but i'll give them to you anyway.
in the case of gravity, the supposed particle which carries the force is the graviton. although this particle has yet to be observed, most physicists agree that it exists, and have many complicated theories as to why we haven't observed it yet.
this being said, the gravitational force is still a mystery to most. the common theory is still einstein's theory of general relativity, which states that matter in space puts a curve in the fabric space-time (which we cannot visualize very well - actually, it is also extremely difficult to visualize the shape of space itself!). then, it is this curvature which brings bodies together under the force of gravity.

now, it is interesting to think about why more matter creates a bigger curvature in space. this is the theory of why matter has mass, and it is also related to the theory of gravity. this is what most physicists have their eyes on now and we are currently testing a theory based on the Higgs boson, which is supposed to be the particle which gives all matter mass.
you may not be very familiar with these concepts, but i'm giving them to you just in case you are!

this may not answer your question of a definite theory of gravity, but keep in mind that today's most brilliant physicists are almost as dumbfounded as the rest of us about the nature of gravity.

hope this helped though (at least the first part about your theory)! any other questions about what i said?

Sunday, March 7, 2010

collatz conjecture

So, I found out about this conjecture known as the 'Collatz conjecture'

It states the following: take any natural number, n. if n is even, divide it by 2 (n/2). if n is odd, multiply it by 3 and add 1 (3n + 1). Repeating this process over and over will eventually get you 1.

(Search it on wikipedia if you don't know it)

So, doing this for, say, n = 9, gives this:

9 -> 28 -> 14 -> 7 -> 22 -> 11 -> 34 -> 17 -> 52 -> 26 -> 13 -> 40 -> 20 -> 10 -> 5 -> 16 -> 8 -> 4 -> 2 -> 1 -> 4 -> 2 -> 1 -> 4 -> 2 -> 1


Now, initially this seems pretty interesting, and indeed it is!
Do it for a few more numbers (larger ones perhaps. although it's worth noting that a small number such as 9 got all the way up to 52!) and you'll see what i mean. It ALWAYS goes to 1, eventually!

This is actually an unsolved problem in pure mathematics, which I was surprised to find out. (Paul Erdos actually offered a $500 prize for the solution).

Like i was saying, it seems really complicated and important at first, but i'm not really sure it is.


----------------------------------------------------------------------------------------------------


Here's my take on it.
(Also, keep in mind that I'm not a degreed mathematician or anything like that. Tthis is just me thinking)


Again, the conjecture states that, for any natural number n, do the following: if n is even, divide it by 2; if n is odd, multiply it by 3 and add 1. Repeating this process over and over will eventually get you 1.

You'll notice pretty quickly (it really only takes two or three runs of this algorithm to do so) that if we reach a power of 2, we're done pretty quickly, because we just keep dividing down by 2 until we hit 1.

So the question really is this (or can be stated as):
how long before we hit a power of 2?

It seems reasonable enough to me to think that given some arbitrary algorithm, you will eventually reach an equally arbitrary goal (assuming they're not contradictory, such as starting with an odd number and adding 2 until you reach an even number).
since 3n + 1 can reach odd numbers and even numbers, there is no reason it shouldn't reach a power of 2 at some point. that is to say, there's no reason that multiplying by 3 and adding 1 shouldn't eventually reach a power of 2 (ie they're not contradictory statements. For example, multiplying instead by 2 and adding 1, and reaching a power of 2 would obviously be contradictory statements). it would seem that the only thing that would need to be proved - if anything - is why that is true.

Consider the following:
Given any natural number:
If the number is not prime, divide it by its smallest prime factor;
If the number is prime, multiply it 2 and add 1, then go eat a cheeseburger.
(If, by chance, you get to 1, consider it prime. I say this just so this process is defined for every natural number.)

It is my contention that any number chosen will, after repeating this process, eventually converge at some small number (such as the 1 for Collatz); it turns out to be 3 for this problem (and indeed it does reach 3 every time). Also, you will soon become very fat.


(You can also see that it does here; and feel free to copy or rewrite this code and try different numbers for yourself):



You can also see that once it reaches 3, it will cycle back up to 7, and reach 3 again. This is much like the Collatz problem, in which it cycles 4-2-1-4-2-1-4-2-1, but never really stopping.



So does this question deserve as much, if any, attention as the collatz problem? Keep in mind, I just pulled this thing out of my rear-end.
Well, it actually seems harder to analyze than the collatz problem! As far as i know, it's much harder to put into an algorithmic form similar to the one for the collatz problem
(which is:
f(n) = n/2 (if n = 0 [mod 2]), 3n+1 (if n = 1 [mod 2])
)

The answer to me seems to be no, we shouldn't really spend much time analyzing this 'truly mysterious phenomenon'.

While, yes, it is very interesting (and fun to play with!), i don't see what the big deal is!

The Collatz problem says pretty much the same thing as 'if we take a number, and do some arithmetic to it, how long does it take until we get to a power of 2?' Actually, not even that, it only asks if we get to a power of 2, not even how long, or how many iterations. Kind of boring, no?
Actually, the 3n+1 just turns an even number into an odd number, and an odd number into an even number! and the n/2 will turn n odd or even. also note that this way, every odd number becomes even.
so we go... iterating...
odd.. even... even... even... odd... even... odd... even... even... odd... POWER OF 2!! YAY!! done!


All in all, this seems more like a statistics problem to me - seeing how long it takes to get a power of 2. Maybe it is interesting in analyzing some properties of the natural numbers; like the density of powers of 2, or even numbers or something like that. But again, don't we already know that? We know the density of powers of 2 because we have an algorithm to get powers of 2 (hint: start with 2 (or 1), multiply by 2). It's not like the density of primes, which we don't know (although we can approximate the number of primes with the prime-counting-function, which approaches ln(n) minus a small constant for sufficiently large n).

Also, notice that it doesn't matter how large these numbers get. You could iterate a thousand times and get a number in the trillions! but still, once you hit a power of 2, you come tumbling down to 1 very quickly. Granted that the powers of 2 are very sparse in the trillions, there is no way that you are going to stay up in the trillions for long, seeing as you are bound to encounter a number which is divisible by 4 or 16 or 256 soon, and come tumbling way down with the n/2 - try it.

In conclusion, it seems to be an arbitrary problem to me! Given an infinite amount of time and iterations, will this algorithm make power of 2, if you keep giving the algorithm even numbers?


But what do you think?
Is this a trivial problem?
(Also keep in mind that Paul Erdos thought this was a very difficult and complex problem. Ohhhh Paul Erdos! Are you intimidated? Can you feel your opinion changing?)

Wednesday, February 17, 2010

Y!A: What is the Taylor series of ln((x^2)+1) centered at c=0?

this is a question i answered on Y!Answers and can be found here:

http://answers.yahoo.com/question/index;_ylt=AmsLM3qKuCKKGf8_wa161Zfty6IX;_ylv=3?qid=20090426105041AA1f5lh&show=7#profile-info-2AVjODBNaa

there are two ways you can do this:

the first is by deriving the taylor series directly. however that involves a lot of messy product rules for derivatives in this case (but i will start it for you anyway).

the second is to use substitution and integration.

THE FIRST METHOD:
you would write normally, as if you were deriving a taylor series:
f(x) = a
+ a
x + ax² + ... = ln(x² + 1)
but you can see that when we differentiate both sides, ln(x² +1) yields confusing derivatives. so, i will use a different, smarter method.

THE SECOND METHOD:
the first thing i will do is take a known taylor series, and later manipulate it:
the taylor series for f(x) = 1/(1-x) is known to be 1 + x + x² + x³ + x+ ...
so i will take f(-x) = 1 / (1 - (-x) ) = 1 / (1+x)
for which the taylor series becomes: 1 - x + x² - x³ + x - ... (plugging in -x everywhere for x)

next, i integrate 1 / (1+x) and its taylor series:
ln(1+x) = C + x - (x²)/2 + (x³)/3 - (x)/4 + (x)/5 - ...
(and we can eliminate C now by plugging in 0 for x and getting ln(1) = C = 0)

now, using some substitution, take our new function g(x) = ln(1+x) and its taylor series, and substitute x² for x. that is, g(x²) = ln(1 + x²), and its taylor series becomes (x²) - ((x²)²)/2 + ((x²)³)/3 - ((x²))/4 + ((x²))/5 - ... (placing x²everywhere that we see an x), which equals
x² - (x)/2 + (x)/3 - (x)/4 + ...

thus ln( 1 + x² ) = x² - (x)/2 + (x^6)/3 - (x)/4 + (x^10)/5 - ...
and in general form:
(-1)ⁿ⁻¹ * x²/n
[from n=1 to ]

though this method seems very confusing, it will get easier and more natural with practice. the trick to picking the correct initial function will also come with practice and your familiarity with taylor series.

i hope this wasn't too confusing!