Truncated Small Rhombicuboctahedron
   HOME

TheInfoList



OR:

In
mathematics Mathematics is a field of study that discovers and organizes methods, Mathematical theory, theories and theorems that are developed and Mathematical proof, proved for the needs of empirical sciences and mathematics itself. There are many ar ...
and
computer science Computer science is the study of computation, information, and automation. Computer science spans Theoretical computer science, theoretical disciplines (such as algorithms, theory of computation, and information theory) to Applied science, ...
, truncation is limiting the number of digits right of the
decimal point FIle:Decimal separators.svg, alt=Four types of separating decimals: a) 1,234.56. b) 1.234,56. c) 1'234,56. d) ١٬٢٣٤٫٥٦., Both a comma and a full stop (or period) are generally accepted decimal separators for international use. The apost ...
.


Truncation and floor function

Truncation of positive real numbers can be done using the
floor function In mathematics, the floor function is the function that takes as input a real number , and gives as output the greatest integer less than or equal to , denoted or . Similarly, the ceiling function maps to the least integer greater than or eq ...
. Given a number x \in \mathbb_+ to be truncated and n \in \mathbb_0, the number of elements to be kept behind the decimal point, the truncated value of x is :\operatorname(x,n) = \frac. However, for negative numbers truncation does not round in the same direction as the floor function: truncation always rounds toward zero, the \operatorname function rounds towards negative infinity. For a given number x \in \mathbb_-, the function \operatorname is used instead :\operatorname(x,n) = \frac.


Causes of truncation

With computers, truncation can occur when a decimal number is type conversion, typecast as an integer; it is truncated to zero decimal digits because integers cannot store non-integer real numbers.


In algebra

An analogue of truncation can be applied to polynomials. In this case, the truncation of a polynomial ''P'' to degree ''n'' can be defined as the sum of all terms of ''P'' of degree ''n'' or less. Polynomial truncations arise in the study of Taylor polynomials, for example.


See also

* Arithmetic precision * Quantization (signal processing) * Precision (computer science) * Truncation (statistics)


References

{{Reflist


External links


Wall paper applet
that visualizes errors due to finite precision Numerical analysis ja:端数処理