Two things: How do advanced physics values work? How do you get physical distance?

Welcome to our brand new Clickteam Community Hub! We hope you will enjoy using the new features, which we will be further expanding in the coming months.

A few features including Passport are unavailable initially whilst we monitor stability of the new platform, we hope to bring these online very soon. Small issues will crop up following the import from our old system, including some message formatting, translation accuracy and other things.

Thank you for your patience whilst we've worked on this and we look forward to more exciting community developments soon!

Clickteam.
  • I have two questions, but they're both related to solving the same problem, so I thought to put them both in one thread.

    Context:

    I'm creating a planetary gravity simulation where the user places down virtual planets, sets their mass, initial velocity, and initial angle, then presses play and watches the planets interact via virtual gravity. During the simulation, the user can click on a planet to view its current velocity, acceleration, the force acting upon it, and the angles of the velocity and force. The problem is that in order to make the planets move faster than snails, I set the forces to be 1000x stronger than they would be in the real world. As you might expect, this is causing issues with the variable viewer, because I want the variables shown to be accurate to the real world, but I also want the visual simulation to be engaging. Also, since the visual simulation is just a representation what's going on, it doesn't necessarily have to be totally physically accurate, unlike the displayed values.

    Alright, let me get to my point. I think part of the problem is that I'm calculating distances using each planet's x and y coordinates (and the Pythagorean Theorem), as well as the physical mass of the planets, thus having a mixture of physical and non-physical values. This is where the two questions come in.

    First question: Can someone explain how Display Factor, Velocity Iterations, and Position Iterations work?

    From the description, the display factor seems to be related to converting between actual distance and physical distance. From testing, I know that increasing the display factor proportionately increases things like force and physical velocity. If I had a better understanding about how it worked, I think I would be able to have the displayed values be accurate, and have the visual simulation be proportionally accurate (for example, have the displayed velocity be scientifically accurate, but have the planets moving twice as fast as they would be, as if it were being fast-forwarded). I'm also unsure as to what the velocity and position iterations do, but maybe they're the key to all this. I don't know.

    Second question: Is there a way to find physical distance?

    You know how in the expression editor, physical mass is written as PMass( "Object" ) and physical velocity is written as PVelocity( "Object")? Is there some way of finding physical distance? Something like PDistance( "Object 1" , "Object 2" )?

    Finally, while writing this, I realized that it might be caused by my planets not being very massive by planet standards, which would explain why when I make my calculations 100% accurate, the force between the planets is so small. Regardless, I've decided to ask the two questions because the information might be useful in the future, be it for me or someone searching past threads for answers.

    Thanks in advance for your help.

  • Under the "Special" Tab there is a function called "Distance Between Two Points", you can use this to find the distance between two objects.

    Fusion Veteran Since 2005. Example Projects: Please login to see this link.

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!