MathGroup Archive 2007

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: from range restriction to domain restriction


Chris Chiasson schrieb:
> If I wanted to ensure that Sqrt[x] was always a real number, perhaps
> as a condition on Piecewise, I would say Im@Sqrt@x==0 (or
> Element[Sqrt@x,Reals], but Mathematica doesn't like to simplify that).
> In my real case, x isn't a symbol - and it comes from the output of
> some other commands. However, I also know that Element[x,Reals], so I
> was wondering if there is a way to make Mathematica do the following:
> 
> (part of) input:
> Im@Sqrt@x==0
> 
> output:
> x>0
> 
> If someone knows how to do this (other than the obvious Cases +
> pattern transformation), I would appreciate being told how. Thank you.
> 

Hi Chris,

is Reduce[ComplexExpand[Im[Sqrt[x]], x] == 0, x]
--> x >= 0
acceptable?

You would have to do sth. like

expr/.{Assuming[a_,ex_]:>Reduce[...],Simplify[ex_,a_]:>... and so on}

I guess I would use the Menu->Find->Find... to replace all "Im@Sqrt@==" with
"0<=" ;-)


Sorry, I've got no better idea :-(

Peter


  • Prev by Date: Re: question on Plot and Show plus Axis Labels
  • Next by Date: Re: question on Plot and Show plus Axis Labels
  • Previous by thread: from range restriction to domain restriction
  • Next by thread: Re: from range restriction to domain restriction