summaryrefslogtreecommitdiff
path: root/1628/CH4/EX4.5/Ex4_5.sce
blob: 4e36b796646f529cd86909d4d5deeecde58c074a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26

                             // Examle 4.5

               // From the diagram (4.8)
               // Using thevenin's equivalent theorem

V1=50;                             // Voltage source V1
V2=10;                             // Voltage source V2
I1=(V1-V2)/(10+10+20);             // Current through the ckt ( when Current source is off )

i=1.5;                            // Current source i
I2=i*(10/(10+(10+20)));           // Current through the ckt ( when Current source is active )
I=I1+I2;                          // Addition of I1 & I2
Vth= I*20;                        // Thevenin's voltage at 20 Ohms R

Rth=(20*(10+10))/(20+(10+10));    // Thevenin's resistance 

Vl=Vth*(5/(5+10));                // Voltage across Rl
disp(' Voltage across olad resistor (Rl) = '+string(Vl)+' Volt');






                    // p 110         4.5