a thing about rockets

Started by
11 comments, last by mldaalder 19 years, 4 months ago
Hello there. I started a game that i have to shoot rockets. :) (how original am i!!!?) I already build a model for the rocket and depending on several forces i know where to render it first and i think it works. Questions: (1)What i am missing is how to calculate the rotation of the rocket based on the forces acting on it. (2)Where should i have the rotation of the rocket? in the middle? Thank you very much.
Advertisement
Quote:Original post by psychoullis
I started a game that i have to shoot rockets. :) (how original am i!!!?)


Could be very cool!

Quote:Original post by psychoullis(1)What i am missing is how to calculate the rotation of the rocket based on the forces acting on it.


Do you have an understanding of rigid body rotational dynamics, e.g., moment of inertia and/or the inertia tensor, torque, angular momentum? These are the analogs of translational motion, and you do need to understand them to simulate rotation realistically...

Quote:Original post by psychoullis(2)Where should i have the rotation of the rocket? in the middle?


The equations are simpler if you treat rotation about the center-of-mass. Which for a game you could just assume is in the middle and all will be well, :).

(Technically, the reason we choose center-of-mass is because it enables you to treat the translational physics independent of the rotational physics, e.g., the equations become decoupled because some nice things happen to the inertia tensor about center-of-mass.)
Graham Rhodes Moderator, Math & Physics forum @ gamedev.net
I've felt an impetus answering this thread , why do you want to rotate a rocket ? i've studied jet fans at uni and i can assure that a rocket isn't allowed to rotate about its own axis, that's why it has final flaps , to stabilize it, am i missing something about your rotation definition ? let me suggest you ( no pun intended ) to have allok at a physics book ,where center of mass translation is discussed, there is a classic example about a rocket!
Or take a look at www.nasa.gov

They have loads on physics articles. Especially rockets.
thnx for the replies.

ketek,i have not study any rockets in uni, but if a rocket wont rotate how is it going to come down to earth? If it always going upwards? Please tell me if i got something wrong.

Thnx for the links also...

I bought an oreilly book to refresh my physics!

Quote:Original post by psychoullis
ketek,i have not study any rockets in uni, but if a rocket wont rotate how is it going to come down to earth? If it always going upwards? Please tell me if i got something wrong.

The rotation has nothing to do with it.
[wink]

The rocket can still be pointing up when it hits the ground.
It can have any number of reasons why it is this.
The tail fins give more drag on the tail end of the rocket than the head end. You can model this by exerting a small force on the tail end of the rocket, counter to the rockets velocity, and proportional to the square of the velocity. This assumes you already have a simulation that can take into account rotational momentum, though -- if you don't, hop on over to http://www.ode.org/ and save yourself a year of implementing it yourself ;-)
enum Bool { True, False, FileNotFound };
Alright, I could be *totally* off base here, as my physics is REALLY rusty, but I did catch what I thought was a miscommuncation and thought I'd highlight it so it could be worked on.

psychoullis mentioned having the rocket "rotate" when it needed to. What I think he meant was the rocket should have the ability to alter its trajectory, NOT spin like a bullet on its own axis.

I could be wrong, but when the post said if it didn't rotate it couldn't come back to Earth, I think that's what he was getting at...spinning bullets don't come back cause they're not supposed to. =)
Quote:Original post by mldaalder
Quote:Original post by psychoullis
ketek,i have not study any rockets in uni, but if a rocket wont rotate how is it going to come down to earth? If it always going upwards? Please tell me if i got something wrong.

The rotation has nothing to do with it.
[wink]

The rocket can still be pointing up when it hits the ground.
It can have any number of reasons why it is this.


??? how accurate will that be? You tell me that when rockets hit the targets are pointing upwards???

as serratemplar said what i meant is to turn not to spin, sorry if i used wrong terms.

Thnx for replies.
Quote:Original post by serratemplar
I could be wrong, but when the post said if it didn't rotate it couldn't come back to Earth, I think that's what he was getting at...spinning bullets don't come back cause they're not supposed to. =)


Erm.. if you shoot a bullet into the air, it comes back again. It doesn't just keep on going.

As for the OP, I'm assuming you're talking about firing a rocket into the air, have gravity taking effect, and it falling back to earth. Well, just add gravity onto the velocity vector every iteration, and point the rocket in the same direction as the velocity vector.
If at first you don't succeed, redefine success.

This topic is closed to new replies.

Advertisement