FlowState is a no-backend scientific web application for exploring first-principles bladder emptying and uroflowmetry curves. It is designed as a biomedical engineering capstone-style simulator for education and research intuition, not for clinical diagnosis.
The physics engine lives in src/lib/physics/uroflow.ts.
- Bladder pressure decays as an elastic pressure vessel:
P(t) = P0 * (V / V0)^1.15. - Outlet area is circular urethral area scaled by sphincter opening:
Aeff = pi * D^2 / 4 * restriction. - Bernoulli velocity is estimated with
v = sqrt(2 deltaP / rho). - Optional Darcy-Weisbach loss uses
deltaP = 0.5 * rho * v^2 * (1 + f * L / D). - Flow rate follows continuity:
Q = Aeff * v. - Bladder volume is integrated with explicit Euler steps:
dV/dt = -Q.
npm install
npm run devThen open http://localhost:3000.
npm run test
npm run lint
npm run buildThe app includes a source matrix connecting continuity, Bernoulli, Darcy-Weisbach loss, viscosity defaults, and uroflowmetry terms to educational references. FlowState intentionally labels these references as teaching context rather than validation evidence.