Bouncing in an Elevator

Going up! You get into a stationary elevator with a bouncing ball. Its collisions with the floor are perfectly elastic; it always bounces to the same height—in an inertial frame. In this problem, we will simulate what happens to the bounce as the elevator’s acceleration increases very slowly over time.

Suppose at t = 0 t=0 the height of the ball's bounce is h 0 = 1 m h_0 = \SI{1}{\meter} and the elevator begins accelerating upward with a slowly increasing rate a ( t ) = ϵ t . a(t) = \epsilon t. When the acceleration of the elevator reaches a = 1 2 g , a=\frac12 g, what is the peak height of the ball above of the floor in each bounce?

Details & Assumptions

  • ϵ = 0.01 m / s 3 . \epsilon=\SI[per-mode=symbol]{0.01}{\meter\per\second\cubed}.
  • Assume the acceleration due to gravity is g = 10 m / s 2 g=\SI[per-mode=symbol]{10}{\meter\per\second\squared} everywhere.
  • The elastic bounces are instantaneous so that the upward speed of the ball after the bounce is v after = 2 v elev v before v_\text{after} = 2 v_\text{elev}-v_\text{before} where v elev v_\text{elev} is the instantaneous speed of the elevator. v before v_\text{before} is the downward velocity of the ball, and v before < 0. v_\text{before} \lt 0.
  • The instantaneous collisions cannot be described easily using a time-stepping method. Simulate the bouncing exactly to avoid inaccuracies accumulated over many simulated bounces.

import math

g = 10.0 #gravity
epsilon = 0.01 #rate of increase of acceleration

#Initially, the ball is coming off a bounce with velocity that would take it to a height of 1 m in a stationary elevator.
initialState = {"vBall": math.sqrt(2 * g), "vElev": 0, "aElev":0} #vBall: ball velocity // vElev: elevator velocity // aElev: elevator acceleration

def update(state):  
    # This function uses kinematics to calculate exactly how much time elapses between two consecutive bounces.
    # Then computes vBall, vElev and aElev immediately after the next bounce.
    #
    #Input: the state of the system as the ball is coming off a bounce with the elevator floor
    #Returns: the state immediately after the next bounce. Calling this function repeatedly moves the system forward in time. 
    
    ###Add code HERE to compute the state of the ball immediately before the next bounce###
    
    beforeCollision = {"vBall": vBall_New, "vElev": vElev_New, "aElev": aElev_New} #state right before the collision with the floor
    afterCollision = bounce(beforeCollision) #apply the effect of the collision on vBall
    return afterCollision 

def bounce(state):
    #This function applies the update rule to vBall during an instantaneous elastic collision with the floor.
    return {"vBall": (-state["vBall"] + 2 * state["vElev"]), "vElev": state["vElev"], "aElev": state["aElev"]}

def hmax(state):
    #This function computes the maximum height after a bounce. At tmax, the relative speed vBall-vElev = 0 and the ball reaches its max height.
    tmax = 1 / (epsilon) * (-(g + state["aElev"]) + math.sqrt((g + state["aElev"])**2 + 2 * epsilon * (state["vBall"] - state["vElev"])))
    
    #Returns the difference between the height of the ball and the elevator floor
    return state["vBall"] * tmax - 0.5 * (g + state["aElev"]) * tmax ** 2 - state["vElev"] * tmax - 1/6 * epsilon * tmax**3

def simulate(state):
    #This function updates the initial state until the acceleration exceeds g/2, then prints the max height of the previous bounce.
    while (state["aElev"] < 0.5 * g):
        prevState = state #Save the previous state of the system
        state = update(state) #Compute the state after the next bounce

    print("The max height is %f" % hmax(prevState))

simulate(initialState)
Python 3
You need to be connected to run code


The answer is 0.87358.

This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try refreshing the page, (b) enabling javascript if it is disabled on your browser and, finally, (c) loading the non-javascript version of this page . We're sorry about the hassle.

3 solutions

Frederick Doering
Oct 19, 2017

Ignoring the simulation entirely.

