Solving simultaneous equations without martix method

4 次查看(过去 30 天)
Hi
What is simply way to solve for a simultaneous equation like below without the uses of matrix method. I was hoping to implement to a hard equation as below is just a example.
x+y=10
x+2*y=15

采纳的回答

Star Strider
Star Strider 2018-8-11
You would most likely have to use the Symbolic Math Toolbox:
syms x y
Eq1 = x + y == 10;
Eq2 = x + 2*y == 15;
[x,y] = solve(Eq1, Eq2)
x =
5
y =
5

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Symbolic Math Toolbox 的更多信息

Community Treasure Hunt

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

Start Hunting!

Translated by