Skip to content
Merged
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ jobs:
shell: bash -l {0}
run: |
# conda upgrade --strict-channel-priority -c conda-forge --all
conda install -c conda-forge fenics numpy=1.24 "python>=3.10"
conda install -c conda-forge fenics numpy=1.24 "python>=3.10" "setuptools<82"

- name: Install dependencies
shell: bash -l {0}
Expand Down
29 changes: 28 additions & 1 deletion .github/workflows/doctest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,33 @@ jobs:
activate-environment: festim-docs
environment-file: docs/environment.yml

- name: urls-checker
uses: urlstechie/urlchecker-action@master
with:
# A subfolder or path to navigate to in the present or cloned repository
subfolder: docs

# A comma-separated list of file types to cover in the URL checks
file_types: .md,.py,.rst

# Choose whether to include file with no URLs in the prints.
print_all: false

# The timeout seconds to provide to requests, defaults to 5 seconds
timeout: 5

# How many times to retry a failed request (each is logged, defaults to 1)
retry_count: 3

# A comma separated links to exclude during URL checks
exclude_urls: https://www.lspm.cnrs.fr/en/home/,https://www.theses.fr/2022PA131054

# A comma separated patterns to exclude during URL checks
exclude_patterns:

# choose if the force pass or not
force_pass : false

- name: Doc Tests
shell: bash -l {0}
run: sphinx-build -b doctest docs/source docs/_build/doctest
run: sphinx-build -b doctest docs/source docs/_build/doctest
3 changes: 2 additions & 1 deletion docs/environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ channels:
- conda-forge
- defaults
dependencies:
- setuptools<82
- wheel<0.45
- fenics
- python>=3.10
- matplotlib==3.7.1
Expand All @@ -16,4 +18,3 @@ dependencies:
- sphinxcontrib-bibtex
- sphinx-copybutton
- pillow
- sphinxcontrib-images
1 change: 0 additions & 1 deletion docs/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,6 @@
"sphinx_design",
"sphinxcontrib.bibtex",
"matplotlib.sphinxext.plot_directive",
"sphinxcontrib.images",
]

suppress_warnings = ["autosectionlabel.*"]
Expand Down
2 changes: 1 addition & 1 deletion docs/source/theory.rst
Original file line number Diff line number Diff line change
Expand Up @@ -299,7 +299,7 @@ introducing hydrogen surface species :math:`c_\mathrm{s}\,[\mathrm{m}^{-2}]`.

Evolution of hydrogen surface concentration is determined by the atomic flux balance at the surface, as sketched in the simplified energy diagram below.

.. thumbnail:: images/potential_diagram.png
.. figure:: images/potential_diagram.png
:align: center
:width: 800

Expand Down
2 changes: 1 addition & 1 deletion docs/source/userguide/beginners_guide.rst
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ Your first FESTIM script
------------------------


Follow `this tutorial <https://github.com/festim-dev/FESTIM-workshop/blob/main/tasks/task01.ipynb>`_ to learn how
Follow `this tutorial <https://festim-workshop.readthedocs.io/en/latest/content/task01.html>`_ to learn how
to run a simple 1D diffusion problem in steady state with an homogeneous temperature, a volumetric source of hydrogen,
and the concentration fixed at zero at boundaries.

4 changes: 2 additions & 2 deletions docs/source/userguide/export_post_processing.rst
Original file line number Diff line number Diff line change
Expand Up @@ -70,13 +70,13 @@ The file can then be opened in Paraview or any other software that can read XDMF

- Open the XDMF file then select the reader Xdmf3 Reader S

.. thumbnail:: ../images/paraview_guide_1.png
.. figure:: ../images/paraview_guide_1.png
:width: 400
:align: center

- Edit the colour map and rescale the colourbar to present the proper view of results

.. thumbnail:: ../images/paraview_guide_2.png
.. figure:: ../images/paraview_guide_2.png
:width: 400
:align: center

Expand Down
44 changes: 22 additions & 22 deletions docs/source/userguide/mesh.rst
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ The following is a workflow using the python API to make a mesh that can be dire

Here we will walk through GMSH's usage when creating a monoblock subsection consisting of tungsten surrounding a tube of CuCrZr

.. thumbnail:: ../images/gmsh_tut_1.png
.. figure:: ../images/gmsh_tut_1.png
:width: 400
:align: center

Expand Down Expand Up @@ -205,7 +205,7 @@ At any point, the GMSH GUI can be opened by running the line
after synchronizing the model.
Running this command at this stage will open the GUI, displaying something that looks like this:

.. thumbnail:: ../images/gmsh_tut_2.png
.. figure:: ../images/gmsh_tut_2.png
:width: 400
:align: center

Expand All @@ -226,13 +226,13 @@ GMSH assigns the surface labels cyclically when performing the extrusion, so the
After opening the GUI, again after synchronising and using `gmsh.fltk.run()`, go into 'Tools' then 'Options', and ensure that 'Surfaces' is checked under 'Geometry'.
This will make the surfaces are visible and selectable in the visualisation.

.. thumbnail:: ../images/gmsh_tut_3.png
.. figure:: ../images/gmsh_tut_3.png
:width: 400
:align: center

We can then hover our mouse over each surface to see its information. For example, we can see that the front tungsten surface is defined as Plane 7, and borders the volume 1.

.. thumbnail:: ../images/gmsh_tut_4.png
.. figure:: ../images/gmsh_tut_4.png
:width: 400
:align: center

Expand Down Expand Up @@ -379,7 +379,7 @@ A FESTIM simulation can then be run:

This produces the following visualisation in Paraview:

.. thumbnail:: ../images/gmsh_tut_5.png
.. figure:: ../images/gmsh_tut_5.png
:width: 400
:align: center

