Class PrimitiveGalaxySimulator

java.lang.Object
org.episteme.natural.ui.viewers.physics.astronomy.PrimitiveGalaxySimulator
All Implemented Interfaces:
GalaxySimulator

public class PrimitiveGalaxySimulator extends Object implements GalaxySimulator
Primitive Matrix/Array-less implementation. Operates directly on StarParticle POJOs using double math. *

Reference:
Prim, R. C. (1957). Shortest connection networks and some generalizations. Bell System Technical Journal, 36(6), 1389-1401.

Since:
1.0
Author:
Silvere Martin-Michiellot, Gemini AI (Google DeepMind)
  • Constructor Details

    • PrimitiveGalaxySimulator

      public PrimitiveGalaxySimulator()
  • Method Details

    • init

      public void init(List<StarParticle> stars)
      Description copied from interface: GalaxySimulator
      Initialize the simulator with the star field.
      Specified by:
      init in interface GalaxySimulator
    • setGalaxy2State

      public void setGalaxy2State(double x, double y, double vx, double vy)
      Description copied from interface: GalaxySimulator
      Updates the state of the second galaxy core.
      Specified by:
      setGalaxy2State in interface GalaxySimulator
    • getG2X

      public double getG2X()
    • getG2Y

      public double getG2Y()
    • update

      public void update(boolean collisionMode, double unusedX, double unusedY)
      Description copied from interface: GalaxySimulator
      Update the simulation by one step.
      Specified by:
      update in interface GalaxySimulator
    • getName

      public String getName()
      Specified by:
      getName in interface GalaxySimulator