cfd_body_drag
Estimate external-flow drag for spheres, cylinders, and bluff bodies without a solver. Screen design candidates in milliseconds before committing to a CFD solve.
Instructions
Analytic EXTERNAL-flow drag screen (NO solver, milliseconds) — the external twin of cfd_pipe_flow, and the banded oracle the wind-tunnel solve cfd_external_flow_submit(model=…) is checked against. Use this FIRST to narrow a design space; escalate to the solve only for the shapes that survive.
Three families:
shape='sphere'— Clift–Gauvin over the whole standard drag curve, Cd = 24/Re·(1+0.15·Re^0.687) + 0.42/(1+4.25e4·Re^-1.16). Collapses to the EXACT Stokes 24/Re as Re→0; valid to Re=2e5 (it does not model the drag crisis). Passdiameter_mm+velocity_m_s.shape='cylinder'— Sucker–Brauer crossflow Cd (axis ⟂ flow), Cd ≈ 10 at Re=1, 1.45 at Re=100, 1.2 at Re=1e5. Passdiameter_mm,velocity_m_s, optionallength_mm(default 1 m, i.e. drag per unit span; L/D<10 warns about end relief).a tabulated bluff/streamlined shape — 'cube_face_on', 'flat_plate_normal', 'hemisphere_open_back', 'streamlined_body', 'car_modern', … (
shape='list'returns the whole table). Needsfrontal_area_mm2(or amodelhandle, whose silhouette alongflow_directionis measured off the live solid) +velocity_m_s;cdoverrides the table with a known value.
Fidelity: sphere/cylinder are correlations with band_pct 10/15; the table is band_pct 20 and only valid for Re ≈ 1e4–1e6 on a shape that genuinely matches.
Returns {cd, drag_force_n, frontal_area_m2, dynamic_pressure_pa, velocity_m_s, fidelity, band_pct, escalate_to} plus {reynolds, regime, valid_range_ok, warnings} for sphere/cylinder — or {shapes: {name: cd}} for shape='list'.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| cd | No | ||
| fluid | No | air-20c | |
| model | No | ||
| shape | No | sphere | |
| mu_pa_s | No | ||
| length_mm | No | ||
| rho_kg_m3 | No | ||
| diameter_mm | No | ||
| velocity_m_s | No | ||
| flow_direction | No | ||
| frontal_area_mm2 | No | ||
| stl_tolerance_mm | No |