Tuesday, October 9, 2018

homework and exercises - Lagrangian and KKT Constraint for Falling Ball with a Floor


I am trying to use KKT conditions and slack variables (pg. 118) to put a floor constraint into my Lagrangian for a falling ball with a floor.


\begin{align} \text{extrem}\ \ &\int dt\ \frac{1}{2} m \dot{x}^2 - mgx \\ \text{s.t.}\ \ &x \ge 0 \end{align}


This can be written with a Lagrange multiplier $ \lambda $ and slack variable $ s $ like, \begin{align} S &= \int dt\ \frac{1}{2} m \dot{x}^2 - mgx + \lambda(x - s^2) \\ \delta S &= \int dt\ (- m \ddot{x} - mg + \lambda) \delta x + \delta \lambda(x - s^2) - 2\lambda s \delta s \end{align} where I made the boundary conditions vanish like normal.



Thus I am left with 3 equations, which need to be reduced, being careful to keep $ s $ real, $ \lambda/m = \mu $ \begin{align} \ddot{x} = -g + \mu,\ \ x &= s^2, \ \ s \lambda = 0 \\ 2(\dot{s}^2 + s \ddot{s}) &= -g + \mu\\ s \mu &= 0 \end{align}


I see two cases. $ s \ne 0 $ and $ s = 0 $.


For $ s \ne 0 $ then $ \mu = 0 $, $$ \dot{s}^2 + s \ddot{s} = -g/2 $$


For $ s = 0 $, then $ \mu $ need not be zero,


\begin{align} 2(\dot{s}^2 + s \ddot{s}) &= -g + \mu \\ \dot{s} &= \sqrt{\frac{\mu - g}{2}} \end{align}


For $ s \in \mathbb{R} $, $ \mu \ge g $. Looking at what $ \mu $ does physically, this makes sense. It cancels the gravity out when the ball hits the floor, and further more permits a rebound effect.


Unfortunately, I don't see how, from this method, to get the what $ \mu $ should be exactly. Is there anyway I can get the exact value for $ \mu $? Its not obvious from here that the ball should rebound, although rebound is permitted thus far mathematically.



Answer



The Hamiltonian is, \begin{align} \mathcal{H} = \frac{p^2}{2} + gx - \mu(x - s^2) \end{align}


We claim that the Hamiltonian must not change after the collision



\begin{align} 0 &= \lim_{\epsilon \rightarrow 0} \mathcal{H}(x(t), p(t)) - \mathcal{H}(x(t+\epsilon), p(\epsilon)) \\ &= \lim_{\epsilon \rightarrow 0} \left[ \frac{p(t)^2 - p(t + \epsilon)^2}{2} + g(x(t) - x(t + \epsilon)) - \mu(t)(x(t) - s(t)^2) + \mu(t+\epsilon)(x(t+\epsilon) - s(t+ \epsilon)^2) \right] \end{align}


Let $ x(t) = \lim_{\epsilon \rightarrow 0} x(t+\epsilon) = 0 $ in accordance with the case we wish to solve for, then


\begin{align} 0 &= \lim_{\epsilon \rightarrow 0} \left[ \frac{p(t)^2 - p(t + \epsilon)^2}{2} \right] \end{align} because $ s^2 = x $.


From Hamilton's equations we get, \begin{align} \dot{p} &= \mu - g \\ p(t+\epsilon) - p(t) &= \int_t^{t+\epsilon} dt\ \mu(t) - g \\ p(t+\epsilon)^2 &= p(t)^2 + 2p(t)\left[-\epsilon g + \int_t^{t+\epsilon} dt\ \mu(t) \right] + \left[-\epsilon g + \int_t^{t+\epsilon} dt\ \mu(t) \right]^2 \\ \end{align}


Thus, we get, \begin{align} \lim_{\epsilon \rightarrow 0} \left[ p(t)^2 - p(t + \epsilon)^2 \right] &= - 2p(t) \int_t^{t+\epsilon} dt\ \mu(t) - \left[\int_t^{t+\epsilon} dt\ \mu(t) \right]^2 \\ 2p(t) \int_t^{t+\epsilon} dt\ \mu(t) &= -\left[\int_t^{t+\epsilon} dt\ \mu(t) \right]^2 \\ \int_t^{t+\epsilon} dt\ \mu(t) &= -2p(t) \end{align}


Or, as could have been guessed, \begin{align} \mu(t) = -2p(t)\delta(x(t)) \end{align}


No comments:

Post a Comment

classical mechanics - Moment of a force about a given axis (Torque) - Scalar or vectorial?

I am studying Statics and saw that: The moment of a force about a given axis (or Torque) is defined by the equation: $M_X = (\vec r \times \...