Expand All @@ -395,82 +395,82 @@ Building the geometry in SALOME
1. Open SALOME and create a new study.
2. Activate the Geometry module

.. thumbnail:: ../images/salome_guide_1.png
.. figure:: ../images/salome_guide_1.png
:width: 400
:align: center

3. Create a first square by clicking "Create rectangular face". Keep the default parameters. Click "Apply and Close"

.. thumbnail:: ../images/salome_guide_2.png
.. figure:: ../images/salome_guide_2.png
:width: 400
:align: center

4. Repeat the operation to create a second square

5. Translate the second square by clicking "Operations/Transformation/Translation"

.. thumbnail:: ../images/salome_guide_3.png
.. figure:: ../images/salome_guide_3.png
:width: 400
:align: center

6. Make sure Face 2 is selected. Enter 100 for the Dx value. Click "Apply and Close"

.. thumbnail:: ../images/salome_guide_4.png
.. figure:: ../images/salome_guide_4.png
:width: 400
:align: center

7. Create a compound by clicking "New Entity/Build/Compound" make sure Face_1 and Translation_1 are selected then click "Apply and Close".

.. thumbnail:: ../images/salome_guide_5.png
.. figure:: ../images/salome_guide_5.png
:width: 400
:align: center

8. Create a group "New Entity/Group/Create group". In Shape Type, select the 2D surface. Name the group "left_volume". Make sure Compound_1 is selected.
Click on the left square and click "Add" (2 should appear in the white window). Click "Apply and Close".

.. thumbnail:: ../images/salome_guide_6.png
.. figure:: ../images/salome_guide_6.png
:width: 400
:align: center

9. Repeat the operation to create a group "right_volume" with the right square (12 should appear in the white window).

10. Create another group "left_boundary" but this time in Shape Type select the 1D curve. Click on the left edge of the left square and click "Add". Click "Apply and Close".

.. thumbnail:: ../images/salome_guide_7.png
.. figure:: ../images/salome_guide_7.png
:width: 400
:align: center

11. Repeat the operation to create a group "right_boundary" with the right edge of the right square. Your study should look like:

.. thumbnail:: ../images/salome_guide_8.png
.. figure:: ../images/salome_guide_8.png
:width: 400
:align: center

12. Click on "Mesh" to activate the mesh module.

.. thumbnail:: ../images/salome_guide_9.png
.. figure:: ../images/salome_guide_9.png
:width: 400
:align: center

13. Create a mesh by clicking "Mesh/Create Mesh".

14. Make sure Compound_1 is selected in "Geometry". Under the 2D tab, select "NETGEN 1D-2D" as algorithm.

.. thumbnail:: ../images/salome_guide_10.png
.. figure:: ../images/salome_guide_10.png
:width: 400
:align: center

15. Next to "Hypothesis" click on the gear symbol. Select "NETGEN 2D Simple Parameters". Click Ok. Click "Apply and Close".

.. thumbnail:: ../images/salome_guide_11.png
.. figure:: ../images/salome_guide_11.png
:width: 400
:align: center

In the Objet Browser, under Mesh_1 you should see Groups of Edges and Groups of Faces, containing left_boundary, right_boundary, left_volume and right_volume.

16. Export the mesh to MED by right clicking on Mesh_1 in the Object Browser, then Export/MED file. Choose a location where you want to write your MED file and click Save.

.. thumbnail:: ../images/salome_guide_12.png
.. figure:: ../images/salome_guide_12.png
:width: 400
:align: center

Expand Down Expand Up @@ -548,7 +548,7 @@ Here, the left volume is tagged with ID 6, the right boundary is tagged with ID

18. Inspect the produced XDMF files with Paraview using the XDMF3 S reader. The file mesh_domains.xdmf should look like:

.. thumbnail:: ../images/salome_guide_13.png
.. figure:: ../images/salome_guide_13.png
:width: 400
:align: center

Expand Down Expand Up @@ -587,7 +587,7 @@ Here, the left volume is tagged with ID 6, the right boundary is tagged with ID

20. The simulation should run without errors. The solute field can be visualised with Paraview.

.. thumbnail:: ../images/salome_guide_14.png
.. figure:: ../images/salome_guide_14.png
:width: 400
:align: center

Expand All @@ -600,13 +600,13 @@ If you have a CAD model, you can export it to a mesh with SALOME.
2. Activate the Geometry module
3. Import STEP file by clicking "File/Import/STEP"

.. thumbnail:: ../images/salome_guide_cad_1.png
.. figure:: ../images/salome_guide_cad_1.png
:width: 400
:align: center

4. By clicking "Fit to selection" you can see the imported geometry:

.. thumbnail:: ../images/salome_guide_cad_2.png
.. figure:: ../images/salome_guide_cad_2.png
:width: 400
:align: center

Expand All @@ -620,6 +620,6 @@ If you have a CAD model, you can export it to a mesh with SALOME.
Meshes from FEniCS
------------------

See the `FEniCS documentation <https://fenicsproject.org/olddocs/dolfin/latest/python/demos/built-in-meshes/demo_built-in-meshes.py.html>`_ for more built-in meshes.
See the `FEniCS documentation <https://olddocs.fenicsproject.org/dolfin/latest/python/demos/built-in-meshes/demo_built-in-meshes.py.html>`_ for more built-in meshes.


2 changes: 1 addition & 1 deletion docs/source/userguide/sources.rst
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ Hydrogen implanted in a material can be simulated by a Gaussian-shaped volumetri
),
]

This class is used in `this tutorial <https://github.com/festim-dev/FESTIM-workshop/blob/main/tasks/task02.ipynb>`_.
This class is used in `this tutorial <https://festim-workshop.readthedocs.io/en/latest/content/task02.html>`_.


Radioactive decay
Expand Down
Loading