SITL: Fix typo in Sub

Signed-off-by: Patrick José Pereira <patrickelectric@gmail.com>
This commit is contained in:
Patrick José Pereira 2019-03-04 13:19:42 -08:00 committed by Peter Barker
parent 8bb0772224
commit ab6b84e876
2 changed files with 4 additions and 4 deletions

View File

@ -125,11 +125,11 @@ float Submarine::calculate_buoyancy_acceleration()
// Completely below water level
if (below_water_level > frame_property.height/2) {
return frame_property.bouyancy_acceleration;
return frame_property.buoyancy_acceleration;
}
// bouyant force is proportional to fraction of height in water
return frame_property.bouyancy_acceleration * below_water_level/frame_property.height;
return frame_property.buoyancy_acceleration * below_water_level/frame_property.height;
};
/*

View File

@ -50,9 +50,9 @@ protected:
float width = 0.338; // y direction (meters)
float height = 0.254; // z direction (meters)
float weight = 10.5; // (kg)
float net_bouyancy = 2.0; // (N)
float net_buoyancy = 2.0; // (N)
float bouyancy_acceleration = GRAVITY_MSS + net_bouyancy/weight;
float buoyancy_acceleration = GRAVITY_MSS + net_buoyancy/weight;
// Frame drag coefficient
const Vector3f linear_drag_coefficient = Vector3f(0.2, 0.3, 0.4);