How to obtain equation from graph?

346 Views Asked by At

Consider we have an autonomous differential equation $$\dfrac{dy}{dt}=f(y)$$ and we need to draw a slope field using the information from this graph: enter image description here

I know how to sketch this by hand, but I am trying to sketch it using a software and I want to know if it was possible to know what is the equation $f(y)$ from just looking at this graph. All I can see is that we have four equilibrium points: $y=-4$, $y=-2$, $y=1$ and $y=4$.

And we can also tell for what values of $y$ the function $f(y)$ is either positive or negative.

I tried $$f(y)=(y+4)(y+2)(y-1)(y-4)$$ but it did not give me the correct slope field. Would it be possible to figure the equation of $f(y)$ out? Or is the only way to sketch it is by hand?

2

There are 2 best solutions below

0
On

If all you have is this graph, then it would be impossible to be sure one has the right formula. Since the derivative is not continuous, it would look like

if $x<2$ then $f(x)=\;$some nonlinear function if $x>2$ then $f(x)=ax+b$

0
On

You are correct about your guess $f()=(+4)(+2)(−1)(−4)$ for the left hand side of the graph when $y\leq 2$. However, we need to scale this by some constant $c$, so really we have $f()=c(+4)(+2)(−1)(−4)$.

For the right hand side when $y\geq 2$, we can see we have something like $f(y)=d(4-y)$ where $d$ is some constant. I hope this helps.