TAN |
Tangente |
---|---|
MySQL |
Syntaxe
Tan(Nombre) |
Paramètres
Nom | Description |
---|---|
Nombre | Ce paramètre permet d'indiquer l'expression contenant le nombre à traiter |
Description
Cette fonction retourne la tangente.
Algorithme
MODULE COS(X) R ← X x X S ← 42.0 BOUCLE POUR I ← 10 JUSQU'A 1 S ← 4.0 x I - 2.0 + (-R) / S FIN BOUCLE POUR S ← S x S RETOURNE (S - R) / (S + R) MODULE SIN(X) R ← X x X S ← 42.0 BOUCLE POUR I ← 10 JUSQU'A 1 S ← 4.0 x I - 2.0 + (-R) / S FIN BOUCLE POUR RETOURNE 2.0 x X x S / (R + S x S) MODULE TAN(X) RETOURNE SIN(X)/COS(X) |
Exemple
Voici un exemple permet d'afficher les tangentes inférieurs à π :
on obtiendra le résultat suivant :
+------------------------------+| CONCAT("Tan(",R,")=",tan(R)) |
+------------------------------+
| Tan(0)=0 |
+------------------------------+
+------------------------------+
| CONCAT("Tan(",R,")=",tan(R)) |
+------------------------------+
| Tan(0.1)=0.100334672085451 |
+------------------------------+
+------------------------------+
| CONCAT("Tan(",R,")=",tan(R)) |
+------------------------------+
| Tan(0.2)=0.202710035508673 |
+------------------------------+
+------------------------------+
| CONCAT("Tan(",R,")=",tan(R)) |
+------------------------------+
| Tan(0.3)=0.309336249609623 |
+------------------------------+
+------------------------------+
| CONCAT("Tan(",R,")=",tan(R)) |
+------------------------------+
| Tan(0.4)=0.422793218738162 |
+------------------------------+
+------------------------------+
| CONCAT("Tan(",R,")=",tan(R)) |
+------------------------------+
| Tan(0.5)=0.54630248984379 |
+------------------------------+
+------------------------------+
| CONCAT("Tan(",R,")=",tan(R)) |
+------------------------------+
| Tan(0.6)=0.684136808341692 |
+------------------------------+
+------------------------------+
| CONCAT("Tan(",R,")=",tan(R)) |
+------------------------------+
| Tan(0.7)=0.842288380463079 |
+------------------------------+
+------------------------------+
| CONCAT("Tan(",R,")=",tan(R)) |
+------------------------------+
| Tan(0.8)=1.02963855705036 |
+------------------------------+
+------------------------------+
| CONCAT("Tan(",R,")=",tan(R)) |
+------------------------------+
| Tan(0.9)=1.26015821755034 |
+------------------------------+
+------------------------------+
| CONCAT("Tan(",R,")=",tan(R)) |
+------------------------------+
| Tan(1)=1.5574077246549 |
+------------------------------+
+------------------------------+
| CONCAT("Tan(",R,")=",tan(R)) |
+------------------------------+
| Tan(1.1)=1.96475965724865 |
+------------------------------+
+------------------------------+
| CONCAT("Tan(",R,")=",tan(R)) |
+------------------------------+
| Tan(1.2)=2.57215162212632 |
+------------------------------+
+------------------------------+
| CONCAT("Tan(",R,")=",tan(R)) |
+------------------------------+
| Tan(1.3)=3.60210244796798 |
+------------------------------+
+------------------------------+
| CONCAT("Tan(",R,")=",tan(R)) |
+------------------------------+
| Tan(1.4)=5.79788371548289 |
+------------------------------+
+------------------------------+
| CONCAT("Tan(",R,")=",tan(R)) |
+------------------------------+
| Tan(1.5)=14.1014199471718 |
+------------------------------+
+------------------------------+
| CONCAT("Tan(",R,")=",tan(R)) |
+------------------------------+
| Tan(1.6)=-34.2325327355571 |
+------------------------------+
+------------------------------+
| CONCAT("Tan(",R,")=",tan(R)) |
+------------------------------+
| Tan(1.7)=-7.69660213945913 |
+------------------------------+
+------------------------------+
| CONCAT("Tan(",R,")=",tan(R)) |
+------------------------------+
| Tan(1.8)=-4.28626167462805 |
+------------------------------+
+------------------------------+
| CONCAT("Tan(",R,")=",tan(R)) |
+------------------------------+
| Tan(1.9)=-2.92709751467777 |
+------------------------------+
+------------------------------+
| CONCAT("Tan(",R,")=",tan(R)) |
+------------------------------+
| Tan(2)=-2.18503986326152 |
+------------------------------+
+------------------------------+
| CONCAT("Tan(",R,")=",tan(R)) |
+------------------------------+
| Tan(2.1)=-1.70984654290451 |
+------------------------------+
+------------------------------+
| CONCAT("Tan(",R,")=",tan(R)) |
+------------------------------+
| Tan(2.2)=-1.37382305676879 |
+------------------------------+
+------------------------------+
| CONCAT("Tan(",R,")=",tan(R)) |
+------------------------------+
| Tan(2.3)=-1.11921364173413 |
+------------------------------+
+------------------------------+
| CONCAT("Tan(",R,")=",tan(R)) |
+------------------------------+
| Tan(2.4)=-0.916014289673409 |
+------------------------------+
+------------------------------+
| CONCAT("Tan(",R,")=",tan(R)) |
+------------------------------+
| Tan(2.5)=-0.747022297238659 |
+------------------------------+
+------------------------------+
| CONCAT("Tan(",R,")=",tan(R)) |
+------------------------------+
| Tan(2.6)=-0.601596613089757 |
+------------------------------+
+------------------------------+
| CONCAT("Tan(",R,")=",tan(R)) |
+------------------------------+
| Tan(2.7)=-0.472727629103036 |
+------------------------------+
+------------------------------+
| CONCAT("Tan(",R,")=",tan(R)) |
+------------------------------+
| Tan(2.8)=-0.355529831651175 |
+------------------------------+
+------------------------------+
| CONCAT("Tan(",R,")=",tan(R)) |
+------------------------------+
| Tan(2.9)=-0.246405393971965 |
+------------------------------+
br /> +------------------------------+
| CONCAT("Tan(",R,")=",tan(R)) |
+------------------------------+
| Tan(3)=-0.142546543074276 |
+------------------------------+
+------------------------------+
| CONCAT("Tan(",R,")=",tan(R)) |
+------------------------------+
| Tan(3.1)=-0.0416166545856346 |
+------------------------------+
Voir également
Article - Les géants de l'informatique - Oracle
Références
MySQL - Référence, Edition Micro Application, Nicolas Rivereau, Antoine Pichot, 2002, ISBN: 2-7429-2560-0, page 929.
MySQL: The definitive guide to using, programming, and administering MySQL 4 databases - Second Edition, Paul Dubois, 2003, ISBN: 0-7357-1212-3, page 808
Dernière mise à jour : Mercredi, le 29 avril 2015