# discretize.TreeMesh.edge_curl¶

TreeMesh.edge_curl

Edge curl operator (edges to faces)

This property constructs the 2nd order numerical curl operator that maps from edges to faces. The operator is a sparse matrix $$\mathbf{C_e}$$ that can be applied as a matrix-vector product to a discrete vector quantity u that lives on the edges; i.e.:

curl_u = Ce @ u


Once constructed, the operator is stored permanently as a property of the mesh.

Returns
(n_faces, n_edges) scipy.sparse.csr_matrix

The numerical curl operator from edges to faces

Notes

In continuous space, the curl operator is defined as:

$\begin{split}\vec{w} = \nabla \times \vec{u} = \begin{vmatrix} \hat{x} & \hat{y} & \hat{z} \\ \partial_x & \partial_y & \partial_z \\ u_x & u_y & u_z \end{vmatrix}\end{split}$

Where $$\mathbf{u}$$ is the discrete representation of the continuous variable $$\vec{u}$$ on cell edges and $$\mathbf{w}$$ is the discrete representation of the curl on the faces, edge_curl constructs a discrete linear operator $$\\mathbf{C_e}$$ such that:

$\mathbf{w} = \mathbf{C_e \, u}$

The computation of the curl on mesh faces can be expressed according to the integral form below. For face $$i$$ bordered by a set of edges indexed by subset $$K$$:

$w_i = \frac{1}{A_i} \sum_{k \in K} \vec{u}_k \cdot \vec{\ell}_k$

where $$A_i$$ is the surface area of face i, $$u_k$$ is the value of $$\vec{u}$$ on face k, and vec{ell}_k is the path along edge k.