summaryrefslogtreecommitdiff
path: root/1445/CH2/EX2.35/ch2_ex_35.sce
diff options
context:
space:
mode:
Diffstat (limited to '1445/CH2/EX2.35/ch2_ex_35.sce')
-rw-r--r--1445/CH2/EX2.35/ch2_ex_35.sce45
1 files changed, 45 insertions, 0 deletions
diff --git a/1445/CH2/EX2.35/ch2_ex_35.sce b/1445/CH2/EX2.35/ch2_ex_35.sce
new file mode 100644
index 000000000..dcc78f2b4
--- /dev/null
+++ b/1445/CH2/EX2.35/ch2_ex_35.sce
@@ -0,0 +1,45 @@
+//CHAPTER 2- STEADY-STATE ANALYSIS OF SINGLE-PHASE A.C. CIRCUIT
+//Example 35 // read it as example 34 in the book on page 2.88
+
+disp("CHAPTER 2");
+disp("EXAMPLE 35");
+
+//VARIABLE INITIALIZATION
+R=100; //in Ω
+L=0.2; //in Henry
+C=20*10^(-6); //farads
+V=240; // volts
+f=50; //Hz
+//
+//SOLUTION
+//Solution (a)
+XL=2*%pi*f*L;
+XC=1/(2*%pi*f*C);
+//impedence Z=sqrt(R^2 +XL^2)
+X=XL-XC;
+Z=sqrt(R^2 +X^2);
+disp("SOLUTION (a)");
+disp(sprintf("The total impedence is %f Ω", Z));
+I=V/Z;
+disp("SOLUTION (b)");
+disp(sprintf("The total current is %f Amp", I));
+Vr=I*R;
+Vi=I*XL;
+Vc=I*XC;
+disp("SOLUTION (c)");
+disp(sprintf("The voltage across resistance is %f V",Vr));
+disp(sprintf("The voltage across inductance is %f V",Vi));
+disp(sprintf("The voltage across capacitance is %f V",Vc));
+pf=R/Z;
+pc=V*I*pf;
+disp("SOLUTION (d)");
+disp(sprintf("The Power Factor is %f leading", pf));
+disp("SOLUTION (e)");
+disp(sprintf("The Power consumed in the circuit is %f W",pc));
+//XL=XC
+f0=1/(2*%pi*sqrt(L*C));
+disp("SOLUTION (f)");
+disp(sprintf("Resonance will occur at %f Hz",f0));
+disp(" ");
+//
+//END