**TI92P*main_æ6&§~7Æ!Ÿ_BæBæ_7æV%§ªŸRfsc© ¥Z O() Prgm © Copyright 2000 © Neil Berger © All rights reserved FnOff ClrIO ClrDraw © Set conditions setMode("Graph","Function")funset setMode("Angle","Radian")radset setMode("Pretty Print","On")ppset setMode("Exact/Approx","Auto")autoset setMode("Split Screen","Full")fullset Lbl start ClrIO ClrHome Toolbar Title "Fourier Sin + Cos",sc Title "Sin",ss Title "Cos",cc Title "Quit",quit EndTBar Lbl sc Disp "Input the value of" Input "half period T:",t ­t*1.5xmin t*1.5xmax 1xscl ClrIO Disp "Number of sin " Input "(and cos terms) computed:",nn ClrIO Disp "Function of x" InputStr "defined for ­T < x < T:",fn1 expr(fn1)*(sign(x+t)-sign(x-t))/2y1(x) expr(fn1)yy(x) FnOff 1/t*½(yy(x),x,­t,t)a0 Define a(n)=1/t*½(yy(x)*cos(n*Œ*x/t),x,­t,t) Define b(n)=1/t*½(yy(x)*sin(n*Œ*x/t),x,­t,t) a0/2+sum(seq(a(n)*cos(n*Œ*x/t)+b(n)*sin(n*Œ*x/t),n,1,nn))|x=rfscr fscr|r=xy2(x) ClrIO Disp "Some terms" Disp "in series are" Disp y2(x) y2(x)scf Disp "The full series is" Disp "stored in: scf" Pause "Press any key to continue" Disp "a( )",seq(a(i),i,0,nn) Disp "b( )",seq(b(i),i,1,nn) Pause "Press any key to continue" FnOn 1 FnOn 2 ZoomFit Pause DispHome Goto start © Cosine series alone Lbl cc Disp "Enter the" Input "half period T:",t ­t*1.5xmin t*1.5xmax 1xscl ClrIO Disp "Number of terms computed" Input "in COS series:",nnn nnn-1nn ClrIO Disp "Input function of x" Disp "defined for 0 < x < T" Disp "to be extended" Disp "as an EVEN function over" InputStr "-T < x < T:",fn1 1/2*(expr(fn1)*(sign(x)-sign(x-t))+(expr(fn1)|x=­x)*(sign(x+t)-sign(x)))y1(x) expr(fn1)yy(x) FnOff 2/t*½(yy(x),x,0,t)a0 Define a(n)=2/t*½(yy(x)*cos(n*Œ*x/t),x,0,t) a0/2+expand(sum(seq(a(n)*cos(n*Œ*x/t),n,1,nn)),x)|x=rfscr fscr|r=xy2(x) ClrIO Disp "Some terms" Disp "in COS series are" Disp y2(x) y2(x)fc Disp "The series is" Disp "stored in: fc " Pause "Press any key to continue" Disp "a( )",seq(a(i),i,0,nn) Pause "Press any key to continue" FnOn 1 FnOn 2 ZoomFit Pause DispHome Goto start © Sine series alone Lbl ss Disp "Input the value of" Input "half period T:",t ­t*1.5xmin t*1.5xmax 1xscl ClrIO Disp "Number of terms computed" Input "in SIN series:",nn ClrIO Disp "Input function of x" Disp "defined for 0 < x < T" Disp "To be extended" Disp "as an ODD function over" InputStr "-T < x < T:",fn1 1/2*(expr(fn1)*(sign(x)-sign(x-t))-(expr(fn1)|x=­x)*(sign(x+t)-sign(x)))y1(x) expr(fn1)yy(x) FnOff Define b(n)=2/t*½(yy(x)*sin(n*Œ*x/t),x,0,t) expand(sum(seq(b(n)*sin(n*Œ*x/t),n,1,nn)),x)|x=rfscr fscr|r=xy2(x) ClrIO Disp "Some terms" Disp "in SIN series are" Disp y2(x) y2(x)fs Disp "The series is" Disp "stored in: fs " Pause "Press any key to continue" Disp "b( )",seq(b(i),i,1,nn) Pause "Press any key to continue" FnOn 1 FnOn 2 ZoomFit Pause DispHome Goto start Lbl quit DispHome setMode("Graph",funset) setMode("Angle",radset) setMode("Pretty Print",ppset) setMode("Exact/Approx",autoset) setMode("Split Screen",fullset) DelVar funset,radset,ppset,autoset,fullset DelVar t,nnn,nn,n,r,yy,i DelVar a,b,a0,fscr,fn1 EndPrgm äåܼÖ