x
\lfloorx\rfloor
\operatorname{frac}(x)=x-\lfloorx\rfloor, x>0
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== 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 <math>\operatorname{frac} (x)=x-\lfloor x \rfloor</math> {{harv|Graham|Knuth|Patashnik|1992}},<ref>{{citation | title=Concrete mathematics: a foundation for computer science | first1=Ronald L. | last1=Graham | author-link1=Ronald Graham | first2=Donald E. | last2=Knuth | author-link2=Donald Knuth | first3=Oren | last3=Patashnik | author-link3=Oren Patashnik | publisher=Addison-Wesley | isbn=0-201-14236-8 | year=1992 | page=70 }}</ref> or as the part of the number to the right of the radix point <math>\operatorname{frac} (x)=|x|-\lfloor |x| \rfloor</math> {{harv|Daintith|2004}},<ref>{{citation|title=A Dictionary of Computing|first=John|last=Daintith|date=2004|publisher=Oxford University Press}}</ref> or by the [[odd function]]:[2]
\operatorname{frac}(x)=\begin{cases} x-\lfloorx\rfloor&x\ge0\\ x-\lceilx\rceil&x<0 \end{cases}
with
\lceilx\rceil
\operatorname{frac}(x)=x-\lfloor|x|\rfloor ⋅ sgn(x)
The
x-\lfloorx\rfloor
\lfloorx\rfloor
\lfloor|x|\rfloor ⋅ sgn(x)
The fractional part defined via difference from ⌊ ⌋ is usually denoted by curly braces:
\{x\}:=x-\lfloorx\rfloor.
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.