summaryrefslogtreecommitdiff
path: root/3754/CH22/EX22.14/22_14.sce
blob: e9954349df778927a8a513eb51de94f37cbac8e5 (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
27
clear//

//Variables

//When VC = 0 volts
VCC = 9.0                                //Source voltage (in volts)
RB = 220.0                               //Base Resistance (in kilo-ohm)
RC = 3.3                                 //Collector Resistance (in kilo-ohm)
VBE = 0.3                                //Emitter-to-Base voltage (in volts)
beta = 100.0                             //Common emitter current gain                     

//Calculation

IB = (VCC - VBE)/((RB + beta*RC)* 10**3) //Base current (in Ampere)
IC = beta * IB                           //Collector current (in Ampere)
VCE = VCC - IC * RC * 10**3              //Collector-to-emitter voltage (in volts)
VC = VCE                                 //Collector voltage (in volts)
ICRC = VCC                               //Voltage (in volts) 

//When VC = 9 volts
IB1 = 16.0                               //Base current (in micro-Ampere)
IC1 = beta * IB1                         //Collector current (in micro-Ampere) 
RC1 = 0                                  //Collector Resistance (in ohm)  

//Result

printf("\n In case 1, Collector junction is short circuited.\nIn case 2, Collector resistance is short circuited. " )