What’s new in FEM for FreeCAD 1.1?

Now that the fea­ture freeze for FreeCAD 1.1 is on, and we are not too far off from the final release, let’s sum­ma­rize the main changes in the FEM work­bench. Just like in the case of the rev­o­lu­tion­ary 1.0.0 release (see this blog post), FEM dom­i­nates the release notes. There have been many sig­nif­i­cant improve­ments, so let’s go through them.

Electromagnetics

In this release cycle, the main focus was on elec­tro­mag­net­ic (EM) analy­ses, post­pro­cess­ing, and key miss­ing Cal­culiX fea­tures. The range of sup­port­ed elec­tro­mag­net­ic sim­u­la­tions was extend­ed with the intro­duc­tion of Elmer’s sta­t­ic cur­rent con­duc­tion solver imple­ment­ed as Equa­tion­Sta­t­ic­Cur­rent. It doesn’t just allow direct cur­rent (DC) flow sim­u­la­tions: when com­bined with the Heat equa­tion, it may also be used to mod­el resis­tive (Joule) heat­ing. There is a ded­i­cat­ed FEM Exam­ple for it, includ­ing ana­lyt­i­cal ver­i­fi­ca­tion of results.

Anoth­er major change for EM work­flows was the addi­tion of the elec­tric charge den­si­ty load. It can be used in elec­tro­sta­t­ic analy­ses to pre­scribe total charge in Coulombs or charge per unit area/volume.

Speak­ing about elec­tro­sta­t­ics, this type of analy­ses is now also pos­si­ble (even in 2D) with the new­ly refac­tored Cal­culiX solver, which we will cov­er in more detail below. This imple­men­ta­tion uti­lizes the anal­o­gy of dif­fer­en­tial equa­tions for elec­tro­sta­t­ics and steady-state heat transfer.

We improved the exist­ing EM bound­ary con­di­tions and loads. There are two modes for the cur­rent den­si­ty bound­ary con­di­tion (Cus­tom and Nor­mal), while the elec­tro­sta­t­ic poten­tial bound­ary con­di­tion can be used to pre­scribe elec­tric flux den­si­ty in C/m^2. These two con­straints now have sym­bols too. Also, we over­hauled the task pan­el for the mag­ne­ti­za­tion bound­ary condition.

Postprocessing

As men­tioned in the begin­ning, we made sev­er­al big improve­ments in the area of post­pro­cess­ing. They main­ly affect­ed results pipelines. If the new Result object: Pipeline only pref­er­ence is enabled, a refac­tored Cal­culiX solver imple­men­ta­tion is used. The main dif­fer­ence is that it doesn’t gen­er­ate the lega­cy CCX_Results objects and only adds one results pipeline object to avoid clut­ter­ing the tree. Thanks to ickby’s effort, there’s no need for mul­ti­ple pipeline objects any­more, as they sup­port results from mul­ti­ple frames — users can eas­i­ly switch between them in the task panel.

The refac­tored ccx solver has oth­er advan­tages too — it sup­ports elec­tro­sta­t­ic analy­ses and pro­vides results in mm and MPa units. How­ev­er, it’s not yet ful­ly devel­oped and doesn’t sup­port some result types as well as pre­pro­cess­ing warnings.

Oth­er sig­nif­i­cant enhance­ments in terms of post­pro­cess­ing are two new pipeline filters:

  • Cal­cu­la­tor cre­ates cus­tom result fields by per­form­ing math­e­mat­i­cal oper­a­tions on the exist­ing fields.
  • Glyph cre­ates sym­bol plots help­ful to visu­al­ize vec­tor quantities.

There is also a new Data and Extrac­tions wid­get for pipelines and three tools allow­ing detailed explo­ration of the num­bers obtained from sim­u­la­tions. The fol­low­ing data extrac­tion objects are available:

  • line plot
  • his­togram
  • table

Final­ly, the lega­cy CCX_Results objects now have a task pan­el option enabling sim­ple ani­ma­tions of the deformed result shapes. There is also a Python func­tion Fem.frdToVTK which can be used to con­vert Cal­culiX results to the Par­aView format.

CalculiX features

