How to solve exponential equation in Matlab?

3 Ansichten (letzte 30 Tage)
Mudasir Buledi
Mudasir Buledi am 18 Jan. 2017
Kommentiert: Star Strider am 21 Jan. 2017
i need to to solve the equation Vr = Vs[1-exp((-R*t)/L)], for t using ''solve'' function, can't do it, there is error says ''can't find an implici solution'', Can anyone help plz.

Akzeptierte Antwort

Star Strider
Star Strider am 18 Jan. 2017
The correct syntax is important with the Symbolic Math Toolbox. You have to define your equation as an expression and assign that to a different variable (here ‘Eq1’).
The Code:
syms L R t Vr Vs
Eq1 = Vr == Vs*(1-exp((-R*t)/L));
t_sol = solve(Eq1, t)
t_sol =
-(L*log(1 - Vr/Vs))/R
  2 Kommentare
Mudasir Buledi
Mudasir Buledi am 21 Jan. 2017
Thank you!
Star Strider
Star Strider am 21 Jan. 2017
As always, my pleasure!

Melden Sie sich an, um zu kommentieren.

Weitere Antworten (0)

Kategorien

Mehr zu Symbolic Math Toolbox finden Sie in Help Center und File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by