Cartesian to polar matrix

29 ビュー (過去 30 日間)
Ahmet Furkan USLU
Ahmet Furkan USLU 2019 年 11 月 23 日
コメント済み: Ahmet Furkan USLU 2019 年 11 月 25 日
Hello,
There is a matrix ;
Ybus=
x1+y1j x2+y2j x3+y3j x4+y4j
Our code should convert polar form;
Result=
x1angle x2 angle x3 angle x4 angle
Can you help us ,please?

回答 (2 件)

Bhaskar R
Bhaskar R 2019 年 11 月 23 日
If Ybus = [x + iy] then
[angle_Ybus, rho_Ybus] = cart2pol(real(Ybus), imag(Ybus));
  2 件のコメント
Ahmet Furkan USLU
Ahmet Furkan USLU 2019 年 11 月 24 日
Ybus = [ 20 -j*50 -10 +j*20 -10 +j*30
-10+j*20 26-j*52 -16+j*32
-10+j*30 -16+j*32 26-j*62];
[angle_Ybus, rho_Ybus] = cart2pol(real(Ybus), imag(Ybus));
D = rad2deg(angle_Ybus)
Result=[rho_Ybus ; D]
>> Result
Result =
53.8516 22.3607 31.6228 -68.1986 116.5651 108.4349
22.3607 58.1378 35.7771 116.5651 -63.4349 116.5651
31.6228 35.7771 67.2309 108.4349 116.5651 -67.2490
But Result Should be ;
>> Result
Result =
53.8516 -68.1986 22.3607 116.5651 31.6228 108.4349
22.3607 116.5651 58.1378 -63.4349 35.7771 116.5651
31.6228 108.4349 35.7771 116.5651 -67.2490 67.2309
Ahmet Furkan USLU
Ahmet Furkan USLU 2019 年 11 月 24 日
It should be [rho angle rho angle rho angle
rho angle rho angle rho angle
rho angle rho angle rho angle]
Thanks for support

サインインしてコメントする。


Bhaskar R
Bhaskar R 2019 年 11 月 25 日
Ybus = [ 20-j*50 -10+j*20 -10+j*30
-10+j*20 26-j*52 -16+j*32
-10+j*30 -16+j*32 26-j*62];
[angle_Ybus, rho_Ybus] = cart2pol(real(Ybus), imag(Ybus));
D = rad2deg(angle_Ybus);
% initialize Result with zeros
Result = zeros(size(rho_Ybus, 1), 2*size(rho_Ybus, 2));
% place rho values in alternative column
Result(:,1:2:end) = rho_Ybus;
% place D values in alternative column
Result(:,2:2:end) = D;
% Result is your required matrix
  1 件のコメント
Ahmet Furkan USLU
Ahmet Furkan USLU 2019 年 11 月 25 日
Thanks a lot "master".

サインインしてコメントする。

カテゴリ

Help Center および File ExchangePolar Plots についてさらに検索

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by