This is documentation for Mathematica 8, which was
based on an earlier version of the Wolfram Language.
View current documentation (Version 11.2)


gives the integer part of x.
  • Mathematical function, suitable for both symbolic and numerical manipulation.
  • IntegerPart[x] in effect takes all digits to the left of the decimal point and drops the others.
  • IntegerPart[x] returns an integer when x is any numeric quantity, whether or not it is an explicit number.
  • For exact numeric quantities, IntegerPart internally uses numerical approximations to establish its result. This process can be affected by the setting of the global variable $MaxExtraPrecision.
  • IntegerPart applies separately to real and imaginary parts of complex numbers.
Find the integer part of a real number:
Find the integer part of a real number:
Click for copyable input
Click for copyable input
Use exact numeric quantities:
IntegerPart threads element-wise over lists:
Manipulate IntegerPart symbolically:
Evaluate an integral:
Use with negative arguments:
Use with complex-number arguments:
IntegerPart can deal with real-valued intervals:
Infinite arguments give symbolic results:
Series expansion:
Iso-curves become full-dimensional regions for piecewise constant functions:
Fibonacci numbers:
Implement a divide-and-conquer-type recursion relation:
Find the ^(th) digit of the fraction in base :
Compare with RealDigits functionality:
Find the day of the week in the Gregorian calendar:
Birthday of Leonard Euler:
Compare with DateString:
Implement the Frisch continuous-but-nowhere-differentiable function:
Simplify expressions containing IntegerPart:
Symbolically expand for complex arguments:
IntegerPart is idempotent:
Use PiecewiseExpand to canonicalize:
Reduce equations containing IntegerPart:
Numerical decision procedures with default settings cannot simplify this expression:
Use Simplify to resolve:
Machine-precision numericalization of IntegerPart can give wrong results:
Use arbitrary-precision evaluation instead:
Because the answer is exact, raising the internal precision does not remove the message:
Symbolic preprocessing of functions containing IntegerPart can be time consuming:
As a discontinuous function, IntegerPart can cause numerical algorithms to converge slowly:
Build a nondecreasing sequence of integers where each number occurs times []:
Generate the sequence up to 5:
Group the same numbers:
New in 3