how to solve the below equations
Afficher commentaires plus anciens
a = [1 2;4 5]
b=[6 7;9 8]
c=[6 5;3 4]
d=[7 4;8 0]
e=[1 5;6 7]
f=[3 2;8 9]
A=[1 5;6 7]
B=[3 2;8 9]
A=a*x+b*y
B=c*x-d*y
I want to know x and y
Réponses (1)
Walter Roberson
le 1 Juin 2016
x = sym('x%d%d', [2 2]);
y = sym('y%d%d', [2 2]);
sol = solve([A==a*x+b*y, B==c*x-d*y]);
Xsol = [sol.x11, sol.x12; sol.x21, sol.x22]);
Ysol = [sol.y11, sol.y12; sol.y21, sol.y22]);
Catégories
En savoir plus sur Numeric Solvers dans Centre d'aide et File Exchange
Produits
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!