summaryrefslogtreecommitdiff
path: root/605/CH11/EX11.3/11_3.sce
diff options
context:
space:
mode:
Diffstat (limited to '605/CH11/EX11.3/11_3.sce')
-rwxr-xr-x605/CH11/EX11.3/11_3.sce55
1 files changed, 25 insertions, 30 deletions
diff --git a/605/CH11/EX11.3/11_3.sce b/605/CH11/EX11.3/11_3.sce
index a721d2b24..518c81de5 100755
--- a/605/CH11/EX11.3/11_3.sce
+++ b/605/CH11/EX11.3/11_3.sce
@@ -1,30 +1,25 @@
-
-S11=0.614*exp(-%i*167.4*%pi/180)
-S21=2.187*exp(%i*32.4*%pi/180)
-S12=0.046*exp(%i*65*%pi/180)
-S22=0.716*exp(-%i*83*%pi/180)
-del=(S11*S22-S12*S21)
-B1=1+mod(S11)^2-mod(S22)^2-mod(del)^2
-B2=1+mod(S22)^2-mod(S11)^2-mod(del)^2
-C1=S11-Ss22*del
-C2=S22-Ss11*del
-function x=mod(n)
- r=real(n)
- i=imag(n)
- x=sqrt(r^2+i^2)
-endfunction
-
-disp(mod(del),"del=")
-k=(1-mod(S11)^2-mod(S22)^2+mod(del)^2)/(2*mod(S12*S21))
-disp(k,"k=")
-FMS=(B1-sqrt(B1^2-4*mod(C1)^2))/(2*C1)
-disp(FMS,"FMS=")
-FML= (B2-sqrt(B2^2-4*mod(C2)^2))/(2*C2)
-disp(FML,"FML=")
-GTmax=mod(S21)/mod(S12)*(k-sqrt(k^2-1))
-printf("\nGTmax=%.3f",GTmax)
-printf("\nGTmax in dB=%.2f dB",10*log10(GTmax))
-
-
-
-
+S11=0.614*exp(-%i*167.4*%pi/180)
+S21=2.187*exp(%i*32.4*%pi/180)
+S12=0.046*exp(%i*65*%pi/180)
+S22=0.716*exp(-%i*83*%pi/180)
+del=(S11*S22-S12*S21)
+B1=1+abs(S11)^2-abs(S22)^2-abs(del)^2
+B2=1+abs(S22)^2-abs(S11)^2-abs(del)^2
+C1=S11-S22*del
+C2=S22-S11*del
+function x=mod(n)
+ r=real(n)
+ i=imag(n)
+ x=sqrt(r^2+i^2)
+endfunction
+
+disp(mod(del),"del=")
+k=(1-mod(S11)^2-mod(S22)^2+mod(del)^2)/(2*mod(S12*S21))
+disp(k,"k=")
+FMS=(B1-sqrt(B1^2-4*mod(C1)^2))/(2*C1)
+disp(FMS,"FMS=")
+FML= (B2-sqrt(B2^2-4*mod(C2)^2))/(2*C2)
+disp(FML,"FML=")
+GTmax=mod(S21)/mod(S12)*(k-sqrt(k^2-1))
+printf("\nGTmax=%.3f",GTmax)
+printf("\nGTmax in dB=%.2f dB",10*log10(GTmax)) \ No newline at end of file