FEM tutorial

Introduction
This tutorial is meant to introduce the reader to the basic workflow of the FEM Workbench, as well as most of the tools that are available to perform a static analysis.



Requirements

 * FreeCAD version 0.17 or above.
 * Netgen and/or GMSH is installed on the system (included in the FreeCAD instalation).
 * Calculix is installed on the system (included in the FreeCAD instalation).
 * The reader has the basic knowledge to use the Part and PartDesign Workbenches.

Modeling
In this example a Cube is used as the study object, but models created in the Part or PartDesign Workbenches can be used instead.


 * 1) Create a new document (press on the [[Image:Std_New.svg|24px|link=Std_New]] button).
 * 2) Activate the [[Image:Workbench_Part.svg|24px|link=Part_Workbench]] Part Workbench.
 * 3) Create a Cube.
 * 4) Change its Dimensions to the following:
 * 5) Length: 8.000 m.
 * 6) Width: 1.000 m.
 * 7) Height:  1.000 m.

Now we have a model with which to work with.

Creating the Analysis

 * 1) Activate the [[Image:Workbench_FEM.svg|24px|link=FEM_Workbench]] FEM Workbench.
 * 2) Select the  option from the menu.

Constraints and Forces

 * 1) Hide the mesh from the Tree View.
 * 2) Show the original model.
 * 3) Select [[Image:FEM_ConstraintFixed.svg|24px|link=FEM_ConstraintFixed]] Create FEM fixed constraint.
 * 4) Click, select the back face of the Cube object (face on the YZ axis) and click.
 * 5) Select  [[Image:FEM_ConstraintForce.svg|24px|link=FEM_ConstraintForce]] Create FEM force constraint.
 * 6) Click, select the front face of the Cube object (the face parallel to the back face) and set the Load [N]  value to 9000000.
 * 7) Set the Direction to -Z by selecting one of the face edges parallel to that direction.
 * 8) Click.

We now have established the restrictions and forces for our static study.

Material

 * 1) Select [[Image:FEM_MaterialSolid.svg|24px]] Material for solid and choose Calculix-Steel as the material.
 * 2) Click.

Meshing
It is recommended to make a mesh as the last step in the analysis preparations due to association to a geometry in FreeCAD. Depending on FreeCAD installation, there can be Netgen or GMSH meshers, you can use any of them.

Netgen

 * 1) Select the model.
 * 2) [[Image:FEM_MeshNetgenFromShape.svg|24px]] FEM mesh from shape by Netgen: Generates a finite element mesh for a model using Netgen.
 * 3) In the meshing dialog, click  and.

You can also drag and drop a mesh to a Mechanical Analysis that does not have a mesh within the Tree view.

GMSH

 * 1) Select the model
 * 2) [[Image:FEM_MeshGmshFromShape.svg|24px]] FEM mesh from shape by Gmsh: Generates a finite element mesh for a model using Gmsh.
 * 3) In the meshing dialog, click  and.

We have now meshed our object and are ready to add constraints and forces.

Standard Procedure

 * 1) Select the solver object [[Image:FEM_SolverCalculixCxxtools.svg|24px]] contained in the Analysis container.
 * 2) Select [[Image:FEM_SolverControl.svg|24px]] Solver job control from the menu.
 * 3) Select Write .inp File.
 * 4) Select Run CalculiX.
 * 5) Click.

Quick Procedure

 * 1) Select the solver object [[Image:FEM_SolverCalculixCxxtools.svg|24px]] contained in the Analysis container.
 * 2) Click on [[Image:FEM_SolverRun.svg|24px]] Run solver calculations.

Analyzing Results

 * 1) From the Object Tree, select the CCX_Results object.
 * 2) Select [[Image:FEM_ResultShow.svg|24px|link=FEM_ResultShow]] Show result.
 * 3) Choose among the different Result types to view the results.
 * 4) The slider at the bottom can be used to alter the mesh visualization. This allows us to visualize the deformation experienced by the object, keep in mind that this is an approximation.
 * 5) To remove the results select [[Image:FEM_ResultsPurge.svg|24px|link=FEM_ResultsPurge]] Purge results.

We are now finished with the basic workflow for the FEM Workbench.