C# Class Trajectories.VesselAerodynamicModel

Afficher le fichier Open project: neuoy/KSPTrajectories Class Usage Examples

Protected Properties

Свойство Type Description
body_ CelestialBody
cachedForces AeroForceCache
vessel_ Vessel

Méthodes publiques

Méthode Description
ComputeForces ( double altitude, UnityEngine.Vector3d airVelocity, UnityEngine.Vector3d vup, double angleOfAttack ) : UnityEngine.Vector3d

Compute the aerodynamic forces that would be applied to the vessel if it was in the specified situation (air velocity, altitude and angle of attack).

GetForces ( CelestialBody body, UnityEngine.Vector3d bodySpacePosition, UnityEngine.Vector3d airVelocity, double angleOfAttack ) : UnityEngine.Vector3d

Returns the total aerodynamic forces that would be applied on the vessel if it was at bodySpacePosition with bodySpaceVelocity relatively to the specified celestial body This method makes use of the cache if available, otherwise it will call ComputeForces.

IncrementalUpdate ( ) : void
Invalidate ( ) : void
PackForces ( UnityEngine.Vector3d forces, double altitudeAboveSea, double velocity ) : Vector2

Aerodynamic forces are roughly proportional to rho and squared air velocity, so we divide by these values to get something that can be linearly interpolated (the reverse operation is then applied after interpolation) This operation is optional but should slightly increase the cache accuracy

UnpackForces ( Vector2 packedForces, double altitudeAboveSea, double velocity ) : UnityEngine.Vector3d

See PackForces

VesselAerodynamicModel ( Vessel vessel, CelestialBody body ) : System
isValidFor ( Vessel vessel, CelestialBody body ) : bool

Méthodes protégées

Méthode Description
ComputeForces_Model ( UnityEngine.Vector3d airVelocity, double altitude ) : UnityEngine.Vector3d

Computes the aerodynamic forces that would be applied to the vessel if it was in the specified situation (air velocity and altitude). The vessel is assumed to be in its current orientation (the air velocity is already adjusted as needed).

Private Methods

Méthode Description
ComputeReferenceDrag ( ) : double
InitCache ( ) : void
updateVesselInfo ( ) : void

Method Details

ComputeForces() public méthode

Compute the aerodynamic forces that would be applied to the vessel if it was in the specified situation (air velocity, altitude and angle of attack).
public ComputeForces ( double altitude, UnityEngine.Vector3d airVelocity, UnityEngine.Vector3d vup, double angleOfAttack ) : UnityEngine.Vector3d
altitude double
airVelocity UnityEngine.Vector3d
vup UnityEngine.Vector3d
angleOfAttack double
Résultat UnityEngine.Vector3d

ComputeForces_Model() protected abstract méthode

Computes the aerodynamic forces that would be applied to the vessel if it was in the specified situation (air velocity and altitude). The vessel is assumed to be in its current orientation (the air velocity is already adjusted as needed).
protected abstract ComputeForces_Model ( UnityEngine.Vector3d airVelocity, double altitude ) : UnityEngine.Vector3d
airVelocity UnityEngine.Vector3d
altitude double
Résultat UnityEngine.Vector3d

GetForces() public méthode

Returns the total aerodynamic forces that would be applied on the vessel if it was at bodySpacePosition with bodySpaceVelocity relatively to the specified celestial body This method makes use of the cache if available, otherwise it will call ComputeForces.
public GetForces ( CelestialBody body, UnityEngine.Vector3d bodySpacePosition, UnityEngine.Vector3d airVelocity, double angleOfAttack ) : UnityEngine.Vector3d
body CelestialBody
bodySpacePosition UnityEngine.Vector3d
airVelocity UnityEngine.Vector3d
angleOfAttack double
Résultat UnityEngine.Vector3d

IncrementalUpdate() public méthode

public IncrementalUpdate ( ) : void
Résultat void

Invalidate() public méthode

public Invalidate ( ) : void
Résultat void

PackForces() public méthode

Aerodynamic forces are roughly proportional to rho and squared air velocity, so we divide by these values to get something that can be linearly interpolated (the reverse operation is then applied after interpolation) This operation is optional but should slightly increase the cache accuracy
public PackForces ( UnityEngine.Vector3d forces, double altitudeAboveSea, double velocity ) : Vector2
forces UnityEngine.Vector3d
altitudeAboveSea double
velocity double
Résultat Vector2

UnpackForces() public méthode

See PackForces
public UnpackForces ( Vector2 packedForces, double altitudeAboveSea, double velocity ) : UnityEngine.Vector3d
packedForces Vector2
altitudeAboveSea double
velocity double
Résultat UnityEngine.Vector3d

VesselAerodynamicModel() public méthode

public VesselAerodynamicModel ( Vessel vessel, CelestialBody body ) : System
vessel Vessel
body CelestialBody
Résultat System

isValidFor() public méthode

public isValidFor ( Vessel vessel, CelestialBody body ) : bool
vessel Vessel
body CelestialBody
Résultat bool

Property Details

body_ protected_oe property

protected CelestialBody body_
Résultat CelestialBody

cachedForces protected_oe property

protected AeroForceCache,Trajectories cachedForces
Résultat AeroForceCache

vessel_ protected_oe property

protected Vessel vessel_
Résultat Vessel