Changes

Jump to navigation Jump to search
294 bytes added ,  16:25, 12 December 2010
no edit summary
==math:pi==
{|
| '''width="90" | <b>Signatures''' </b> | <code> '''<b>math:pi'''() as xs:double</code>
|-
| '''<b>Summary''' </b>
|Returns the value of the mathematical constant π.
|-
| '''<b>Rules''' </b>
|This function returns the <code>xs:double</code> value whose lexical representation is 3.141592653589793.
|-
| '''<b>Examples''' </b>
|The expression <code>2*math:pi()</code> returns <code>6.283185307179586e0</code>.The expression <code>60 * (math:pi() div 180)</code> converts an angle of 60 degrees to radians.
|}
==math:e==
{|
| '''width="90" | <b>Signatures''' </b> | <code> '''<b>math:e'''() as xs:double</code>
|-
| '''<b>Summary''' </b>
|Returns the value of the mathematical constant <i>e</i>.
|-
| '''<b>Rules''' </b>
|This function returns the <code>xs:double</code> value whose lexical representation is 2.718281828459045.
|-
| '''<b>Examples''' </b>
|The expression <code>5*math:e()</code> returns <code>13.591409142295225</code>.
|}
{|
|-
|'''width="90" | <b>Signatures''' </b> | <code> '''<b>math:sqrt'''($arg as xs:double?) as xs:double?</code>
|-
|'''<b>Summary''' </b>
|Returns the square root of the argument.
|-
|'''<b>Rules''' </b>
|If <code>$arg</code> is the empty sequence, the function returns the empty sequence.Otherwise the result is the <code>xs:double</code> value of the mathematical square root of <code>$arg</code>.
|}
{|
|-
|'''width="90" | <b>Signatures''' </b> | <code> '''<b>math:sin'''($arg as xs:double?) as xs:double?</code>
|-
|'''<b>Summary''' </b>
|Returns the sine of the argument, expressed in radians.
|-
|'''<b>Rules''' </b>
|If <code>$arg</code> is the empty sequence, the function returns the empty sequence.Otherwise the result is the sine of <code>$arg</code>, treated as an angle in radians.
|}
{|
|-
|'''width="90" | <b>Signatures''' </b> | <code> '''<b>math:cos'''($arg as xs:double?) as xs:double?</code>
|-
|'''<b>Summary''' </b>
|Returns the cosine of the argument, expressed in radians.
|-
|'''<b>Rules''' </b>
|If <code>$arg</code> is the empty sequence, the function returns the empty sequence.Otherwise the result is the cosine of <code>$arg</code>, treated as an angle in radians.
|}
{|
|-
|'''width="90" | <b>Signatures''' </b> | <code> '''<b>math:tan'''($ as xs:double?) as xs:double?</code>
|-
|'''<b>Summary''' </b>
|Returns the tangent of the argument, expressed in radians.
|-
|'''<b>Rules''' </b>
|If <code>$arg</code> is the empty sequence, the function returns the empty sequence.Otherwise the result is the tangent of <code>$arg</code>, treated as an angle in radians.
|}
{|
|-
|'''width="90" | <b>Signatures''' </b> | <code> '''<b>math:asin'''($arg as xs:double?) as xs:double?</code>
|-
|'''<b>Summary''' </b>
|Returns the arc sine of the argument.
|-
|'''<b>Rules''' </b>
|If <code>$arg</code> is the empty sequence, the function returns the empty sequence.Otherwise the result is the arc sine of <code>$arg</code>, returned as an angle in radians in the range -π/2 to +π/2.
|}
{|
|-
|'''width="90" | <b>Signatures''' </b> | <code> '''<b>math:acos'''($arg as xs:double?) as xs:double?</code>
|-
|'''<b>Summary''' </b>
|Returns the arc cosine of the argument.
|-
|'''<b>Rules''' </b>
|If <code>$arg</code> is the empty sequence, the function returns the empty sequence.Otherwise the result is the arc cosine of <code>$arg</code>, returned as an angle in radians in the range 0 to +π.
|}
{|
|-
|'''width="90" | <b>Signatures''' </b> | <code> '''<b>math:atan'''($arg as xs:double?) as xs:double?</code>
|-
|'''<b>Summary''' </b>
|Returns the arc tangent of the argument.
|-
|'''<b>Rules''' </b>
|If <code>$arg</code> is the empty sequence, the function returns the empty sequence.Otherwise the result is the arc tangent of <code>$arg</code>, returned as an angle in radians in the range -π/2 to +π/2.
|}
{|
|-
|'''width="90" | <b>Signatures''' </b> | <code> '''<b>math:atan2'''($arg1 as xs:double?, $arg2 as xs:double?) as xs:double?</code>
|-
|'''<b>Summary''' </b>
|Returns the arc tangent of the first argument divided by the second argument, the result being in the range -π/2 to +π/2 radians.
|-
|'''<b>Rules''' </b>
|If <code>$arg1</code> is the empty sequence, the function returns the empty sequence.Otherwise the result is the arc tangent of <code>$arg1</code> divided by <code>$arg2</code>, returned as an angle in radians in the range -π to +π.
|}
{|
|-
|'''width="90" | <b>Signatures''' </b> | <code> '''<b>math:pow'''($arg1 as xs:double?, $arg2 as xs:double?) as xs:double?</code>
|-
|'''<b>Summary''' </b>
|Returns the first argument raised to the power of the second argument.
|-
|'''<b>Rules''' </b>
|If <code>$arg1</code> is the empty sequence, the function returns the empty sequence.Otherwise the result is the <code>$arg1</code> raised to the power of <code>$arg2</code>.
|-
|'''<b>Examples''' </b>
|The expression <code>math:pow(2, 3)</code> returns <code>8</code>.
|}
{|
|-
|'''width="90" | <b>Signatures''' </b> | <code> '''<b>math:exp'''($arg as xs:double?) as xs:double?</code>
|-
|'''<b>Summary''' </b>
|Returns <i>e</i> raised to the power of the argument.
|-
|'''<b>Rules''' </b>
|If <code>$arg</code> is the empty sequence, the function returns the empty sequence.Otherwise the result is the value of <i>e</i> raised to the power of <code>$arg</code>.
|-
|'''<b>Examples''' </b>
|The expression <code>math:exp(1)</code> returns <i>e</i>.
|}
{|
|-
|'''width="90" | <b>Signatures''' </b> | <code> '''<b>math:log'''($arg as xs:double?) as xs:double?</code>
|-
|'''<b>Summary''' </b>
|Returns the natural logarithm of the argument.
|-
|'''<b>Rules''' </b>
|If <code>$arg</code> is the empty sequence, the function returns the empty sequence.Otherwise the result is the natural logarithm (base <i>e</i>) of <code>$arg</code>.
|-
|'''<b>Examples''' </b>
|The expression <code>math:log(math:e())</code> returns <code>1</code>.
|}
{|
|-
|'''width="90" | <b>Signatures''' </b> | <code> '''<b>math:log10'''($arg as xs:double?) as xs:double?</code>
|-
|'''<b>Summary''' </b>
|Returns the base 10 logarithm of the argument.
|-
|'''<b>Rules''' </b>
|If <code>$arg</code> is the empty sequence, the function returns the empty sequence.Otherwise the result is the base 10 logarithm of <code>$arg</code>.
|-
|'''<b>Examples''' </b>
|The expression <code>math:log(100)</code> returns <code>2</code>.
|}
{|
|-
|'''width="90" | <b>Signatures''' </b> | <code> '''<b>math:random'''() as xs:double?</code>
|-
|'''<b>Summary''' </b>
|Returns a random value.
|-
|'''<b>Rules''' </b>
|This function returns a random <code>xs:double</code> value between <code>0.0</code> and <code>1.0</code>.
|}
{|
|-
|'''width="90" | <b>Signatures''' </b> | <code> '''<b>math:sinh'''($arg as xs:double?) as xs:double?</code>
|-
|'''<b>Summary''' </b>
|Returns the hyperbolic sine of the argument.
|-
|'''<b>Rules''' </b>
|If <code>$arg</code> is the empty sequence, the function returns the empty sequence.Otherwise the result is the hyperbolic sine of <code>$arg</code>.
|-
|'''<b>Examples''' </b>
|The expression <code>math:sinh(0)</code> returns <code>0</code>.
|}
{|
|-
|'''width="90" | <b>Signatures''' </b> | <code> '''<b>math:cosh'''($arg as xs:double?) as xs:double?</code>
|-
|'''<b>Summary''' </b>
|Returns the hyperbolic cosine of the argument.
|-
|'''<b>Rules''' </b>
|If <code>$arg</code> is the empty sequence, the function returns the empty sequence.Otherwise the result is the hyperbolic cosine of <code>$arg</code>.
|-
|'''<b>Examples''' </b>
|The expression <code>math:cosh(0)</code> returns <code>1</code>.
|}
{|
|-
|'''width="90" | <b>Signatures''' </b> | <code> '''<b>math:tanh'''($arg as xs:double?) as xs:double?</code>
|-
|'''<b>Summary''' </b>
|Returns the hyperbolic tangent of the argument.
|-
|'''<b>Rules''' </b>
|If <code>$arg</code> is the empty sequence, the function returns the empty sequence.Otherwise the result is the hyperbolic tangent of <code>$arg</code>.
|-
|'''<b>Examples''' </b>
|The expression <code>math:tanh(100)</code> returns <code>1</code>.
|}
 
[[Category:XQuery]]
bueraucrat, Bureaucrats, editor, reviewer, Administrators
907

edits

Navigation menu