First lets observe that the elevator increasing in acceleration results in the same relative moment between the elevator and the ball as if gravity were increasing at a rate of ϵ \epsilon

Then let's look at the energy the ball has at any given point.

E = K E + P E \displaystyle E = KE + PE

E = 1 2 m h ˙ 2 + m ( g + ϵ t ) h \displaystyle E = \frac12\,m\,\dot h^2 + m\,(g+ \epsilon\,t)\,h

Normally, the kinetic energy and potential energy changes cancel out, but in this case we have an additional term:

d E d t = m h ˙ h ¨ + m ( g + ϵ t ) h ˙ + m ϵ h \displaystyle \frac{dE}{dt} = \,m\,\dot h\,\ddot h + m\,(g+ \epsilon\,t)\,\dot h + m\, \epsilon \,h

Since h ¨ = ( g + ϵ t ) \ddot h = -(g+\epsilon\,t) the first two terms cancel as usual and we get:

d E d t = m ϵ h \displaystyle \frac{dE}{dt} = m\, \epsilon \,h

If we have the energy then we can find the peak height:

h p e a k = E m ( g + ϵ t ) \displaystyle h_{peak} = \frac{E}{m\,(g+\epsilon\,t)}

Looking at the time average of a parabola, the average height is exactly 2 3 \frac23 of the peak height. When looking at these cubic curves it's a little off but accurate to 1 ppm. Thus:

h a v e = 2 3 h p e a k \displaystyle h_{ave}=\frac23 h_{peak}

Now if we use this h a v e h_{ave} value in our energy change equation we can create a solvable differential equation:

d E d t = m ϵ h a v e \displaystyle \frac{dE}{dt} = m\, \epsilon \,h_{ave}

d E d t = m ϵ 2 3 h p e a k \displaystyle \frac{dE}{dt} = m\, \epsilon \,\frac23 h_{peak}

d E d t = ϵ 2 3 E g + ϵ t \displaystyle \frac{dE}{dt} = \epsilon \,\frac23 \frac{E}{g+\epsilon\,t}

1 E d E = 2 3 ϵ g + ϵ t d t \displaystyle \int \frac1E dE = \int \frac23 \frac{\epsilon}{g+\epsilon\,t} dt

ln ( E ) = 2 3 ln ( C ( g + ϵ t ) ) \displaystyle \ln(E) = \frac23 \, \ln(C (g+\epsilon\, t) )

E = C ( g + ϵ t ) 2 3 \displaystyle E = C (g+\epsilon\, t)^{\frac23}

We know our initial energy:

E 0 = m g h 0 \displaystyle E_0 = m\,g\,h_0

So we can find out constant C:

E = m g h 0 ( g + ϵ t g ) 2 3 \displaystyle E = m\,g\,h_0 \ \left( \frac{ g+\epsilon\, t } {g} \right) ^{\frac23}

Since we have our energy we can now find our peak height:

h p e a k = h 0 g g + ϵ t ( g + ϵ t g ) 2 3 \displaystyle h_{peak} = h_0\, \frac{g}{g+\epsilon\,t} \, \left( \frac{ g+\epsilon\, t } {g} \right) ^{\frac23}

h p e a k = h 0 ( g + ϵ t g ) 1 3 \displaystyle h_{peak} = h_0\, \left( \frac{ g+\epsilon\, t } {g} \right) ^{-\frac13}

Since we know ϵ t = 1 2 g \epsilon \,t = \frac12 \, g we can now plug that in to get the final answer:

h p e a k = h 0 ( 3 2 ) 1 3 = 0.87358 h 0 \displaystyle h_{peak} = h_0\, \left( \frac32 \right) ^{-\frac13} = 0.87358 h_0

This is a fantastic solution—I did not think it could be calculated by simple means. Beautifully done 😍 .

Josh Silverman Staff - 3 years, 7 months ago

Please explain it in more detail because I don't understand it. And it would be really nice if you could also tell me the representations of the additional symbols you have used. Thanks.

Prakhar Mathur - 3 years, 7 months ago

Log in to reply

