Find v_O in terms of the inputs v_{S1} and v_{S2} in Figure P4-35.
Use superposition and the known OP AMP circuits to determine the input-output relationship.
The following MATLAB code contains the necessary steps.
clear all
syms vs1 vs2 R1 R2 vo
% Turn on vs1 and ground vs2
% The signal from vs1 passes through two inverting amplifiers
K1 = -R2/R1;
K2 = -R1/R2;
Kvs1 = K1*K2;
% Turn on vs2 and ground vs1
% Analyze each path for vs2 separately
% First path is through both OP AMPs
% One is a non-inverting amplifier and the other is an inverting amplifier
K3 = (R1+R2)/R1;
K4 = K2;
% Second part is through one OP AMP as a non-inverting amplifier
K5 = (R2+R1)/R2;
% Combine the gains for vs2
Kvs2 = K3*K4+K5;
% Create the output expression
vo = Kvs1*vs1+Kvs2*vs2
vo =
vs1
v_O = v_{S1} + 0v_{S2}.