What Causes the Sun's Unusual Orbital Path in a Java Solar System Model?

Join the discussion
Registration is free. Start your own thread to ask a follow-up.
1 reply · 2K views · last reply
whatisreality
Messages
286
Reaction score
1
I've written a java program to model the solar system. All my planets move in very well defined, stable orbits. The sun, on the other hand, is doing some very weird stuff. I've attached a plot of its path, a very zoomed in and a very zoomed out one. It isn't spiralling gradually inwards or outwards, as far as I can tell it's going in weird, wobbly loops. How do I explain that?! Especially as the rest of the planets work so well??

In my model, all bodies are point masses and have circular orbits, and they orbit around their common centre of mass.
 
Attachments
  • Scatter plot of a dense cluster of overlapping black dots forming looping, wobbly curves, with X axis from about 170,000 to 190,000 and Y axis from about -40,000 to 40,000.
    sun orbit3.jpg
    42.8 KB · Views: 522
  • Scatter plot of a large filled black annulus centred at the origin, with a white circular hole at the centre; axes run from -800,000 to 800,000 with the title 'Title' and axis titles 'X Axis Title' and 'Y Axis Title'.
    sun orbit.jpg
    29.5 KB · Views: 495
Astronomy news on Phys.org