4th order Taylor approximation

baseballfan_ny
Messages
92
Reaction score
23
Homework Statement
Get a 4th order taylor approximation for $$ f(p) = (1 + \frac {p^2} {m^2c^2})^{\frac 1 2} $$
Relevant Equations
$$\sum_{n=0}^\infty \frac {f^{(n)}(a) (x-a)^n} {n!}$$ around a = 0
So I just followed Taylor's formula and got the four derivatives at p = 0

##f^{(0)}(p) = (1 + \frac {p^2} {m^2c^2})^{\frac 1 2} ##
##f^{(0)}(0) = 1 ##

## f^{(1)}(p) = \frac {p} {m^2c^2}(1 + \frac {p^2} {m^2c^2})^{\frac {-1} 2} ##
## f^{(1)}(0) = 0 ##

## f^{(2)}(p) = \frac {1} {m^2c^2}(1 + \frac {p^2} {m^2c^2})^{\frac {-1} 2} - \frac {p^2} {m^4c^4}(1 + \frac {p^2} {m^2c^2})^{\frac {-3} 2} ##
## f^{(2)}(0) = \frac {1} {m^2c^2} ##

## f^{(3)}(p) = \frac {p} {m^4c^4}(1 + \frac {p^2} {m^2c^2})^{\frac {-3} 2} - \frac {3p^3} {m^6c^6}(1 + \frac {p^2} {m^2c^2})^{\frac {-5} 2} ##
## f^{(3)}(0) = 0##

## f^{(4)}(p) = \frac {1} {m^4c^4}(1 + \frac {p^2} {m^2c^2})^{\frac {-3} 2} +... ## (terms that are 0 when p = 0)
## f^{(4)}(0) = \frac {1} {m^4c^4} ##

Now that would give me $$ f(p) = 1 + \frac {p^2} {2! m^2c^2} + \frac {p^4} {4! m^4c^4} $$
$$ f(p) = 1 + \frac {p^2} {2m^2c^2} + \frac {p^4} {24m^4c^4} $$

But that's not right. The answer key has the following answer (and so does Wolfram) $$ f(p) = 1 + \frac {p^2} {2m^2c^2} - \frac {p^4} {8m^4c^4} $$

A picture of the answer key soln is below. Ignore the factor of ##Mc^2## outside the approximation.
1620333257276.png


I noticed that the answer doesn't even get any of the derivatives equal to 0, and I was getting all the odd derivatives equal to 0. That makes me think I'm applying Taylor's formula incorrectly and it's more than just an algebra mistake?
 
Physics news on Phys.org
Can you check your ##f^{(3)}(p)\ ## ?

Another comment: looks as if the expansion can be done with ##p^2## as a variable (as opposed to ##p##)...

##\ ##
 
  • Like
Likes baseballfan_ny and FactChecker
Taylor expand ##\sqrt{1+x}## to second order in ##x##. Set ##x= p^2/(mc)^2##.
 
  • Like
Likes baseballfan_ny, Mark44 and FactChecker
Homework Statement:: Get a 4th order taylor approximation for $$ f(p) = (1 + \frac {p^2} {m^2c^2})^{\frac 1 2} $$
Relevant Equations:: $$\sum_{n=0}^\infty \frac {f^{(n)}(a) (x-a)^n} {n!}$$ around a = 0

So I just followed Taylor's formula and got the four derivatives at p = 0
. . .

. . .
Now that would give me $$ f(p) = 1 + \frac {p^2} {2! m^2c^2} + \frac {p^4} {4! m^4c^4} $$
$$ f(p) = 1 + \frac {p^2} {2m^2c^2} + \frac {p^4} {24m^4c^4} $$

But that's not right. The answer key has the following answer (and so does Wolfram) $$ f(p) = 1 + \frac {p^2} {2m^2c^2} - \frac {p^4} {8m^4c^4} $$
. . .
I agree with @BvU .
Looks like you missed or messed up the product rule in differentiating the second term in your expression for ## f^{(2)}(p) ##.
## f^{(2)}(p) = \frac {1} {m^2c^2}(1 + \frac {p^2} {m^2c^2})^{\frac {-1} 2} - \frac {p^2} {m^4c^4}(1 + \frac {p^2} {m^2c^2})^{\frac {-3} 2} #### f^{(3)}(p) = \frac {p} {m^4c^4}(1 + \frac {p^2} {m^2c^2})^{\frac {-3} 2} - \frac {3p^3} {m^6c^6}(1 + \frac {p^2} {m^2c^2})^{\frac {-5} 2} ##
A couple of suggestions have been given to you.

You might also want to consider that your expression for ## f^{(2)}(p) ## can be significantly simplified.

I have that ##\displaystyle f^{(2)}(p) = \frac {1} {m^2c^2}\left(1 + \frac {p^2} {m^2c^2}\right)^{ \frac { {-3} } {2}}##
 
Last edited:
  • Like
Likes baseballfan_ny
BvU said:
Can you check your f(3)(p) ?
I definitely messed something up, but I keep getting that that ##f^{(3)}(0) = 0##.

$$ f^{(2)}(p) = \frac {1} {m^2c^2}(1 + \frac {p^2} {m^2c^2})^{\frac {-1} 2} - \frac {p^2} {m^4c^4}(1 + \frac {p^2} {m^2c^2})^{\frac {-3} 2} $$

$$ f^{(3)}(p) = \frac {-1} {2} \frac {1} {m^2c^2}(1 + \frac {p^2} {m^2c^2})^{\frac {-3} {2}} \frac {2p} {m^2c^2} - \frac {2p} {m^4c^4}(1 + \frac {p^2} {m^2c^2})^{\frac {-3} {2}} - \frac {p^2} {m^4c^4} \frac {-3} {2} (1 + \frac {p^2} {m^2c^2})^{\frac {-5} {2}} \frac {2p} {m^2c^2} $$

