Revised Q: How to apply a Stencil to all leafs in an expression
Richard Guenther
rguenth at tat.physik.uni-tuebingen.de
Wed Oct 30 09:37:18 UTC 2002
Hi!
To make my point in my previous messages more clear (just thought about
what I'm actually trying to do), I like to apply a (Field)Stencil to all
leafs (of Engine type, but just ignore this for now) in an expression.
I.e. instead of writing
A(I) = (stencil(B)*stencil(C))(I);
I'd like to write something like
A(I) = applyStencil(B*C)(I);
for brevity (I really have huge expressions, they get completely
unreadable otherwise).
I know this has to be possible somehow, but I'm stuck at
a) Creating the Field type resulting from stencil(leaf)
b) how to use forEach() in conjunction with TreeCombine to stick
the result from a) in place of the leafs.
Can anybody point me to the right traits classes that create the
necessary types for me? I tried to find out where the Field type
is constructed for a simple expression like A = B*C, but I failed
here -- need some 'interactive C++ code explorer' that handles
templates...
Thanks, Richard.
--
Richard Guenther <richard.guenther at uni-tuebingen.de>
WWW: http://www.tat.physik.uni-tuebingen.de/~rguenth/
The GLAME Project: http://www.glame.de/
More information about the pooma-dev
mailing list