Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7929347
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T20:02:33+00:00 2026-06-03T20:02:33+00:00

So I am working on a simulation of the solar system and ran into

  • 0

So I am working on a simulation of the solar system and ran into a roadblock…

In reality, the speed of the moon compared to the earth is much slower then that of the earth compared to the sun. However, the moon completes its orbit much quicker because it has to travel much less distance. The moon orbits the earth about 13 times in 1 year.

In my simulation however, the moon gets maybe 2 orbits in a year…

I’ve checked the speed with wikipedia and they are correct.

The only difference is that I scale everything, making me suspect that that’s the cause.

All distances are devided by 100 000 and all speeds are devided by 1000

    this.angle += (speed * deltatime);

    this.x = this.semi_major_axis * Math.cos(this.angle) + this.parent.x + this.focalX;
    this.y = this.semi_minor_axis * Math.sin(this.angle) + this.parent.y + this.focalY;

Speed is the speed according to Wikipedia. (29.78 km/s for earth and 1.022 km/s for the moon)

Parent in this case means the object it is orbiting (in case of the earth, it’s the sun. In case of the moon, it’s the Earth)

focalX and focalY are the offset from the planet.

Speed and the 2 axis values are already scaled at this point.

Am I wrong in the manner of the scale? Am I completely missing something obvious? Am I just doing it completely the wrong way?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-03T20:02:35+00:00Added an answer on June 3, 2026 at 8:02 pm

    Since speed is distance/time (eg kilometres/second) when you scale speed by 1000 and distance by 100000 you have, whether you know it or not, scaled time by 100. Are you sure that you have taken this into account in the rest of your calculations ?

    And yes, you are approaching this entirely the wrong way. If you were building a mechanical simulator you would want to scale distances quite early in the process, but in a numerical simulator why scale them at all ? Just work in the original units.

    Since you don’t have a computer screen which is several AU (astronomical units) across, you might have to scale the numbers for imaging but most graphics systems will do that for you at some point in the pipeline.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm working on a evolutionary simulation model implemented in Java and ran into a
I'm working on a simulation system written in C++ that is managed by git.
I am working on a simulation system. I will soon have experimental data (histograms)
I am working on feeding Matlab's simulation data to Google Earth Plug-in via COM.
I'm working in a simulation environment called AnyLogic and it uses Java as its
I have a large simulation written in C++. The main working unit for the
i'm trying to make some sort of Business Simulation Game and everything is working
Situation: We are working on a project that reads datafeeds into the database at
I'm working on a simulation in Qt (C++), and would like to make use
I am writing a simulation Memory Manger and I was working with Jtables to

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.