phetsims/collision-lab

Should the step-backward button be disabled for perfectly inelastic collisions

Closed this issue · 4 comments

Currently, stepping backwards works by trying to reconstruct the Balls motion by their current velocity.

This is bringing up a variety of bugs with perfectly inelastic collisions. For instance, after a sticking perfectly inelastic collision, the balls are stuck together and moving in the same direction. Stepping the sim backwards will simply move the ball in the opposite direction. The model has no idea when they collided and doesn't know when to separate the balls.

1231231623


The flash sim completely avoided this issue by disabling the step-backward button for perfectly inelastic collisions. Should the HTML5 version do the same?

In Flash, the StepBackwardButton is only enabled for perfectly elastic collisions. We should follow the same pattern here and disable the button for elasticity =/= 100%.

Thanks @arouinfar, this has been implemented in the commit above.

Since I used a workaround solution, I'm not going to close this until phetsims/scenery-phet#563 is addressed.

@jonathanolson this issue looks stale, and given the changes in #183 we can probably close it.

This is stale, closing.