Take the 2-minute tour ×
Mathematica Stack Exchange is a question and answer site for users of Mathematica. It's 100% free, no registration required.
InverseFunction[ConditionalExpression[#, 0 <= # <= 1] &]
InverseFunction[ConditionalExpression[#, -1 <= # <= 1] &]

The first line produces what I would expect:

ConditionalExpression[#1, 0 <= #1 <= 1] &

But when I make the lower limit in ConditionalExpression negative, the inequalities become strict:

ConditionalExpression[#1, -1 < #1 < 1] &

Why is this happening?

share|improve this question
    
This bug has been handled at least in mma10.1.:) –  WateSoyan May 13 at 12:37

1 Answer 1

In the second case, the InverseFunction is computed by Solve, similarly to

In[1]:= Solve[x == y && -1 <= x <= 1 && Element[y, Reals], x]

Out[1]= {{x -> ConditionalExpression[y, -1 < y < 1]}}

According to the documentation,

Solve gives generic solutions only. Solutions that are valid only when continuous parameters satisfy equations are removed. Additional solutions can be obtained by using nondefault settings for MaxExtraConditions.

For example, the following gives the desired answer.

In[2]:= SetOptions[Solve, MaxExtraConditions -> All];
        InverseFunction[ConditionalExpression[#, -1 <= # <= 1] &]

Out[3]= ConditionalExpression[#1, -1 <= #1 <= 1] &
share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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