The Naked Scientists

The Naked Scientists Forum

Author Topic: How do I build an accurate galaxy simulator?  (Read 6661 times)

Offline galaxysim

  • Jr. Member
  • **
  • Posts: 36
    • View Profile
How do I build an accurate galaxy simulator?
« on: 03/07/2013 17:31:37 »
Maths & Physics help wanted ref building a galaxy simulator

I have a very broad and fairly deep understanding of everything but i could do with some help to dot the i's and cross the T's

There appears to be a catalog of over simplification errors associated with galaxy rotation, dark matter etc Im on a mission to find out which if any of these issues is 'actually relevant' or if its my scientific instincts that are mostly in error....Hence my compulsion to code up a highly detailed galaxy simulator.

I have my own personal parallel super computer  ....and its about time i did something constructive with it, lol



First question


I need to sum the total gravity in the milky way....if my understanding is correct i also need to sum all the energy as well , not just the mass

yes/no/maybe ?

« Last Edit: 13/10/2013 11:22:12 by chris »


 

Offline Pmb

  • Neilep Level Member
  • ******
  • Posts: 1838
  • Physicist
    • View Profile
    • New England Science Constortium
Quote from: galaxysim
Maths & Physics help wanted ref building a galaxy simulator
Sure. How can I be of assistance?
Quote from: galaxysim
I need to sum the total gravity in the milky way....if my understanding is correct i also need to sum all the energy as well , not just the mass
yes/no/maybe ?
No. The contribution to the strength of the gravitational from energy contributions other than rest mass can be neglected. How else can I be of assistance?
 

Offline galaxysim

  • Jr. Member
  • **
  • Posts: 36
    • View Profile
Second question

Ball park figure for the energy contribution of gravity in the milky way ? ....rough % terms ???


Just so i have some idea of how much gravity ill be  ignoring.


Ill be keeping a rough tally of all effects/phenomena/force contributors that ill be ignoring. Hence my pedantry / double checking.
« Last Edit: 04/07/2013 01:29:24 by galaxysim »
 

Offline Pmb

  • Neilep Level Member
  • ******
  • Posts: 1838
  • Physicist
    • View Profile
    • New England Science Constortium
Second question

 
Ball park figure for the energy contribution of gravity in the milky way ? ....rough % terms ???

Just so i have some idea of how much gravity ill be  ignoring.


Ill be keeping a rough tally of all effects/phenomena/force contributors that ill be ignoring. Hence my pedantry / double checking.


I don't know. It's not that hard to calculate so you can figure it out for yourself. There's no reason for me to do the same work that you're able to do. It's good exercise for your brains muscles. :)  Just determine the kinetic energy of a star moving in the galaxay. Then compare it to the rest energy of the star. Do you know how to do that?
 

Offline galaxysim

  • Jr. Member
  • **
  • Posts: 36
    • View Profile
Im a bit rusty maths wise hence the ask....im guessing using E=MC'2

be cool if you could provide me with 1 example

AFAIK all the energy in all its forms contributes to gravity....i might be wrong on this but i think it includes rotation, movement, heat, binding energies ....even gravitational potential energy itself?



 

Offline Pmb

  • Neilep Level Member
  • ******
  • Posts: 1838
  • Physicist
    • View Profile
    • New England Science Constortium
Quote from: galaxysim
Im a bit rusty maths wise hence the ask....im guessing using E=MC'2

be cool if you could provide me with 1 example
I don't understand. This is a trivial math problem. How can you do such complicated computational physics with the computer and programing when don't know such simple math? I don't mean to be rude here. I'm just puzzled.

Choose a sample star to work with. Determine its distance from the center of the Galaxy. Determine its orbital period. Use the distance R and period T to calculate its speed v by v = (2*pi*R)/T. Now choose a sample mass of a star M. Now calculate the kinetic energy K = mv2/2. If M >> K/c2 then you can ignore the kinetic energy.
Quote from: galaxysim
AFAIK all the energy in all its forms contributes to gravity....
That's true. And momentum contributes as well. But its contribution is too small to make a difference. I can show you the strength of the gravitation field that is due to the motion if you'd like?
 

