
Browse by Category
 All Solutions
 ALE / Parameterized Geometry (1)
 Error Messages (59)
 Export (1)
 Fluid Dynamics (1)
 General (11)
 Geometry (11)
 Import (9)
 Installation (32)
 Mesh (12)
 Physics (10)
 Postprocessing (4)
 Solver (30)
 Structural Mechanics (2)
Solution Number:  875 
Title:  What does degrees of freedom (DOFs) mean in COMSOL Multiphysics? 
Platform:  All Platforms 
Applies to:  All Products 
Versions:  All versions 
Categories:  Physics, Physics 
Keywords:  DOF, degree of freedom 
Problem Description
What does degrees of freedom (DOFs) mean in COMSOL Multiphysics?
Solution
The solution time and memory requirements are strongly related to the number of degrees of freedom in the model. It is often desirable to be able to estimate the number of degrees of freedom based on the number of elements in the model.
For most physics interfaces each dependent variable is present in all nodes in the mesh. This means that the number of degrees of freedom is given by the number of nodes multiplied by the number of dependent variables. The relation between the number of nodes and the number of elements depends on the order of the elements and differs between 2D and 3D. The relation is only approximate since it depends on the ratio of the elements that lie on the boundary of the geometry. For thin geometries, where a large proportion of the elements lie on the boundary, the number of nodes per element is a bit higher.
The following are approximate relations between the number of nodes and the number of elements in 2D and 3D for Lagrange elements of different order. Quadrilateral (quad) meshes have roughly twice as many nodes as triangular meshes, and hexahedral (brick) meshes have about 6 times as many nodes as tetrahedral meshes.
2D
 Linear triangular elements: (#nodes) = 0.5 * (#elements)
 Linear quad elements: (#nodes) = 1 * (#elements)
 Quadratic triangular elements: (#nodes) = 2 * (#elements)
 Quadratic quad elements: (#nodes) = 4 * (#elements)
 Cubic triangular elements: (#nodes) = 4.5 * (#elements)
 Cubic quad elements: (#nodes) = 9 * (#elements)
3D
 Linear tetrahedral elements: (#nodes) = 0.2 * (#elements)
 Linear brick elements: (#nodes) = 1.2 * (#elements)
 Quadratic tetrahedral elements: (#nodes) = 1.4 * (#elements)
 Quadratic brick elements: (#nodes) = 8.5 * (#elements)
 Cubic tetrahedral elements: (#nodes) = 4.6 * (#elements)
 Cubic brick elements: (#nodes) = 28 * (#elements)
The total number of degrees of freedom is then given by:
(#degrees of freedom) = (#nodes) * (#dependent variables)
The number of mesh elements in your model is presented in the Log window each time you create a new mesh or modify an existing one by clicking the Build All button. You can also find it by righclicking the Mesh node and choosing Statistics.
To see the number of degrees of freedom, you need to first create solver configurations by solving the model or rightclicking Study and choosing Show Default Solver. Your study will then contain one Compile Equations node for each study step. Rightclick on any such node and select Statistics to see the number of degrees of freedom solved for by the corresponding study step.
Note that the number of degrees of freedom is not the only factor determining the memory requirements and the solution time of a problem. For more information on how to avoid running out of memory, please visit Knowledge Base entry 1030
Disclaimer
COMSOL makes every reasonable effort to verify the information you view on this page. Resources and documents are provided for your information only, and COMSOL makes no explicit or implied claims to their validity. COMSOL does not assume any legal liability for the accuracy of the data disclosed. Any trademarks referenced in this document are the property of their respective owners. Consult your product manuals for complete trademark details.