MathGroup Archive 2001

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

Search the Archive

RE: find argument of function inside long result?


Jose,

expr = ((1 + Sqrt[a])/(2 + Sqrt[b]))*(1/Sqrt[c]);

Cases[expr, a_^b:(-1/2 | 1/2) -> a^(2*b), Infinity]
{a, b, 1/c}

There may be some question as to how you want to treat the last square root
in the denominator.

Cases[expr, Power[a_, b : (-1/2 | 1/2)] -> a, Infinity]
{a, b, c}

David Park
djmp at earthlink.net
http://home.earthlink.net/~djmp/

> From: jose flanigan [mailto:jflanigan at netzero.net]
To: mathgroup at smc.vnet.net
>
> I have a very long symbolic result that has several sqrt functions. I
> would like to extract the arguments of each of the sqrt's.
>
> How can I do this? The expression is too complicated to try and
> read it off.
>
> thanks.
>



  • Prev by Date: Re: Plotting the histogram
  • Next by Date: Chi Square test for goodness of fit
  • Previous by thread: Re: find argument of function inside long result?
  • Next by thread: Re: find argument of function inside long result?