Offline galaxysim

  • Jr. Member
  • **
  • Posts: 36
    • View Profile
Im slowly wading through a long list of factors. What i need to code up, best method to code it up etc. I have a lot on the brain. Just double checking my facts as i go along. I appreciate your input.

ref But its contribution (energy effect gravity/mass ) is too small to make a difference.

Very small effects can still have noticeable consequences especially when those effects are felt continuously throughout the system and the experiment is left to run for billions of years....this long term contribution is one area i wish to consider.  I also appreciate that the value of rest mass of the milky way has a much larger upper and lower bound of uncertainty...and that the energy contribution can probably be ignored.

* the distribution of some of the gravitational force caused by energy, neutrinos and dust may well have an impact. Im referring to the fact that these forces are not point like as is the case with stars but are distributed throughout the galaxy....a minor contribution & effect im sure.  It would be interesting to see if adding or ignoring 101 minor factors does result in tangible changes.  I have a fairly hefty amount of computation at my disposal and i might be able to wring out some subtleties that have been previously ignored.



ref trivial math problem

Im sure it is, my concern is not doing trivial maths but investigating and simulating a complex system. Which will involve lots and lots of trivial maths interacting with each other....i know enough about maths to have faith in maths...it will take me a while to convince myself i have done the trivial maths correctly :-p, bit rusty, but that is no deterrent to me whatsoever....all the maths tools are out there, i just have to figure out which maths spanner cracks which  nut...thanks for the example.




Question 3


Gravity travels at the speed of light ?

yes/no/maybe/ possible issues with calculation

If so im curious as to how this effects the orbits, especially at galactic scales....any insight on this most welcome
« Last Edit: 04/07/2013 17:20:59 by galaxysim »
 

Offline Pmb

  • Neilep Level Member
  • ******
  • Posts: 1838
  • Physicist
    • View Profile
    • New England Science Constortium
Quote from: galaxysim
Im slowly wading through a long list of factors. What i need to code up, best method to code it up etc. I have a lot on the brain. Just double checking my facts as i go along. I appreciate your input.
Oh. I see. I had a feeling that might be the case.

Quote from: galaxysim
Very small effects can still have noticeable consequences especially when those effects are felt continuously throughout the system and the experiment is left to run for billions of years....this long term contribution is one area i wish to consider.
The small effects wonít be noticeable as it pertains to the orbital speed since that depends only on the field strength. The contribution to the field strength from kinetic energy can be determined rather easily and shown to not contribute very easily..

As far as the long-term manifestation of small contributions Ė Youíre referring to chaos. The problem here is that the error due to the inaccuracy in the data will overwhelm such variations.

Quote from: galaxysim
I also appreciate that the value of rest mass of the milky way has a much larger upper and lower bound of uncertainty...and that the energy contribution can probably be ignored.
Iím not sure that you understand something here. When youíre determining how much energy to take into account you have to keep in mind that itís all mass-energy.  When we talk about the contribution from mass then at the same time weíre talking about the contribution of the mass from rest mass. So when youíre calculating the contribution to the field strength due to the mass of a star then what youíre doing is talking about the rest energy contribution. The source of gravity in general relativity is the stress-energy-momentum (SEM) tensor. The time-time component is the energy density. The mass is contained in this component as energy density. So you canít really talk about these things as being different ďShould I take rest energy into account rather than just rest mass?Ē etc. is a question which tells me that youíre thinking of mass and energy as contributing in different ways. They donít. Rest  mass and rest  energy are the same thing and appear as the same thing in the SEM tensor.

