Why a ship of steel floats while a nail sinks. Drop a block into a fluid and the fluid pushes back up with the weight of whatever the block shoves aside — Archimedes' principle, buoyant force B = ρfluid·g·Vsubmerged. Less dense than the fluid and the block floats, settling with just enough of itself under the surface — a fraction equal to ρobject/ρfluid; denser, and it sinks. Change the block's density and the fluid, drag it under and let it bob back, and watch the two force arrows fight it out. It all runs on your device.
You are in the Physics lab.
What the two vectors, the highlighted volume and the density panel are telling you.
The red arrow is the weight W = ρobject·g·V pulling straight down; the teal arrow is the buoyant force Fb = ρfluid·g·Vsubmerged pushing straight up. They are drawn to the same scale, so whichever arrow is longer is the winner: while the block is settling the buoyant arrow grows as more of the block goes under, until the two match and it floats — or, if weight stays longer even fully submerged, the block sinks. The net force readout is simply Fb − W.
The blue hatched region is the displaced fluid — the part of the block below the waterline. A floating block stops sinking exactly when the fluid it displaces weighs as much as the block, so the submerged fraction settles at ρobject/ρfluid. Wood at 700 in water at 1000 rides 70% under; ice at 917 sits about 92% under — the iceberg. Change the volume and the fraction does not move: bigger blocks weigh more but displace proportionally more, so density alone sets how deep it floats.
The side panel compares the object's density bar to the fluid's, with a dashed float line at the fluid: a bar below the line floats, above it sinks. Steel at 7850 towers over water and drops to the floor — but switch the fluid to mercury at 13600 and the same steel bar falls below the line, so it bobs at the surface. That is why density, not weight or size, decides, and why a dense metal can float on a denser liquid.
Displaced fluid pushes back, a floating object finds its level, and density draws the line between floating and sinking.
Pressure in a fluid grows with depth, so the fluid presses up on the bottom of a submerged object harder than it presses down on the top. The net is an upward buoyant force, and Archimedes showed it equals the weight of the displaced fluid: B = ρfluid·g·Vsubmerged. The deeper the object sits, the more it displaces and the stronger the push.
If the object is less dense than the fluid, it can displace its whole weight of fluid while still partly above the surface. It sinks until buoyancy exactly balances gravity and then floats there, with the submerged fraction equal to ρobject/ρfluid. Ice at 920 in water at 1000 sits about 92 percent under — the iceberg's hidden bulk.
If the object is denser than the fluid, even fully submerged it cannot displace its own weight, so the buoyant force stays below the weight and the net force is downward — it sinks to the bottom, where it still feels a real buoyant force that makes it seem lighter than in air. Slide the density across the fluid's value to flip between floating and sinking.
Teaching or blogging about fluids? You can embed this simulator on your own site free — one line of code, no sign-up.