For faster navigation, this Iframe is preloading the Wikiwand page for Fractional part.

Fractional part

Graph of the fractional part of real numbers

The fractional part or decimal part[1] of a non‐negative real number is the excess beyond that number's integer part. The latter is defined as the largest integer not greater than x, called floor of x or . Then, the fractional part can be formulated as a difference:

.

For a positive number written in a conventional positional numeral system (such as binary or decimal), its fractional part hence corresponds to the digits appearing after the radix point. The result is a real number in the half-open interval [0, 1).

For negative numbers

[edit]

However, in case of negative numbers, there are various conflicting ways to extend the fractional part function to them: It is either defined in the same way as for positive numbers, i.e., by (Graham, Knuth & Patashnik 1992),[2] or as the part of the number to the right of the radix point (Daintith 2004),[3] or by the odd function:[4]

with as the smallest integer not less than x, also called the ceiling of x. By consequence, we may get, for example, three different values for the fractional part of just one x: let it be −1.3, its fractional part will be 0.7 according to the first definition, 0.3 according to the second definition, and −0.3 according to the third definition, whose result can also be obtained in a straightforward way by

.

The and the "odd function" definitions permit for unique decomposition of any real number x to the sum of its integer and fractional parts, where "integer part" refers to or respectively. These two definitions of fractional-part function also provide idempotence.

The fractional part defined via difference from ⌊ ⌋ is usually denoted by curly braces:

Relation to continued fractions

[edit]

Every real number can be essentially uniquely represented as a continued fraction, namely as the sum of its integer part and the reciprocal of its fractional part which is written as the sum of its integer part and the reciprocal of its fractional part, and so on.

See also

[edit]

References

[edit]
  1. ^ "Decimal part". Oxford Dictionaries. Archived from the original on February 15, 2018. Retrieved 2018-02-15.
  2. ^ Graham, Ronald L.; Knuth, Donald E.; Patashnik, Oren (1992), Concrete mathematics: a foundation for computer science, Addison-Wesley, p. 70, ISBN 0-201-14236-8
  3. ^ Daintith, John (2004), A Dictionary of Computing, Oxford University Press
  4. ^ Weisstein, Eric W. "Fractional Part." From MathWorld--A Wolfram Web Resource
{{bottomLinkPreText}} {{bottomLinkText}}
Fractional part
Listen to this article

This browser is not supported by Wikiwand :(
Wikiwand requires a browser with modern capabilities in order to provide you with the best reading experience.
Please download and use one of the following browsers:

This article was just edited, click to reload
This article has been deleted on Wikipedia (Why?)

Back to homepage

Please click Add in the dialog above
Please click Allow in the top-left corner,
then click Install Now in the dialog
Please click Open in the download dialog,
then click Install
Please click the "Downloads" icon in the Safari toolbar, open the first download in the list,
then click Install
{{::$root.activation.text}}

Install Wikiwand

Install on Chrome Install on Firefox
Don't forget to rate us

Tell your friends about Wikiwand!

Gmail Facebook Twitter Link

Enjoying Wikiwand?

Tell your friends and spread the love:
Share on Gmail Share on Facebook Share on Twitter Share on Buffer

Our magic isn't perfect

You can help our automatic cover photo selection by reporting an unsuitable photo.

This photo is visually disturbing This photo is not a good choice

Thank you for helping!


Your input will affect cover photo selection, along with input from other users.

X

Get ready for Wikiwand 2.0 🎉! the new version arrives on September 1st! Don't want to wait?