Quote from: galaxysim
the distribution of some of the gravitational force caused by energy, neutrinos and dust may well have an impact.
Do the run with it and without it and youíll get identical answers if you program it correctly. Add the mass-energy of all the neutrinos that the sun puts out in one hour to the mass of the sun. Then calculate the orbital period of the earth Using that value and the value without the neutrino contribution. Youíll find that you canít input that result because the precision of the calculations is not that accurate nor is the data. Do you know what I mean by that?

Quote from: galaxysim
Gravity travels at the speed of light ?

yes/no/maybe/ possible issues with calculation
Yes. You donít need to take that into account since there are no effects that are propagating that you need to consider.

Quote from: galaxysim
If so im curious as to how this effects the orbits, especially at galactic scales....any insight on this most welcome
I have a paper on the active gravitational mass of a moving body. You should read it. It will tell you how to calculate the field strength of a moving body. How do I get this paper to you? Do you want to PM your e-mail address to you or do you want the reference and you can go to a science library and get it yourself?
 

Offline galaxysim

  • Jr. Member
  • **
  • Posts: 36
    • View Profile
thanks for the heads up on
http://en.wikipedia.org/wiki/Stress%E2%80%93energy_tensor [nofollow]

 

Offline galaxysim

  • Jr. Member
  • **
  • Posts: 36
    • View Profile
Quote from: galaxysim

    Gravity travels at the speed of light ?

    yes/no/maybe/ possible issues with calculation

Yes. You donít need to take that into account since there are no effects that are propagating that you need to consider.



really  ? Is there an article or video which explains why this is so. Explains how  i can ignore the fact that gravity travels at the speed of light....which is what i think you are saying.


To clarify  I was thinking of ray casting with gravitons, (as one method of calculating gravity ) and my instinct tells me that the speed of these virtual particles would be influential on outcomes.




Gravity exerted by a fast moving object versus stationary object?
http://www.physicsforums.com/showthread.php?t=687833 [nofollow]

Im not the first person to ask, nor be confused by the answers, lol

I also had a quick read of this...its a bit old so im not so sure of its validity given my current level of comprehension
http://home.comcast.net/~peter.m.brown/ref/mass_articles/Olson_Guarino_1985.pdf [nofollow]



ref I have a paper on the active gravitational mass of a moving body. You should read it.

Q Is there a web link to your paper ?


Ps, i am taking it all on board, your efforts not wasted

I can if needs be run small test simulations accurate to a million decimal places....just for fun...one can pick up even minor effects at this level of accuracy...but this is a side show to my main quest

This is so wrong  :o  Richard Feynamn "if it disagrees with experiment its wrong"
http://astro.unl.edu/classaction/animations/milkyway/milkywayrotationalvelocity.html [nofollow]
« Last Edit: 04/07/2013 18:29:30 by galaxysim »
 

Offline Pmb

  • Neilep Level Member
  • ******
  • Posts: 1838
  • Physicist
    • View Profile
    • New England Science Constortium
Re: Maths & Physics help wanted ref building a galaxy simulator
« Reply #10 on: 04/07/2013 18:31:12 »
Quote from: galaxysim
really  ? Is there an article or video which explains why this is so. Explains how  i can ignore the fact that gravity travels at the speed of light....which is what i think you are saying.
No. No article or video. But then again you have me! :)    After all, that is why I'm here and why you're asking me. But I'll explain later when the pain in my neck subsides.
Quote from: galaxysim
To clarify  I was thinking of ray casting with gravitons, (as one method of calculating gravity ) and my instinct tells me that the speed of these virtual particles would be influential on outcomes.
Virtual? Where did you get the notion that they're virtual particles? I'm not saying that they aren't. I'm simply curious as to why you think that they are. In any case those are used in a quantum theory of gravity and right now we're talking about a classical theory of gravity, i.e. general relativity. Why use quantum gravity?
Quote from: galaxysim
I also had a quick read of this...its a bit old so im not so sure of its validity given my current level of comprehension
http://home.comcast.net/~peter.m.brown/ref/mass_articles/Olson_Guarino_1985.pdf
That's the article I was referring to. I forgot that I placed it on my website. Yes, it's valid. Don't get the idea that just because an article is old that it's not correct. If an article ussa theory known to be accurate within the area of applicability that it addresses then assume its valid. After all it's published in the American Journal of Physics which is a highly respected journal.
Quote from: galaxysim
Ps, i am taking it all on board, your efforts not wasted
Thanks for that note. I'm glad to hear that.  I enjoy helping people like this so the pleasure is also mine, sir! :)
 

