matlab - aplication of arrays and matrices in electrical systems

11

Click here to load reader

Upload: shameer-ahmed-koya

Post on 21-Jan-2018

314 views

Category:

Education


0 download

TRANSCRIPT

Page 1: MATLAB - Aplication of Arrays and Matrices in Electrical Systems

11

Application of Arrays and Matrices in Electrical Systems

Lecture – 3

by

Shameer Koya

Page 2: MATLAB - Aplication of Arrays and Matrices in Electrical Systems

2

Sets of Linear Equations

x1+2x2+3x3 = 366

4x1+5x2+6x3 = 804

7x1+8x2+0x3 = 351

In matrix form

1 2 3 x1 366

4 5 6 x2 = 804

7 8 0 x3 351

This is in the form

A * x = y

Hence x = A-1 y

Page 3: MATLAB - Aplication of Arrays and Matrices in Electrical Systems

Solving Linear Equations

The problem have a solution if rank of A and rank of augmented matrix, ( [ A y] ), are equal.

rank (A)

rank ( [ A y] )

Then test condition number of A, which should be a small number (close to 1 is better)

( the condition number associated with the linear equation Ax = b gives a bound on how inaccurate the solution x will be after approximation)

cond (A)

Now the solution is

x= inv(A)*y or x = A\y

3

rank of a matrix A is the maximum number

of linearly independent row vectors of A

Page 4: MATLAB - Aplication of Arrays and Matrices in Electrical Systems

D C Loop Analysis4

Page 5: MATLAB - Aplication of Arrays and Matrices in Electrical Systems

D C Loop Analysis …5

Page 6: MATLAB - Aplication of Arrays and Matrices in Electrical Systems

Example Circuit6

Page 7: MATLAB - Aplication of Arrays and Matrices in Electrical Systems

Example Circuit …..

In matrix form:

Matlab Script:

Z = [ 26 -20 0; -16 41 -6; -4 -6 24]

V = [10; 5; 0]

I = Z\V

7

Page 8: MATLAB - Aplication of Arrays and Matrices in Electrical Systems

Node Analysis8

Page 9: MATLAB - Aplication of Arrays and Matrices in Electrical Systems

Y = [ 0.15 -0.1 -0.05;

-0.1 0.145 -0.025;

-0.05 -0.025 0.075];

I = [5; 0; 2];

V = inv(Y)*I

Or V=Y\I

V =

404.2857

350.0000

412.8571

9

Page 10: MATLAB - Aplication of Arrays and Matrices in Electrical Systems

AC Circuit Analysis10

Page 11: MATLAB - Aplication of Arrays and Matrices in Electrical Systems

Z = [10-7.5*j -6+5*j;

-6+5*j 16+3*j];

b = -2*exp(j*pi*75/180);

V = [5; b]; % voltage vector in column form

I = inv(Z)*V; % solve for loop currents

Or I = Z\V

11