Let me summarize the workflow FreeCAD - Elmer:
boundary conditions:
- FreeCAD's mesh is based on mm and the SI base unit is m
- Elmer is designed to use consistently base SI units.
Here is the workflow and what we did in FreeCAD 0.19, 0.20 and what we have to do now:
- Elmer-Workflows.jpg (250.07 KiB) Viewed 1461 times
(hereby "non-SI" means not in the SI base units: s, A, kg, m cd, mol, K)
EDIT: The 0.20 workflow is correct. it is just a bug that the heat source does not take Elmer Solver's scale option into account.
The golden rule one is taught at the university is to calculate in base SI units, only change units when you have the final results. (Here a recent example were a users did not follow this and failed:
https://forum.freecadweb.org/viewtopic. ... 22#p614222)
Therefore the approach of FC 0.19 was no success. We used several factors for input parameters but since Elmer is multiphysics it is a nightmare to assure the result will be correct SI so that we or the user can do something with it.
In FC 0.20 I changed it that we consistently create case.sif files using base SI units. This has the beauty that you can run your .sif file also directly with Elmer, you can send you .sif files to others or take .sif file from others.
To overcome the mm-mesh problem, we use ElmerGrid to scale the mesh. Elmer gets then everything in base-SI units. This worked fine (tested with flow simulations, voltages, mechanical). However now it turns out that input parameters that take the length unit from the mesh, will be recalculated by Elmer because of the scaling. This sucks, but we have to face this.
Of course the same case.sif files must deliver the same results in Elmer directly and with FreeCAD.
So we cannot scale the mesh. As result we get results that have base SI units only if the results do not depend on the mesh's length unit. For example voltage has a length unit in it, but this is not the one of the mesh. Results like displacements or stresses take the length unit from the mesh and therefore we have to recalculate them.
This is a bit annoying but the results that directly depend on the mesh's length unit are not that many.