Offline galaxysim

  • Jr. Member
  • **
  • Posts: 36
    • View Profile
Re: Maths & Physics help wanted ref building a galaxy simulator
« Reply #11 on: 04/07/2013 18:33:43 »
ref Yes, it's valid.

well you sound convincing to me so far...ill run with that for now, thanks

I love this guy

Great interview. He unintentionally makes Hoyle look like a dork, lol

Please excuse my caution, even very bright people can espouse erroneous concepts. Hence my desire to cross reference and double/triple check as i advance slowly to the front line of human knowledge. When standing on the shoulders of giants the floor is a long way down, one must climb with caution if the pyramid is not of your own construction.

It is my intention to understand this graph, and perhaps with due diligence alter its shape to fit reality a tad better
http://astro.unl.edu/classaction/animations/milkyway/milkywayrotationalvelocity.html [nofollow]

It stands before us as an inconvenient truth
« Last Edit: 04/07/2013 18:44:43 by galaxysim »
 

Offline Pmb

  • Neilep Level Member
  • ******
  • Posts: 1838
  • Physicist
    • View Profile
    • New England Science Constortium
Re: Maths & Physics help wanted ref building a galaxy simulator
« Reply #12 on: 04/07/2013 18:53:11 »
Quote from: galaxysim
It i my intention to understand this graph, and perhaps with due diligence alter its shape to fit reality a tad better
http://astro.unl.edu/classaction/animations/milkyway/milkywayrotationalvelocity.html
I don't mind. In fact I appreciate it when people are careful. I've seen many people in discussion forums who act like they're knowledgeable and screw up a bunch of stuff. Even very simple stuff. There was kid (I call him a kid because he bahaved like a little bratty child) who kept claiming that nobody uses relativistic mass anymore. He was quite wrong. In fact I was amazed at just how wrong he was and the people he used to back up his claim were. It benefited me greatly because it got me to learn a subject that I would have otherwise dismissed as being trivially simple. When it comes to artilces in journals you don't have to worry about them that much. They'r not only written by physicists who know a great deal about what they're talking about but they are reviewed by several other physicists and the editor. Given that how would you expect to learn if the article is right or wrong?

You might find these of interest
http://home.comcast.net/~peter.m.brown/gr/weight_moving_body.htm
http://home.comcast.net/~peter.m.brown/gr/grav_moving_rod.htm
http://home.comcast.net/~peter.m.brown/gr/grav_moving_sheet.htm

I worked out all those problems just to make sure that I knew that the gravitational field of a moving body is a function of speed. The kid I mentioned above kept claiming that nobody used rel-mass. I worked out these problems to demonstrate that the properties that we associate with mass are all functions of speed and as such it's quite useful to think of mass as a function of speed. That kid's arguments got worse and worse. Eventually he ended up claiming that everything was meaningless. It was then that I realized that the problem all along was that he was unable to admit that he made a mistake.
 

Offline galaxysim

  • Jr. Member
  • **
  • Posts: 36
    • View Profile
Re: Maths & Physics help wanted ref building a galaxy simulator
« Reply #13 on: 04/07/2013 19:18:09 »
so true, if there is a discrepancy between my beliefs and mainstream science i default to ' i must be the one whose wrong '

and guess what, 99,99% of the time im right about that

I tend not to dig too deep, i enjoy the broader view of life the universe and everything, but every now and then i will burrow down and do a little first hand checking myself.

Ive already forgotten more than most people will ever know...there are wonders a plenty in the realm of reality.  Sci fi is great for ideas and what ifs....but its an intellectual crime to confuse the two...in fact those who do miss out.

