X-Git-Url: https://git.stg.codes/stg.git/blobdiff_plain/0c9c28efcd43f53ac54aa60b2dfefa69c70dbadf..6b6d9b29e9e9e91f79507a8bf193fb30de311dcc:/doc/help/xslt/slides/keynote/xsltsl/math.xsl diff --git a/doc/help/xslt/slides/keynote/xsltsl/math.xsl b/doc/help/xslt/slides/keynote/xsltsl/math.xsl new file mode 100644 index 00000000..e3e14dde --- /dev/null +++ b/doc/help/xslt/slides/keynote/xsltsl/math.xsl @@ -0,0 +1,704 @@ + + + + + + + $Id: math.xsl 3991 2004-11-10 06:51:55Z balls $ + + + Ball + Steve + + + 2004 + 2002 + Steve Ball + + + + Math Module + + +
+ Introduction + + This module provides mathematical functions. +
+
+ +
+ + + Power + + + Raises a number to a power. + + + + + + base + + The base number. Must be a number. + + + + power + + The power to raise the number to. Must be an integer. + + + + + + + Returns base multiplied by itself power times. If the base or power are not numbers or if the power is fractional then an empty string is returned. + + + + + + + + + + 1 + + + 1 + + + + 0 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Absolute Value + + + Absolute value of a number. + + + + + + number + + The number. Must be a number. + + + + + + + Returns the absolute value of the number. + + + + + + + + + + + + + + + + + + Conversion + + + Converts a hexidecimal value to a decimal value. + + + + + + value + + The hexidecimal number. Must be a number in hexidecimal format. + + + + + + + Returns the value as a decimal string. If the value is not a number then a NaN value is returned. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 10 + 11 + 12 + 13 + 14 + 15 + + + + + Conversion + + + Converts a decimal value to a hexidecimal value. + + + + + + value + + The decimal number. + + + + + + + Returns the value as a hexidecimal string (lowercase). If the value is not a number then a NaN value is returned. + + + + + + + + 0 + NaN + + + + + + + + + + a + b + c + d + e + f + + + + + + + + Ordinal number + + + Gives the ordinal number of a given counting number. For example, 1 becomes "1st". + + + + + + number + + An integer number. + + + + + + + Returns the number with an ordinal suffix. + + + + + + + + + + + + th + st + nd + rd + th + + + + + + + + Returns an ordinal number + + + This template returns the ordinal number for a given counting number as a word. For example "first" for 1. + Only handles numbers less than 10000000 (ten million). + + + + + + number + + The counting number. + + + + conjunctive + + Whether to add the word "and" to the result, for example "one hundred and first" rather than "one hundred first". Default is "yes". + + + + + + + Returns the ordinal number as a string. + + + + + + + + + + + zeroth + + + + + and + first + + + and + second + + + and + third + + + and + fourth + + + and + fifth + + + and + sixth + + + and + seventh + + + and + eighth + + + and + ninth + + + and + tenth + + + and + eleventh + + + and + twelveth + + + and + thirteenth + + + and + fourteenth + + + and + fifteenth + + + and + sixteenth + + + and + seventeenth + + + and + eighteenth + + + and + nineteenth + + + and + twentieth + + + and + thirtieth + + + and + fortieth + + + and + fiftieth + + + and + sixtieth + + + and + seventieth + + + and + eightieth + + + and + ninetieth + + + + + + + millionth + + + and + + + + thousandth + + + and + + + + hundredth + + + + + + and + + + + + + + + + + + + + + + + + + + + + + + + + + and + + + + + + + + + + + + + + + + + + + + + + + + + + + and + + + + + + + + + + + + + + + and + + + + + + + + + + + + + + + + + Returns a number as a word + + + This template returns the word for a given integer number, for example "one" for 1. + Only handles numbers less than 10000000 (ten million). + + + + + + number + + The counting number. + + + + conjunctive + + Adds the word "and" where appropriate, for example. + + + + + + + Returns the number as a string. + + + + + + + + + + zero + + + minus + + + + + + + + + + + + million + + + + + + million + + + + + + + + + thousand + + + + + + thousand + and + + + + + + + + + hundred + + + + + + hundred + and + + + + + + one + two + three + four + five + six + seven + eight + nine + ten + eleven + twelve + thirteen + fourteen + fifteen + sixteen + seventeen + eighteen + nineteen + twenty + thirty + forty + fifty + sixty + seventy + eighty + ninety + + + + + + + + + + + + +
+