FEMorph 2.0FEMorph is an extensive addon for Python FEniCS for large scale nodal shape optimization, morphing and deformation. Its main feature is the automatic derivation of shape derivatives in UFL. It also features robust grid deformation algorithms, mesh repair techniques, equal distant point spacing, curvature computation and symmetry computations, among others.
The software will be made available soon on GitHub.
The strongest new feature of version 2.0 is the automatic generation of 1st and higher order classical Hadamard-type shape derivatives in UFL and FEniCS.
Consider for example the problem to find a flow obstacle, such that internal shear, resp. drag, is minimized in a viscous, incompressible fluid: With the new version 2.0 capabilities, it suffices to specify the Lagrangian (excluding the target volume) in UFL
and a call to the ShapeDerivative-routine will automatically generate the Hadamard shape derivative, that is the derivative of the Lagrangian into the direction of a domain deformation V.
L = Eta*inner(grad(u0), grad(u0))*dx L +=(Eta*inner(grad(u0), grad(lu0)) + lp0*div(u0) - p0*div(lu0))*dx L += (lVol*OneR)*dx
The resulting UFL object can then be used in a steepest descent algorithm or a repeated application of the routines can be used to construct a Newton-like scheme.
dLV = ShapeDerivative(L, V, N, ...)
FEMorph 1.0The version 1.0 software is available here. It contains the actual shape optimization toolbox "ShapeOpt.py" as well as the transient/stationary 2D/3D primal/adjoint flow solver "Navier.py" and the SUPG Convection-Diffusion solver "ConvectionDiffusion.py". Together with the meshes also contained in the .zip, all results from this website should be reproduceable. The software also works in distributed memory parallelism.
The article describing the reparameterization and deformation strategy is available here.
This addon is tested with dolfin version 1.4.0+ (Dorsal automatic installation on OpenSuse 13.2 and Debian Wheezy). I have had reports of memory leaks when version 1.4.0 was used.