...i got some brushing up to do on the details with all this galactic rotation / dark matter stuff

ill get there in the end



I enjoy taking the known science and seeing what it allows us to do....a string of oort cloud comets as a colony ship....a vast bank of orbital lasers clearing a path through the atmosphere as part of a teleport device, burnt on arrival perhaps, lol, but true to known science. My real world teleport system is still in need of some work !

slightly off topic

I envisage colliding comets and using the thermal energy to power manufacturing plants.  A big comet with a tunnel to its core catching little ones like a baseball glove and closing the lid, thus entrapping most of the thermal energy. Far from the sun energy is precious. Tiny thrusters line up titanic collisions which perhaps take many decades to come to fruition. Thus the EROEI is high but the penalty is the time it takes.

This may well be the actual mechanism by which we build interstellar colony ships....where ever we go we must go with sufficient strength. Turning up at Mars 2.0 some 20 light years from earth in a gleamy white space shuttle doth not a self sustaining colony make.

If we can live in the near darkness of the outer solar system and sustain ourselves in that manner then we can live anywhere there is sufficient potential gravitational energy and kinetic energy for us to harness. The road to planet fall a long and winding one.

« Last Edit: 04/07/2013 19:33:48 by galaxysim »
 

Offline galaxysim

  • Jr. Member
  • **
  • Posts: 36
    • View Profile
Re: Maths & Physics help wanted ref building a galaxy simulator
« Reply #14 on: 04/07/2013 19:57:20 »
All this dark matter whatever that's messing up the galactic rotation speeds is interfering with my plans to conquer the galaxy....I want to make sure that 10,000 or ten million years from now my ' dummies guide to conquering the universe' is still in print. A 1:1 simple functional model and map of the milky way is now buildable thanks to advances in computation.

A time machine may be beyond me, but the ability to predict the future and thus play a lead role is the next best prize to being there. This particular CHON assembly may not be there to take part in the proceedings, but if i get the road map right there will be a solid gold statue of me on every world we settle....that's my cunning plan anyway :-p


Luhman 16 here we come, and we maybe be hitching a ride on the real planet X and arriving in a real flying saucer ! with a Dalek at the helm ....that's what the science is telling me...does reality get any better than that ?






« Last Edit: 04/07/2013 20:10:23 by galaxysim »
 

Offline Pmb

  • Neilep Level Member
  • ******
  • Posts: 1838
  • Physicist
    • View Profile
    • New England Science Constortium
Re: Maths & Physics help wanted ref building a galaxy simulator
« Reply #15 on: 05/07/2013 01:06:12 »
What you want to read is Gravity from the Ground Up by Bernard Schutz, Cambridge University Press (2003). It has everything from active gravitational mass to relativistic mass to gravitomagnetism. You really should pick this book up and read it from cover to cover and go through it with a fine toothed comb. I know I am.

See - http://www.gravityfromthegroundup.org/
 

Offline galaxysim

  • Jr. Member
  • **
  • Posts: 36
    • View Profile
Re: Maths & Physics help wanted ref building a galaxy simulator
« Reply #16 on: 05/07/2013 11:31:53 »
I need something for sure.

Its finding the right model of gravity to work with, gravity gets tricky when you go past the decimal point.

That graph showing galactic rotation speeds etc is asking a lot of questions of us.


Dark Matter and Galaxy Rotation  ( basic explanation with the maths )



« Last Edit: 05/07/2013 11:37:27 by galaxysim »
 

Offline galaxysim

  • Jr. Member
  • **
  • Posts: 36
    • View Profile
Re: Maths & Physics help wanted ref building a galaxy simulator
« Reply #17 on: 05/07/2013 11:53:27 »
Potential Measurement bias

The Doppler shift  is good for stuff like stars that are moving directly away or towards us, less so for tracking complex or elliptical orbits which may take millions of years to complete. Which is in reality how all the stars are moving around.

