PHYSICS 360 Problem Set #1: "Basic Numerical Mathematica Manipulations" Due 9/11

 
Problem 1: 20pts Numerical Summation of Series
A) The Geometric series.  I want to find an appropriate numerical approximation of the following function:
S(a) = 1 + a + a*a + a* a* a + a*a*a*a + ... 
The sum indicated continues forever, but in a computer it is only possible to keep a finite number of terms in the series.  Let the function:
SApproximate(a,nmax) = 1 + a + a^2 + ... + a^(nmax).
The question is, given a, how big should nmax be in order to ensure that the series is approximated to one part in a million, that is, one part in 10^(-6).  Make a plot of the required nmax vs. the value of a for -1 < a < 1.  Based on your answer, where is it "easy" to sum the series, and where is is "hard" to sum the series?  That is, where do you have to include more terms to get the approximation, and where can you use fewer terms.  Are there any values of afor which the finite approximation SApproximate(a, nmax) gives an exact answer for S(a), the whole infinite series?
B) A different series.  Again, I want to find an appropriate numerical approximation to the following series:
S = 4 - 4/3 + 4/5 - 4/7 + 4/9 -4/11 + 4/13 + ...
How many terms are required to determine S to within one part in 10^(-4)? 
Extra:  The student who manages to correctly determine S to the most decimal places gains an extra ten points on the problem set.

 
Problem 2: 20 pts Symbolic Summation of Series
A) Get a general formula for the approximate geometric series SApproximate(a, nmax) using the mathematica-built-in function Sum.  What is the exact answer for the infinite series, S(A)?  In 1(A) you found some places in -1 < a < 1 where convergence of the finite series was extremely difficult.  From the analytic form of S(a), can you hazard a guess as to what the numerical problem is?
B) Again, try to use the built-in mathematica function Sum to determine the value of S in 1(B).  How close were you able to get to the infinite sum result in your numerical work in 1(B).  Compare the relative efficiencies of the two series, S(a) and S. Which one converges "quickest"?

 
Problem 3: 20 pts Numerical Solution of Equations.
A) This problem may sound like it is full of arbitrary functions, but there is a physical content to these manipulations that will become clearer later in the course.  For the moment, we can just look on them as exercises in numerical equation solving.

t*u == Tanh[u] 

is a simple enough equation to write down, but solving this equation for u is not possible with the elementary trigonometric functions (try it!).  Here, t is an adjustable parameter, and we want to find all values of uwhich make the equation true for a given t.

Using FindRoot, define a "delayed definition function" that will tell you the value of u which satisfies this equation for a given t.  Plot :

t*u[t] vs. t for 0 < t < 2.

Where are the "special" values of t at which the solution changes character?

B) Do the same as in A) but this time solving the equation:

t*u == -1/u + 1/Tanh[u],

for 0< t < 2.
Again, where are the special values of t at which the solution changes character?
Here, the student who determines the "special" point to the most decimal places will receive 10 bonus points.


 
Problem 4: 20 pts Trigonometric Identities, and Replacement Rules.
A) Use any method you like to verify these formulae explicitly (either numerically or analytically)
Cos[x]^2 + Sin[x]^2 =1
Cos[a+b] = Cos[a]*Cos[b] - Sin[a]* Sin[b]
Sin[a+b] = Sin[a]*Cos[b] + Cos[a]*Sin[b]
Cosh[x]^2 - Sinh[x]^2 =1
Cosh[a+b] = Cosh[a]*Cosh[b] + Sinh[a]* Sinh[b]
Sinh[a+b] = Sinh[a]*Cosh[b] - Cosh[a] * Sinh[b]
Cos[x/2] = Sqrt[ 1 + Cos[x]/2]
Sin[x/2] = Sqrt[ 1- Cos[x]/2]

 
Problem 5: 20pts Damped Oscillations
A) Consider a damped oscillator.  That is, the body is connected by a spring to the origin, and experiences a drag-froce proportional to its velocity.  Lets assume that all motion is along the x-axis.  The free-body diagram and equation of motion for the object is:
Show that rescaling of the time variable puts Newton's second law for this particle into the following form: x''[t] + b' x'[t] + x[t] =0.  Tell me explicitly, in terms of b, m, and k, what is the formula for b'?  Try a "trial" solution for x[t] of the form x[t] = Exp[a*t].  What values of a ensure that your "guess" actually solves Newton's second law for this problem?  There are two possible solutions for a, here, a1 and a2.  Therefore, a general solution to these equations is a linear combination:
x[t] = c1* Exp[a1*t] + c2* Exp[a2*t]
Lets suppose that x[t=0] = 1, and x'[t=0] =0.  Find the values of c1 and c2 which ensure that these values are obtained.  Make several plots of x[t] for these values of b'
b'= 0.1, 0.5, 1.0, 1.5, 2.0, 2.5, 3.0, 4.0
Again, are there any special values of b'?  What happens to a1 and a2 when b'= 2.0, b'<2.0, b'>2.0?  Functionally, what is the qualitative difference in x[t] that happens at this special value of b'?
B) Do the same problem as in A) but this time assume that x[t=0] =0.2, and x'[t=0] = 1.