Skip to content

FreeCAD and ParaView

noooway edited this page Sep 3, 2017 · 9 revisions

FreeCAD

FreeCAD module allows to visualize placement of particle sources and inner regions inside computation domain. Ultimately, it generates config file, which can be used by Ef.

To intall module, create a symlink from freecad folder in ef distribution to FreeCAD module folder:

ln -s /your-ef-dir/freecad/ ~/.FreeCAD/Mod/ef

To use it:

  1. Create new document in FreeCAD.
  2. Activate Ef workbench.
  3. Press 'New minimal ef config' command.
  4. Add particle sources and inner regions (for these commands to be available, select at least one object in the ef_conf group).
  5. Modify properties of the objects.
  6. When ready, press 'Generate .conf file' command to export config file.

ParaView

Paraview can be used to visualize results of simulation. Install the plugin by command

ln -s /your-ef-dir/paraview/ef.py ~/.config/ParaView/Macros/ef.py

(striktly speaking, it is not a plugin, but a macros).

To use it:

  1. Press 'ef' macro-command button. Select and load file to visualize.
  2. Change particles representation ( color by px/py/pz value, etc ... )
  3. Hide them, when they are no longer necessary.
  4. To visualize values on the grid, select spat_mesh_grid object from the pipeline. Change it's representation to volume.
  5. Select quality to visualize (potential/charge density/E_x etc).

ParaView is a very powerful visualization tool. It is capable to perform postprocessing of data. For example, it is possible to visualize a potential on a given plane ('slice' filter, see figure below), show only particle with energies above certain value ('threshold' filter), etc. Consult ParaView tutorial for various possibilities.

Clone this wiki locally