GameDev.net Posting Guidelines (please read before posting)
For Beginners Forum FAQs (please read before posting)
Subscribe to GameDev.net Direct to receive the latest updates and exclusive content.
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.
Posted 08 February 2014 - 04:34 PM
UNREAL ENGINE 4:
Total LOC: ~3M Lines
Total Languages: ~32
--
GREAT QUOTES:
I can do ALL things through Christ - Jesus Christ
--
Logic will get you from A-Z, imagination gets you everywhere - Albert Einstein
--
The problems of the world cannot be solved by skeptics or cynics whose horizons are limited by the obvious realities. - John F. Kennedy
Posted 08 February 2014 - 04:56 PM
The basic form of velocity = start_velocity + (acceleration) * (time) is valid in any number of spatial dimensions. The only thing that changes is the number of components in the relevant vectors.
UNREAL ENGINE 4:
Total LOC: ~3M Lines
Total Languages: ~32
--
GREAT QUOTES:
I can do ALL things through Christ - Jesus Christ
--
Logic will get you from A-Z, imagination gets you everywhere - Albert Einstein
--
The problems of the world cannot be solved by skeptics or cynics whose horizons are limited by the obvious realities. - John F. Kennedy
Posted 08 February 2014 - 05:02 PM
All physics stuff I can think of that works on a vector works regardless of how many spatial dimensions you have, 1D, 2D or 3D doesn't really matter.
As ApochPiQ said, it just changes the vector from being e.g. direction.x to direction.x, direction.y, direction.z.
Posted 08 February 2014 - 05:07 PM
Cross product is 3D specific, that's maths not physics though. There is an analogy for any dimension, the wedge product.
Posted 08 February 2014 - 05:10 PM
UNREAL ENGINE 4:
Total LOC: ~3M Lines
Total Languages: ~32
--
GREAT QUOTES:
I can do ALL things through Christ - Jesus Christ
--
Logic will get you from A-Z, imagination gets you everywhere - Albert Einstein
--
The problems of the world cannot be solved by skeptics or cynics whose horizons are limited by the obvious realities. - John F. Kennedy
Posted 08 February 2014 - 05:14 PM
Physics generalizes pretty well to higher dimensions, so the vector functions like v = u + at, F = ma, and so on apply in any number of dimensions. However some things are different due to the changes in geometry. For instance, there is no rotation in the usual sense in 1D, the cross product operation is not closed in neither one nor two dimensions (but you can still define something which works similarly from a physics perspective). While physics in general is typically first defined in three dimensions because, as far as we can tell, this is the space in which we exist, along with a temporal dimension, there is no reason we can't come up with generalizations in lower or higher dimensions where all or most of the known laws of physics still apply in some sense, even if we can't visualize or test them directly. In fact, generalizations often guide physicists to find simplifications or improvements to existing theories, so it's actually beneficial to seek them.
So, to answer your question, yes, people have tried very hard to make sure that all of the physics equations are applicable in as many different situations as possible, and that includes different number of dimensions. However, you may need to make some changes to some of the code between 2D and 3D to account for fundamental changes in how the various operations which physics builds on are defined (and whether they apply at all in a meaningful way, e.g. rotation in one-dimensional space). Overall you can probably think of 2D as being 3D constrained to two dimensions.
However v = u + at probably doesn't "apply" that well in any dimension to find the velocity of a car, since a car generally is not accelerating in a constant direction at a constant rate. You probably want dv = a * dt where the acceleration of the car is integrated over time to obtain its change in velocity (and you can then integrate that to obtain its change in position).
--
More formally, modern physics does not assume that space is three-dimensional, or even euclidean. The formulas apply to any type of space-time geometry which meets specific mathematical requirements (which depend on the theory being considered, e.g. classical newtonian physics, general relativity, etc.). If you've learnt polymorphism and/or interfaces and/or contracts, this is the same idea: the Physics class uses a Space interface, such as euclidean R^3, which defines what distances, points, and vectors are, as well as a Time interface which describes the flow of time, and applies the (very generic) laws of physics to these. How these interfaces are implemented doesn't matter as long as they behave as expected by the Physics class. Thus you can create different "kinds" of physics which look different, but which ultimately all behave the same on some level. Apologies if I've used poor terminology, I'm not a physicist, just trying to convey that physics can be generalized. (and, no, those aren't *real* classes to be coded up, they are an analogy that I thought might be easier to understand to someone with a programming background)
“If I understand the standard right it is legal and safe to do this but the resulting value could be anything.”
Posted 08 February 2014 - 05:16 PM
What of distance etc. because i saw a formula that is dx/something + dy/something. I can't remember what it was divided by
Edited by Álvaro, 08 February 2014 - 05:17 PM.
Posted 08 February 2014 - 05:19 PM
Distance depends on the topology though. The distance between 2 points on the surface of the Earth is not the Euclidean distance unless you build a tunnel. Same kind of thing applies in Manhattan.
Posted 08 February 2014 - 05:19 PM
You consider it poor and i consider it new.Physics generalizes pretty well to higher dimensions, so the vector functions like v = u + at, F = ma, and so on apply in any number of dimensions. However some things are different due to the changes in geometry. For instance, there is no rotation in the usual sense in 1D, the cross product operation is not closed in neither one nor two dimensions (but you can still define something which works similarly from a physics perspective). While physics in general is typically first defined in three dimensions because, as far as we can tell, this is the space in which we exist, along with a spatial dimension, there is no reason we can't come up with generalizations in lower or higher dimensions where all or most of the known laws of physics still apply in some sense, even if we can't visualize or test them directly. In fact, generalizations often guide physicists to find simplifications or improvements to existing theories, so it's actually beneficial to seek them.
So, to answer your question, yes, people have tried very hard to make sure that all of the physics equations are applicable in as many different situations as possible, and that includes different number of dimensions. However, you may need to make some changes to some of the code between 2D and 3D to account for fundamental changes in how the various operations which physics builds on are defined (and whether they apply at all in a meaningful way, e.g. rotation in one-dimensional space). Overall you can probably think of 2D as being 3D constrained to two dimensions.
However v = u + at probably doesn't "apply" that well in any dimension to find the velocity of a car, since a car generally is not accelerating in a constant direction at a constant rate. You probably want dv = a * dt where the acceleration of the car is integrated over time to obtain its change in velocity (and you can then integrate that to obtain its change in position).
--
More formally, modern physics does not assume that space is three-dimensional, or even euclidean. The formulas apply to any type of space-time geometry which meets specific mathematical requirements (which depend on the theory being considered, e.g. classical newtonian physics, general relativity, etc.). If you've learnt polymorphism and/or interfaces and/or contracts, this is the same idea: the Physics class uses a Space interface, such as euclidean R^3, which defines what distances, points, and vectors are, as well as a Time interface which describes the flow of time, and applies the (very generic) laws of physics to these. How these interfaces are implemented doesn't matter as long as they behave as expected by the Physics class. Thus you can create different "kinds" of physics which look different, but which ultimately all behave the same on some level. Apologies if I've used poor terminology, I'm not a physicist, just trying to convey that physics can be generalized. (and, no, those aren't *real* classes to be coded up, they are an analogy that I thought might be easier to understand to someone with a programming background)
UNREAL ENGINE 4:
Total LOC: ~3M Lines
Total Languages: ~32
--
GREAT QUOTES:
I can do ALL things through Christ - Jesus Christ
--
Logic will get you from A-Z, imagination gets you everywhere - Albert Einstein
--
The problems of the world cannot be solved by skeptics or cynics whose horizons are limited by the obvious realities. - John F. Kennedy
Posted 08 February 2014 - 05:27 PM
UNREAL ENGINE 4:
Total LOC: ~3M Lines
Total Languages: ~32
--
GREAT QUOTES:
I can do ALL things through Christ - Jesus Christ
--
Logic will get you from A-Z, imagination gets you everywhere - Albert Einstein
--
The problems of the world cannot be solved by skeptics or cynics whose horizons are limited by the obvious realities. - John F. Kennedy
Posted 08 February 2014 - 05:35 PM
That would generalise to dv/dt where v = (x, y, z) [maybe more or less components of v depending on dimension]
Posted 08 February 2014 - 05:41 PM
UNREAL ENGINE 4:
Total LOC: ~3M Lines
Total Languages: ~32
--
GREAT QUOTES:
I can do ALL things through Christ - Jesus Christ
--
Logic will get you from A-Z, imagination gets you everywhere - Albert Einstein
--
The problems of the world cannot be solved by skeptics or cynics whose horizons are limited by the obvious realities. - John F. Kennedy
Posted 08 February 2014 - 06:00 PM
UNREAL ENGINE 4:
Total LOC: ~3M Lines
Total Languages: ~32
--
GREAT QUOTES:
I can do ALL things through Christ - Jesus Christ
--
Logic will get you from A-Z, imagination gets you everywhere - Albert Einstein
--
The problems of the world cannot be solved by skeptics or cynics whose horizons are limited by the obvious realities. - John F. Kennedy
Posted 08 February 2014 - 06:03 PM
Check out my book, Game Development with Unity, aimed at beginners who want to build fun games fast.
Also check out my personal website at bryanwagstaff.com, where I occasionally write about assorted stuff.
Posted 08 February 2014 - 06:18 PM
I'll have to understand the basics that is taught online and by textbooks first.Re-iterating the points from Bacterius, the math is still valid in different dimensions.
In college, my linear algebra teacher often gave us simple physics problems but in higher and lower dimensions. (He also had some fun things to help disprove the physics myths of 4+ spatial dimensions, such as "imagine light traveling in 4D space in this direction; what velocity would the light be when viewed on a 3D projection?") Math functions like cross product and dot product, also called the vector product and the inner product, respectively, still work exactly as expected mathematically in different spatial dimensions. It may take some extra work to calculate a 5D cross product, but if you have 4 5D vectors you can still use it to calculate something perpendicular to them.
We live in a world of 3 spatial dimensions. It may take some work to figure out what an operation means in a world with a different number of spatial dimensions, but once you understand it, the math still holds. Right now I expect you could easily explain perpendicular vectors in 2D space and 3D space. But in 4D, can you explain what it means to be perpendicular to a hyperplane? Or in 1D, can you explain what it means to be perpendicular to a point? (Hint, I can't for 1D.)
Going on with your 1D example. With only one spatial dimension you have a scalar universe. I can still imagine acceleration and position in a 1D universe, but concepts like angles don't work as well as they require two or more dimensions. Many operations that use n-1 dimensional components -- such as the cross product -- won't work directly because n-1 is zero. This is probably a perfectly valid thing since in a scalar universe perpendicular would be undefined. With only one component nothing can be orthogonal.
The math still works, you just need to make sure your formulas are the proper versions for that specific dimensionality. And to do that, you need to really understand the math, not just regurgitate formulas fed to you by your search engine.
UNREAL ENGINE 4:
Total LOC: ~3M Lines
Total Languages: ~32
--
GREAT QUOTES:
I can do ALL things through Christ - Jesus Christ
--
Logic will get you from A-Z, imagination gets you everywhere - Albert Einstein
--
The problems of the world cannot be solved by skeptics or cynics whose horizons are limited by the obvious realities. - John F. Kennedy
Posted 08 February 2014 - 07:04 PM
Yes, it is very easy to use currently-stated universal constants to show that our universe has 3 spatial dimensions, not 4 or more as some people claim. The speed of light (mentioned in my example) is one of the easiest ones to use for that. If we lived in a universe with 4 spatial dimensions our 3D physics systems based on 3D constants would not work; the speed of light would not be constant from a 3D reference if it can also angle through 4D. Tautology is great.I'll have to understand the basics that is taught online and by textbooks first.
I just finished reading an article about dimensions greater than 3d or 1d and it basically said there'll be no earth/universe because there'll be no orbit if the universe was 4d or more.
Check out my book, Game Development with Unity, aimed at beginners who want to build fun games fast.
Also check out my personal website at bryanwagstaff.com, where I occasionally write about assorted stuff.
Posted 08 February 2014 - 07:36 PM
Distance depends on the topology though. The distance between 2 points on the surface of the Earth is not the Euclidean distance unless you build a tunnel. Same kind of thing applies in Manhattan.
True, I should have specified I meant Euclidean distance.
Posted 08 February 2014 - 07:45 PM
Distance depends on the topology though. The distance between 2 points on the surface of the Earth is not the Euclidean distance unless you build a tunnel. Same kind of thing applies in Manhattan.
Edited by Álvaro, 08 February 2014 - 07:55 PM.
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.
GameDev.net™, the GameDev.net logo, and GDNet™ are trademarks of GameDev.net, LLC.