summaryrefslogtreecommitdiff
path: root/3871/CH7
diff options
context:
space:
mode:
authorprashantsinalkar2018-02-03 11:01:52 +0530
committerprashantsinalkar2018-02-03 11:01:52 +0530
commit7bc77cb1ed33745c720952c92b3b2747c5cbf2df (patch)
tree449d555969bfd7befe906877abab098c6e63a0e8 /3871/CH7
parentd1e070fe2d77c8e7f6ba4b0c57b1b42e26349059 (diff)
downloadScilab-TBC-Uploads-7bc77cb1ed33745c720952c92b3b2747c5cbf2df.tar.gz
Scilab-TBC-Uploads-7bc77cb1ed33745c720952c92b3b2747c5cbf2df.tar.bz2
Scilab-TBC-Uploads-7bc77cb1ed33745c720952c92b3b2747c5cbf2df.zip
Added new codeHEADmaster
Diffstat (limited to '3871/CH7')
-rw-r--r--3871/CH7/EX7.1/Ex7_1.sce19
-rw-r--r--3871/CH7/EX7.10/Ex7_10.sce16
-rw-r--r--3871/CH7/EX7.11/Ex7_11.sce22
-rw-r--r--3871/CH7/EX7.12/Ex7_12.sce17
-rw-r--r--3871/CH7/EX7.13/Ex7_13.sce14
-rw-r--r--3871/CH7/EX7.14/Ex7_14.sce35
-rw-r--r--3871/CH7/EX7.15/Ex7_15.sce20
-rw-r--r--3871/CH7/EX7.16/Ex7_16.sce18
-rw-r--r--3871/CH7/EX7.17/Ex7_17.sce26
-rw-r--r--3871/CH7/EX7.18/Ex7_18.sce25
-rw-r--r--3871/CH7/EX7.19/Ex7_19.sce29
-rw-r--r--3871/CH7/EX7.2/Ex7_2.sce30
-rw-r--r--3871/CH7/EX7.20/Ex7_20.sce25
-rw-r--r--3871/CH7/EX7.21/Ex7_21.sce27
-rw-r--r--3871/CH7/EX7.22/Ex7_22.sce33
-rw-r--r--3871/CH7/EX7.23/Ex7_23.sce48
-rw-r--r--3871/CH7/EX7.24/Ex7_24.sce17
-rw-r--r--3871/CH7/EX7.25/Ex7_25.sce25
-rw-r--r--3871/CH7/EX7.3/Ex7_3.sce31
-rw-r--r--3871/CH7/EX7.4/Ex7_4.sce42
-rw-r--r--3871/CH7/EX7.5/Ex7_5.sce20
-rw-r--r--3871/CH7/EX7.6/Ex7_6.sce30
-rw-r--r--3871/CH7/EX7.7/Ex7_7.sce27
-rw-r--r--3871/CH7/EX7.8/Ex7_8.sce42
-rw-r--r--3871/CH7/EX7.9/Ex7_9.sce30
25 files changed, 668 insertions, 0 deletions
diff --git a/3871/CH7/EX7.1/Ex7_1.sce b/3871/CH7/EX7.1/Ex7_1.sce
new file mode 100644
index 000000000..e884ff9ca
--- /dev/null
+++ b/3871/CH7/EX7.1/Ex7_1.sce
@@ -0,0 +1,19 @@
+//===========================================================================
+//chapter 7 example 1
+
+clc;clear all;
+
+
+//variable declaration
+P = 250; //wattmeter reading in watts
+Rp = 2000; //pressure coil circuit resistance in Ω
+VL = 200; //load voltage in V
+
+//calculations
+p = (VL^2)/Rp; //power lost in pressure coil in watts
+P1 = P-p; //power lost in the pressure coil circuit in watts
+
+
+//result
+mprintf("power lost in the pressure coil circuit = %3.2f watts",P1);
+
diff --git a/3871/CH7/EX7.10/Ex7_10.sce b/3871/CH7/EX7.10/Ex7_10.sce
new file mode 100644
index 000000000..6cea02795
--- /dev/null
+++ b/3871/CH7/EX7.10/Ex7_10.sce
@@ -0,0 +1,16 @@
+//===========================================================================
+//chapter 7 example 10
+
+clc;clear all;
+
+//variable declaration
+V1 = 200; //voltage across an inductive load in volts
+V2 = 180; //voltage across an nono- inductive resistor in volts
+V3 = 300; //voltage across the two in series in volts
+
+//calculations
+x = ((V3^2)-(V1^2)-(V2^2))/(2*V1*V2); //cos(phi)
+
+//result
+mprintf("power factor cos (phi) = %3.3f lagging",x);
+
diff --git a/3871/CH7/EX7.11/Ex7_11.sce b/3871/CH7/EX7.11/Ex7_11.sce
new file mode 100644
index 000000000..c3339acdb
--- /dev/null
+++ b/3871/CH7/EX7.11/Ex7_11.sce
@@ -0,0 +1,22 @@
+//===========================================================================
+//chapter 7 example 11
+
+clc;clear all;
+
+//variable declaration
+I1 = 2.5; //current across an inductive load in A
+I2 = 2.4; //current across an non- inductive resistor in A
+I3 = 4.5; //current across the two in series in A
+V = 250; //supply voltage in V
+
+
+//calculations
+R = V/I2; // non- inductive resistance in Ω
+P = ((I3^2)-(I1^2)-(I2^2))*(R/2); //power absorbed by the load in watts
+Z = V/I1; //load impedance in Ω
+x = ((I3^2)-(I1^2)-(I2^2))/(2*I1*I2); //cos(phi)
+
+//result
+mprintf("power absorbed by the load = %3.2f watts",P);
+mprintf("\nload impedance = %3.2f Ω",Z);
+mprintf("\npower factor cos (phi) = %3.4f lagging",x);
diff --git a/3871/CH7/EX7.12/Ex7_12.sce b/3871/CH7/EX7.12/Ex7_12.sce
new file mode 100644
index 000000000..25780fcc6
--- /dev/null
+++ b/3871/CH7/EX7.12/Ex7_12.sce
@@ -0,0 +1,17 @@
+//===========================================================================
+//chapter 7 example 12
+clc;clear all;
+
+//variable declaration
+V1 = 6600; //primary voltage in V
+V2 = 110; //secondary voltage in V
+I1 = 50; //primary current in A
+I2 = 5; //secondary voltage in A
+
+//calculations
+r = V1/V2; //hence transformation ratio of PT
+r1 = I1/I2; //transformation ratio of CT
+
+//result
+mprintf("transformation ratio of CT = %3.2f ",r1);
+
diff --git a/3871/CH7/EX7.13/Ex7_13.sce b/3871/CH7/EX7.13/Ex7_13.sce
new file mode 100644
index 000000000..cfbb55f0c
--- /dev/null
+++ b/3871/CH7/EX7.13/Ex7_13.sce
@@ -0,0 +1,14 @@
+//===========================================================================
+//chapter 7 example 13
+clc;clear all;
+
+//variable declaration
+m = 10; //wattmeter multiplying factor
+
+//calculations
+x = 100/5; //CT ratio
+y = 1000/100; //PT ratio
+W = x*y*m; //new multiplying factor of wattmeter
+
+//result
+mprintf("new multiplying factor of wattmeter = %3.2f",W);
diff --git a/3871/CH7/EX7.14/Ex7_14.sce b/3871/CH7/EX7.14/Ex7_14.sce
new file mode 100644
index 000000000..5c7e5b9d1
--- /dev/null
+++ b/3871/CH7/EX7.14/Ex7_14.sce
@@ -0,0 +1,35 @@
+//===========================================================================
+//chapter 7 example 14
+clc;
+clear all;
+
+//variable declaration
+
+V = 6000; //load voltage in V
+I = 100; //load current in A
+p = 0.5; //power factor cos(phi) lagging
+theta = 0; //since wattmeter reads correctly
+x1 = 20; // current transformers nominal ratio
+x2 = 60; // potenetial transformers nominal ratio
+e1 =-0.005; // ration error
+e2 = 0.01; // ratio error
+
+//calculations
+P = V*I*p; //actual power consumed in W
+phi =acos(p);
+phi1 = (phi*180)/%pi;
+d = -1; //phase angle in °
+b = 2; //phase angle in °
+g = phi1+d-theta1-b; //phase angle in °
+theta1 =theta*180/%pi
+g1 = g*180/%pi;
+A =cos(phi1)
+K = (cos(phi1*%pi/180))/((cos(theta1*%pi/180))*(cos(g*%pi/180)));
+CT = x1*(1+e1); //actual transformation ratio of CT
+PT = x2*(1+e2); //actual transformation ratio of PT
+P1 = P/(K*CT*PT); //power indicated by wattmeter in kW
+T = P/(x1*x2); //true reading of wattmeter in kW
+e = ((P1-T)/T)*100; //percentage errror in %
+//result
+mprintf("phase angle between the currents in CC and PC of wattmeter %3.2f ° ",K);
+mprintf("\npercentage error = %3.0f percentage ",e);
diff --git a/3871/CH7/EX7.15/Ex7_15.sce b/3871/CH7/EX7.15/Ex7_15.sce
new file mode 100644
index 000000000..0686bcc01
--- /dev/null
+++ b/3871/CH7/EX7.15/Ex7_15.sce
@@ -0,0 +1,20 @@
+//===========================================================================
+//chapter 7 example 15
+clc;
+clear all;
+
+//variable declaration
+W1 = 300; //wattmeter reading in kW
+W2 = 100; //wattmeter reading in kW
+
+//calculations
+P = W1+W2; //input power in kW
+phi = atan(((W1-W2)/(W1+W2))*sqrt(3)); //phase angle in radians
+phi1 = (phi*180)/%pi;
+pf =cos((phi1*%pi)/180); //power factor lagging
+
+
+//result
+mprintf("input power = %3.2f kW",P);
+mprintf("power factor = %3.3f lagging",pf);
+
diff --git a/3871/CH7/EX7.16/Ex7_16.sce b/3871/CH7/EX7.16/Ex7_16.sce
new file mode 100644
index 000000000..750409d15
--- /dev/null
+++ b/3871/CH7/EX7.16/Ex7_16.sce
@@ -0,0 +1,18 @@
+//===========================================================================
+//chapter 7 example 16
+
+clc;clear all;
+
+//variable declaration
+W1 = 20; //wattmeter reading in kW
+W2 = -5; //wattmeter reading in kW
+
+//calculations
+P = W1+W2; //input power in kW
+phi = atan(((W1-W2)/(W1+W2))*sqrt(3)); //phase angle in °
+pf =cos(phi); //power factor lagging
+
+//result
+mprintf("input power = %3.2f kW",P);
+mprintf("\npower factor = %3.4f lagging",pf);
+
diff --git a/3871/CH7/EX7.17/Ex7_17.sce b/3871/CH7/EX7.17/Ex7_17.sce
new file mode 100644
index 000000000..015e0dbea
--- /dev/null
+++ b/3871/CH7/EX7.17/Ex7_17.sce
@@ -0,0 +1,26 @@
+//===========================================================================
+//chapter 7 example 17
+
+clc;clear all;
+
+//variable declaration
+P = 30000; //total power in kW
+pf = 0.4; //power factor assuming lagging
+
+//calculations
+phi = acos(pf); //phase angle in radians
+phi1 = (phi*180)/%pi;
+y = sqrt(3);
+z =y*pf;
+x = P/(y*pf); //VL*IL in VA
+
+//W = VL*IL*cos(30-phi)
+//VL*IL = x;
+W1 = x*cos((30*%pi/180)-(phi1*%pi/180)); //reading of wattemeter in W
+W2 = x*cos((30*%pi/180)+(phi1*%pi/180)); //reading of wattemeter in W
+
+//result
+mprintf("reading of wattemeter %3.2f W %3.0f W",W1,W2);
+mprintf("\nNote:x value is taken approximate value,so the w1 and w2 differing ")
+mprintf("\nif power factor is leading the readings of wattmeters interchange ");
+
diff --git a/3871/CH7/EX7.18/Ex7_18.sce b/3871/CH7/EX7.18/Ex7_18.sce
new file mode 100644
index 000000000..708fd5d8a
--- /dev/null
+++ b/3871/CH7/EX7.18/Ex7_18.sce
@@ -0,0 +1,25 @@
+//===========================================================================
+//chapter 7 example 18
+
+
+clc;clear all;
+
+//variable declaration
+VL =400; //voltage in V
+IL = 10; //current in A
+//r = W1/W2
+//tan(phi) = sqrt(3)*((W1-W2)/(W1+W2))
+//tan(phi) = sqrt(3)*((1-(W2/W1))/(1+(W2/W1)))
+//tan(phi) = sqrt(3)*((1-r)/(1+r))
+//cos(phi) = 1/sec(phi) = 1/sqrt(1+(tan(phi)^2) = 1/sqrt(1+(3*((1-r)/(1+r))^2)
+r = 0.5;
+z = ((1-r)/(1+r))^2;
+pf = 1/sqrt(1+(3*z));
+phi = (acos(pf)*180/%pi);
+W1 = VL*IL*cos((30*%pi/180)-(phi*%pi/180)); //wattmeter reading in W
+W2 = VL*IL*cos((30*%pi/180)+(phi*%pi/180)); //wattmeter reading in W
+
+//result
+mprintf("wattmeter reading = %3.2f W", W1);
+mprintf("\nwattmeter reading = %3.2f W",W2);
+
diff --git a/3871/CH7/EX7.19/Ex7_19.sce b/3871/CH7/EX7.19/Ex7_19.sce
new file mode 100644
index 000000000..101477de1
--- /dev/null
+++ b/3871/CH7/EX7.19/Ex7_19.sce
@@ -0,0 +1,29 @@
+//===========================================================================
+//chapter 7 example 19
+
+clc;
+clear all;
+
+//variable declaration
+W1 = 3000; //wattmeter reading in W
+W2 = 1000; //wattmeter reading in W
+f = 50; //frequency in HZ
+V = 400; //voltage in V
+
+
+//calculations
+VP = V/sqrt(3); //voltage in V
+P = W1+W2; //input power in kW
+phi = atan(((W1-W2)/(W1+W2))*sqrt(3)); //phase angle in radians
+phi1 = phi*180/%pi; //phase angle in degrees
+pf =cos(phi1*%pi/180); //power factor lagging
+IL = P/((sqrt(3))*V*pf); //line current in A
+ZP =VP/IL; //impedance of the circuit per phase in Ω
+R = ZP*pf; //resistance per phase Ω
+XL = sqrt((ZP^2 )-(R^2)); //reactance per phase in Ω
+L = XL/(2*%pi*f); //inducatance per phase in H
+
+//result
+mprintf("resistance per phase = %3.2f Ω",R);
+mprintf("\ninducatance per phase in = %3.3f H",L);
+
diff --git a/3871/CH7/EX7.2/Ex7_2.sce b/3871/CH7/EX7.2/Ex7_2.sce
new file mode 100644
index 000000000..1abd4fcb4
--- /dev/null
+++ b/3871/CH7/EX7.2/Ex7_2.sce
@@ -0,0 +1,30 @@
+//===========================================================================
+//chapter 7 example 2
+
+clc;clear all;
+
+//variable declaration
+x = 0.004;
+y = 0.707; //power factor lagging
+y1 = 0.5; //power factor lagging
+
+//calculaitons
+theta = atan(x) //theta in degrees
+a = cos(theta)
+b = sin(theta)
+phi = acos(y)
+c = cos(phi)/(a*cos(theta-phi)) //correction factor
+A = cos(phi)/sin(phi);
+e = (b/(A+b))*100 //percentage error in %
+phi1 = acos(y1)
+c1 = cos(phi1)/(a*cos(theta-phi1)) //correction factor
+B = cos(phi1)/sin(phi1);
+e1 = (b/(B+b))*100 //percentage error in %
+
+//result
+mprintf("correction factor when 0.707 pf lagging = %3.3f",c);
+mprintf("\npercentage error =%3.2f percentage ",e);
+mprintf("\ncorrection factor when 0.707 pf lagging = %3.3f",c1);
+mprintf("\npercentage error =%3.1f percentage ",e1)
+
+
diff --git a/3871/CH7/EX7.20/Ex7_20.sce b/3871/CH7/EX7.20/Ex7_20.sce
new file mode 100644
index 000000000..80a8cbd43
--- /dev/null
+++ b/3871/CH7/EX7.20/Ex7_20.sce
@@ -0,0 +1,25 @@
+//===========================================================================
+//chapter 7 example 20
+
+clc;
+clear all;
+
+//variable declaration
+IPR = 8; //current in line R in A
+IPY = 10; //current in line Y in A
+IPB = 6; //current in line B in A
+VP =120; //voltage in V
+pf = 1; //power factor
+
+//calculations
+W1 = VP*IPR*pf; //wattage shown by wattmeter having current coil in line R in watts
+W2 = VP*IPY*pf; //wattage shown by wattmeter having current coil in line Y in watts
+W3 = VP*IPB*pf; //wattage shown by wattmeter having current coil in line B in watts
+p = W1+W2+W3; //power taken by lighting load in watts
+
+//result
+mprintf("wattage shown by wattmeter having current coil in line R = %3.2f watts",W1);
+mprintf("\nwattage shown by wattmeter having current coil in line Y = %3.2f watts",W2);
+mprintf("\nwattage shown by wattmeter having current coil in line B = %3.2f watts",W3);
+mprintf("\npower taken by lighting load = %3.2f watts",p);
+
diff --git a/3871/CH7/EX7.21/Ex7_21.sce b/3871/CH7/EX7.21/Ex7_21.sce
new file mode 100644
index 000000000..121a5b0e3
--- /dev/null
+++ b/3871/CH7/EX7.21/Ex7_21.sce
@@ -0,0 +1,27 @@
+//===========================================================================
+//chapter 7 example 21
+
+clc;
+clear all;
+
+//variable declaration
+R = 10; //resistance in Ω
+XL = 10; //reactance in Ω
+VL = 440; //load voltage in V
+
+//calculations
+Z = sqrt((R^2)+(XL^2)); //impedance of each choking coil in Ω
+VP = VL/sqrt(3); //phase voltage in V
+IP = VP/Z; //phase current in A
+IL = IP; //line current in A
+phi = atan(XL/R); //phase angle in °
+phi1 = phi*180/%pi;
+
+W1 = VL*IL*cos((30*%pi/180)-(phi1*%pi/180)); //wattmeter reading in W
+W2 = VL*IL*cos((30*%pi/180)+(phi1*%pi/180)); //wattmeter reading in W
+
+//result
+mprintf("line current = %3.2f A",IL);
+mprintf("\nwattmeter reading = %3.2f W",W1);
+mprintf("\nwattmeter reading = %3.2f W",W2);
+
diff --git a/3871/CH7/EX7.22/Ex7_22.sce b/3871/CH7/EX7.22/Ex7_22.sce
new file mode 100644
index 000000000..87b6dd3c5
--- /dev/null
+++ b/3871/CH7/EX7.22/Ex7_22.sce
@@ -0,0 +1,33 @@
+//===========================================================================
+//chapter 7 example 22
+
+clc;
+clear all;
+
+//variable declaration
+W1 = 5000; //wattmeter reading in W
+W2 = -1000; //wattmeter reading in W
+VL = 440; //load voltage in V
+f = 50; //frequency in Hz
+VP = 440;
+
+//calculations
+P = W1+W2; //total power in the load circuit in W
+phi = atan(((W1-W2)/(W1+W2))*sqrt(3)); //phase angle in °
+phi1 = phi*180/%pi;
+pf = cos(phi); //power factor
+IP = P/((sqrt(3)*VL*pf)); //load current per phase in A
+IP1 = IP/sqrt(3);
+ZP = VP/IP1; //load impedance per phase
+RP = ZP*pf; //load resistance per phase in Ω
+XP =ZP*sin(phi); //load reactance per phase in Ω
+pf1 = 0.5; //power factor
+phi2 = (acos(pf1))*180/%pi;
+//reading of wattmeter will be zero
+XP1 = RP*tan((phi2)*%pi/180); //reactnace in circuit per phase in Ω
+XC =XP-XP1; //value of capacitive reactance in troduced in each phase in Ω
+C = 1/(2*%pi*f*XC); //value of capacitive reactance introduced in each phase of delta connected in uF
+
+//result
+mprintf("value of capacitive reactance introduced in each phase of delta connected = %3.0f uF",(C*10^6));
+
diff --git a/3871/CH7/EX7.23/Ex7_23.sce b/3871/CH7/EX7.23/Ex7_23.sce
new file mode 100644
index 000000000..4ec29ab83
--- /dev/null
+++ b/3871/CH7/EX7.23/Ex7_23.sce
@@ -0,0 +1,48 @@
+//================================================================================
+//chapter 7 example 23
+
+clc;
+clear all;
+
+//variable declaration
+VAB1 = 400+0*%i; //voltage in V
+VBC1 = -200-346.41*%i; //voltage in V
+VCA1 = -200+346.41*%i; //voltage in V
+VAB =400;
+VBC = 400;
+VCA = 400;
+TVAB = 0;
+TVBC = -120;
+TVCA =120;
+PAB = 20000; //Wwattmetr readig VA
+PBC = 30000; //Wwattmetr readig VA
+PCA = 20000; //Wwattmetr readig VA
+
+
+//calculations
+IAB = PAB/VAB; //magnitude of IABC
+IBC = PBC/VAB; //magnitude of IABC
+ICA = PCA/VAB; //magnitude of IABC
+c1 = 0;
+c2 = (acos(0.8)*180/%pi);
+c3 = -(acos(0.6)*180/%pi);
+angle1 = c1-TVAB;
+angle2 = c2-TVBC;
+angle3 = c3-TVCA;
+IAB1 = (IAB*cos(angle1))+(IAB*sin(angle1))*%i;
+IBC1 = (IBC*cos(angle2*%pi/180))+(IBC*sin(-angle2*%pi/180))*%i;
+ICA1 = (ICA*cos(angle3*%pi/180))+(ICA*sin(-angle3*%pi/180))*%i;
+IA = IAB1-ICA1;
+IB = IBC1-IAB1;
+IC = ICA1-IBC1;
+W1 = -(VBC1)*IA;
+W2 = VCA1*IB;
+
+
+
+//result
+mprintf("line current IA = %3.2f %3.2f *j A",real(IA),imag(IA));
+mprintf("\nline current IA = %3.2f%3.2f*j A",real(IB),imag(IB));
+mprintf("\nline current IA = %3.2f + %3.2f*j A",real(IC),imag(IC));
+mprintf("\nreading of wattmeter W1 = %3.2f W",W1);
+mprintf("\nreading of wattmeter W2 = %3.2f W",W2);
diff --git a/3871/CH7/EX7.24/Ex7_24.sce b/3871/CH7/EX7.24/Ex7_24.sce
new file mode 100644
index 000000000..f378291f5
--- /dev/null
+++ b/3871/CH7/EX7.24/Ex7_24.sce
@@ -0,0 +1,17 @@
+//===========================================================================
+//chapter 7 example 24
+clc;
+clear all;
+
+//variable declaration
+W1 = 2000; //reading of wattmeter in watts
+W2 = 1000; //reading of wattmeter in watts
+
+//calculations
+Q = sqrt(3)*(W1-W2); //reactive power of the network in V A
+P = Q/(sqrt(3)); //wattmeter reading when current coil is connected in one phase and the potential coil across the two phases in VA
+
+//result
+mprintf("Wattmeter reading = %3.2f reactive volt amperes",P);
+
+
diff --git a/3871/CH7/EX7.25/Ex7_25.sce b/3871/CH7/EX7.25/Ex7_25.sce
new file mode 100644
index 000000000..9f1a39531
--- /dev/null
+++ b/3871/CH7/EX7.25/Ex7_25.sce
@@ -0,0 +1,25 @@
+//===========================================================================
+//chapter 7 example 25
+clc;
+clear all;
+
+//variable declaration
+VL = 415; //voltage in V
+IL = 20; //current in A
+pf = 0.8; //phase angle
+
+//calculations
+phi =acos(pf) //phase angle in °
+phi1 = (phi*180)/%pi
+x = cos((30-phi1)*%pi/180)
+W1 = VL*IL*x //wattmeter reading in W
+W2 = VL*IL*cos((30+phi1)*%pi/180) //wattmeter reading in W
+//total KVAR = sqrt(3))*(W1-W2)
+// W = totalKVAR/sqrt(3)
+//W = (sqrt(3))*(W1-W2))/sqrt(3); //wattmeter reading
+W = W1-W2 //wattmeter reading
+
+//result
+mprintf("reading on wattmeter 1 = %3.2d W",W1);
+mprintf("\nreading on wattmeter 2 = %3.2d W",W2);
+mprintf("\nreading on wattmeter = %3.2f W",W);
diff --git a/3871/CH7/EX7.3/Ex7_3.sce b/3871/CH7/EX7.3/Ex7_3.sce
new file mode 100644
index 000000000..b30c19bc3
--- /dev/null
+++ b/3871/CH7/EX7.3/Ex7_3.sce
@@ -0,0 +1,31 @@
+//===========================================================================
+//chapter 7 example 3
+
+clc;clear all;
+
+//variable declaration
+V = 240; //voltage in V
+I = 8; //current in A
+x = 0.1; //pf lagging
+Rp = 8000; //resistance in Ω
+f = 50; //frequency in Hz
+L = 63.6*10^-3 //inductance
+
+//calculations
+phi = acos(x);
+phi1 =(phi*180)/%pi;
+P = V*I*x; //load power
+Pl = (V^2)/Rp; //power lost in the pressure coil circuit in watts
+Pt = P+Pl; //neglecting inductance of the voltage coil the reading of wattmeter would be in watts
+Xp = 2*%pi*f*L; //reactance in Ω
+theta = atan(Xp/Rp);
+theta1 = (theta*180)/%pi;
+A = cos(theta1);
+B =cos(phi1-theta1);
+C = cos(phi1);
+w = Pt*(A)*(B/C); //wattmeter reading
+e = ((w-P)/P)*100; //percentage error in %
+
+//result
+mprintf("phi value in textbook is taken wrong correct is 84°.16 but value is 84°.26 so textbook answer is coming wrong")
+mprintf("\npercentage error in %3.2f percentage ",e);
diff --git a/3871/CH7/EX7.4/Ex7_4.sce b/3871/CH7/EX7.4/Ex7_4.sce
new file mode 100644
index 000000000..beb6261cf
--- /dev/null
+++ b/3871/CH7/EX7.4/Ex7_4.sce
@@ -0,0 +1,42 @@
+//===========================================================================
+//chapter 7 example 4
+
+clc;clear all;
+
+//variable declaration
+w = 23; //wattmeter reading in watts
+Rp = 2000; //resistance in Ω
+f = 100; //frequency in Hz
+L = 10*10^-3 //inductance
+V = 240; //voltage in V
+I = 4.5; //current in A
+
+//calculations
+Xp = 2*%pi*f*L; //reactance in Ω
+theta = atan(Xp/Rp);
+theta1 =(theta*180)/(%pi)
+//cos(phi)=P/V*I
+//phi = acos(P/V*I)
+//w = Pt*(cos(theta))*(cos(phi-theta))/cos(phi); //wattmeter reading
+W1 = V*I; //V*I in watts
+//phi = acos(P/W) = acos(P/1080)
+//W = P*cos(theta)*(cos(phi-theta))/cos(phi)
+//W =23 =P*cos(0.18)*cos((acos(P/1080))-0.18)/(P/V*I)
+//let cos(acos(P/1080)-0.18) =A
+//B = cos(0.18)
+//W=23 = (P*B*A)/(P/(V*I))
+// W= B*A*V*I
+//A = W/(B*V*I)
+B = cos((theta1*%pi)/180);
+A = w/(B*V*I);
+//cos(acos(P/1080)-0.18) =A
+//C =acos(P/1080) = acos(A)+0.18
+A1 =(acos(A))*(180/%pi);
+C = A1+0.18
+D = cos(C*%pi/180)
+P =1080*D;
+e = ((w-P)/P)*100; //percentage error in %
+
+//result
+mprintf("percentage error in %3.2f percentage ",e);
+
diff --git a/3871/CH7/EX7.5/Ex7_5.sce b/3871/CH7/EX7.5/Ex7_5.sce
new file mode 100644
index 000000000..a5ba78d77
--- /dev/null
+++ b/3871/CH7/EX7.5/Ex7_5.sce
@@ -0,0 +1,20 @@
+//===========================================================================
+//chapter 7 example 5
+clc;clear all;
+
+//variable declaration
+f = 50; //frequency in Hz
+L = 5*10^-3 //inductance
+V = 100; //voltage in V
+I = 10; //current in A
+R1 = 3000; //resistance in Ω
+
+//calculations
+x = ((2*%pi*f*L)/R1); //tan(theta)
+theta = atan(x); //the angle by which the current in pressure coil lags behind the voltage
+//W = V*I*sin(90+theta) = V*I*cos(theta) = V*I*tan(theta)
+//W=V*I*theta //since theta is small
+W = V*I*x; //reading of wattmeter in watt
+
+//result
+mprintf("error = %3.2f watts",W);
diff --git a/3871/CH7/EX7.6/Ex7_6.sce b/3871/CH7/EX7.6/Ex7_6.sce
new file mode 100644
index 000000000..7c6825183
--- /dev/null
+++ b/3871/CH7/EX7.6/Ex7_6.sce
@@ -0,0 +1,30 @@
+//===========================================================================
+//chapter 7 example 6
+clc;clear all;
+
+//variable declaration
+RL = 2; //resistance in Ω
+f =50; //frequency in Hz
+L = 0.25; //inductance in H
+V = 200; //voltage in V
+LP = 5.6*10^-3; //inductance in H
+RP =1000;
+
+//calculations
+XL = 2*%pi*f*L; //load reactance in Ω
+ZL = RL+XL*%i; //load impedance
+IL = V/ZL; //load current in A
+XLP = 2*%pi*f*LP; //reactance in Ω
+ZP = RP+XLP*%i; //pressure coil circuit impedance in Ω
+IP = V/ZP; //pressure coil current in A
+theta = (atan(imag(IP)/real(IP)))*180/%pi;
+Ic = IL+IP;
+Ic1 = sqrt(((imag(Ic))^2)+((real(Ic))^2))
+phi = (atan(imag(Ic)/real(Ic)))*180/%pi;
+A = (phi-theta);
+x = cos((A*%pi)/180);
+y =cos((theta*%pi)/180);
+W = V*Ic1*y*x; //actual reading of wattmeter in watts
+
+//result
+mprintf("actual reading of wattmeter = %3.4f watts",W);
diff --git a/3871/CH7/EX7.7/Ex7_7.sce b/3871/CH7/EX7.7/Ex7_7.sce
new file mode 100644
index 000000000..f2c868146
--- /dev/null
+++ b/3871/CH7/EX7.7/Ex7_7.sce
@@ -0,0 +1,27 @@
+//===========================================================================
+//chapter 7 example 7
+clc;clear all;
+
+//variable declaration
+V = 250; //load voltage in V
+I = 12; //load current in A
+Rc = 0.1; //resistance in Ω
+Rp =6500; //resistance in Ω
+x = 1; //pf cos(phi)
+y = 0.4; //pf cos(phi)
+
+//calculations
+P = V*I*x; //power input to the apparatus in W
+PL = (I^2)*Rc; //power lost in current coil in W
+e = (PL/P)*100; //percentage error in %
+Pc = (V^2)/Rp; //power lost in presuure coil in W
+e = (Pc/P)*100; //percentage error in %
+P1 = V*I*y; //power input to the apparatus in W
+PL1 = (I^2)*Rc; //power lost in current coil in W
+e1 = (PL1/P1)*100; //percentage error in %
+Pc1 = (V^2)/Rp; //power lost in presuure coil in W
+e1 = (Pc1/P1)*100; //percentage error in %
+
+//result
+mprintf("percentage error when pf 1 lagging %3.2f percentage",e);
+mprintf("\npercentage error when pf 0.4 lagging %3.2f percentage",e1);
diff --git a/3871/CH7/EX7.8/Ex7_8.sce b/3871/CH7/EX7.8/Ex7_8.sce
new file mode 100644
index 000000000..d7746901c
--- /dev/null
+++ b/3871/CH7/EX7.8/Ex7_8.sce
@@ -0,0 +1,42 @@
+ //============================================================================
+//Chapter 7 Example 8
+
+
+clc;
+clear all;
+
+//variable declaration
+theta1 =1; //pressure coil phase angle in °
+theta2 =2; //pressure coil phase angle in °
+P1 = 700; //wattmeter reading in W
+P2 = 620; //wattmeter reading in W
+V = 240; //voltage in V
+
+
+//calculations
+x = P1/P2;
+//P1 =P*cos(theta2)*cos(phi-theta2)/cos(phi)
+//P2 = P*cos(theta1)*cos(phi-theta1)/cos(phi)
+//P1/P2 = cos(theta2)*cos(phi-theta2)/cos(phi)/cos(theta1)*cos(phi-theta1)/cos(phi)
+//x = cos(theta2)*cos(phi-theta2)/cos(phi)/cos(theta1)*cos(phi-theta1)/cos(phi)
+//x = (cos(theta2)/cos(theta1))*(cos(phi-theta2)/cos(phi-theta1))
+//x = y*(cos(phi-theta2)/cos(phi-theta1))
+//(cos(phi-theta2)/cos(phi-theta1)) = x/y
+y = (cos(theta2*%pi/180)/cos(theta1*%pi/180));
+z = x/y;
+//(cos(phi-theta2)/cos(phi-theta1)) = ((cos(thet2*%pi/180))*cos(phi))+(sin(thet2*%pi/180))*sin(phi))/((cos(theta1*%pi/180))*cos(phi))+(sin(thet1*%pi/180))*sin(phi))
+//z = ((cos(thet2*%pi/180))*cos(phi))+(sin(thet2*%pi/180))*sin(phi))/((cos(theta1*%pi/180))*cos(phi))+(sin(thet1*%pi/180))*sin(phi))
+t = ((z*cos(theta1*%pi/180))-(cos(theta2*%pi/180)))/((sin(theta2*%pi/180))-(z*sin(theta1*%pi/180)));
+phi = (atan(t))*180/%pi;
+pf = cos(phi*%pi/180);
+C = (phi-theta2)
+c = cos(C*%pi/180);
+a = (cos(theta2*%pi/180));
+b = a*c;
+B = P1*pf;
+P = B/b;
+I = P/(V*pf);
+
+//result
+mprintf("actual power = %3.3f W",P);
+mprintf("\ncurrent drawn = %3.2f A",I);
diff --git a/3871/CH7/EX7.9/Ex7_9.sce b/3871/CH7/EX7.9/Ex7_9.sce
new file mode 100644
index 000000000..97da88e05
--- /dev/null
+++ b/3871/CH7/EX7.9/Ex7_9.sce
@@ -0,0 +1,30 @@
+//===========================================================================
+//chapter 7 example 9
+clc;clear all;
+
+//variable declaration
+Np = 500; //number of turns on moving coil
+Ip = 0.05; //current through moving coil in A
+B = 0.012; // flux density in the air gap in T
+d = 0.03; //diameter in m
+theta1 = 30;
+theta2 = 90;
+x = 0.866; //power factor cos(phi)
+
+//calculations
+
+A = (%pi/4)*(d^2); //area of x-section of moving coilin m^2
+phimax = B*A; //maximum flux through moving coil in Wb
+//Mmax = (phimax*Np)/Ic
+//Mmax*Ic = X = phimax*Np
+X = (phimax*Np);
+//T = Ip*Ic*Mmax*cos(phi)*sin(theta)
+//T = Ip*Ic*(X/Ic)*cos(phi)*sin(theta)
+//T = Ip*(X)*cos(phi)*sin(theta)
+T1 = Ip*X*x*sin(theta1*%pi/180);
+T2 = Ip*X*x*sin(theta2*%pi/180);
+
+//result
+mprintf("torque in when 30° = %3.4e N-m",T1);
+mprintf("\ntorque in when 90° = %3.4e N-m",T2);
+