=========
Tutorials
=========

This page provides connections to PETSc tutorial examples by type of physics being modeled,
discretization technique being used, solvers used, etc.

.. toctree::
  :maxdepth: 2

  guide_to_examples_by_physics
  handson
  meshing/guide_to_subsurface
  performance/guide_to_TAS
  in_person

In addition, PETSc has many additionally poorly curated tutorial examples, found in the ``tutorials/``
directories throughout the PETSc ``src/`` tree.

- `Linear problems <PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/ksp/ksp/tutorials/index.html>`__
- `Nonlinear problems <PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/snes/tutorials/index.html>`__
- `Time integration <PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/ts/tutorials/index.html>`__
- Optimization

  - `Least-squares <PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/leastsquares/tutorials/index.html>`__ (Manual: :any:`sec_tao_leastsquares`)
  - `Quadratic <PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/quadratic/tutorials/index.html>`__  (Manual: :any:`sec_tao_quadratic`)
  - `Unconstrained <PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/unconstrained/tutorials/index.html>`__ (Manual: :any:`sec_tao_unconstrained`)
  - `Bound <PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/bound/tutorials/index.html>`__ (Manual: :any:`sec_tao_bound`)
  - `Constrained <PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/constrained/tutorials/index.html>`__ (Manual: :any:`sec_tao_constrained`)
  - `Complementarity <PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/complementarity/tutorials/index.html>`__ (Manual: :any:`sec_tao_complementary`)
  - `PDE constrained <PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/pde_constrained/tutorials/index.html>`__ (Manual: :any:`sec_tao_pde_constrained`)