$$ f^{(3)}(p) = - \frac {p} {m^4c^4}(1 + \frac {p^2} {m^2c^2})^{\frac {-3} {2}} - \frac {2p} {m^4c^4}(1 + \frac {p^2} {m^2c^2})^{\frac {-3} {2}} + \frac {3p^3} {m^6c^6} (1 + \frac {p^2} {m^2c^2})^{\frac {-5} {2}} $$

$$ f^{(3)}(p) = - \frac {3p} {m^4c^4}(1 + \frac {p^2} {m^2c^2})^{\frac {-3} {2}} + \frac {3p^3} {m^6c^6} (1 + \frac {p^2} {m^2c^2})^{\frac {-5} {2}} $$

which still vanishes when p = 0.

SammyS said:
You might also want to consider that your expression for f(2)(p) can be significantly simplified.

I have that

How did you make that simplification? Are our expressions for ##f^{(2)}(p)## consistent?

Orodruin said:
Taylor expand ##\sqrt{1+x}## to second order in ##x##. Set ##x= p^2/(mc)^2##.
Oh I suppose that would be easier. I think that's what the answer key did. I'm kind of wondering why are we allowed to substitute in expressions for variables that would carry different inside derivatives when applying the chain rule? Maybe that will clear up when I'm able to fix my algebra but I'm just curious.

Thanks all for the replies btw!
 
Oh wait a sec, my diff expression of ##f^{(3)}(p)## has consequences on ##f^{(4)}(p)##!

Now I get...
##f^{(4)}(p) = - \frac {3p} {m^4c^4}(1 + \frac {p^2} {m^2c^2})^{\frac {-3} {2}} + ... ## (other terms that vanish when p = 0)

which means ##f^{(4)}(0) = \frac {-3} {m^4c^4} ## and that gives me the Taylor approximation with the 4th order coeff being ##\frac {-1} {8}##. Thanks y'all!

I'm still wondering about why the substitution works though... How come the inside derivatives don't impact anything?
 
  • Like
Likes BvU
baseballfan_ny said:
Oh wait a sec, my diff expression of ##f^{(3)}(p)## has consequences on ##f^{(4)}(p)##!

Now I get...
##f^{(4)}(p) = - \frac {3p} {m^4c^4}(1 + \frac {p^2} {m^2c^2})^{\frac {-3} {2}} + ... ## (other terms that vanish when p = 0)

which means ##f^{(4)}(0) = \frac {-3} {m^4c^4} ## and that gives me the Taylor approximation with the 4th order coeff being ##\frac {-1} {8}##. Thanks y'all!

I'm still wondering about why the substitution works though... How come the inside derivatives don't impact anything?
Just think about the meaning of a Taylor series. If ##f(x)=\sqrt{1+x}\approx 1+\frac{1}{2} x## when ##x=0.00001##, then when ##y=0.001##, ##y^2=x## so we should get that ##f(y^2)\approx 1+\frac{1}{2} y^2##. If there was some better approximation in terms of y, you could just use that to get a better approximation of ##f(x)## in terms of x
 
  • Like
Likes baseballfan_ny
baseballfan_ny said:
I'm still wondering about why the substitution works though... How come the inside derivatives don't impact anything?
Must have something to do with the fact that a function of ##p^2## is even, so a Taylor expansion can't have any odd powers of ##p## in it . . .

##\ ##
 
Orodruin said:
Taylor expand ##\sqrt{1+x}## to second order in ##x##. Set ##x= p^2/(mc)^2##.

baseballfan_ny said:
Oh I suppose that would be easier. I think that's what the answer key did. I'm kind of wondering why are we allowed to substitute in expressions for variables that would carry different inside derivatives when applying the chain rule? Maybe that will clear up when I'm able to fix my algebra but I'm just curious.

I think the answer key is using the binomial series for (1 + x)^\alpha = 1 + <br /> \alpha x + \frac{\alpha(\alpha-1)}{2}x^2 + \dots + \frac{\alpha(\alpha-1) \cdots (\alpha - n + 1)}{n!}x^n + \dots, \qquad |x| &lt; 1,<br /> with x = p^2/(mc)^2 and \alpha = \frac12.
 
  • #10
baseballfan_ny said:
I definitely messed something up, but I keep getting that that ##f^{(3)}(0) = 0##.

$$ f^{(2)}(p) = \frac {1} {m^2c^2}(1 + \frac {p^2} {m^2c^2})^{\frac {-1} 2} - \frac {p^2} {m^4c^4}(1 + \frac {p^2} {m^2c^2})^{\frac {-3} 2} $$How did you make that simplification? Are our expressions for ##f^{(2)}(p)## consistent?
Starting with your expression:
##\displaystyle f^{(2)}(p) = \frac {1} {m^2c^2}(1 + \frac {p^2} {m^2c^2})^{\frac {-1} 2} - \frac {p^2} {m^4c^4}(1 + \frac {p^2} {m^2c^2})^{\frac {-3} 2}##

Then noting that ##B^{-\frac {1} 2}=B\cdot B^{-\frac {3} 2}##, we have that:

##\displaystyle f^{(2)}(p) = \frac {1} {m^2c^2}\left(1 + \frac {p^2} {m^2c^2}\right) \left(1 + \frac {p^2} {m^2c^2} \right)^{-\frac {3} 2} - \frac {p^2} {m^4c^4} \left(1 + \frac {p^2} {m^2c^2}\right)^{-\frac {3} 2}##

Then do some distributing and combining of like terms.
 
Last edited:
Back
Top