Finding x from function - symbolics

Hi, I'm looking for a command to find x from my function (it's a bit long function but i'm writing an example): y=ax+b (for example), and i wanna transform it to expression: x=... by command (I mean determination x from this equation). It's all symbolics. Please, help me!

回答 (1 件)

Star Strider
Star Strider 2015 年 5 月 6 日

0 投票

Use the solve function. Note that since your function is longer than your example (and we do not know what it is), it may not have an analytic solution in x.

3 件のコメント

kamil oster
kamil oster 2015 年 5 月 6 日
編集済み: kamil oster 2015 年 5 月 6 日
Everything would be OK, but when i use this function for y=ax+b i get -b/a. And i don't wanna lose y. I'm trying to find the command to transform y=ax+b to x=y-b/a.
Walter Roberson
Walter Roberson 2015 年 5 月 6 日
syms x a b
y = a*x+b;
solve(y, x)
Star Strider
Star Strider 2015 年 5 月 6 日
Thank you, Walter.

サインインしてコメントする。

カテゴリ

ヘルプ センター および File ExchangeSymbolic Math Toolbox についてさらに検索

質問済み:

2015 年 5 月 6 日

コメント済み:

2015 年 5 月 6 日

Community Treasure Hunt

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

Start Hunting!

Translated by