TITLE 'Percolation through a Concrete Block' { sim231.pde } SELECT errlim=1e-4 ngrid=1 spectral_colors VARIABLES phi p DEFINITIONS L=1.0 visc=1e-3 k=1e-12 p0=1e5 delp=1e3 vx=dx( phi) vy=dy( phi) v=vector( vx, vy) vm=magnitude( v) EQUATIONS phi: div( grad( phi))=0 p: div( grad( p))=0 BOUNDARIES region 'domain' start 'outer' (0,0) value( phi)=0 value( p)=p0 line to (L,0) { Bottom } natural( phi)=0 natural( p)=0 line to (L,L) to (0,L) to (0,2/3*L) natural( phi)=k/visc*dx( p) value( p)=delp+p0 { Seeping window } line to (0,L/3) natural( phi)=0 natural(p)=0 line to close PLOTS contour( phi) contour( p) painted contour( vm) painted vector( v) norm contour(div( v)) contour( curl( v)) elevation( p) on 'outer' END