Re: Trig Substitution
- To: mathgroup at smc.vnet.net
- Subject: [mg93461] Re: [mg93434] Trig Substitution
- From: Bob Hanlon <hanlonr at cox.net>
- Date: Sun, 9 Nov 2008 05:25:59 -0500 (EST)
- Reply-to: hanlonr at cox.net
x = Sin[t] + Sin[t]^2 + Sin[t]^3; y = x /. {Sin[t_]^n_?EvenQ :> (1 - Cos[t]^2)^(n/2), Sin[t_]^n_ :> (1 - Cos[t]^2)^((n - 1)/2) Sin[t]} // Expand (-Sin[t])*Cos[t]^2 - Cos[t]^2 + 2*Sin[t] + 1 y == x // Simplify True Bob Hanlon ---- Bruce Colletti <bwcolletti at verizon.net> wrote: ============= Re Mathematica 6.0.3 under WinXP. Given a sum of (positive integer) powers of sin(t), I wish to cast (as much as possible) the sum in terms of cos t, chiefly by substituting 1 - (cos t)^2 for (sin t)^2 throughout. The code below does this. X=Sin[t]+Sin[t]^2+Sin[t]^3; Y=Apply[List,X]/.{Sin[t]^n_?EvenQ:>Expand[(1-Cos[t]^2)^(n/2)],Sin[t]^n_:>Exp and[(1-Cos[t]^2)^Quotient[n,2] Sin[t]]}; Apply[Plus,Y] What is an easier way? Thankx. Bruce -- Bob Hanlon