Package cnuphys.swim

Class Swimming

java.lang.Object
cnuphys.swim.Swimming

public class Swimming extends Object
  • Constructor Details

    • Swimming

      public Swimming()
  • Method Details

    • setNotifyOn

      public static void setNotifyOn(boolean notifyOn)
      Set whether we notify listeners. Might turn off temporarily to avoid multiple notifications.
      Parameters:
      notifyOn - the flag.
    • clearMCTrajectories

      public static void clearMCTrajectories()
      Clear all the mc trajectories.
    • clearReconTrajectories

      public static void clearReconTrajectories()
      Clear all the recon trajectories.
    • clearAuxTrajectories

      public static void clearAuxTrajectories()
      Clear all the aux trajectories.
    • clearAllTrajectories

      public static void clearAllTrajectories()
      Clear all trajectories
    • getMCTrajectories

      public static ArrayList<SwimTrajectory> getMCTrajectories()
      Get all the cached mc trajectories
      Returns:
      all the cached mc trajectories
    • getReconTrajectories

      public static ArrayList<SwimTrajectory> getReconTrajectories()
      Get all the cached recon trajectories
      Returns:
      all the cached recon trajectories
    • getAuxTrajectories

      public static ArrayList<SwimTrajectory> getAuxTrajectories()
      Get all the cached aux trajectories
      Returns:
      all the cached aux trajectories
    • addMCTrajectory

      public static void addMCTrajectory(SwimTrajectory traj)
      Add a trajectory to the mc collection
      Parameters:
      traj - the trajectory to add.
    • addReconTrajectory

      public static void addReconTrajectory(SwimTrajectory traj)
      Add a trajectory to the recon collection
      Parameters:
      traj - the trajectory to add.
    • removeMCTrajectory

      public static void removeMCTrajectory(SwimTrajectory traj)
      Remove a trajectory from the mc collection
      Parameters:
      traj - the trajectory to remove.
    • removeReconTrajectory

      public static void removeReconTrajectory(SwimTrajectory traj)
      Remove a trajectory from the recon collection
      Parameters:
      traj - the trajectory to remove.
    • removeAuxTrajectory

      public static void removeAuxTrajectory(SwimTrajectory traj)
      Remove a trajectory from the aux collection
      Parameters:
      traj - the trajectory to remove.
    • notifyListeners

      public static void notifyListeners()
    • addSwimTrajectoryListener

      public static void addSwimTrajectoryListener(SwimTrajectoryListener SwimTrajectoryListener)
      Add a magnetic field change listener
      Parameters:
      SwimTrajectoryListener - the listener to add
    • removeSwimTrajectoryListener

      public static void removeSwimTrajectoryListener(SwimTrajectoryListener SwimTrajectoryListener)
      Remove a SwimTrajectoryListener.
      Parameters:
      SwimTrajectoryListener - the SwimTrajectoryListener to remove.
    • printSummary

      public static void printSummary(String message, int nstep, double momentum, double[] y, double[] hdata)
    • testSwim

      public static SwimTrajectory testSwim(int opt)
    • main

      public static void main(String[] arg)