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!

Respuestas (1)

Star Strider
Star Strider el 6 de Mayo de 2015

0 votos

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 comentarios

kamil oster
kamil oster el 6 de Mayo de 2015
Editada: kamil oster el 6 de Mayo de 2015
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.
syms x a b
y = a*x+b;
solve(y, x)
Star Strider
Star Strider el 6 de Mayo de 2015
Thank you, Walter.

Iniciar sesión para comentar.

Categorías

Más información sobre Symbolic Math Toolbox en Centro de ayuda y File Exchange.

Preguntada:

el 6 de Mayo de 2015

Comentada:

el 6 de Mayo de 2015

Community Treasure Hunt

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

Start Hunting!

Translated by