Solving C0-Dependant Functions

80 Views Asked by At

Alright. I'm attempting the most advanced math of my life and trying to figure this out. I nearly broke Wolfram Alpha trying to enter this in.

$c(f) = -4(t - m)f^2 - 4(m - t)f+m$ when f <= 0.5
$c(f) = t$ when f > 0.5
$f(x) = (x / c * 1000) / p$

f bound between 0 and 1

m, t and p are constants. I'm trying to basically reduce these equations, solving for c and f respectively, given x. Is it possible?

EDIT: So I know this should be possible. I broke it down into a spreadsheet, generating values in small increments: https://docs.google.com/spreadsheets/d/1x51uLpdDuoYnK3UdkRDCTs3ZE_4qzkyytvHfCvNoGug/edit?usp=sharing

I guess what I'm really looking for is c(x) and f(x) with x as the only variable input. The way I set up the spreadsheet, I think it might be a calculus problem? i.e. incorporating dc and df. In the spreadsheet, we initialize with x = f = 0. c is then calculated based on the previously calculated f value.

EDIT 2: This is kind of bizarre. If we approximate the derivative of the f function using (dy/dx) on the spreadsheet, we get a very interesting graph. If we approximate the derivative of that function, we get a steeper curve. If we keep approximating the derivative of the subsequent derivatives, we get graphs that approximate an L / and upside-down L converging on the x and y axes. WHAT DOES IT MEAN?

1

There are 1 best solutions below

3
On

First, taking a look at the case where $f(x) > 0.5.$ In this case, you can solve directly for $f$.

$c = \frac{1000x} {pf} = t$

$f = \frac{1000x} {tp}$

Since f is bounded between 0.5 and 1 here, you can solve for the x-values that give this region, which are:

$\frac1 2 \frac {tp} {1000} < x < \frac{tp}{1000} $

The other region, $f(x) \le 0.5$, is more difficult. Setting the two definitions of $c(f)$ equal to each other, you get a cubic equation in $f$:

$4(t-m)f^3-4(t-m)f^2-mf+ \frac{1000x}{p} = 0$

or

$f^3-f^2-\frac m {4(t-m)}f+\frac{1000x}p=0 $

Solutions to cubics are big and messy, but here's the overview, a la wikipedia:

$a=1, b=-1, c=\frac{-m}{4(t-m)}, d=\frac{1000x}{p}$

$\Delta=18abcd -4b^3d+b^2c^2-4ac^3-27a^2d^2$

If $\Delta$, the discriminant, is positive, there will be three real solutions, otherwise there will be one.

$\Delta_1=2b^3-9abc+27a^2d, \Delta_0 = b^2-3ac$

$C=\sqrt[3]{\frac{\Delta_1 \pm \sqrt{-27a^2\Delta}}{2}}$

Finally, $f=\frac{-1}{3a}(b+C+\frac{\Delta_0}{C})$, which is a function of $x$. It's messy and annoying to do by hand, but you could set up a program to solve for the coefficients in something like Excel or Matlab.

Now, to find the conditions for which this function is bounded between 0 and 0.5. From your definition of $f(x)$ in terms of $c$, it can be seen that $f(x)$ is equal to zero if $x=0$ or $c\rightarrow \infty$. Since $c$ only goes to infinity when $f$ does, $x=0$ is the only zero of $f$.

Plugging in for $f=0.5$, you can find that the boundary for this region is: $0<x\le\frac1 2 \frac{tp}{1000}$

Assuming $p>0$, you have a function $f$ which grows from 0 at $x=0$ to 0.5, then becomes linear until it reaches 1.