Swelling hydrogel

How hydrogel beads swell in a tube

This simulation is inspired by the work of Alexia Beale on the swelling of chickpeas and hydrogel beads.

The simulation is coded as a constrained optimization problem with CasADi.