Is it possible to define (or assume) a general positive function?

asked 2011-12-15 14:36:40 +0100

Hi,

Is it possible to assume a positive function when doing simplifications? (like Simplify[expr,a[t]>0] in Mathematica)

To be explicit, I have

# output: abs(a(t))
# changing to assume(a(t)>0) still doesn't work, and results in a DeprecationWarning
a = function('a',var('t'))
assume(a>0)
sqrt(a**2).simplify_full()

This is to be compared to variable case (where works):

# output: t
assume(t>0)
sqrt(t**2).simplify_full()

I could do a replacement to subs_expr abs(a(t)) into a(t). But is there a simple and elegant resolution? Thank you!

edit retag flag offensive close merge delete

Comments

1

I also have this doubt

brenogil gravatar imagebrenogil ( 2012-07-30 11:37:45 +0100 )edit