Méthode Python math.tanh()
Exemple
Trouvez la tangente hyperbolique de différents nombres :
# Import math Library
import math
# Return the hyperbolic tangent of
different numbers
print(math.tanh(8))
print(math.tanh(1))
print(math.tanh(-6.2))
Définition et utilisation
La math.tanh()
méthode renvoie la tangente hyperbolique d'un nombre.
Syntaxe
math.tanh(x)
Valeurs des paramètres
Parameter | Description |
---|---|
x | Required. A number to find the hyperbolic tangent of. If the value is not a number, it returns a TypeError |
Détails techniques
Valeur de retour : | Une float valeur, représentant la tangente hyperbolique d'un nombre |
---|---|
Version Python : | 1.4 |