summaryrefslogtreecommitdiff
path: root/3554/CH1
diff options
context:
space:
mode:
Diffstat (limited to '3554/CH1')
-rw-r--r--3554/CH1/EX1.1/Ex1_1.sce15
-rw-r--r--3554/CH1/EX1.2/Ex1_2.sce13
-rw-r--r--3554/CH1/EX1.3/Ex1_3.sce39
-rw-r--r--3554/CH1/EX1.4/Ex1_4.sce31
-rw-r--r--3554/CH1/EX1.5/Ex1_5.sce26
-rw-r--r--3554/CH1/EX1.6/Ex1_6.sce27
-rw-r--r--3554/CH1/EX1.7/Ex1_7.sce19
-rw-r--r--3554/CH1/EX1.8/Ex1_8.sce23
8 files changed, 193 insertions, 0 deletions
diff --git a/3554/CH1/EX1.1/Ex1_1.sce b/3554/CH1/EX1.1/Ex1_1.sce
new file mode 100644
index 000000000..4f94dba7e
--- /dev/null
+++ b/3554/CH1/EX1.1/Ex1_1.sce
@@ -0,0 +1,15 @@
+//Exa 1.1a
+
+clc;
+clear all;
+
+Yn=80;//voltage across a resistor(Volts)
+Xn=79;//Measured voltage (Volts)
+
+//solution
+e=Yn-Xn; //absolute error
+Pe=(Yn-Xn)/Yn *100;//% error
+A=1-abs((Yn-Xn)/Yn); //relative accuracy
+a=100*A;
+printf('Absolute Error = %d V \n Percentage Error = %.2f percent\n Relative accuracy = %.4f \n Percentage of accuracy = %0.2f percent \n',e,Pe,A,a);
+disp("");
diff --git a/3554/CH1/EX1.2/Ex1_2.sce b/3554/CH1/EX1.2/Ex1_2.sce
new file mode 100644
index 000000000..777c954b6
--- /dev/null
+++ b/3554/CH1/EX1.2/Ex1_2.sce
@@ -0,0 +1,13 @@
+//Exa 1.2
+
+clc;
+clear all;
+
+//Refering to table 1.1- Set of 10 measurements that were recorded in the laboratory.
+
+X={98;101;102;97;101;100;103;98;106;99}; //From table 1.1
+
+//solution
+X_n= mean(X); //Average value
+Prec=1-abs((X(6)-X_n)/X_n);//precision of 6th reading
+printf('The precision of 6th measurement = %0.3f \n',Prec);
diff --git a/3554/CH1/EX1.3/Ex1_3.sce b/3554/CH1/EX1.3/Ex1_3.sce
new file mode 100644
index 000000000..97002fa04
--- /dev/null
+++ b/3554/CH1/EX1.3/Ex1_3.sce
@@ -0,0 +1,39 @@
+// Exa 1.3a
+
+clc;
+clear all;
+
+Sv=1000; //voltmeter sensitivity(ohm/V)
+Vt=80; //Voltage across unknown resistance (V)
+It=10; //Current through unknown resistance (mA)
+Scale=150; //Volts
+
+//solution
+
+//Neglecting milliammeter resistance
+Rt=Vt/It; //Total circuit resistance(K ohm)
+Rv=Sv*Scale/1000; //Voltmeter resistance(K ohm/V)
+Rx=Rt*Rv/(Rv-Rt); //actual value of unknown resistance(K ohm)
+err=(Rx-Rt)/Rx *100;
+printf('Apparent value of resistance = %d K ohm \n Actual value of resistance = %.2f K ohm \n Percentage error = %.1f percent \n',Rt,Rx,err);
+disp("");
+
+// Exa 1.3b
+
+Sv=1000; //voltmeter sensitivity(ohm/V)
+Vt=30; //Voltage across unknown resistance (V)
+It=600; //Current through unknown resistance (mA)
+Scale=150; //Volts
+
+//solution
+
+//Neglecting milliammeter resistance
+Rt=Vt/(It*10^-3); //Total circuit resistance(ohm)
+Rv=Sv*Scale; //Voltmeter resistance(ohm/V)
+Rx=Rt*Rv/(Rv-Rt); //actual value of unknown resistance(ohm)
+err=(Rx-Rt)/Rx *100;
+printf('Apparent value of resistance = %d ohm \n Actual value of resistance = %.3f ohm \n Percentage error = %.3f \n',Rt,Rx,err);
+disp("In Example1.3a, a well calibrated voltmeter may give a misleading resistance when connected across two points in a high resistance circuit.")
+disp("The same voltmeter, when connected in a low resistance circuit(Examole 1.3b) may give a more dependable reading. This shows that voltmeters have a loading effect in the circuit during measurement.");
+// In the 1.3b example, the answer mentioned in the textbook for Rx and percent error is isncorrect.
+
diff --git a/3554/CH1/EX1.4/Ex1_4.sce b/3554/CH1/EX1.4/Ex1_4.sce
new file mode 100644
index 000000000..c22cf88c6
--- /dev/null
+++ b/3554/CH1/EX1.4/Ex1_4.sce
@@ -0,0 +1,31 @@
+// Exa 1.4
+
+clc;
+clear all;
+
+// Given data
+x1= 49.7;
+x2= 50.1;
+x3= 50.2;
+x4= 49.6;
+x5= 49.7;
+
+// solution
+
+X_mean= (x1+x2+x3+x4+x5)/5; // Arithmatic mean
+
+d1= x1-X_mean;
+d2= x2-X_mean; // deviation from each value
+d3= x3-X_mean;
+d4=x4-X_mean;
+d5=x5-X_mean;
+
+d_total= d1+d2+d3+d4+d5; //Algebraic sum of deviations
+
+printf('The arithmatic mean is %.2f \n \n',X_mean);
+printf(' Deviation from x1 is %.2f \n ',d1);
+printf('Deviation from x2 is %.2f \n ',d2);
+printf('Deviation from x3 is %.2f \n ',d3);
+printf('Deviation from x4 is %.2f \n ',d4);
+printf('Deviation from x5 is %.2f \n \n',d5);
+printf(' The algebraic sum of deviation is %d \n',d_total);
diff --git a/3554/CH1/EX1.5/Ex1_5.sce b/3554/CH1/EX1.5/Ex1_5.sce
new file mode 100644
index 000000000..7c323e56a
--- /dev/null
+++ b/3554/CH1/EX1.5/Ex1_5.sce
@@ -0,0 +1,26 @@
+// Exa 1.5
+//Data taken from Exa 1.4 as stated
+
+clc;
+clear all;
+
+// Given data
+
+x1= 49.7;
+x2= 50.1;
+x3= 50.2;
+x4= 49.6;
+x5= 49.7;
+n= 5; // number of x values
+
+// solution
+
+X_mean= (x1+x2+x3+x4+x5)/5; // Arithmatic Mean
+d1= x1-X_mean;
+d2= x2-X_mean; // deviation from each value
+d3= x3-X_mean;
+d4=x4-X_mean;
+d5=x5-X_mean;
+
+D_av= (abs(d1)+abs(d2)+abs(d3)+abs(d4)+abs(d5))/n; //Average deviation
+printf('The average deviation = %.3f \n',D_av);
diff --git a/3554/CH1/EX1.6/Ex1_6.sce b/3554/CH1/EX1.6/Ex1_6.sce
new file mode 100644
index 000000000..1b18337d9
--- /dev/null
+++ b/3554/CH1/EX1.6/Ex1_6.sce
@@ -0,0 +1,27 @@
+// Exa 1.6
+//Data taken from Eg 1.4 as stated
+
+clc;
+clear all;
+
+// Given data
+
+x1= 49.7;
+x2= 50.1;
+x3= 50.2;
+x4= 49.6;
+x5= 49.7;
+n= 5; // number of x values
+
+// solution
+
+X_mean= (x1+x2+x3+x4+x5)/5; // Arithmatic Mean
+d1= x1-X_mean;
+d2= x2-X_mean; // deviation from each value
+d3= x3-X_mean;
+d4=x4-X_mean;
+d5=x5-X_mean;
+
+Std_dev= sqrt((d1^2+d2^2+d3^2+d4^2+d5^2)/(n-1)); //Standard deviation
+printf('The standard deviation = %.2f \n',Std_dev);
+
diff --git a/3554/CH1/EX1.7/Ex1_7.sce b/3554/CH1/EX1.7/Ex1_7.sce
new file mode 100644
index 000000000..e466deaba
--- /dev/null
+++ b/3554/CH1/EX1.7/Ex1_7.sce
@@ -0,0 +1,19 @@
+// Exa 1.7
+
+clc;
+clear all;
+
+// Given data
+
+Range= 600; //volgmeter range(volts)
+Accu= 0.02; //Accuracy
+X= 250; //voltage to be measured(volts)
+
+// Solution
+
+Mag= Accu * Range; //magnitude of limiting error
+X_mag = Mag/X * 100; // limiting error at 250V inpercentag
+
+printf('Limiting error when instrument is used to measure at 250V = %.1f percentage \n',X_mag);
+
+
diff --git a/3554/CH1/EX1.8/Ex1_8.sce b/3554/CH1/EX1.8/Ex1_8.sce
new file mode 100644
index 000000000..9662b2138
--- /dev/null
+++ b/3554/CH1/EX1.8/Ex1_8.sce
@@ -0,0 +1,23 @@
+// Exa 1.8
+
+clc;
+clear all;
+
+// Given data
+
+X= 100; // Range of voltmeter(V)
+x= 70; // Measured value on voltmeter(V)
+Y= 150; // Range of milliammeter
+y= 80; // Measurex d value on milliammeter
+Accu= 0.015; // Accuracy of instruments
+
+// Solution
+
+X_mag= Accu*X; //Magnitude of limiting error for voltmeter
+Y_mag= Accu*Y; // Magnitude of limiting error for milliammeter
+x_mag= X_mag/x; // limiting error at 70V
+y_mag= Y_mag/y; // limiting error at 80mA
+
+disp("Limiting error for the power calculation is the sum of the individual limiting errors involved");
+printf(' Therefore, limiting error = %.3f percentage \n',(x_mag+y_mag)*100);
+// The answer vary due to round off error