calculate_buoyancy
Calculate the buoyant force on an object using Archimedes' principle. Input volume, fluid density, and submerged fraction to determine if the object floats or sinks.
Instructions
Calculate buoyancy force using Archimedes' principle.
The buoyant force equals the weight of displaced fluid:
F_b = ρ_fluid * V_submerged * g
Args:
volume: Object volume in m³
fluid_density: Fluid density in kg/m³ (water=1000, air=1.225)
gravity: Gravitational acceleration in m/s² (default 9.81)
submerged_fraction: Fraction submerged 0.0-1.0 (default 1.0 = fully submerged)
Returns:
Buoyant force (upward) and displaced mass
Example - Checking if a 1kg ball will float:
# 10cm diameter sphere: V = (4/3)πr³ = 0.000524 m³
result = await calculate_buoyancy(
volume=0.000524,
fluid_density=1000 # water
)
# buoyant_force = 5.14 N
# If weight (mg) < buoyant force, it floats
# 1kg * 9.81 = 9.81 N > 5.14 N, so it sinksInput Schema
| Name | Required | Description | Default |
|---|---|---|---|
| volume | Yes | ||
| fluid_density | Yes | ||
| gravity | No | ||
| submerged_fraction | No |