I am attempting to solve transient Stokes flow in a canonical channel (parabolic inlet, no-slip bottom and top wall, fixed pressure and inlet).
The Stokes problem leads to a mass-matrix DAE. A naive hand code backward Euler works fine. Next, I an attempting to use DifferentialEquations.jl. The DAE solvers provided by this package are implicit. A Jacobian is thus required.
A finite difference approximation of the Jacobian (using autodiff=AutoFiniteDiff()) fails (I guess) to take the boundary conditions properly into account. Time integration fails.
Is there literature and/or examples of how mass matrix, stiffness matrix and Jacobian ought to be constructed (including boundary conditions) for the DAE solver to converge?
A small example showing what goes wrong is at