How to plot this type of function?

3 vues (au cours des 30 derniers jours)
Dinh Le Dung
Dinh Le Dung le 3 Août 2022
Modifié(e) : KSSV le 4 Août 2022
  2 commentaires
Walter Roberson
Walter Roberson le 4 Août 2022
Strange, I could have sworn I saw someone post code for this involving fplot3()
Dinh Le Dung
Dinh Le Dung le 4 Août 2022
That was me LOL

Connectez-vous pour commenter.

Réponses (1)

KSSV
KSSV le 4 Août 2022
Modifié(e) : KSSV le 4 Août 2022
t = linspace(-5,5) ;
x = exp(t) ;
y = 1-exp(-t) ;
z = atan2(y,x) ;
plot(t,z)
  3 commentaires
Walter Roberson
Walter Roberson le 4 Août 2022
Note that atan(y./x) is usually better done as atan2(y, x) . The difference is that atan2() will get the right quadrant.
KSSV
KSSV le 4 Août 2022
Modifié(e) : KSSV le 4 Août 2022
@Walter Roberson agree.....edited the code.

Connectez-vous pour commenter.

Catégories

En savoir plus sur Line Plots dans Help Center et File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by