[GiNaC-list] extending the symbol
Krishna Mohan Gundu
gkmohan at gmail.com
Sun Oct 5 01:09:59 CEST 2008
Hi,
I am adding a light weight support for vector algebra in ginac. I am
aware that it can be done through Clifford algebra, but the output is
almost incomprehensible to debug. My problem is this. When a request
like inner_product(lhs, rhs) is made, where one of lhs and rhs is not
a vector, I would like to replace the inner_product with a regular
product. How can I achieve this?
I am planning to do it as follows
1) extend a symbol to a vector
2) determine if both lhs and rhs have a hanging vector by traversing
the expressions in lhs and rhs and by testing for is_a<vector>
Is there a better way to test if a symbol is a vector? If not what is
the simplest way to extend symbol?
thanks,
Krishna.
More information about the GiNaC-list
mailing list