summaryrefslogtreecommitdiff
path: root/1757/CH4/EX4.5/EX4_5.sce
blob: c110fea47b7812b95d3b6e56deb810714df386ef (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
//Example 4.5 // Determine the differece voltage and open loop gain of an op-amp
clc ;
clear ;
close ;
V1 = 5 ; // volt // input voltage  // GND
V2 = -5 ; // volt  
Vo = -20 ; //volt  // output voltage

// the difference voltage is given by 
 Vd = V2-V1 ;
disp('  The difference voltage is = '+string(Vd)+' V ');

// open loop gain 
A = (Vo/Vd);
disp('  The open loop gain is = '+string(A)+'  ');