I am looking for a parametrized equation (i.e. a class of equations), which has the following properties:
- It has the form of $f(x) = 0$, where $f(x)$ is an increasing or decreasing (i.e. monotone) function
- It has a solution
- It has a single solution
- Boundaries for the solution can be easily calculated from the parameters
- The solution can be obtained easily only by numericalal methods, in particular, binary search.
I need it to set up a problem for a programming contest for first-year students, in which they must find the solution for an equation, given its parameters. The first three requirements make things simpler. The requirement about the boundaries will enable them to set up the boundaries for their binary search (they don't know any more sophisticated numerical methods yet). The last requirement is to ensure that they cannot analytically find a solution, so they will have to use binary search.
If, in addition, the equation makes physical sense, that would be perfect (I could invent a background story for the problem). Hope the question is on topic.
Here is another idea. Use the $\Gamma$ function to pose the problem instead:
$$f\left(t;\theta\right)=\Gamma\left(\theta t+2\right)-1.5$$
$\theta$ is the parameter you requested. A sufficient condition for a root to exist on $t\in\left(0,1\right)$ are $\theta\geq 1$, which gives you a very large range of parameters to use.
I doubt they will find a direct way to compute the inverse of $\Gamma$.
You can allow them to use one of $\Gamma$'s well-known approximations. One of the Lanczos approximations featured on that page (at the time of writing) is:
$$\Gamma\left(x\right) \approx x^{x-\frac{1}{2}}e^{-x}\sqrt{2\pi}\left(1+\frac{1}{12x}+\frac{1}{288x^2}-\frac{139}{51840x^3}-\frac{571}{2488320x^4}\right)$$
for all $x\in\mathbb{R}$.
For $\theta=1$, the answer is approximately $0.6628$. Here is a plot using the approximation to the Gamma function: