FEATool Multiphysics  v1.16.6 Finite Element Analysis Toolbox
fenics.m File Reference

## Description

FENICS MATLAB FEniCS project FEA solver CLI interface.

[ PROB ] = FENICS( PROB, VARARGIN ) Export, solves, and/or imports the problem described by the finite element struct PROB using the FEniCS solver. The fea problem struct is returned with updated SOL.U and SOL.T fields if applicable. Accepts the following property/value pairs.

Input       Value/{Default}              Description
-----------------------------------------------------------------------------------
modes       {c, e, s, i, l}              Command mode(s) to call (default all)
(c)heck, (e)xport, (s)olve, (i)mport, c(l)ear
data        {fenics_data}                FEniCS input data file to use, by default
uses fenics_data(prob, varargin{:})
fname       featool-fenics               FEniCS base filename root
fdir        string  {pwd}                Directory to write data and mesh files
order       scalar  {2}                  Integration order used in c-expressions
linsolv     string  {default}            Linear solver
precond     string  {default}            Preconditioner for iterative solver
ischeme     scalar  {0}                  Solver type/time stepping scheme
1 - 1st order Backward Euler
2 - 2nd order Crank-Nicolson
tstep       scalar  {0.1}                Time step size (for ischeme >= 1)
tmax        scalar  {1.0}                Maximum simulation time (for ischeme >= 1)
islin       scalar  {auto}               Specify linear or non-linear solver
maxnit      scalar  {20}                 Maximum number of non-linear iterations
nlrlx       scalar  {1.0}                Relaxation for non-linear iterations
toldef      scalar  {1e-6}               Relative stopping criteria
tolchg      scalar  {1e-6}               Absolute stopping criteria
nproc       scalar  {numcores/2}         Number of processors to use
saveall     logical {true}               Save all time steps/solutions
otherwise just saves last one
python      string  {python-fenics|python3|python}    Python interpreter call command
scmd        system default               Custom system solve command string
ccmd        string  {                    FEniCS installation check/validation command
bash -c "dolfin-version 2>/dev/null ||
python -c 'import dolfin;print(dolfin.__version__)'"}
wbash       C:\Windows\System32\bash.exe Windows bash executable path
pause       boolean {false}              Pause external log terminal
fid         scalar  {1}                  File identifier for output ([]=no output)

Example
  1) Uniform heating of a unit circle.

fea.sdim = {'x', 'y'};