blob: 8f6a13274fde341259872c441409639e14963a49 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
|
//Chapter 3
//Example 3-1
//ProbOnOpampDescriptions
//Page 46,47 figure 3-1
clear;clc;
//Given
Rf=100*(10^3);//Feedback Resistance in ohms
Ri=10*(10^3);//Input Resistance in ohms
Ei=1;//Input volts
//Calculate
//Example 3-1(a)
I=Ei/Ri;//Equation for current through Rf
printf("\n\n Current through Rf = %.4f A \n\n",I)
//Example 3-1(b)
Vout=-(Rf/Ri)*Ei;//Equation for Output Voltage
printf("\n\n Value of output voltage = %.4f V \n\n",Vout)
//Example 3-1(c)
Acl=-(Rf/Ri);//Closed loop gain of the amplifier
printf("\n\n Value of closed loop gain = %.4f \n\n",Acl)
|