PlanetMath (more info)
 Math for the people, by the people.
Encyclopedia | Requests | Forums | Docs | Wiki | Random | RSS  
Login
create new user
name:
pass:
forget your password?
Main Menu
Owner confidence rating: High Entry average rating: No information on entry rating
infix notation (Definition)

Infix notation is how we usually read and write arithmetic expressions. In this notation, the operator goes between the operands in the expression:

   (operand1)   (operator)   (operand2)$\displaystyle $

E.g., $ 3 + 2 $, or $ 196 \times 11 $, etc.

Infix notation suffers from some ambiguity; e.g.

$\displaystyle 3 + 9 \times 2 $

could mean $ ( 3 + 9) \times 2 $ or $ 3 + (9 \times 2) $. Parentheses are needed to specify the order of operations unambiguously.

Postfix notation (or reverse-Polish notation) does not suffer this ambiguity; but it is considered harder for humans to read (hence its primary use in computer applications).

The “usual” fix for the ambiguity problem described above is to provide a convention regarding precedence of operations. This is typically done for computer parsing of mathematical expressions rather than in math done by hand, because in the former case, the computer must have some standard rules to proceed. For example, it is typical to make multiplication “higher precedence” than addition, so in the above case, $ 9 \times 2$ would be performed before adding the result to 3.

The ambiguity problem only occurs when multiple operators are present in one expression, and thus, the associative law does not hold. E.g., there is no ambiguity in $ 1 + 2 + 3$, because $ (1 + 2) + 3$ is the same as $ 1 + (2 + 3)$, by the associative property of addition.



"infix notation" is owned by akrowne.
(view preamble)

View style:

See Also: general associativity

Other names:  infix
Also defines:  infix arithmetic
Log in to rate this entry.
(view current ratings)

Cross-references: property, associative, multiple, addition, multiplication, fix, applications, primary, postfix notation, order of operations, mean, operator, expressions, arithmetic
There are 11 references to this entry.

This is version 2 of infix notation, born on 2006-10-29, modified 2006-12-04.
Object id is 8490, canonical name is InfixNotation.
Accessed 2356 times total.

Classification:
AMS MSC00-01 (General :: Instructional exposition )

Pending Errata and Addenda
None.
[ View all 1 ]
Discussion
Style: Expand: Order:
forum policy

No messages.

Interact
post | correct | update request | add derivation | add example | add (any)