Using squared math to map a timer to a digipot

Unfortunately the OP insists on having one of the X endpoints of the curve to be determined on the fly, so a lookup table is not possible. I quote:

The low value is always 250, the high valve varies anywhere between 200 and 90 depending on where the potentiometer is set

I agree that a simple quadratic would be fine, but the OP does not appear to be in a position to even describe the goal accurately, let alone implement it unassisted.

I'm done with this thread, so have fun! But here is another approach: find the quadratic that passes through two points, with a defined slope at one of the points.

Ah, yes, right. Then either that, or maybe a bi-linear approach.

Well, I couldn't resist: just for completeness, here is the solution to the quadratic
y = a x^2 + b x + c
that passes through the two points (x1, y1), (x2, y2) and has slope d at x1.

quadratic

Not as straightforward as Langrange interpolation.

Nice work. Here's hoping the OP will find one of the offered solutions to be useful.

An advantage of the quadratic approach is that unlike Lagrange interpolation (which cannot be reduced to a quadratic), the equation IS a simple quadratic. The "d" or slope parameter can be used to tune the amount of curvature.

While those algebraic equations look a bit unwieldy, a decent program like Mathematica can simplify the result quite handily. And, it comes free with operating systems distributed with a Raspberry Pi.

After a few minutes of experimentation, I was able to produce this plot, for a quadratic that passes through the two points (90, 127), (250, 0) and has initial slope of 1.5x that of the straight line through those two points.

It reduces to a very simple equation.

This curve has slope = 2x that of the straight line through the two points.

Capture

Nice!

PS: regarding...

...it can, but the three terms (a,b,c) become very complex functions of the three points (xi,yi). The Lagrange formulation is much simpler. This MathCAD example hides the complexity, since it solves for the quadratic with three given points:

image
.
.
.
But since apparently one of the points changes on the fly, it would be much easier to go with your approach in #25.

but the three terms (a,b,c) become very complex functions of the three points (xi,yi). The Lagrange formulation is much simpler. This MathCAD example hides the complexity, since it solves for the quadratic with three given points.

I don't see how that approach converts the Langrange expression into a quadratic, and I'm unable to convince myself that the f1() and f2() yield the same numbers, for the same input.

Edit: they do, after all. Thanks!