How To

Small angle approximation help

Small angle approximation help

Postby sajidbutt » Wed Jun 23, 2010 9:51 am
Hello!

I am trying to solve a problem in mathematica with energy methods. I have used displacements for potential and velocity for kinetic energies and later i differentiated the energies..

For this problem i used small angles, i.e. sin(alpha)~alpha and cos(alpha)~1 etc. But due to multiplicaion involved, i am getting squares and multiples of angles i.e. (alpha)^2 , (beta)^2 or (alpha)(beta) etc...

I want to delete the terms by taking the multiples and squares equal to zero but i am not able to find any method to do it automatically.

Can anyone help me to do so?

Thanks
sajidbutt
 
Posts: 1
Joined: Wed Jun 23, 2010 9:45 am

Re: Small angle approximation help

Postby lordofazeroth » Sun Jan 15, 2012 4:24 pm
Hi.

I need such a function too.
Can anybody help me?
I need an automated simplify function for this as I must not delete the angles manually.
lordofazeroth
 
Posts: 2
Joined: Sun Jan 15, 2012 4:22 pm

Re: Small angle approximation help

Postby lordofazeroth » Wed Jan 18, 2012 7:31 am
Answer:

FullSimplify[function,Cos[alpha]==0]

should work....
lordofazeroth
 
Posts: 2
Joined: Sun Jan 15, 2012 4:22 pm

Re: Small angle approximation help

Postby alexeymor » Wed Mar 06, 2013 4:37 am
I was looking for exactly the same thing! http://mathematica.stackexchange.com/questions/15283/replacing-functions/20730#comment45169_15283 helped me a lot, so now I can remove sines:
Code: Select all
Sin[a + b] /. Sin -> Function[x, x]
    a + b

and my trigonometric equation turns into an algebraic one:
Code: Select all
-4 Cos[g] Sin[a + b] Sin[t] - 4 Cos[g] /. {Sin -> Function[x, x], Cos -> Function[x, 1]}
    -4 - 4 (a + b) t

or even second order:
Code: Select all
Series[Sin[x], {x, 0, 2}]
-4Cos[g]Sin[a+b]Sin[t]-4Cos[g]/.{Sin->Function[x,x],Cos->Function[x, 1-x^2/2]}
    -4 (1 - g^2/2) - 4 (a + b) (1 - g^2/2) t
alexeymor
 
Posts: 1
Joined: Wed Mar 06, 2013 4:28 am

Who is online

Users browsing this forum: Yahoo [Bot] and 2 guests