Sign in to follow this  
data2

How to model distortion of rubber surface due to gravity??

Recommended Posts

Hi there, I have a grid laying on the xz-plane in 3d space and like to have a distortion like these used to visualize bending of (2d) space due to gravity (like in http://fusionanomaly.net/gravity.jpg, though the pic isn't very nice). Does anybody have an idea how to model this?? Which function is to be used to bend the grid / 2d surface? What are the parameters? It looks like a gaussian normal distribution or something. I'm not looking for a physically based method (which I doubt exists for such a crude simplification). I'll also need to compute the normals for the grid points to have a nice lighting of the bended suface :-). Thanks and greetings, Data

Share this post


Link to post
Share on other sites
I think the picture you linked is illustrating gravitational potential energy (if you ignore the space-bending relativity aspect). The function is then inversely proportional to the distance from the center squared, unless the distance is less than the radius of the sun, at which point it depends on the sun's density. If a uniform density is assumed, the function becomes proportional to distance, ie linear. With a black hole, the density is focused at the singularity and the thing stays inversely proportional to the distance squared the whole way, which appears in illustrations like this as a sort of hole because of the asymptote.

Share this post


Link to post
Share on other sites
Ehem, sounds cool. But do you have an equation? In fact, I don't really have objects with a mass or something. I'm only interested in this smooth bending effect. I'll have something like a radius of effect and a "distance" how far the central point is moved away orthogonal to the surface.

Share this post


Link to post
Share on other sites
A completely non-physically accurate method is to visualize the gravitating body as producing a central force field, a repulsion at that, inversely proportional with respect to distance between force center and test point. Imagine the vertices of the rubber sheet as being pushed directly away from the force center by an amount proportional to the body mass, and inversely proportional to the distance. Of course, this is a purely fictional 'force' only used to 'remap' space.

For example, assuming R is the position vector of the mass, M is the mass, r is the position vector of an undeformed sheet vertex, then:

r'=r+M*(r-R)/((|r-R|)*(|r-R|))

where r' is the deformed position of the vertex.

[Edited by - Mastaba on April 9, 2007 11:30:20 PM]

Share this post


Link to post
Share on other sites
@pingt Ok, but how do I get a translation of vertices from this?? Is it simply the vector between center of gravity C to my current point P that gets multipled by the factor iven by GM/r?? Like

P' = P + (P-C)*GM/(P-C)

@Mastaba I implemented your idea. It looks nice as long as the center of mass is somehow far enough away from the surface. If it get closer, the bending "explodes" somehow...

Share this post


Link to post
Share on other sites
Right, that explosive behavior is a result of simply modeling the central force field of a point mass. If you want to model the force field of an extended body, you have to modify it a bit once your test point is inside the body, or else constrain your model.

Share this post


Link to post
Share on other sites
may I ask what you mean by "modify it a bit once your test point is inside the body"?? In which way modifying it? I'm sorry to ask such silly questions, but I don't know much about physics...

Or, to come back to pingt's approach, how are the vertices moved due to the gravity potential? If I'm right, the given equations give me a scalar. How do I get a displacement vector from that??

Cheers,
Data

Share this post


Link to post
Share on other sites
Gravity due to a spherical mass of constant density, is a central force field, so the force at any test point is directly away or towards the force center. Also again, the potential does not move the vertices of the rubber sheet. That is, if you took an über sized actual rubber sheet and put it near a star or planet, it would not simply deform in the manner you see in the picture. It would do something much more complex. The picture you see is representing in a highly artificial fashion how gravity bends a 2D spacelike cross section of spacetime, not how gravity would make actual matter deform. So if you are simply wanting to model a dimple in a rubber sheet, what you have been given is a good starting point. If you are trying to actually model general relativity's bending of spacetime then that's a far more complicated topic, and certainly overkill for any game.

Share this post


Link to post
Share on other sites
Quote:
Original post by data2
@pingt Ok, but how do I get a translation of vertices from this?? Is it simply the vector between center of gravity C to my current point P that gets multipled by the factor iven by GM/r?? Like

P' = P + (P-C)*GM/(P-C)


r here is your grid position in 2D undisturbed:
r=sqrt(x*x + y*y)

z of the grid is the potential:
z= -GM/r


Share this post


Link to post
Share on other sites
If you just want to use a normal curve instead, compute the distance of the point from the center of the dimple and compute the value of the normal curve at that point. The normal curve has nothing to do with the bending of space, but if all you're using it for is to make a dimple, it doesn't matter. You could also consider using the hyperbolic cosine function, which actually describes catenaries (the shape of a rope or chain hanging from two points), but I'm not sure how exactly that would apply to a sheet of rubber...you could also try physically modelling it with a mass-spring system.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this