# Define an implicit function?

**URL:** <https://community.wolfram.com/t/define-an-implicit-function/13092>\
**Category:** Questions\
**Tags:** calculus, equation-solving, statistics-and-probability\
**Created:** [September 14, 2018, 11:24am UTC](https://community.wolfram.com/t/define-an-implicit-function/13092 "2018-09-14T11:24:04Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![bauer](https://avatars.discourse-cdn.com/v4/letter/b/f6c823/32.png) [@bauer](https://community.wolfram.com/u/bauer)\
**Post date:** [September 14, 2018, 11:24am UTC](https://community.wolfram.com/t/define-an-implicit-function/13092/1 "2018-09-14T11:24:04Z")

</div>

Hi there,  
I have a theoretic decision model that involves a number of equations that cannot be solved in a closed form, i.e. the solution is given only implicitely. The first of these functions then enters another equaition, that again can only be solved implicitely. And encounter problems when I try to implement this. I only need a numerical solution, as it is for illustration prupose only.  
Now here’s the first equation:

```
b[x_] := Solve[b == x - 0.1*Quantile[NormalDistribution[0, 1], b], b]

```

which gives the error message

```
$RecursionLimit::reclim2: Recursion depth of 1024 exceeded during evaluation of -0.1 Quantile[NormalDistribution,b].

```

I’d prefer to have the 0.1 as a free parameter “b[x\_,s\_] :=…”, but would be able to live with that if I have to. Any ideas or comments?  
Best Christian

---

<div class="post-metadata">

**Author:** ![mariuszi28cg](https://yyz1.discourse-cdn.com/wolfram/user_avatar/community.wolfram.com/mariuszi28cg/32/308_2.png) [@mariuszi28cg](https://community.wolfram.com/u/mariuszi28cg)\
**Post date:** [September 14, 2018, 11:43am UTC](https://community.wolfram.com/t/define-an-implicit-function/13092/2 "2018-09-14T11:43:22Z")

</div>

Maybe so:

```
ClearAll["Global`*"]; Remove["Global`*"];(* Clears the kernel *)

```

.

```
b[x_] := FindRoot[b == x - 1/10*Quantile[NormalDistribution[0, 1], b][[1]], {b, 1/2}]

b[0.1]
(* {b -> 0.188386} *)

b[2]
(* Give error messages because, InverseErfc[x] exist only for 0 < x < 2*)

Func[x_, ?_, ?_, s_] := FindRoot[b == x - s*Quantile[NormalDistribution[?, ?], b][[1]], {b, 1/10}]
Func[0.1, 0, 1, 1/10]
(* {b -> 0.188386} *)

```

Another way:

```
f[b_?NumericQ, ?_?NumericQ, ?_?NumericQ, s_?NumericQ] := s*Quantile[NormalDistribution[?, ?], b]
x = 0.1;
? = 0;
? = 1;
s = 1/10;
NMinimize[{1, -b + x - f[b, ?, ?, s] == 0}, b, Method -> "RandomSearch"][[2]] // Quiet
(* {b -> 0.188386 } *)

```

---

<div class="post-metadata">

**Author:** ![bauer](https://avatars.discourse-cdn.com/v4/letter/b/f6c823/32.png) [@bauer](https://community.wolfram.com/u/bauer)\
**Post date:** [September 14, 2018, 3:53pm UTC](https://community.wolfram.com/t/define-an-implicit-function/13092/3 "2018-09-14T15:53:54Z")

</div>

Sorry, I get the same error message as before when I use your first definition. Are there any options or packages to choose?  
I use 11.3.0 on a windows PC and started a new np file with this as the first line.

---

<div class="post-metadata">

**Author:** ![jpd](https://yyz1.discourse-cdn.com/wolfram/user_avatar/community.wolfram.com/jpd/32/34994_2.png) [@jpd](https://community.wolfram.com/u/jpd)\
**Post date:** [September 14, 2018, 4:31pm UTC](https://community.wolfram.com/t/define-an-implicit-function/13092/4 "2018-09-14T16:31:07Z")

</div>

I think you must already have given `b` a value. Try `Clear[b]`, or, better, work in a fresh kernel.
