# Non-instantaneous model of applied force?

1. Jul 5, 2011

### Aaorris

Hey everyone! I'm a recent high school graduate, and I've been trying to model some simple physics with computer code. What's on my mind right now is modeling applied force using keyboard input. The computer knows if a key is down, or not. Applying force based on that input would mean that your applied force is instantaneous! To remedy this, I imagine 2 solutions:
1. Sin targeting of velocity
2. Damping force
modeled below is an idea for sin targeting, but damping seems a more usual, less computer intensive method... I just have to think about modeling damping force more...

[thinking out loud]
for damping, F = -cV ?
delta_a = -cV
maybe I've just been thinking too hard. What do you guys think?
[PLAIN]http://popoa.webs.com/appliedForce.jpg [Broken]

Last edited by a moderator: May 5, 2017
2. Jul 5, 2011

### Drakkith

Staff Emeritus
I can't see your picture from here at work, so I have to ask that you be a little more specific with what you are asking. Are you asking how to program a "ramp up" time where the force gradually increases in your program after you press the key? I'm not a programmer at all so I apologize if my terminology isn't correct.

3. Jul 6, 2011

### Aaorris

Yes, imagine yourself pushing on a wall - you cannot instantly apply all of your force at once, and you also cannot pull away instantly. I just wanted insight into how to model that.

I believe I'll just half-skip this situation by having a linear force increase over a certain ammount of time, until the force desired is reached to create smooth force transitions