@Frederick Doering can you expand on why you make the replacement h h ave ? h\rightarrow h_\textrm{ave}? It is a subtle point, and the reasoning to justify it is pretty interesting/makes connections to @Sean Lourette 's approach.

Josh Silverman Staff - 3 years, 7 months ago
Alex L
Oct 17, 2017

Elevator floor position changes as x e l e v ( t ) = x e + v e t + a e t 2 2 + ϵ t 3 6 x_{elev}\left(t\right)=x_{e} + v_{e} \cdot t + a_{e}\cdot\frac{t^2}{2}+ \epsilon\cdot\frac{t^3}{6} ball position is x b a l l ( t ) = x b + v b t g t 2 2 x_{ball}\left(t\right)=x_b + v_b \cdot t-g\cdot\frac{t^2}{2} ball height relative to the elevator floor is x b a l l ( t ) x e l e v ( t ) = v b t g t 2 2 v e t a e t 2 2 ϵ t 2 6 x_{ball}\left(t\right) - x_{elev}\left(t\right) = v_{b}\cdot t-g\cdot\frac{t^2}{2} - v_{e}\cdot t- a_{e}\cdot\frac{t^2}{2} - \epsilon\cdot\frac{t^2}{6} next bounce occurs when height is zero t ( ( v b v e ) ( g + a e ) 2 t ϵ 6 t 2 ) = 0 t\cdot\left(\left( v_{b} - v_{e} \right) - \frac{\left(g+a_{e}\right)}{2} \cdot t-\frac{\epsilon}{6} \cdot t^2 \right)=0 or t next bounce = ( g + a e ) 2 + ( g + a e ) 2 4 + 4 ϵ 6 ( v b v e ) 2 ϵ 6 t_\text{next bounce} = \frac{-\frac{\left(g+a_{e}\right)}{2} + \sqrt{\frac{\left(g+a_{e}\right)^2}{4} + 4\cdot\frac{\epsilon}{6}\cdot\left( v_{b} - v_{e} \right)}}{2\cdot\frac{\epsilon}{6}}

so we need to complete update function:

#calculate time of next bounce
t_next = 3 / (2 * epsilon) * (-(g + state["aElev"]) + math.sqrt((g + state["aElev"])**2 + 8 * epsilon * (state["vBall"] - state["vElev"]) / 3)) 

#calculate velocity and acceleration before next bounce
vBall_New = state["vBall"] - g * t_next
vElev_New = state["vElev"] + state["aElev"] * t_next + 0.5 * epsilon * (t_next ** 2)
aElev_New = state["aElev"] + epsilon * t_next

and simulation outputs answer:

The max height is 0.873609

Thank you!. What I still do not understand is why the speed after the bounce is 2 ve - v bf. Can anyone explain?

Jose Jimenez - 3 years, 7 months ago

Log in to reply

Hey Jose, I'm going to assume that you're comfortable with the idea that if the ball bounces on the floor, its velocity goes from v b v_b to v b -v_b (because it reflects off the floor). If not, let me know.

So, let's assume that the initial velocity of the ball is zero. It's just sitting there, the elevator comes along and hits it traveling with velocity v e . v_e. Let's assume that the velocity of the elevator goes from v e v_e to v e Δ v e . v_e - \Delta v_e. Writing down the conservation of momentum, we have

M v e before = m v b + M ( v e Δ v e ) after \overbrace{Mv_e}^\textrm{before} = \overbrace{mv_b + M(v_e - \Delta v_e)}^\textrm{after}

which simplifies to M Δ v e = m v b . M\Delta v_e = mv_b.

This gives us a simple relationship between the change in velocity of the elevator and the final velocity of the ball v b = M m Δ v e . v_b = \frac{M}{m}\Delta v_e.

Now if we write down the conservation of energy, we have

1 2 M v e 2 before = 1 2 m v b 2 + 1 2 M ( v e Δ v e ) 2 after M m v e 2 = v b 2 + M m ( v e 2 2 v e Δ v e ) v b 2 = 2 M m v e Δ v e \begin{aligned} \overbrace{\frac12 Mv_e^2}^\textrm{before} &= \overbrace{\frac12mv_b^2 + \frac12M\left(v_e - \Delta v_e\right)^2}^\textrm{after} \\ \frac{M}{m}v_e^2 &= v_b^2 + \frac{M}{m}\left(v_e^2 - 2v_e\Delta v_e\right) \\ v_b^2 &= 2\frac{M}{m}v_e\Delta v_e \end{aligned}

