How does one solve ODE with some domain constraints?

129 Views Asked by At

So far I have no clue, how to go about this .. in school we did not go over constraint based ODES.

So let's say we have

$\ x'' = -ax' $

$\ y'' = -ay' - b $

Note: a,b are constant and x(t), y(t).

$\ x(0) = X_{i} $

$\ y(0) = Y_{i} $

$\ x'(t_{end}) = V_{xf} $

$\ y'(t_{end}) = V_{yf} $

How do I solve for a solution in which I want some constraint such that let's say when

$\ 10<x<11 $ then $ y > 10 $

in words (when x is between 10 and 11, y has to be more than 10).

Is there any numerical way to solve this type of situations ? Any feedback would be greatly appreciated.

1

There are 1 best solutions below

0
On

Note that the two ODEs are not coupled. Let's focus on $$ x^{\prime\prime}\left(t\right)=-ax^{\prime}\left(t\right)\text{ for }0<t<t_{end}. $$ The general solution is $$ x\left(t\right)=c_{1}e^{-at}+c_{2}\text{ for }0<t<t_{end}. $$ where $c_{1}$ and $c_{2}$ are arbitrary. We need to satisfy the initial conditions. On the left-hand boundary, $$ x\left(0\right)=X_{i}=c_{1}+c_{2} $$ so that $c_{2}=X_{i}-c_{1}$. On the right-hand boundary, $$ x^{\prime}\left(t_{end}\right)=V_{xf}=-ac_{1}e^{-at_{end}} $$ so that $$ c_{1}=-\frac{V_{xf}e^{at_{end}}}{a}. $$ You can use the same ideas to solve the other one.