summaryrefslogtreecommitdiff
path: root/2234/CH3/EX3.26/ex3_26.sce
blob: a019d353fd42f095c0385ebb308a61a660ab717f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
clc;
v=10^-5;  //ac voltage
di=10*10^-3;  //discharge rate of current
t=10*10^-3;  //time in sec
ch=(14.14-0.6);  //charge of capacitor
q=ch*v;  //charge
disp(q,"Charge in Coloumb = ");  //displaying result
qt=di*t;  //charge for 10 ms
rc=q-qt;  //remaining charge
disp(qt,"Charge for 10 ms = ");  //displaying result
disp(rc,"Remaining charge in Coloumb = ");  //displaying result
a=(rc/q)*10;  //voltage
disp(a,"Voltage in volt = ");  //displaying result