Ask Your Question

Revision history [back]

This is a bug and it's already on trac: 6480

Unfortunately GiNaC doesn't support pattern matching with functions, or substituting functions (like substitute_function()). This is partly due to the fact that defining symbolic functions at runtime is a Python luxury, which you don't get in a convenient form using C++.

Asking on the GiNaC lists about how to do this would be a good start. At the moment I don't have too much time to start looking at this myself.