Multiplying matrices with values in polar form
10 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
Luccas S.
am 11 Aug. 2021
Kommentiert: Luccas S.
am 14 Aug. 2021
Hello, I'm trying to perform the following operation (Image). I did the operation in complex form in matlab and it worked, but I would like to know how to make it in polar form so I don't need to convert all the values.
a = 1 ∠ 120
I0 = I1 = I2 = 1.7478 ∠ - 90
I was using the following function to multiply complex numbers:
function [ sum ] = pmult( x,y )
A=x(1).*y(1);
B=x(2)+y(2);
sum=[A B];
end
I tried to use it in the matrix, but it was not successful.
0 Kommentare
Akzeptierte Antwort
DGM
am 12 Aug. 2021
Bearbeitet: DGM
am 12 Aug. 2021
It's been a long time since I did this, but here goes:
% note that phasors in polar form are not scalar
% a complex number in rectangular form can be a scalar!
% if you're going to do matrix algebra with the numbers,
% they really need to be in rectangular form in order to fit
a = [1 120];
I0 = [1.7478 -90];
% define a conversion function, convert to rectangular form
% you could also use pol2cart(), but you'd also need to convert to radians
p2r = @(x) x(1).*cosd(x(2)) + x(1).*sind(x(2))*1j;
a = p2r(a)
I0 = p2r(I0)
F = [1 1 1; 1 a^2 a; 1 a a^2];
ICC = F*[I0; I0; I0] % answer in rect form
ICCp = [abs(ICC) angle(ICC)/pi*180] % convert to phasor in degrees
Note that this last conversion only works neatly if ICC is a column vector, since ICCp needs to have twice as many columns as ICC.
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Create Fixed-Point Objects in MATLAB finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!