Debian Codegraph @

demo/documented/nonmatching-interpolation/cpp/P3.ufl.rst

raw
1 UFL input for P3 finite element
2 ===============================
3
4 We define the finite element in UFL in a separate form file
5 :download:`P3.ufl`. We define the linear finite element::
6
7 from ufl_legacy import (FiniteElement, triangle)
8 element = FiniteElement("Lagrange", triangle, 3)
9
10 Before the form file can be used in the C++ program, it must be
11 compiled using FFC by running (on the command-line):
12
13 .. code-block:: sh
14
15 ffc -l dolfin P3.ufl