I need to evaluate the inverse of this function in the domain [0,1):
There is an analytic inverse (which I won't bother putting here as it's quite big), but it only works for a limited range of the constant A, i.e. if A>0.385f(x). Then, I thought of two possible solutions:
I am tending towards (2), since it seems simple enough and doesn't slow down my code, as (1) might, but I'm insecure about the validity of the approximation. I'd also appreciate other suggestions.
My code is in C++, if there is some built-in way of solving my problem.
Although both proposed methods you suggested are interesting for more general cases, this function can be inverted analytically.
In Mathematica you probably inverted it and got this "wrong" answer:
The correct real answer is the absolute value of this due to the squareroot.
Here is a plot to illustrate this "right" answer works: