| README.md (0a1d75a00eef2c2b2c9cdfbd3bcf319dba0408f2) | README.md (2774d5cba221882c6b4100a2009c80f26d4c6f5c) |
|---|---|
| 1# libCEED: Examples 2 | 1# libCEED: Examples 2 |
| 3libCEED comes with several examples of its usage, ranging from standalone C 4codes to examples based on external packages,such as MFEM, PETSc and Nek5000. | 3This page provides a brief description of the examples for the libCEED library. |
| 5 6## Example 1 7 8This example uses the mass matrix to compute the length, area, or volume of a 9region, depending upon runtime parameters. 10 11## Bakeoff Problems 12 --- 11 unchanged lines hidden (view full) --- 24The supplied examples solve *_B_ u = f*, where *_B_* is the mass matrix. 25 26### Bakeoff Problem 3 27 28Bakeoff problem 1 is the Poisson problem. 29 30The supplied examples solve *_A_ u = f*, where *_A_* is the Poisson operator. 31 | 4 5## Example 1 6 7This example uses the mass matrix to compute the length, area, or volume of a 8region, depending upon runtime parameters. 9 10## Bakeoff Problems 11 --- 11 unchanged lines hidden (view full) --- 23The supplied examples solve *_B_ u = f*, where *_B_* is the mass matrix. 24 25### Bakeoff Problem 3 26 27Bakeoff problem 1 is the Poisson problem. 28 29The supplied examples solve *_A_ u = f*, where *_A_* is the Poisson operator. 30 |
| 31### Navier-Stokes Solver 32 33The Navier-Stokes problem solves the compressible Navier-Stokes equations using an explicit time integration. 34 |
|
| 32## Running Examples 33 34To build the examples, set the `MFEM_DIR`, `PETSC_DIR` and `NEK5K_DIR` variables 35and run: 36 37```console 38# libCEED examples on CPU and GPU 39cd ceed --- 11 unchanged lines hidden (view full) --- 51 52# PETSc+libCEED examples on CPU and GPU 53cd petsc 54make 55./bp1 -ceed /cpu/self 56./bp1 -ceed /gpu/occa 57cd ../.. 58 | 35## Running Examples 36 37To build the examples, set the `MFEM_DIR`, `PETSC_DIR` and `NEK5K_DIR` variables 38and run: 39 40```console 41# libCEED examples on CPU and GPU 42cd ceed --- 11 unchanged lines hidden (view full) --- 54 55# PETSc+libCEED examples on CPU and GPU 56cd petsc 57make 58./bp1 -ceed /cpu/self 59./bp1 -ceed /gpu/occa 60cd ../.. 61 |
| 62cd navier-stokes 63make 64./navierstokes -ceed /cpu/self 65./navierstokes -ceed /gpu/occa 66cd ../.. 67 |
|
| 59# Nek+libCEED examples on CPU and GPU 60cd nek5000 61./make-nek-examples.sh 62./run-nek-example.sh -ceed /cpu/self -b 3 63./run-nek-example.sh -ceed /gpu/occa -b 3 64cd ../.. 65``` 66 67The above code assumes a GPU-capable machine with the OCCA backend 68enabled. Depending on the available backends, other Ceed resource specifiers can 69be provided with the `-ceed` option. | 68# Nek+libCEED examples on CPU and GPU 69cd nek5000 70./make-nek-examples.sh 71./run-nek-example.sh -ceed /cpu/self -b 3 72./run-nek-example.sh -ceed /gpu/occa -b 3 73cd ../.. 74``` 75 76The above code assumes a GPU-capable machine with the OCCA backend 77enabled. Depending on the available backends, other Ceed resource specifiers can 78be provided with the `-ceed` option. |