Tool to compute roundings, an approximate value of digits/decimal places (rounding down floor, rounding up ceil, rounding to multiple calculator) from a given precision.
Rounding Calculator - dCode
Tag(s) : Data Processing, Arithmetics
dCode is free and its tools are a valuable help in games, maths, geocaching, puzzles and problems to solve every day!
A suggestion ? a feedback ? a bug ? an idea ? Write to dCode!
In mathematics, rounding is an approximation of a number to make it simpler or shorter while maintaining an approximate value close to the original.
Rounding is generally represented with a limited decimal expansion (defined by a number of digits after the decimal point) which results in a loss of precision on the value of the number but can make it more practical to use (simplification of calculations) or display it (fewer numbers).
There are several possible rounding calculators, the main ones are rounding to the nearest, rounding by default and rounding by excess.
dCode allows rounding (or approximate value) from an exact value, to the desired number, the rounded default is closest (approximation), i.e. the upper value if the decisive digit is greater than or equal to 5 and the lower value if the decisive digit is less than 5.
Round to ones (no decimal dot), round to tenth (1 one decimal place), round to hundredth (2 two decimal places) or round to thousands (3 three decimal places).
Example: 3.15 is rounded to 3.2 with 1 digit after decimal point (to tenth)
Some textbooks refer to rounding to + infinity for rounding up or - infinity for rounding down, or to 0 for rounding down positive numbers and rounding up negative numbers.
Monetary notations (euros, dollars, etc.) use a 2-digit precision format
dCode calculates the nearest multiple (rounded up/superior or rounded down/inferior to the multiple) according to the formula:
Let $ x $ be the number to round and $ m $ be the desired multiple, then round to the multiple $$ = \left\lfloor \frac{x}{m} + \frac{1}{2} \right\rfloor \times m $$
Example: 123 can be rounded to the closest multiple of 5 so: 125.
The ceiling rounding (or rounding by excess) is in the upper rounding.
Example: 1.2 is ceil rounded to 2
Floor rounding (or rounding by default) is the lower rounding.
Example: 1.7 is floor rounded to 1
Truncation is the removal of digits beyond a certain precision, without taking into account any rounding.
Example: 2.89 truncated to 1 decimal value gives 2.8
The significant digits are the figures (of a decimal number) known with certainty. They depend on the measuring tool, but also on the rounding done.
Example: 0.0123 has 3 significant digits (1,2,3)
All rouding (by default) of 0.99999999… are 1.
Mathematically speaking $ 0.999\dots = 1 $
dCode retains ownership of the "Rounding Calculator" source code. Except explicit open source licence (indicated Creative Commons / free), the "Rounding Calculator" algorithm, the applet or snippet (converter, solver, encryption / decryption, encoding / decoding, ciphering / deciphering, breaker, translator), or the "Rounding Calculator" functions (calculate, convert, solve, decrypt / encrypt, decipher / cipher, decode / encode, translate) written in any informatic language (Python, Java, PHP, C#, Javascript, Matlab, etc.) and all data download, script, or API access for "Rounding Calculator" are not public, same for offline use on PC, mobile, tablet, iPhone or Android app!
Reminder : dCode is free to use.
The copy-paste of the page "Rounding Calculator" or any of its results, is allowed (even for commercial purposes) as long as you credit dCode!
Exporting results as a .csv or .txt file is free by clicking on the export icon
Cite as source (bibliography):
Rounding Calculator on dCode.fr [online website], retrieved on 2024-11-18,