New issue 3102 by smi...@gmail.com: Piecewise subs of function fails
http://code.google.com/p/sympy/issues/detail?id=3102
g = Function('g')
h = Function('h')
p = Piecewise((g, x < -1), (g(x), x <= 1))
This fails with a TypeError.
This is corrected in https://github.com/sympy/sympy/pull/690
I take it you wanted to do something else too. That alone doesn't fail,
and you're not using the h you defined.
Anyway, if something with a bare Function fails, it's not surprising, as
this does not really make sense.
sorry, p.subs(g, h). I thought it didn't make sense, either, but such a
piecewise could be used to select the function that you want to apply, I
think. Imagine that the g(x) were replaced with f (another
UndefinedFunction).
I disagree. Unless we can get this kind of thing to work generically
(issue 2006), we shouldn't pretend that it works at all.
Comment #4 on issue 3102 by smi...@gmail.com: Piecewise subs of function
fails
http://code.google.com/p/sympy/issues/detail?id=3102
replacement of functions doesn't fail now.