# TITLE: Complex Trig,Logs,Exponential & Powers # AUTHOR: Roy F.A. Maclean # EMAIL: rfamgm at gmail # WEB: http://www.spiderpixel.co.uk/caspro # DATE: 9700version 96/97?, 27Oct2006, 25Feb2007 # MAKE: CASIO # MODEL: 9x50 # SIZE: 226 over two areas # # With this program you can find the exponential, log, sin, cos, sinh, cosh # of a complex number, or raise to a complex power. # A menu is displayed. Enter 1-7 to make choice. # If you enter 7 then you will be prompted for the power you wish to raise to. # Z & N can be real or complex. # If you want Z^N then Z must be nonzero for this program. # Zero raised to anything is zero of course. # # The formulae that this program uses are: # let z=x+iy, then e^z = (e^x)(cos y + i*sin y) # proof: e^z=e^(x+iy)=(e^x)(e^iy)=(e^x)(cos y +i*siny) # # ln(z)=ln(abs z)+i*arg(z) # # z^n=e^(n*ln(z)) # # sin(z)=(e^(iz)-e^(-iz))/2i cos(z)=(e^(iz)+e^(-iz))/2 # # sinh(z)=(e^z-e^(-z))/2 cosh(z)=(e^z+e^(-z))/2 # # i, Imp & Rep are on the complex menu. # e^ is the inverse natural log on button. # # @@ Program "CXEXP" Lbl 0 Rad "e ln S C SH CH ^" "1 2 3 4 5 6 7"?->A "Z"?->Z Z:Prog "CXSUB":Ans->C -Z:Prog "CXSUB":Ans->D iZ:Prog "CXSUB":Ans->E -iZ:Prog "CXSUB":Ans->F Frac (14/A)=0=>ln Abs Z+i*Arg Z->H A=1=>C_ A=2=>H_ A=3=>(E-F)/2i_ A=4=>(E+F)/2_ A=5=>(C-D)/2_ A=6=>(C+D)/2_ A<>7=>Goto 0 "N"?->N:NH:Prog "CXSUB" Ans_ Goto 0 @@ Program "CXSUB" (cos ImP Ans+i*sin ImP Ans)e^ReP Ans (Rep Ans)(Abs ReP Ans>10^-10)+i(ImP Ans)(Abs ImP Ans>10^-10)