Chp3 Nodal Analysis & MATLAB Engineering 43 Chp3 Nodal Analysis & MATLAB Bruce Mayer, PE Licensed Electrical & Mechanical Engineer BMayer@ChabotCollege.edu
Last of The Hand-Soln
The .m Script File % ENGR43_Chp3_Nodal_Analysis_MATLAB_Tutorial_0602.m % Bruce Mayer, PE % ENGR43 * 05Feb05 % % The Coeffiecent Matrix A (unitless) A = [1 0 0 0; 0 0 -1 1; -4 7 -2 0; 30 -25 -4 -10] % The Constraint Vector B B = [40; 60; 0; -200] % in Volts % Solve by MATLAB "Back Division" V = A\B; disp('The Solution Vector, [V1; V2; V3; V4] in Volts = ') disp(V) % Power to I-Src is V4*10mA disp('Power Supplied by 10 mA current source in mW =') disp(V(4)*10)
The Solution From ENGR43_Chp3_Nodal_Analysis_MATLAB_Tutorial_0602.m 1 0 0 0 0 0 -1 1 -4 7 -2 0 30 -25 -4 -10 B = 40 60 -200 The Solution Vector, [V1; V2; V3; V4] in Volts = 40.0000 25.9459 10.8108 70.8108 Power Supplied by 10 mA current source in mW = 708.1081