If all you can do is take a snapshot or two of an object moving in an elliptical  orbit the accuracies plummet when its moving along the slow part.


The measurements of stars in our galaxy are also up to 120,000 years out of date. I wonder what measurement bias that has.
https://en.wikipedia.org/wiki/Milky_Way [nofollow]

« Last Edit: 05/07/2013 11:59:37 by galaxysim »
 

Offline galaxysim

  • Jr. Member
  • **
  • Posts: 36
    • View Profile
Re: Maths & Physics help wanted ref building a galaxy simulator
« Reply #18 on: 05/07/2013 12:57:19 »
My Dark Jello Hypothesis This would have some interesting effects.

Its repelled by ordinary matter (or just itself ) but is effected by and contributes to gravity

Imagine a galaxy forming, a bit like a sponge being squeezed....the Dark jello works its way to the surface of the sponge in a similar fashion to water.

You would certainly get and maintain some interesting mass distributions....as well as some interesting effects that occur during the various stages of the universe forming and galactic evolution.

Einasto profile
http://en.wikipedia.org/wiki/Einasto_profile [nofollow]

Dark matter halo
http://en.wikipedia.org/wiki/Dark_matter_halo#Milky_Way_dark_matter_halo [nofollow]


Michio Kaku: What Is Dark Matter?



 


« Last Edit: 05/07/2013 13:24:57 by galaxysim »
 

Offline Pmb

  • Neilep Level Member
  • ******
  • Posts: 1838
  • Physicist
    • View Profile
    • New England Science Constortium
Re: Maths & Physics help wanted ref building a galaxy simulator
« Reply #19 on: 13/10/2013 09:07:01 »
Does anyone here have experience with these kinds of numerical computations? I'm curious as to how the required computational power increases with the number of stars being taken into account. I'm also interested in the memory requirements required to do such calulations.
 

Offline CliffordK

  • Neilep Level Member
  • ******
  • Posts: 6321
  • Thanked: 3 times
  • Site Moderator
    • View Profile
Re: Maths & Physics help wanted ref building a galaxy simulator
« Reply #20 on: 13/10/2013 10:24:33 »
I did a very simplified galaxy gravity simulation a while ago.

Calculation of gravitational interactions is essentially the gravity between every body with every other one.

10 bodies would take calculations the order of:
10 + 9 + 8 + 7 +...+2+1 interactions.  This is a basic Gauss sum with the total: n*(n+1)/2

So your basic gravity calculations will be on the order of n2.

Do you also have to interpolate motions over time?  Then you would need to choose a granularity of time to do the calculations.

Do you also need to calculate velocity, mass, and direction of each star? 
 

Offline Pmb

  • Neilep Level Member
  • ******
  • Posts: 1838
  • Physicist
    • View Profile
    • New England Science Constortium
Re: Maths & Physics help wanted ref building a galaxy simulator
« Reply #21 on: 13/10/2013 10:35:14 »
It's not for me but for the OP.

Solving the equations requires initial conditions. That means providing the intial position and velocity of each star plus its mass. I was explaining to the OP that this simply cannot be done for a real galaxy since the computational power and memory requirements are unrealistic.
 

Offline evan_au

  • Neilep Level Member
  • ******
  • Posts: 4113
  • Thanked: 245 times
    • View Profile
Re: Maths & Physics help wanted ref building a galaxy simulator
« Reply #22 on: 13/10/2013 11:59:18 »
Quote
help wanted ref building a galaxy simulator

To help scope it out, what type of simulation do you want to perform? eg:
  • How many galaxies (eg 1 or 100)?
  • The Milky Way or other galaxies (eg Andromeda)?
  • A static cross-section model of the galaxy?
  • A static 3D model of a whole galaxy?
  • A dynamic 3D model of a whole galaxy?
  • How long do you want to run the simulation (eg 1 rotation, or a dozen rotations)?
  • Can you afford to ignore local effects like stellar lifecycles?
  • Can you afford to ignore more global effects like satellite galaxies and other galaxies in the galaxy cluster?
  • How many different distributions of Dark Matter do you want to try? 

