Changes

Jump to navigation Jump to search
252 bytes added ,  12:32, 2 July 2020
m
Text replacement - "[http://www.w3.org/TR/xpath-functions-30" to "[https://www.w3.org/TR/xpath-functions-31"
The math [[Module Library|XQuery Module]] defines functions to perform mathematical operations, such as {{Code|pi}}, {{Code|asin}} and {{Code|acos}}. Most functions are specified in the [httphttps://www.w3.org/TR/xpath-functions-3031/ Functions and Operators Specification] of the upcoming XQuery 3.0 Recommendation, and some additional ones have been added in this module.
=Conventions=
All functions in this module are assigned to the {{Code|<code><nowiki>http://www.w3.org/2005/xpath-functions/math}} </nowiki></code> namespace, which is statically bound to the {{Code|math}} prefix.<br/>
=W3 Functions=
{| width='100%'
|-
| width='90120' | '''Signatures'''
|{{Func|math:pi||xs:double}}
|-
{| width='100%'
|-
| width='90120' | '''Signatures'''
|{{Func|math:sqrt|$arg as xs:double?|xs:double?}}
|-
{| width='100%'
|-
| width='90120' | '''Signatures'''
|{{Func|math:sin|$arg as xs:double?|xs:double?}}
|-
{| width='100%'
|-
| width='90120' | '''Signatures'''
|{{Func|math:cos|$arg as xs:double?|xs:double?}}
|-
{| width='100%'
|-
| width='90120' | '''Signatures'''
|{{Func|math:tan|$arg as xs:double?|xs:double?}}
|-
{| width='100%'
|-
| width='90120' | '''Signatures'''
|{{Func|math:asin|$arg as xs:double?|xs:double?}}
|-
{| width='100%'
|-
| width='90120' | '''Signatures'''
|{{Func|math:acos|$arg as xs:double?|xs:double?}}
|-
{| width='100%'
|-
| width='90120' | '''Signatures'''
|{{Func|math:atan|$arg as xs:double?|xs:double?}}
|-
{| width='100%'
|-
| width='90120' | '''Signatures'''
|{{Func|math:atan2|$arg1 as xs:double?, $arg2 as xs:double|xs:double?}}
|-
{| width='100%'
|-
| width='90120' | '''Signatures'''
|{{Func|math:pow|$arg1 as xs:double?, $arg2 as xs:double|xs:double?}}
|-
{| width='100%'
|-
| width='90120' | '''Signatures'''
|{{Func|math:exp|$arg as xs:double?|xs:double?}}
|-
{| width='100%'
|-
| width='90120' | '''Signatures'''
|{{Func|math:log|$arg as xs:double?|xs:double?}}
|-
{| width='100%'
|-
| width='90120' | '''Signatures'''
|{{Func|math:log10|$arg as xs:double?|xs:double?}}
|-
{| width='100%'
|-
| width='90120' | '''Signatures'''
|{{Func|math:e||xs:double}}
|-
{| width='100%'
|-
| width='90120' | '''Signatures'''
|{{Func|math:sinh|$arg as xs:double?|xs:double?}}
|-
{| width='100%'
|-
| width='90120' | '''Signatures'''
|{{Func|math:cosh|$arg as xs:double?|xs:double?}}
|-
{| width='100%'
|-
| width='90120' | '''Signatures'''
|{{Func|math:tanh|$arg as xs:double?|xs:double?}}
|-
{| width='100%'
|-
| width='90120' | '''Signatures'''|{{Func|math:crc32|$str string as xs:string?|xs:hexBinary?}}<br />
|-
| '''Summary'''
|Calculates the CRC32 check sum of the given string {{Code|$strstring}}.<br />If an empty sequence is supplied, the empty sequence is returned.
|-
| '''Examples'''
=Changelog=
 
; Version 9.1
* Updated: [[#math:crc32|math:crc32]] can be called with empty sequence.
; Version 7.5
* Moved: [[Random Module#random:integer|math:random ]] and [[Random Module#random:uuid|math:uuid ]] have been move moved to [[Random Module]]. 
; Version 7.3
* Added: [[#math:crc32|math:crc32]] and [[Random Module#mathrandom:uuid|math:uuid]] have been adopted from the obsolete Utility Module. [[Category:XQuery]]
Bureaucrats, editor, reviewer, Administrators
13,550

edits

Navigation menu