Difference between revisions of "Documentation/How Tos/Calc: TRUNC function"
From Apache OpenOffice Wiki
< Documentation | How Tos
(Initial content) |
m |
||
(10 intermediate revisions by 5 users not shown) | |||
Line 1: | Line 1: | ||
− | __NOTOC__ | + | {{DISPLAYTITLE:TRUNC function}} |
+ | {{Documentation/CalcFunc MathematicalTOC | ||
+ | |ShowPrevNext=block | ||
+ | |PrevPage=Documentation/How_Tos/Calc:_ATANH_function | ||
+ | |NextPage=Documentation/How_Tos/Calc:_ROUND_function | ||
+ | }}__NOTOC__ | ||
== TRUNC == | == TRUNC == | ||
Truncates a number by removing decimal places. | Truncates a number by removing decimal places. | ||
− | |||
=== Syntax: === | === Syntax: === | ||
Line 10: | Line 14: | ||
: <tt>'''TRUNC(number; 0)'''</tt> behaves as <tt>'''INT(number)'''</tt> for positive numbers, but effectively rounds towards zero for negative numbers. | : <tt>'''TRUNC(number; 0)'''</tt> behaves as <tt>'''INT(number)'''</tt> for positive numbers, but effectively rounds towards zero for negative numbers. | ||
− | |||
=== Example: === | === Example: === | ||
Line 19: | Line 22: | ||
: returns <tt>'''-1.234'''</tt>. All the <tt>'''9'''</tt>s are lost. | : returns <tt>'''-1.234'''</tt>. All the <tt>'''9'''</tt>s are lost. | ||
− | If these examples do not seem to work, see | + | If these examples do not seem to work, see {{menu|Tools|Options|OpenOffice Calc|Calculate}} to check the display precision. |
+ | {{SeeAlso|EN| | ||
+ | * [[Documentation/How_Tos/Calc: INT function|INT]] | ||
+ | * [[Documentation/How_Tos/Calc: ROUND function|ROUND]] | ||
+ | * [[Documentation/How_Tos/Calc: ROUNDDOWN function|ROUNDDOWN]] | ||
+ | * [[Documentation/How_Tos/Calc: ROUNDUP function|ROUNDUP]] | ||
− | + | * [[Documentation/How_Tos/Calc: CEILING function|CEILING]] | |
− | + | * [[Documentation/How_Tos/Calc: FLOOR function|FLOOR]] | |
− | + | * [[Documentation/How_Tos/Calc: EVEN function|EVEN]] | |
− | + | * [[Documentation/How_Tos/Calc: ODD function|ODD]] | |
− | + | * [[Documentation/How_Tos/Calc: MROUND function|MROUND]] | |
− | + | * [[Documentation/How_Tos/Calc: Mathematical functions|Mathematical functions]] | |
− | + | ||
− | + | ||
− | + | ||
− | + | ||
− | + | * [[Documentation/How_Tos/Calc: Functions listed alphabetically|Functions listed alphabetically]] | |
+ | * [[Documentation/How_Tos/Calc: Functions listed by category|Functions listed by category]]}} | ||
+ | [[Category: Documentation/Reference/Calc/Mathematical functions]] |
Latest revision as of 14:35, 31 January 2024
- Mathematical FunctionsTrigonometric
- COSSINTANCOTACOSACOTASINATANATAN2DEGREESRADIANSPIHyperbolic
- COSHSINHTANHCOTHACOSHACOTHASINHATANHRounding and remainders
- TRUNCROUNDROUNDDOWNROUNDUPCEILINGFLOOREVENODDMROUNDINTQUOTIENTMODLogarithm/Powers
-