Notice that I ignored the term on the right hand side proportional to ( Δ v e ) 2 , \left(\Delta v_e\right)^2, that's because we assume it is very small relative to v e . v_e.

Now, if we substitute Δ v e = m M v b \Delta v_e = \frac{m}{M}v_b into the last equation we find

v b 2 = 2 M m v e Δ v e = 2 M m v e m M v b v b = 2 v e \begin{aligned} v_b^2 &= 2\frac{M}{m}v_e\Delta v_e \\ &= 2\frac{M}{m}v_e\frac{m}{M}v_b \\ v_b &= 2v_e \end{aligned}

which is the result we're after.

The calculation turns on the idea that the change in velocity of the elevator is very small compared to that of the ball. This should be a reasonable assumption given that the elevator's speed is imposed by the motor that's lifting it, so Δ v e \Delta v_e is very tiny indeed.

Josh Silverman Staff - 3 years, 7 months ago

Log in to reply

Thank you. Very clear and nice explanation.

Jose Jimenez - 3 years, 7 months ago

I not understand that how peak height ??

Satanand Tiwari - 3 years, 6 months ago

Log in to reply

Hi @Satanand Tiwari , can you say a bit more about what you're confused about?

Josh Silverman Staff - 3 years, 6 months ago
Sean Lourette
Oct 19, 2017

This problem has an elegant solution using the adiabatic invariant, which should work as long as ϵ \epsilon is small. First, using conservation of energy, we find an equation for the relationship between the maximum displacement and maximum momentum.

E = p 0 2 2 m = m g x 0 E = \frac{ p_{0}^2 }{ 2 m } = m g x_0

x 0 = p 0 2 2 m 2 g x_0 = \frac{ p_{0}^2 }{ 2 m^2 g } , p 0 = 2 m 2 g x 0 p_0 = \sqrt{ 2 m^2 g x_0 }

Then we can use the adiabatic invariant (area enclosed in the phase diagram is constant under adiabatic changes) as a second relationship between these two quantities.

A = p d x A = \oint p\,dx

A x 0 p 0 A \propto x_0 \cdot p_0

Combining these we can eliminate momentum and see how maximum displacement is affected by g, Earth's gravitational constant.

A g 1 / 2 x 0 3 / 2 A \propto g^{1/2} x_0^{3/2}

x 0 g 1 / 3 x_0 \propto g^{-1/3}

In this problem, increasing acceleration to 0.5 0.5 g has the same effect as increasing g by a factor of 1.5 so

g ( 3 2 ) g g \mapsto ( \frac{3}{2} ) g

p 0 ( 3 2 ) 1 / 3 p 0 p_0 \mapsto (\frac{3}{2})^{1/3} p_0

x 0 ( 2 3 ) 1 / 3 x 0 0.874 x 0 x_0 \mapsto (\frac{2}{3})^{1/3} x_0 \approx 0.874 x_0

Is there an intuitive reason why p d x \oint p\ dx should stay unchanged over the course of the acceleration?

Josh Silverman Staff - 3 years, 7 months ago

Log in to reply

I'm not sure how intuitive this explanation is, but I'll give it a shot. If g is only increased when the ball is at its maximum displacement, then x 0 x_0 should remain unchanged and p 0 p_0 will be larger, making the integral larger by some factor. If g is only increased when the ball is at its maximum momentum, then p 0 p_0 will be unchanged and x 0 x_0 will be smaller, making the integral smaller by the same factor . However, if we increase g gradually, we should get a combination of these effects, and due to the symmetry in the Hamiltonian equations of motion, these effects will cancel keeping the integral constant.

Sean Lourette - 3 years, 7 months ago

0 pending reports

×

Problem Loading...

Note Loading...

Set Loading...