matlab_complex

# matlab_complex - Using MATLAB to solve Simultaneous...

This preview shows pages 1–2. Sign up to view the full content.

Using MATLAB to solve Simultaneous Complex-valued Equations: Denard Lynch Page 1 of 4 Nov 15, 2003; Revised: Nov, 2009. Open the MATLAB application (from the START Mathematics and Graphing MATLAB R2008b) on any of the lab computers. Have your simultaneous equations written in the form: a 11 i 1 + a 12 i 2 + a 13 i 3 _ … = b 1 a 21 i 1 + a 22 i 2 + a 23 i 3 _ … = b 2 a 31 i 1 + a 32 i 2 + a 33 i 3 _ … = b 3 . . a n1 i 1 + a n2 i 2 + a n3 i 3 _ … = b n Arrange the coefficients in matrix form AX=B , where: , , and Enter the coefficients into MATLAB as shown in the following example and then solve for X using MATLAB’s left division operator (\): X=A\B Example: After analyzing an AC circuit you are left with the following equations: (22 –j22)i 1 + (-10)i 2 + (0)i 3 = 10 0 0 V (-10)i 1 + (25 +j30)i 2 + (j10)i 3 = 0 (0)i 1 + (j10)i 2 + (75 +j15)i 3 = 25 40 0 V Enter these into MATLAB as follows, leaving a space only between elements in each row (note the semicolon starts a new row): >> format short g, format compact just sets up the umber format so it isn’t too long

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
This is the end of the preview. Sign up to access the rest of the document.

{[ snackBarMessage ]}

### What students are saying

• As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

Kiran Temple University Fox School of Business ‘17, Course Hero Intern

• I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

Dana University of Pennsylvania ‘17, Course Hero Intern

• The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

Jill Tulane University ‘16, Course Hero Intern