Skip to content

Commit

Permalink
Doc: Improve examples
Browse files Browse the repository at this point in the history
* Updated TensorProductExperiment_doc.i.in. Used the vect macros.

* Update SmolyakExperiment_doc.i.in. Used the vect macros.

* Update EnumerateFunctionImplementation_doc.i.in

Use the vect macros.
Removed unnecessary blank lines.
Clarified meaning of multi-indices.

* Update plot_kriging_beam_trend.py and plot_kriging_chose_trend.py.

* Update plot_kriging_chose_trend.py. Added links between trend examples.
  • Loading branch information
mbaudin47 authored Jul 13, 2023
1 parent 8e2b86c commit 1d861ea
Show file tree
Hide file tree
Showing 7 changed files with 306 additions and 297 deletions.
Original file line number Diff line number Diff line change
@@ -1,12 +1,15 @@
"""
Configuring an arbitrary trend in Kriging
=========================================
Kriging: choose an arbitrary trend
==================================
"""
# %%
# The goal of this example is to show how to configure an arbitrary trend in a Kriging metamodel.
# In the :doc:`/auto_meta_modeling/kriging_metamodel/plot_kriging_chose_trend`
# and :doc:`/auto_meta_modeling/kriging_metamodel/plot_kriging_beam_trend` examples,
# we show how to configure a polynomial trend.
#
# In general, any collection of multivariate functions can be used as the
# `basis` argument of a `KrigingAlgorithm`.
# `basis` argument of a :class:`~openturns.KrigingAlgorithm`.
# In practice, it might not be convenient to create a multivariate basis and
# this is why we sometimes create it by tensorization of univariate functions.
# In this example, we first use Legendre polynomials as our univariate functions,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,14 +1,17 @@
"""
Choose the trend basis of a kriging metamodel
=============================================
Kriging: choose a polynomial trend on the beam model
====================================================
"""
# %%
# The goal of this example is to show how to configure the trend in a Kriging metamodel.
# This is why this example focuses on the three available trends:
# This example focuses on three polynomial trends:
#
# * `ConstantBasisFactory`,
# * `LinearBasisFactory`,
# * `QuadraticBasisFactory`.
# * :class:`~openturns.ConstantBasisFactory`,
# * :class:`~openturns.LinearBasisFactory`,
# * :class:`~openturns.QuadraticBasisFactory`.
#
# In the :doc:`/auto_meta_modeling/kriging_metamodel/plot_kriging_chose_trend` example,
# we give another example of this procedure.
#
# For this purpose, we use the :ref:`cantilever beam <use-case-cantilever-beam>` example.

Expand Down Expand Up @@ -43,7 +46,7 @@

# %%
# We consider a simple Monte-Carlo sampling as a design of experiments.
# This is why we generate an input sample using the `getSample` method of the distribution.
# This is why we generate an input sample using the :meth:`~openturns.Distribution.getSample` method of the distribution.
# Then we evaluate the output using the `model` function.

# %%
Expand Down
Loading

0 comments on commit 1d861ea

Please sign in to comment.