Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,7 @@ instance/

# Sphinx documentation
doc/_build/
doc/source/examples

# PyBuilder
.pybuilder/
Expand Down Expand Up @@ -161,4 +162,8 @@ PyMAPDL_Dev
doc/source/technology_showcase_examples/*.ipynb
doc/source/technology_showcase_examples/*.py
doc/source/technology_showcase_examples/*.md5
doc/source/technology_showcase_examples/*.pickle
doc/source/technology_showcase_examples/*.pickle

# Results generated during doc build and example run locally
examples/technology_showcase/out
examples/basic/out
17 changes: 0 additions & 17 deletions doc/source/basic_examples/_static/custom.css

This file was deleted.

225 changes: 0 additions & 225 deletions doc/source/basic_examples/basic/ex_01-valve.rst

This file was deleted.

Binary file not shown.
Binary file not shown.
41 changes: 0 additions & 41 deletions doc/source/basic_examples/index.rst

This file was deleted.

8 changes: 6 additions & 2 deletions doc/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
from datetime import datetime
import os

import ansys.mechanical.core
from ansys_sphinx_theme import ansys_favicon
from ansys_sphinx_theme import pyansys_logo_black as logo
import numpy as np
Expand Down Expand Up @@ -59,9 +60,9 @@
# convert rst to md for ipynb
"pypandoc": True,
# path to your examples scripts
"examples_dirs": ["../../examples/basic"],
"examples_dirs": ["../../examples/"],
# path where to save gallery generated examples
"gallery_dirs": ["basic"],
"gallery_dirs": ["examples"],
# Pattern to search for example files
"filename_pattern": r"\.py",
# Remove the "Download all examples" button from the top level gallery
Expand Down Expand Up @@ -126,6 +127,9 @@
if not os.path.exists(pyvista.FIGURE_PATH):
os.makedirs(pyvista.FIGURE_PATH)

# configure pymechanical for embedding
ansys.mechanical.core.BUILDING_GALLERY = True

# static path
html_static_path = ["_static"]

Expand Down
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
31 changes: 9 additions & 22 deletions doc/source/index.rst
Original file line number Diff line number Diff line change
@@ -1,33 +1,20 @@
.. _sphx_glr_pymechanical_embedding_examples:

PyMechanical Embedding Examples
===============================

Embedding examples for `PyMechanical <_pymechanical_docs>`_ are contained in this repository.

.. === EXAMPLES Gallery ===

.. === BASIC EXAMPLES ===

Basic Examples
==============


These demonstrate basic simulation capabilities of Ansys Mechanical.
The problems demonstrate how to use the embedding feature of PyMechanical to
effectively and accurately solve interdisciplinary problems from a variety of
industries and engineering fields.

Summary of the exposed basic examples
--------------------------------------
..
We have to include this rather than include it in a tree.

.. include:: ./basic_examples/index.rst
:start-line: 7
:end-line: 33
.. include:: examples/index.rst
:start-line: 2

.. === EXAMPLES ===
.. === Include examples/index to avoid warning but it is not shown ===

.. toctree::
:hidden:
:includehidden:
:hidden:
:includehidden:

basic_examples/index
examples/index
8 changes: 8 additions & 0 deletions examples/README.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
.. _ref_example_gallery:

Examples
========
End-to-end examples show how you can use pymechanical.

.. note::
Some examples require additional Python packages.
1 change: 0 additions & 1 deletion examples/basic/.gitignore

This file was deleted.

Loading