The absolute value of a real number x, often written |x| in mathematics or abs(x) in various programming languages is x if x>=0, and -x if x < 0.

The magnitude of a real number, disregarding its positive or negative sign: the absolute value of -4 or +4, written |-4| or |+4|, is 4.

The absolute value of a complex number z=(r,i) is |z| or abs(z), and can be found using good old trigonometry: |z| = sqrt(r2 + i2)

The absolute value of an n-dimentional vector v = (x1, x2, ... , xn) can similarly be found thus: |v| = sqrt(x12 + x22 + ... + xn2)

In simple terms, the absolute value of a number is its "distance" from the number .

With real numbers, this is quite simple, but when you have the "2-dimensionality" of a complex number (represented as a + bi, where ii=-1), you must use the pythagorean theorem to find the hypotenuse, which is the distance from 0.

|a + bi| = sqrt(aa + bb)
{"found_math": false, "script_math_tex": 0, "script_math_asciimath": 0, "math_annotations": 0, "math_alttext": 0, "mathml": 0, "mathjax_tag": 0, "mathjax_inline_tex": 0, "mathjax_display_tex": 0, "mathjax_asciimath": 0, "img_math": 0, "codecogs_latex": 0, "wp_latex": 0, "mimetex.cgi": 0, "/images/math/codecogs": 0, "mathtex.cgi": 0, "katex": 0, "math-container": 0, "wp-katex-eq": 0, "align": 0, "equation": 0, "x-ck12": 0, "texerror": 0}