Message Boards Message Boards

0
|
7521 Views
|
5 Replies
|
1 Total Likes
View groups...
Share
Share this post:

Interpolate the following implicit function?

Posted 6 years ago

Hi, I have a problem with solve. I need to define this function b of two variables, which is implicitly defined. I need it later to enter it into some other really nasty equations, which then again have to be solved numerically. So I wanted to define a grind of x and ss and then use an interpolation to get a smooth function version of b. However, I cannot even get a solution at a single point. (Maple does that without problems, so it shouldn't be a mathematical problem, but more of my stupidity). Below find the code an error text. If I use "NSolve" I even get no output. Any ideas?

Best

Christian

    b[x_, ss_] :=  Solve[b == x - ss*Quantile[NormalDistribution, b], b, Reals]

    b[0.3,0.1]

Solve::inex: Solve was unable to solve the system with inexact coefficients or the system obtained by direct rationalization of inexact numbers present in the system. Since many of the methods used by Solve require exact input, providing Solve with an exact version of the system may help.
POSTED BY: Christan Bauer
5 Replies
POSTED BY: Mariusz Iwaniuk
Posted 6 years ago
POSTED BY: Christan Bauer
POSTED BY: Mariusz Iwaniuk

If I am not wrong, the equation

b == x - ss*InverseCDF[NormalDistribution[0, 1], b][[1]]

should be equivalent to

2 b == Erfc[(b - x)/(Sqrt[2] ss)]

and this one Mathematica can do:

b[x_, ss_] := 
 Solve[2 b == Erfc[(b - x)/(Sqrt[2] ss)] && 0 <= b <= 1, b, Reals]
b[3/10, 1/10]
POSTED BY: Gianluca Gorni
Posted 6 years ago

Awesome! Thanks a lot.

Question to the developers: Why can't the system do this automatically??

POSTED BY: Christan Bauer
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard

Group Abstract Group Abstract