Suggestion: Start with item 3, a static cross-section of a single galaxy, which is probably the simplest that would illustrate the effects of dark matter, modeled on a cross-section of a nearby, well-studied galaxy like Andromeda. Ignore galaxy rotation, stellar lifecycles, and nearby galaxies, and focus on the real question: Dark Matter.

To see how another team tackled a related simulation (modeling the entire universe since the Big Bang), see: http://omegataupodcast.net/2010/04/31-the-millennium-simulation/
Spoiler Alert: The universe looks quite different if you don't include Dark Matter in the model.

In more detail:
  • How many galaxies (eg 1 or 100)? Obviously, the more galaxies modeled, the longer it will take. Start with 1.
  • The Milky Way or other galaxies (eg Andromeda)? The structure of our Milky Way galaxy is obscured by dust clouds, and it is not easy to measure the rotational velocity of the stars, since we are embedded in the disk. Astronomers are making progress in working out the structure of the Milky Way by charting the location of molecules like carbon monoxide, but it is still a bit of a guess, especially behind the galactic bulge. It is probably easier to use a nearby galaxy like Andromeda as a basis for comparison, where we can clearly see the entire structure, and measure the rotational velocity of the galaxy at different points across its radius. Elliptical galaxies are probably harder than "fried egg" galaxies like Andomeda, since it is harder to peer inside and see the radial distribution of stellar velocities.
  • A static cross-section model of a galaxy: This takes all the stars in a narrow strip (eg 1 light-year across) which is the full diameter and thickness of the galaxy, with their initial velocities, plus the supposed distribution of dark matter, and from the gravitational field of all these, calculates the orbital period of all the stars using Kepler's laws. You can experiment with different densities of dark matter. This can then be compared with the measured distribution of orbital velocity vs radius as seen in nearby galaxies. This is probably the minimal model that could examine the effects of dark matter.
  • A static 3D model of a whole galaxy? This takes all the stars in the entire the galaxy, with their initial velocities, plus the supposed distribution of dark matter, and from the gravitational field of all these, calculates the orbital period of all these. You can experiment with different densities of dark matter. This has far more stars and requires more memory and processing power.
  • A dynamic 3D model of a whole galaxy?  This takes all the stars in the entire the galaxy, with their initial velocities, plus the supposed distribution of dark matter, and simulates the motion of all of the stars and Dark Matter over time, using Newton's laws. This requires immensely more processing power and calculation time.
  • How long do you want to run the simulation (eg 1 rotation, or a dozen rotations)? The longer the simulation runs, the more processing time. Probably the accuracy will not improve much when you get beyond 2 revolutions of the galaxy (bearing in mind that it does not rotate as a solid object!).
  • Can you afford to ignore local effects like stellar lifecycles? On larger distance scales, the gravitational effect of a star is similar, regardless of whether it is a gas cloud, a glowing star, a a white dwarf, a neutron star or a black hole. You can just distribute "particles" with some density over a volume of space. I recommend that an initial model ignores the stellar lifecycle.
  • Can you afford to ignore more global effects like satellite galaxies and other galaxies in the galaxy cluster? The structure of a galaxy is distorted by other galaxies it has previously swallowed, and collisions with other galaxies over time. I recommend that an initial model just treats a single isolated galaxy.
  • How many different distributions of Dark Matter do you want to try?  There are various theories about Hot & Cold Dark Matter, which will have different radial distributions.

Computation Model
Galaxy Model State: The computation represents the state of a galaxy by the mass, location (3 dimensions) and velocity (3 dimensions) of the mass which makes up the galaxy. You will want to model the galactic central black hole, plus stars, dark matter, and other items that may be of interest such as neutral gas/dust clouds and neutrinos.

