<H1><A NAME="HDR0"><B>tan, tanh</B></A></H1>
<H2><A NAME="HDR1">Purpose</A></H2>
Tangent and hyperbolic tangent.<p>
<H2><A NAME="HDR2">Synopsis</A></H2>
<PRE>
<CODE>Y = tan(X)</CODE>
<CODE>Y = tanh(X)</CODE>
</PRE>
<H2><A NAME="HDR3">Description</A></H2>
The trigonometric functions operate element-wise on matrices. Their domains and ranges include complex values. All angles are measured in radians. <p>
<CODE>tan(X)</CODE> is the circular tangent of each element of <CODE>X</CODE>.<p>
<CODE>tanh(X)</CODE> is the hyperbolic tangent of each element of <CODE>X</CODE>.<p>
<H2><A NAME="HDR4">Examples</A></H2>
<CODE>tan(pi/2)= 1.6332e+16</CODE> is not infinite, but rather a value the size of the reciprocal of the floating-point accuracy <CODE>eps</CODE>, because <CODE>pi</CODE> is only a floating-point approximation to the exact value.<p>
<H2><A NAME="HDR5">Algorithm</A></H2>
<A HREF="pt11t2z.figure.id.6.gif"><img src="pt11t2z.figure.id.6.gif"></A><p>
<H2><A NAME="HDR6">See Also</A></H2>
<PRE>
<CODE><A HREF="acos.html">acos</A></CODE>, <CODE><A HREF="asin.html">asin</A></CODE>, <CODE><A HREF="atan.html">atan</A></CODE>, <CODE><A HREF="cos.html">cos</A></CODE>, <CODE><A HREF="exp.html">exp</A></CODE>, <CODE><A HREF="expm.html">expm</A></CODE>, <CODE><A HREF="funm.html">funm</A></CODE>, <CODE><A HREF="sin.html">sin</A></CODE>
</PRE>
<A HREF="ReferenceTOC.html"><iMG ALT=" " SRC="TOC.Button.gif">
<A HREF="ReferenceIX.html" ><iMG ALT=" " SRC="Index.Button.gif">
</A>
<p>
(c) Copyright 1994 by The MathWorks, Inc. <p>