We added sev­er­al use­ful Cal­culiX key­words and options to fur­ther extend the sup­port of FreeCAD FEM for its main solver. This includes, among others:

  • addi­tion­al beam sec­tions — box and elliptical;
  • tie con­straint applic­a­ble to shell faces;
  • def­i­n­i­tion of ref­er­ence tem­per­a­ture for ther­mal expansion;
  • off­set for shell elements;
  • ther­mal con­tact (gap conduction);
  • hard (auto­mat­i­cal­ly deter­mined stiff­ness) and tied (bond­ed) contact;
  • cav­i­ty (sur­face to sur­face) radiation;
  • ampli­tudes for most bound­ary con­di­tions and loads to define their time variation;
  • region selec­tion for ini­tial temperature;
  • pre­scribed tem­per­a­ture field in sta­t­ic analyses;
  • mem­brane (shell with no bend­ing stiff­ness) and truss (beam with no bend­ing stiff­ness) elements;
  • print­ing con­tact forces and rigid body constraint’s ref­er­ence point dis­place­ments to ccx_dat_file;
  • pres­sure and heat flux load, as well as con­tact and tie con­straints applic­a­ble to edges in 2D analyses;
  • body heat source and cen­trifu­gal force loads applic­a­ble to faces in 2D analyses.

Other improvements

Among oth­er major fea­tures, there are some mesh­er enhance­ments, such as sup­port for sim­ple extrud­ed hexa­he­dral-dom­i­nat­ed mesh­es with Netgen.

This mesh­er can now also use local refine­ment, gen­er­ate sec­ond-order mesh­es by lin­ear inter­po­la­tion of nodes, and cre­ate con­for­mal mesh­es. Pre­vi­ous­ly, those fea­tures were only avail­able with Gmsh.

We made it pos­si­ble to sup­press (deac­ti­vate) not only con­straints but also oth­er FEM fea­tures for which sup­pres­sion makes sense.

Anoth­er handy new fea­ture is a pop-up menu to select the prop­er sol­id of a Comp­Sol­id when pick­ing its face belong­ing to both solids. This facil­i­tates mate­r­i­al assignment.

Summary

FEM has been active­ly devel­oped in the v1.1 devel­op­ment cycle. Such progress wouldn’t be pos­si­ble with­out the invalu­able con­tri­bu­tions of marioalexis84 and ick­by, as well as oth­er devs occa­sion­al­ly con­tribut­ing to FEM. There’s still a lot to improve, such as:

  • more Cal­culiX and Elmer features;
  • mixed and mul­ti­ple meshes;
  • mul­ti­step analyses;
  • fur­ther post­pro­cess­ing usabil­i­ty improve­ments (includ­ing unit han­dling and col­or leg­end issues);
  • a frame­work for addi­tion­al spe­cial­ized solvers.

Thus, we wel­come all new con­trib­u­tors to help make FEM even better!


Discover more from FreeCAD News

Subscribe to get the latest posts sent to your email.

3 responses to “What’s new in FEM for FreeCAD 1.1?”

  1. Laurie Hartley Avatar

    Thank you NewJok­er, marioalexis84, ick­by, and every­one else for devel­op­ing this what is for me, a fas­ci­nat­ing workbench.

  2. And Avatar
    And

    > “the fea­ture freeze for FreeCAD 1.1 is on, and we are not too far off from the final release”
    Where do you see this and where is this dis­cussed? One rea­son for me to look over these blog posts are to find this kind of roadmap or release sched­ule infor­ma­tion. I haven’t real­ly found it in the forum or in the wiki. The wip posts are nice, but most of the nit­ty-grit­ty go over my head as I don’t always see how they fit into the big pic­ture or when I might be able to use them. So I am a bit sur­prised to find this infor­ma­tion in a throw­away sub­or­di­nate clause.

    1. Aleksandr Prokudin Avatar
      Aleksandr Prokudin

      Here is the thread: https://forum.freecad.org/viewtopic.php?t=99009

      I dis­cussed the need to announce this on the blog as well with team mem­bers. The con­sen­sus was that it’s a tech­ni­cal detail not worth a sep­a­rate post, so I com­plied with it.

Discover more from FreeCAD News

Subscribe now to keep reading and get access to the full archive.

Continue reading