Actual source code: ex49.c
1: static char help[] = "Test basic DMProduct operations.\n\n";
3: #include <petscdm.h>
4: #include <petscdmproduct.h>
6: int main(int argc, char **argv)
7: {
8: DM dm;
9: PetscInt dim;
12: PetscInitialize(&argc, &argv, (char *)0, help);
13: dim = 1;
14: PetscOptionsGetInt(NULL, NULL, "-dim", &dim, NULL);
15: DMCreate(PETSC_COMM_WORLD, &dm);
16: DMSetType(dm, DMPRODUCT);
17: DMSetDimension(dm, dim);
18: DMSetFromOptions(dm);
19: DMSetUp(dm);
20: DMDestroy(&dm);
21: PetscFinalize();
22: return 0;
23: }
25: /*TEST
27: test:
28: suffix: basic_1
30: TEST*/