Package jsim.core
Class SimConstants
java.lang.Object
jsim.core.SimConstants
Simulation-wide constants. All values are SI (metres, kilograms, seconds).
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final doubleBaumgarte positional correction factor.static final doubleDefault fixed timestep in seconds (20 ms = 50 Hz, matching FRC robot loop).static final intImpulse solver iteration count per tick.static final doubleDefault gravity vector X component (m/s²); zero for FRC field convention.static final doubleDefault gravity vector Y component (m/s²); zero for FRC field convention.static final doubleDefault gravity vector Z component (m/s²); negative Z = downward, FRC field convention.static final doubleMinimum penetration before positional correction is applied (slop).static final doubleRelative velocity below this is treated as resting contact (no restitution). -
Method Summary
-
Field Details
-
DEFAULT_DT
public static final double DEFAULT_DTDefault fixed timestep in seconds (20 ms = 50 Hz, matching FRC robot loop).- See Also:
-
GRAVITY_X
public static final double GRAVITY_XDefault gravity vector X component (m/s²); zero for FRC field convention.- See Also:
-
GRAVITY_Y
public static final double GRAVITY_YDefault gravity vector Y component (m/s²); zero for FRC field convention.- See Also:
-
GRAVITY_Z
public static final double GRAVITY_ZDefault gravity vector Z component (m/s²); negative Z = downward, FRC field convention.- See Also:
-
DEFAULT_SOLVER_ITERATIONS
public static final int DEFAULT_SOLVER_ITERATIONSImpulse solver iteration count per tick. Higher = more accurate but slower.- See Also:
-
BAUMGARTE_BETA
public static final double BAUMGARTE_BETABaumgarte positional correction factor. Fraction of penetration depth corrected per tick.- See Also:
-
PENETRATION_SLOP
public static final double PENETRATION_SLOPMinimum penetration before positional correction is applied (slop).- See Also:
-
RESTITUTION_VELOCITY_THRESHOLD
public static final double RESTITUTION_VELOCITY_THRESHOLDRelative velocity below this is treated as resting contact (no restitution).- See Also:
-