## Re: [xsl] What's your visual metaphor for XSL Transformations?

 Subject: Re: [xsl] What's your visual metaphor for XSL Transformations? From: "Dimitre Novatchev" Date: Wed, 21 Mar 2007 20:12:39 -0700
```I used to write a lot of recursive functions in C , but have now
forgotten all about recursion since I didn't use it since school.```

```I plan to read this: http://en.wikipedia.org/wiki/Recursion  carefully
to remember it again, I think it is useful to know especially in XSLT.
```
```One will not wonder what recursion is if they are in good terms with
proof by induction.```

```Both need to have some empirical base (some N0, N1, ... etc.) for
which F(N) is true,```

```then we assume that F(k) is true and based on this prove (calculate)
that F(k1) is true, where k1 > k (typycally k1 = k + 1, but we may use
k1 = 2*k, or any other convenient relation)```

```Then comes the big plunge down to the base of induction/recursion --
and here's where we use the base of the proof/calculation. F(base) is
true and we have proved that from F(N) it follows F(k(N)),```

then we have proved that:

F(base) ==> F(k(base)) ==> F(k(k(base)) ... etc.

```that is, we have proved/calculated F() for any argument of the form
k(k(...k(base))...)```

```Therefore rather than a dragon trying to eat his tail, my visual
metaphore for recursion would be one or several Vienese wheels, some
going up and some going down, but all of them stopping at initial
moments to pick passengers (base).```

```To put it simply, something with a definite start that can go on for
as long as one needs to.```

```Often a proof by induction is carried over on an infinite set of
arguments (such as all natural numbers) and the same may be possible
to accomplish with recursive processing with indefinite depth, where
the argument is an infinite list of items and the processing and
producing of results is carried out in "real time", "streaming" mode.```

```Probably fractals would be a better visual metaphore for such kind of
recursive processing.```

```--
Cheers,
Dimitre Novatchev
---------------------------------------
Truly great madness cannot be achieved without significant intelligence.
---------------------------------------
To invent, you need a good imagination and a pile of junk
-------------------------------------
You've achieved success in your field when you don't know whether what
you're doing is work or play```

On 3/21/07, Rashmi Rubdi <rashmi.sub@xxxxxxxxx> wrote:
Nice post.

It would be interesting to know how a recursive template could be visualized.

```A few days ago I posted a request on this list to create an HTML menu
in the form of ul , li tags recursively. I found it tough to visualize

```I used to write a lot of recursive functions in C , but have now
forgotten all about recursion since I didn't use it since school.```

```I plan to read this: http://en.wikipedia.org/wiki/Recursion  carefully
to remember it again, I think it is useful to know especially in XSLT.```

-Rashmi

```> On 3/21/07, W Charlton < XSLList@xxxxxxxxxx> wrote:
> >
> > When working with an element or attribute I have a mental awareness of where
> > I am in the "branch" with relation to the other "branches" that I am trying
> > to access or manipulate.
```