summaryrefslogtreecommitdiff
path: root/147/CH3/EX3.13/Example3_13.sce
diff options
context:
space:
mode:
Diffstat (limited to '147/CH3/EX3.13/Example3_13.sce')
-rw-r--r--147/CH3/EX3.13/Example3_13.sce17
1 files changed, 17 insertions, 0 deletions
diff --git a/147/CH3/EX3.13/Example3_13.sce b/147/CH3/EX3.13/Example3_13.sce
new file mode 100644
index 000000000..a43ff963a
--- /dev/null
+++ b/147/CH3/EX3.13/Example3_13.sce
@@ -0,0 +1,17 @@
+close();
+clear;
+clc;
+//resistance 'R', inductance 'L', angular frequency 'w', phase difference 'theta'
+R = 20; //ohm
+L = 15*10^(-3); //mH
+w = 1000; //rad/s
+theta = 45; //degree
+//net reactance of parallel LC combination = 20 ohm or -20 ohm
+C1 = poly(0,'C1');
+pc1 = 1/(%i*w*L) - 1/(R*%i) + %i*w*C1;
+C1 = roots(pc1);
+C2 = poly(0,'C2');
+pc2 = 1/(%i*w*L) + 1/(R*%i) + %i*w*C2;
+C2 = roots(pc2);
+mprintf("C1 = %0.2f uF\nC2 = %0.1f uF\n\n",C1*10^6, C2*10^6);
+mprintf("For smaller (larger) capacitance, I lags (leads) V by 45 degree"); \ No newline at end of file