The most common way to reduce extra digits in calculations is to round up the result.

#### Truncation

is an alternative method of removing extra digits. When truncating a number, the extra digits are simply removed. In computers, truncation can occur when a decimal number is typecast as an integer; it is truncated to zero decimal digits because integers cannot store non-integer real numbers.Unlike the algorithm that takes a positive float and truncates it to an int value, the floor function receives and returns a double value. The algorithm of subtracting 0.5 from a value and then rounding it (which truncates a positive number) is so useful that Java has included a method in its standard library to do it for you. Note that the domains of the truncation function and the rounding function for any given return value are offset exactly 0.5.In mathematics and computer science, truncation limits the number of digits to the right of the decimal point. The algorithm for truncating positive numbers differs slightly from that for negative numbers.

When Excel is truncated, it trims part of the entered number and does not perform any rounding. To learn more about using rounding and truncation, go to Excel Help. Truncation of a polynomial P to degree n can be defined as the sum of all P terms of degree n or less.

## Leave Reply