Suggestions on solving this complex-vector-nonlinear system of equations in MATLAB
조회 수: 1 (최근 30일)
이전 댓글 표시
José David Castillo Blanco
2022년 6월 15일
댓글: José David Castillo Blanco
2022년 6월 16일
I have this equation in here:
W is a vector with a component in the real numbers and one in the imaginary numbers (At the end it's just like an x component and y component), same with Z and delta 2 and delta 3.
I want to know about ways to solve this using Matlab or something in Toolbox, I already tried to debunk the equation to get a 4x4 non linear equation and I solved it
clc
clear all
syms wx zx wy zy
alfa2=205*(pi/180);
alfa3=55*(pi/180);
beta2=39*(pi/180);
beta3=94*(pi/180);
delta2x=0.2;
delta2y=1.2;
delta3x=-0.75;
delta3y=2.5;
E1=wx*cos(beta2)-wx+wy*sin(beta2)+zx*cos(alfa2)-zx+zy*sin(alfa2)-delta2x;
E2=wx*sin(beta2)+wy*cos(beta2)-wy+zx*sin(alfa2)+zy*cos(alfa2)-zy-delta2y;
E3=wx*cos(beta3)-wx+wy*sin(beta3)+zx*cos(alfa3)-zx+zy*sin(alfa3)-delta3x;
E4=wx*sin(beta3)+wy*cos(beta3)-wy+zx*sin(alfa3)+zy*cos(alfa3)-zy-delta3y;
result=vpasolve([E1,E2,E3,E4], [wx,zx,wy,zy],[1,1,1,1])
I wanna know any other way to solve it in Matlab
댓글 수: 0
채택된 답변
Torsten
2022년 6월 15일
편집: Torsten
2022년 6월 15일
This is a simple linear system of equations in the unknowns W and Z:
alpha2 = 205*(pi/180);
alpha3 = 55*(pi/180);
beta2 = 39*(pi/180);
beta3 = 94*(pi/180);
delta2x = 0.2;
delta2y = 1.2;
delta2 = delta2x + 1i*delta2y;
delta3x = -0.75;
delta3y = 2.5;
delta3 = delta3x + 1i*delta3y;
A = [exp(1i*beta2)-1.0,exp(1i*alpha2)-1.0 ; exp(1i*beta3)-1.0,exp(1i*alpha3)-1.0];
b = [delta2;delta3];
sol = A\b;
W = sol(1)
Z = sol(2)
댓글 수: 2
추가 답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Assumptions에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!