Thread: Force and Momentum

  1. #1

    Force and Momentum

    I took chemistry instead of physics so I need some help.

    What variables should I include in my objects to calculate Force and Momentum.

    I need...
    int speed;
    float angle;


    what do i need to calculate the force of an object given I have the weight and speed already recorded also Momentum?
    My Avatar says: "Stay in School"

    Rocco is the Boy!
    "SHUT YOUR LIPS..."

  2. #2
    physics is fun
    Guest
    force = mass * accelleration

  3. #3
    Ok thanks,

    but is acceleration what I'm thinking about Momentum?

    I mainly want to know how to decelerate something realistically.
    My Avatar says: "Stay in School"

    Rocco is the Boy!
    "SHUT YOUR LIPS..."

  4. #4
    Registered User Aran's Avatar
    Join Date
    Aug 2001
    Posts
    1,301
    that depends on several factors.

    I'll need to know if there's any wind resistance, and what the quantity of the force of friction in order to answer your question.

  5. #5
    This is a standard 3D world - so Earth's gravity - I don't think I will need wind resistance on my objects - I can mimmick it and only for things like Flags and Smoke.

    so NO Wind... and I guess Friction would be Earth's gravity pull.

    I will have more complicated objs. but right now it can be thought of as a BULLET or BALL flying through the air.
    My Avatar says: "Stay in School"

    Rocco is the Boy!
    "SHUT YOUR LIPS..."

  6. #6
    Programming Sex-God Polymorphic OOP's Avatar
    Join Date
    Nov 2002
    Posts
    1,078
    Originally posted by OneStiffRod
    I need...
    int speed;
    float angle;
    Originally posted by OneStiffRod
    This is a standard 3D world
    In 3D, a single scalar angle is not enough to represent orientation. You'd need to express an arbitrary axis to rotate around, or you'd have to present it as combined rotation around two or more of the standard axes.

    But, to be honest, neither of those is usually the optimal solution. If you express angle using a scalar angle measure, then you need to use trigonometric functions to get any use out of them. Instead, what you want to use is a 3-Dimensional vector with x, y, and z components. Each components represents the "power" the motion has along the corresponding axis.

    Also, a vector not only represents direction, but also magnitude in that direction. That means that you can contain both the direction and speed (velocity) in a single vector.

    If you're trying to work strictly with angles and no vectors and want to do physics in 3D, then you'll have a lot of problems and the calculations will be slower and more complex. Look up "linear algebra" online and study vectors.

  7. #7
    I know about working with vectors but I don't get how xyz can hold Velocity, don't I have to add another 'thing' in the vector like xyza or something.

    My models have a PIVOT PT and a DIRECTION PT the direction pt pivots around the pivot pt., so the directional pt is the key to deciding where the obj is heading.

    Code:
                       0   -directional pt
                         \+  +
                       + \     +
                     +    \      +
                    +      O - pivot pt
                      +          +
                        +       +
                          +   +
                            
    //as close to a circle as I can get
    My Avatar says: "Stay in School"

    Rocco is the Boy!
    "SHUT YOUR LIPS..."

  8. #8
    Programming Sex-God Polymorphic OOP's Avatar
    Join Date
    Nov 2002
    Posts
    1,078
    no, you don't need a 4th value. The ratios of the components (or lack there of) give you the direction. The magnitude of the vector gives you the velocity in that direction (or you can use the magnitude to represent acceleration, or anything else you want as well).

    You get the magnitude of the vector through the pythagorean thereom

    sqrt( x*x + y*y + z*z )

  9. #9
    I lurk
    Join Date
    Aug 2002
    Posts
    1,361
    I read this: http://www.gamedev.net/reference/art...rticle1443.asp yesterday. It seems to pertain to what you're talking about.

  10. #10
    Blank
    Join Date
    Aug 2001
    Posts
    1,034
    momentum is mv so this is vector that can have x, y, z components. I think newtons law can be rephrased
    to be f = dp/dt where p is the momentum.

  11. #11
    Registered User Coder's Avatar
    Join Date
    Aug 2001
    Location
    Cairo, Egypt
    Posts
    128
    I think newtons law can be rephrased to be f = dp/dt where p is the momentum.
    Yes. Actually, newton's law states that the force is equal to the rate of change of the momentum ( mass * velocity ).

    For macro-particles, the mass is considered a constant and thus the force becomes "mass multiplied by the rate of change of the velocity ( acceleration )"

    dp/dt = d(mv)/dt = m * dv/dt = m * a

    For particles at high velocities, the mass changes , and you can get the new mass using Einstein's equation:
    newMass = restMass/( sqrt( 1 - velocitySquared/lightVelocitySquared ) )

    In general, as long as the velocity of your particle/object is less than ( 0.1 * lightVelocity ) you can consider its mass to be constant. ( light velocity approx = 300,000,000 m/s )

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Force and Velocity Physics
    By IdioticCreation in forum Game Programming
    Replies: 12
    Last Post: 12-19-2007, 05:29 PM
  2. Need help with gravity engine
    By madmech in forum Game Programming
    Replies: 11
    Last Post: 07-03-2005, 02:41 PM
  3. another physics question (momentum)
    By Leeman_s in forum A Brief History of Cprogramming.com
    Replies: 3
    Last Post: 12-23-2003, 05:28 AM
  4. just a thought...
    By Carlos in forum A Brief History of Cprogramming.com
    Replies: 66
    Last Post: 05-25-2003, 07:46 PM