7
$\begingroup$

I often need to check whether integrals are solvable in closed form and use a notebook with 5–10 variables that need to be assumed positive. Is there a better way of doing this than adding the clunky line:

$Assumptions=a>0&&b>0&&c>0&&d>0&&f>0; ?

I tried $Assumptions={a,b,c,d,f}>0; but it didn't work.

$\endgroup$
3
  • $\begingroup$ $Assumptions=Thread[{a,b,c,d,f}>0]? $\endgroup$
    – kglr
    Commented Apr 24, 2020 at 13:56
  • $\begingroup$ also $Assumptions=Element[{a,b,c,d,f}, PositiveReals] $\endgroup$
    – kglr
    Commented Apr 24, 2020 at 13:57
  • $\begingroup$ @kglr Both worked! Thanks. $\endgroup$
    – WillG
    Commented Apr 24, 2020 at 13:59

1 Answer 1

10
$\begingroup$
$Assumptions = Element[{a, b, c, d, f}, PositiveReals] ;
Simplify[Sign[a + b + c]]
 1
$Assumptions = {};
Simplify[Sign[a + b + c]]
 Sign[a + b + c] 
$Assumptions = Thread[{a, b, c, d, f} > 0] ;
Simplify[Sign[a + b + c]]
 1
$Assumptions = AllTrue[{a,b,c,d,f}, Positive] ;
Simplify[Sign[a+b+c]]
 1
$\endgroup$
0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.