Professional Documents
Culture Documents
Shrinathji Institute of Technology & Engineering, Nathdwara
Shrinathji Institute of Technology & Engineering, Nathdwara
Shrinathji Institute of Technology & Engineering, Nathdwara
Number of Experiment
SYSTEM PROGRAMMING LAB
DEPARTMENT OF ELECTRICAL Code: 5EE9A No.: 4
Pg No.1/4
EXPRIMENT NO.4
4x-2y+6z=8
2x+8y+2z=4
6x+10y+3z=0
A=2 6 3
5 8 4
B =1 4 10
3 2 7
>> A.*B
ans = 2 24 30
15 16 28
>> C=A./B
>> B.^3
ans = 1 64 1000
27 8 343
>> A*B
??? Error using ==> mtimes
Inner matrix dimensions must agree.
>> x=[1:8]
x= 1 2 3 4 5 6 7 8
>> y=x.^2-4*x
y = -3 -4 -3 0 5 12 21 32
>> z=[1:2:15]
z =1 3 5 7 9 11 13 15
>> y=(z.^3+5*z)./(4*z.^2-10)
(iii) The electric resistive network shown below consists of resistors and
voltage sources. Determine the current in each resistor using the mesh current
method which is based on Kirchhoff’s voltage law.
R1=18, R2=10, R3=16, R4=6, R5=15, R6=8, R7=12, R8=14.
V1=20V, V2=12V, V3= 40V.
SHRINATHJI INSTITUTE OF TECHNOLOGY & ENGINEERING, NATHDWARA
Number of Experiment
SYSTEM PROGRAMMING LAB
DEPARTMENT OF ELECTRICAL Code: 5EE9A No.: 4
Pg No.3/4
circuit
>> R1=18;R2=10;R3=16;R4=6;
>> R5=15;R6=8;R7=12;R8=14;
A = -44 10 16 0
10 -43 6 12
16 6 -30 8
0 12 8 -34
>> B=[-V1;0;V2;-V3]
B = -20
12
-40
>> I=A\B
I = 0.8411
0.7206
0.6127
1.5750
RESULT: We have solve following linear equation and circuit solved by MATLAB