Méthode Python math.cosh()
Exemple
Trouvez le cosinus hyperbolique de différents nombres :
# Import math Library
import math
# Return the hyperbolic cosine of
different numbers
print (math.cosh(1))
print (math.cosh(8.90))
print (math.cosh(0))
print (math.cosh(1.52))
Définition et utilisation
La math.cosh()
méthode renvoie le cosinus hyperbolique d'un nombre (équivalent à (exp(nombre) + exp(-nombre)) / 2).
Syntaxe
math.cosh(x)
Valeurs des paramètres
Parameter | Description |
---|---|
x | Required. A number to find the hyperbolic cosine of. If the value is not a number, it returns a TypeError |
Détails techniques
Valeur de retour : | Une float valeur, représentant le cosinus hyperbolique d'un nombre |
---|---|
Version Python : | 1.4 |