#### Archived

This topic is now archived and is closed to further replies.

# Book : Physics for game developers

This topic is 5733 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

## Recommended Posts

Guys, I bought the above book a week ago, and although it is very good at providing background knowledge of physics (most of the stuff I new already), one major thing struck me as I read it. Now I guess this must be an obvious statement, so don''t kill me for it. The books author, all the way through the book uses trig to work out angles etc, for example in firing a projectile, he uses trig to separate the forces in horizontal and vertical components. But in designing my own simple physics engine, I thought, why use expensive trig. functions, when vector maths will sort it out for you. e.g. a Velocity vector of v = (0,0,0), if there is an acceleration vector of a = (0,20,10), and we have a time interval of t=1 second, and gravity is g = (0,-10,0) N, then to work out the new velocity vector, we simply do: v_new = v_old +(a+g)*t v_new => (0,0,0) + (0,10,10)*1 > => (0,10,10) Is that obvious, and have I just stated the most obvious thing on this forum, but why even think about using trig and the equations of motion etc? cheers Matt

##### Share on other sites
I haven''t read the book, but I''m assuming the author started with an angle and a acceleration instead of starting with (0, 20, 10).

If you start with vectors, then your way makes sense. If you start with "the turret is angled at D degrees and the muzzle velocity is V", then you really need trig.

Like I said, I haven''t read the book, but it''s probably easier to explain the concepts using trig. If you can create your engine in a way that doesn''t use trig, that''s great, but you will probably have to jump through hoops that aren''t necessarily a key part of learning physics.

Author, "Real Time Rendering Tricks and Techniques in DirectX", "Focus on Curves and Surfaces"

##### Share on other sites
I think that the issue that you are running in to is the difference between the math, what is programatically ideal, and how we think about real world situations. In mathematical terms, either way is perfectly acceptable. Because of the various ways to represent vectors (magnitude-angle, components, imaginary numbers, etc.), it is important to be versed in all the different methods of dealing with them. I personally like component form, but sometimes its nice to know what the magnitude is rather than looking at the direction. Programatically, it would be best to have everything in terms of components because then vector arithmitic simplifies to addition problems. Finally is the issue of how we think about vectors. When driving or flying, we use bearings and magnitudes because it is far easier to understand flying 300 m/s at 65 degrees rather than <271.9, 126.8> m/s. Thats just my thought on the subject, hope it helps.
Brendan

1. 1
2. 2
3. 3
Rutin
21
4. 4
5. 5

• 14
• 30
• 13
• 11
• 11
• ### Forum Statistics

• Total Topics
631777
• Total Posts
3002306
×