summaryrefslogtreecommitdiff
path: root/1445/CH2/EX2.20/Ex2_20.sce
diff options
context:
space:
mode:
Diffstat (limited to '1445/CH2/EX2.20/Ex2_20.sce')
-rw-r--r--1445/CH2/EX2.20/Ex2_20.sce9
1 files changed, 5 insertions, 4 deletions
diff --git a/1445/CH2/EX2.20/Ex2_20.sce b/1445/CH2/EX2.20/Ex2_20.sce
index 77d5ad76a..74c8f035b 100644
--- a/1445/CH2/EX2.20/Ex2_20.sce
+++ b/1445/CH2/EX2.20/Ex2_20.sce
@@ -1,6 +1,7 @@
//CHAPTER 2- STEADY-STATE ANALYSIS OF SINGLE-PHASE A.C. CIRCUIT
//Example 20 // read it as example 19 in the book on page 2.72
+clc;
disp("CHAPTER 2");
disp("EXAMPLE 20");
@@ -14,26 +15,26 @@ R=25 //in ohms
//Resonance frequency f = (1/2π)sqrt((1/LC)-R^2/L^2)
fr=(1/(2*%pi))*sqrt((1/(L*C*10^-6))-(R^2)/(L^2));
disp("SOLUTION (i)");
-disp(sprintf("For parallel circuit,Resonant frquency is %3.2f Hz", fr));
+disp(sprintf("For parallel circuit,Resonant frquency is %3f Hz", fr));
disp(" ");
//solution (ii)
//Total circuit impedance at resonance is Z=L/RC
z=L/(R*C*10^-6);
disp("SOLUTION (ii)");
-disp(sprintf("Total impedence at resonance is %3.0f kΩ", z/1000));
+disp(sprintf("Total impedence at resonance is %3f kΩ", z/1000));
//
//solution (iii)
//Bandwidth (f2-f1)=R/(2.π.L)
bw=R/(2*%pi*L);
disp("SOLUTION (iii)");
-disp(sprintf("Bandwidth is %3.2f Hz", bw));
+disp(sprintf("Bandwidth is %3f Hz", bw));
//
//solution (iv)
//Quality factor Q=1/R.sqrt(L/C)
Q=(1/R)*sqrt(L/(C*10^-6));
disp("SOLUTION (iv)");
-disp(sprintf("Quality Factor is %3.2f", Q));
+disp(sprintf("Quality Factor is %3f", Q));
//solution in the book is wrong as there is a total mistake in imaginery part 7.2+0.798=11.598
//
//END