Absolute Value Calculator

Calculate the absolute value of any number instantly. Find |a − b| distance, batch absolute values, complex number modulus, mean absolute deviation, and absolute error.

Absolute Value
Distance from Zero
Sign
Extended More scenarios, charts & detailed breakdown
|x|
Sign
Distance from Zero
Professional Full parameters & maximum detail

Complex Number Modulus

|a + bi| (complex modulus)

Mean Absolute Deviation

Mean of 5 values
Mean Absolute Deviation (MAD)
Absolute Deviations from Mean

Absolute & Relative Error

Absolute Error |measured − expected|
Relative Error (%)

How to Use This Calculator

  1. Enter any number (positive, negative, or zero) to see its absolute value instantly.
  2. Use Expression tab to calculate |a − b| — the distance between two numbers on a number line.
  3. Use Batch tab to find absolute values of 5 numbers at once.
  4. Use the Professional tab for complex number modulus, Mean Absolute Deviation (MAD), and absolute/relative error analysis.

Formula

|x| = x if x ≥ 0, −x if x < 0

|a + bi| = √(a² + b²)  (complex modulus)

MAD = Σ|xᵢ − x̄| / n  (mean absolute deviation)

Example

|−7| = 7  |  |3 − 8| = |−5| = 5  |  |3 + 4i| = √(9+16) = 5 (complex modulus)

Frequently Asked Questions

  • The absolute value of a number is its distance from zero on the number line, always non-negative. |7| = 7, |−7| = 7, |0| = 0. Mathematically, |x| = x if x ≥ 0, and |x| = −x if x < 0.
  • |a − b| is the absolute value of the difference between two numbers — the distance between them on the number line. |3 − 8| = |−5| = 5, meaning 3 and 8 are 5 units apart.
  • For a complex number a + bi, the modulus |a + bi| = √(a² + b²). This is its distance from the origin in the complex plane. For 3 + 4i: |3 + 4i| = √(9+16) = √25 = 5.
  • MAD measures the average absolute deviation of each value from the mean. For data {2, 4, 4, 4, 5}, mean = 3.8, deviations = {1.8, 0.2, 0.2, 0.2, 1.2}, MAD = (1.8+0.2+0.2+0.2+1.2)/5 = 0.72.
  • Absolute error = |measured − expected|. Relative error = |measured − expected| / |expected| × 100%. If you measured 9.8 and expected 10.0: absolute error = 0.2, relative error = 2%.

Related Calculators