We are now finding that there are probably as many planets Jupiter-size or larger in the galaxy as there are stars. However, you don't need to model all of these - just put in a representative sample of "particles" representing the mass of stars & planets in that volume of space, plus other particles representing the amount of dark matter in that volume of space.

Initial Population: Generate a random initial distribution of these particles, with a representative distribution of mass, density and velocities. Base the distribution of stars and gas on a real galaxy, like Andromeda.

Relativistic Effects: I have suggested using Kepler's or Newton's laws to simplify processing. Einstein's relativistic effects are more complex to calculate; they are important in the immediate neighborhood of the galactic black hole, but I don't expect it will make much difference on the scale of a whole galaxy. Start with classical physics.

Processing Complexities: In a dynamic model, you need to model the motion of all the stars. Most of the galaxy is empty space, so stars interact loosely and infrequently; this can be modeled by taking large time steps. However, in the galactic bulge, stars are densely packed, and interact frequently; to simulate this accurately, small time steps must be taken. To keep the galaxy rotation synchronised, processing time must be dynamically allocated to those regions undergoing close stellar interactions. This is entirely avoided by using a static model.

Numerical Algorithms: It is important to use stable numerical algorithms; the intuitive straight-line approximation to simulating motion under gravity cannot stably model a single planet orbiting its star, let alone a solar system or a galaxy. It is also necessary to select an algorithm which can take variable time steps: small for closely interacting "particles", and larger for low-density regions.

Multiprocessor allocation: These types of dynamic simulations are typically run on multiprocessors. The problem must be partitioned across the processors in such a way that the communications between processors take less time than the computation itself. As CliffordK mentioned, if you tried to model every stellar interaction, you have an n2 problem. However, due to the inverse square law, stars interact most strongly with other nearby stars, so there is an advantage in assigning a volume of space to one processor. The detailed distribution of mass within a volume of space affects adjacent volumes strongly, but has a more general impact on more distant volumes. Therefore it is sufficient to summarise the entire contents of a volume of space by a point mass, as far as distant volumes are concerned.

Good luck with your dreams of galactic conquest!
 

Offline Phractality

  • Hero Member
  • *****
  • Posts: 523
  • Thanked: 1 times
    • View Profile
Re: How do I build an accurate galaxy simulator?
« Reply #23 on: 13/10/2013 18:01:06 »
There are several galaxy simulation projects already under weigh. I'm sure some of them would welcome you into their group or share expertise with you. Some of them are investigating electro-magnetic forces between galaxies due to a small net electric charge rotating with the galaxies.
There are several galaxy simulators available to download, free or not. If you can get the source code, you can tweak the models to match your understanding.
Not standard physics, but I suspect you might find a correlation between galaxy spin and motion of the galaxy relative to the CMB. This would be attributable to a speed-of-gravity which is finite but much faster than light.
 

Offline Pmb

  • Neilep Level Member
  • ******
  • Posts: 1838
  • Physicist
    • View Profile
    • New England Science Constortium
Re: How do I build an accurate galaxy simulator?
« Reply #24 on: 13/10/2013 22:47:23 »
There are several galaxy simulation projects already under weigh. I'm sure some of them would welcome you into their group or share expertise with you. Some of them are investigating electro-magnetic forces between galaxies due to a small net electric charge rotating with the galaxies.
There are several galaxy simulators available to download, free or not. If you can get the source code, you can tweak the models to match your understanding.
Not standard physics, but I suspect you might find a correlation between galaxy spin and motion of the galaxy relative to the CMB. This would be attributable to a speed-of-gravity which is finite but much faster than light.
If you read the entire thread from the first post you'd see that the OP wants to write a simulator which calculates the trajectory of every single star in the galaxy. This is impossible for all practical purposes. I tried to explain to him/her why its impossible but failed to do so. I'm curious as to where he went with this.
 

The Naked Scientists Forum

Re: How do I build an accurate galaxy simulator?
« Reply #24 on: 13/10/2013 22:47:23 »

 

SMF 2.0.10 | SMF © 2015, Simple Machines
SMFAds for Free Forums