MathGroup Archive 1998

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Inconsistencies in pattern matching.


Jrgen Tischer wrote in message <6n4ro5$o1b at smc.vnet.net>...

..........

>What it says is that ReplaceAll is traversing the tree structure of the
>expression breadth first.

..........


Jrgen:
It looks to be a depth first search. For example the following prints
the part being tested for matching.

Clear[a,b,c]

h[a][k[b],c]/.x_/;(Print[x];False)->2

h[a][k[b],c]
h[a]
h
a
k[b]
k
b
c
h[a][k[b],c]

Allan

------------------------------------------------------------- Allan
Hayes
Training and Consulting
Leicester UK
http://www.haystack.demon.co.uk
hay at haystack.demon.co.uk
voice: +44 (0)116 271 4198
fax: +44(0)116 271 8642



  • Prev by Date: Re: Problems using TWJ contour for irregular data (fwd)
  • Next by Date: Re: Starting Sound in Mathematica for Windows
  • Previous by thread: Re: Problems using TWJ contour for irregular data (fwd)
  • Next by thread: Re: How to Extract a common factor from a Sum