solve 2 equations with two sympolic variables
1 次查看(过去 30 天)
显示 更早的评论
I want solve these equations with the same variables U10 and U20 because they are part of other code
2*U20 + sin(U20)
2*U10 + sin(U10 - 1) - 2
0 个评论
回答(1 个)
Walter Roberson
2023-2-24
Those are independent equations. Over the reals they have one solution each. U20=0, U10=1
3 个评论
Askic V
2023-2-24
First of all those are NOT equations. The equation can be for example: 2*U20 + sin(U20) = 0
We can assume that you mean that both expressions are equal to zero.
If that is the case, the code is very simple:
syms U20
f = solve(2*U20 + sin(U20), U20)
So the solution is zero, just like Walter told you.
Walter Roberson
2023-2-24
syms U20
f = (2*U20 + sin(U20))
fplot(f, [-pi pi]); xline(0); yline(0)
Exactly 0.
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Calculus 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!