Examples
ex1.c: Tests solving linear system on 0 by 0 matrix, and KSPLSQR convergence test handling.
ex10.c: Linear elastiticty with dimensions using 20 node serendipity elements.
ex11.c: Solves a Q1-P0 Stokes problem from Underworld.
ex12f.F90:
ex13.c:
ex14.c: Solves a nonlinear system in parallel with a user-defined Newton method.
ex15.c: KSP linear solver on an operator with a null space.
ex16f.F90:
ex17.c: Solves a linear system with KSP. This problem is
ex18.c: Reads a PETSc matrix and vector from a file and solves a linear system.
ex19.c: Solvers Laplacian with multigrid, bad way.
ex2.c: Tests repeated solving linear system on 2 by 2 matrix provided by MUMPS developer, Dec 17, 2012.
ex20.c: Bilinear elements on the unit square for Laplacian. To test the parallel
ex21.c: Tests MatGetSchurComplement
ex22.c: Test MatNest solving a linear system
ex23.c: Test whether KSPSolve() can be executed without zeroing output for KSPPREONLY";
ex24.c: Tests CG, MINRES and SYMMLQ on symmetric matrices with SBAIJ format. The preconditioner ICC only works on sequential SBAIJ format.
ex25.c: Tests CG, MINRES and SYMMLQ on the symmetric indefinite matrices: afiro
ex26.c: Solves Laplacian with multigrid. Tests block API for PCMG
ex27.c: Reads a PETSc matrix and vector from a file and solves a linear system.
ex28.c: Test procedural KSPSetFromOptions() or at runtime; Test PCREDUNDANT.
ex29.c: Tests ML interface. Modified from ~src/ksp/ksp/tests/ex19.c
ex3.c: Bilinear elements on the unit square for Laplacian. To test the parallel
ex30.c: Reads a PETSc matrix and vector from a file and solves a linear system.
ex31.c: Test partition. Reads a PETSc matrix and vector from a file and solves a linear system.
ex32.c:
ex33.c: Test MatGetInertia().
ex34.c: Tests solving linear system with KSPFGMRES + PCSOR (omega != 1) on a matrix obtained from MatTransposeMatMult.
ex37.c: Test MatGetMultiProcBlock() and MatCreateRedundantMatrix()
ex38.c:
ex39.c:
ex4.c: Bilinear elements on the unit square for the Laplacian. Input arguments are:
ex40.c: Solves a linear system in parallel with KSP.
ex42.c: Solves a linear system in parallel with MINRES.
ex43.c: Reads a PETSc matrix from a file and solves a linear system
ex44.c: Solves a tridiagonal linear system. Designed to compare SOR for different Mat impls.
ex45.c:
ex47.c:
ex48.c: Solves a tridiagonal linear system with KSP.
ex49.c: Tests SeqSBAIJ factorizations for different block sizes
ex5.c: Tests MATLMVM classes.
ex50.c: Tests point block Jacobi and ILU for different block sizes
ex51.c: Test PCFailedReason.
ex52f.F90:
ex53.c: Tests setup PCFIELDSPLIT with blocked IS.
ex54.c:
ex54f.F90:
ex55.c: Example demonstrating PCCOMPOSITE where one of the inner PCs uses a different operator
ex57.c:
ex58.c: Solves a tridiagonal linear system with KSP.
ex5f.F90:
ex6.c: Reads a PETSc matrix and vector from a file and solves a linear system.
ex60.c: Working out corner cases of the ASM preconditioner.
ex61.c: * Example code testing SeqDense matrices with an LDA (leading dimension of the user-allocated array) larger than M.
ex62f.F90:
ex63.cxx:
ex7.c: Illustrate how to solves a matrix-free linear system with KSP.
ex70.c: Solves an ill-conditioned tridiagonal linear system with KSP for testing GMRES breakdown tolerance.
ex71f.F90:
ex8.c: Solves a linear system in parallel with KSP.
ex80.c: Test the Fischer-3 initial guess routine.
ex81.c: Test different KSP and Mat prefixes.
ex82.c: Uses KSPComputeRitz() on a matrix loaded from disk
ex83.c: Test the Fischer-1 initial guess routine with VECNEST.
ex84.c: Solves a Q2-Q1 Navier-Stokes problem.
ex85.c: Estimate eigenvalues with KSP.
ex86f.F90:
ex87.c: Block-structured Nest matrix involving a HermitianTranspose block.
ex9.c: Tests repeated setups and solves of PCFIELDSPLIT.
lostnullspace.c: Losing nullspaces in PCFIELDSPLIT after zeroing rows.
Directories