Tasked with solving the system of equations

solve the system of equations :
5x + 3y - 8z + 16w = -21
6x + 8z - 20w = 18
7x + 9y + 12z - 8w = 15
16y + 11z + 8w = 10

Answers (1)

syms x y z w
RC = @() randi([-25 25]);
eqn1 = RC()*x + RC()*y + RC()*z + RC()*w == RC()
eqn1 = 
eqn2 = RC()*x + RC()*y + RC()*z + RC()*w == RC()
eqn2 = 
eqn3 = RC()*x + RC()*y + RC()*z + RC()*w == RC()
eqn3 = 
eqn4 = RC()*x + RC()*y + RC()*z + RC()*w == RC()
eqn4 = 
eqns = [eqn1;eqn2;eqn3;eqn4]
eqns = 
vars = [x, y, z, w];
[A,b] = equationsToMatrix(eqns, vars)
A = 
b = 
vars(:) == A\b
ans = 

Categories

Asked:

on 7 Oct 2021

Answered:

on 7 Oct 2021

Community Treasure Hunt

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

Start Hunting!