Mathematica 9 is now available

Alternatives (|)Optional (_.)

Pattern

FilledSmallSquares:obj represents the pattern object obj, assigned the name s.

FilledSmallSquare The name s must be a symbol.

FilledSmallSquare The object obj can be any pattern object.

FilledSmallSquare When a transformation rule is used, any occurrence of s on the right-hand side is replaced by whatever expression it matched on the left-hand side.

FilledSmallSquare The operator : has a comparatively low precedence. The expression x:_+_ is thus interpreted as x:(_+_), not (x:_)+_.

FilledSmallSquare The form s_ is equivalent to s:_. Similarly, s_h is equivalent to s:_h, s__ to s:__, and so on.

FilledSmallSquare See The Mathematica Book: Section 2.3.3 and Section A.2.7.

Further Examples

Alternatives (|)Optional (_.)



Any questions about topics on this page? Click here to get an individual response.Buy NowMore Information
THIS IS DOCUMENTATION FOR AN OBSOLETE PRODUCT.
SEE THE DOCUMENTATION CENTER FOR THE LATEST INFORMATION.