I am to solve for $r(\rho)$ given the function,

ρAsymp[r_, b_, q_] := 
  1/(1 - q) Gamma[1/(1 - q)]/Gamma[(q - 2)/(q - 1)] r Sqrt[1 - (b/r)^(1 - q)]

This can be solved in a straightforward way by converting this into a quadratic equation and use Solve to find for the root corresponding to $r(\rho)$ for every value of $q$. But I have difficulty implementing the InverseFunction to this problem.

Can someone help me with this? Also, I want to scan $r(\rho)$ for all values of $q<1$, how can I implement this by using a Module?

  • $\begingroup$ Recommend that you change your definition to \[Rho]Asymp[r_, b_, q_] := 1/(1 - q) Gamma[1/(1 - q)]/Gamma[(q - 2)/(q - 1)] r Sqrt[ 1 - (b/r)^(1 - q)] // FullSimplify // Evaluate which will be simplified to Sqrt[1 - (b/r)^(1 - q)]*r $\endgroup$ – Bob Hanlon Jan 15 '19 at 15:55
  • $\begingroup$ I did not see that. Thank you for pointing out. Is there an efficient way of getting $r(\rho)$? for all allowed values of $q$? $\endgroup$ – user583893 Jan 16 '19 at 2:35
  • $\begingroup$ Have you tried using FullSimplify on your function? The gamma functions all disappear and I get ρ = r*Sqrt[1-(b/r)^(1-q)]. Doesn't solve your problem though. $\endgroup$ – Roman Jun 14 '19 at 9:13

Looking at the examples in the documentaion you could do the following:

g = InverseFunction[Function[{r, b, q}, ρAsymp[r, b, q]], 1, 3]

which gives the inverse of ρAsymp[r, b, q], a function of 3 arguments, with respect to it's first argument r. Evaluation is then

g[1, 2, 3]


The function g may now be used as a usual function.

  • $\begingroup$ What about symbolically? If i only specify, $b$ and $q$ $\endgroup$ – user583893 Jan 15 '19 at 7:43
  • $\begingroup$ @user583893 sadly that doesn't work for this particular function and my suggested solution. $\endgroup$ – gothicVI Jan 15 '19 at 8:12

This function shows a very different behavior depending on parameters. Decide which parameter combinations are relevant for you with the help of a graphical overview.

  ParametricPlot[{Sqrt[1 - (b/r)^(1 - q)] r /. q -> s/t, r}, {r, -10, 10}, 
    AxesLabel -> {"rho", "r"}, AspectRatio -> 1], 
  {{b, -2}, -5, 5}, 
  {{s, 3}, Join[Range[-5, 5], {1/Pi, Pi, 10 Pi, -1/Pi, -Pi, -10 Pi}]}, 
  {t, Range[5]}]

enter image description here


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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