How to solve symbolic function
1 回表示 (過去 30 日間)
古いコメントを表示
I want to solve t:
eq=(ap^2*t^3)/2 - ap*t^3 + (ap*t^2)/2 - t^3/2 + t^2/2 + (127*t)/8 - 8
assume(1>ap>0)
sol=solve(eq==0,t,"ReturnConditions",true)
But I got this result:
[root(4*ap^2*z^3 - 8*ap*z^3 - 4*z^3 + 4*ap*z^2 + 4*z^2 + 127*z - 64, z, 1); root(4*ap^2*z^3 - 8*ap*z^3 - 4*z^3 + 4*ap*z^2 + 4*z^2 + 127*z - 64, z, 2); root(4*ap^2*z^3 - 8*ap*z^3 - 4*z^3 + 4*ap*z^2 + 4*z^2 + 127*z - 64, z, 3)]
ans =
Empty sym: 1-by-0
I want to get the result like t(ap)=...
Could you please give me some teaching to help me to solve this problem? Thanks a lot.
0 件のコメント
回答 (1 件)
Torsten
2023 年 5 月 7 日
syms t ap
eq=(ap^2*t^3)/2 - ap*t^3 + (ap*t^2)/2 - t^3/2 + t^2/2 + (127*t)/8 - 8
sol=solve(eq==0,'ReturnConditions',true,'MaxDegree',3)
sol.t
sol.conditions
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!

