summaryrefslogtreecommitdiff
path: root/608/CH42/EX42.09
diff options
context:
space:
mode:
authorpriyanka2015-06-24 15:03:17 +0530
committerpriyanka2015-06-24 15:03:17 +0530
commitb1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b (patch)
treeab291cffc65280e58ac82470ba63fbcca7805165 /608/CH42/EX42.09
downloadScilab-TBC-Uploads-b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b.tar.gz
Scilab-TBC-Uploads-b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b.tar.bz2
Scilab-TBC-Uploads-b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b.zip
initial commit / add all books
Diffstat (limited to '608/CH42/EX42.09')
-rwxr-xr-x608/CH42/EX42.09/42_09.sce20
1 files changed, 20 insertions, 0 deletions
diff --git a/608/CH42/EX42.09/42_09.sce b/608/CH42/EX42.09/42_09.sce
new file mode 100755
index 000000000..d1dfdf9f4
--- /dev/null
+++ b/608/CH42/EX42.09/42_09.sce
@@ -0,0 +1,20 @@
+//Problem 42.09: The propagation coefficients of two filter networks are given by (a) r = (1.25 + i0.52) (b) r = 1.794/_-39.4° Determine for each (i) the attenuation coefficient, and (ii) the phase shift coefficient.
+
+//initializing the variables:
+r1 = 1.25 + %i*0.52; // propagation coefficients
+rr = 1.794; // propagation coefficients
+thetar = -39.4; // in ddegrees
+
+//calculation:
+//r
+r2 = rr*cos(thetar*%pi/180) + %i*rr*sin(thetar*%pi/180)
+//attenuation coefficient
+a1 = real(r1)
+a2 = real(r2)
+//phase shift coefficient
+b1 = imag(r1)
+b2 = imag(r2)
+
+printf("\n\n Result \n\n")
+printf("\nattenuation coefficient are for (a) is %.2f N and for (b) is %.3f N ",a1,a2)
+printf("\nphase shift coefficient are for (a) is %.2f rad and for (b) is %.3f rad ",b1,b2) \ No newline at end of file