petsc-3.6.1 2015-08-06
Report Typos and Errors
CFLAGS	        =
FFLAGS	        =
CPPFLAGS        =
FPPFLAGS        =
LOCDIR          = src/dm/examples/tests/
EXAMPLESC       = ex1.c ex2.c ex3.c ex4.c ex6.c ex7.c ex8.c ex9.c ex10.c\
                  ex11.c ex12.c ex12.m ex13.c ex14.c ex15.c ex16.c ex17.c ex19.c ex20.c \
	          ex21.c ex22.c ex23.c ex24.c ex25.c ex26.c ex27.c ex28.c ex30.c \
	          ex31.c ex32.c ex34.c ex36.c ex37.c ex38.c ex39.c ex40.c ex41.c \
	          ex42.c ex43.c
EXAMPLESF       =
MANSEC          = DM

include ${PETSC_DIR}/lib/petsc/conf/variables
include ${PETSC_DIR}/lib/petsc/conf/rules

ex1: ex1.o   chkopts
	-${CLINKER} -o ex1 ex1.o  ${PETSC_DM_LIB}
	${RM} -f ex1.o

ex2: ex2.o  chkopts
	-${CLINKER} -o ex2 ex2.o  ${PETSC_DM_LIB}
	${RM} -f ex2.o

ex3: ex3.o  chkopts
	-${CLINKER} -o ex3 ex3.o  ${PETSC_DM_LIB}
	${RM} -f ex3.o

ex4: ex4.o   chkopts
	-${CLINKER} -o ex4 ex4.o  ${PETSC_DM_LIB}
	${RM} -f ex4.o

ex5: ex5.o  chkopts
	-${CLINKER} -o ex5 ex5.o  ${PETSC_DM_LIB}
	${RM} -f ex5.o

ex6: ex6.o   chkopts
	-${CLINKER} -o ex6 ex6.o  ${PETSC_DM_LIB}
	${RM} -f ex6.o

ex7: ex7.o   chkopts
	-${CLINKER} -o ex7 ex7.o  ${PETSC_DM_LIB}
	${RM} -f ex7.o

ex8: ex8.o   chkopts
	-${CLINKER} -o ex8 ex8.o  ${PETSC_DM_LIB}
	${RM} -f ex8.o

ex9: ex9.o   chkopts
	-${CLINKER} -o ex9 ex9.o  ${PETSC_DM_LIB}
	${RM} -f ex9.o

ex10: ex10.o   chkopts
	-${CLINKER} -o ex10 ex10.o  ${PETSC_DM_LIB}
	${RM} -f ex10.o

ex11: ex11.o   chkopts
	-${CLINKER} -o ex11 ex11.o  ${PETSC_DM_LIB}
	${RM} -f ex11.o

ex12: ex12.o   chkopts
	-${CLINKER} -o ex12 ex12.o  ${PETSC_DM_LIB}
	${RM} -f ex12.o

ex13: ex13.o   chkopts
	-${CLINKER} -o ex13 ex13.o  ${PETSC_DM_LIB}
	${RM} -f ex13.o

ex14: ex14.o   chkopts
	-${CLINKER} -o ex14 ex14.o  ${PETSC_DM_LIB}
	${RM} -f ex14.o

ex15: ex15.o   chkopts
	-${CLINKER} -o ex15 ex15.o  ${PETSC_DM_LIB}
	${RM} -f ex15.o

ex16: ex16.o   chkopts
	-${CLINKER} -o ex16 ex16.o  ${PETSC_DM_LIB}
	${RM} -f ex16.o

ex17: ex17.o   chkopts
	-${CLINKER} -o ex17 ex17.o  ${PETSC_DM_LIB}
	${RM} -f ex17.o

ex18: ex18.o   chkopts
	-${CLINKER} -o ex18 ex18.o  ${PETSC_DM_LIB}
	${RM} -f ex18.o

ex19: ex19.o   chkopts
	-${CLINKER} -o ex19 ex19.o  ${PETSC_DM_LIB}
	${RM} -f ex19.o

ex20: ex20.o   chkopts
	-${CLINKER} -o ex20 ex20.o  ${PETSC_DM_LIB}
	${RM} -f ex20.o

ex21: ex21.o   chkopts
	-${CLINKER} -o ex21 ex21.o  ${PETSC_DM_LIB}
	${RM} -f ex21.o

ex22: ex22.o   chkopts
	-${CLINKER} -o ex22 ex22.o  ${PETSC_DM_LIB}
	${RM} -f ex22.o

ex23: ex23.o   chkopts
	-${CLINKER} -o ex23 ex23.o  ${PETSC_DM_LIB}
	${RM} -f ex23.o

ex24: ex24.o   chkopts
	-${CLINKER} -o ex24 ex24.o  ${PETSC_DM_LIB}
	${RM} -f ex24.o

ex25: ex25.o   chkopts
	-${CLINKER} -o ex25 ex25.o  ${PETSC_DM_LIB}
	${RM} -f ex25.o

ex26: ex26.o   chkopts
	-${CLINKER} -o ex26 ex26.o  ${PETSC_DM_LIB}
	${RM} -f ex26.o

ex27: ex27.o   chkopts
	-${CLINKER} -o ex27 ex27.o  ${PETSC_DM_LIB}
	${RM} -f ex27.o

ex28: ex28.o   chkopts
	-${CLINKER} -o ex28 ex28.o  ${PETSC_DM_LIB}
	${RM} -f ex28.o

ex29: ex29.o   chkopts
	-${CLINKER} -o ex29 ex29.o  ${PETSC_DM_LIB}
	${RM} -f ex29.o

ex30: ex30.o   chkopts
	-${CLINKER} -o ex30 ex30.o  ${PETSC_DM_LIB}
	${RM} -f ex30.o

ex31: ex31.o   chkopts
	-${CLINKER} -o ex31 ex31.o  ${PETSC_DM_LIB}
	${RM} -f ex31.o

ex32: ex32.o   chkopts
	-${CLINKER} -o ex32 ex32.o  ${PETSC_DM_LIB}
	${RM} -f ex32.o
ex33: ex33.o   chkopts
	-${CLINKER} -o ex33 ex33.o  ${PETSC_DM_LIB}
	${RM} -f ex33.o
ex34: ex34.o   chkopts
	-${CLINKER} -o ex34 ex34.o  ${PETSC_DM_LIB}
	${RM} -f ex34.o
ex35: ex35.o   chkopts
	-${CLINKER} -o ex35 ex35.o  ${PETSC_DM_LIB}
	${RM} -f ex35.o
ex36: ex36.o   chkopts
	-${CLINKER} -o ex36 ex36.o  ${PETSC_DM_LIB}
	${RM} -f ex36.o
ex37: ex37.o   chkopts
	-${CLINKER} -o ex37 ex37.o  ${PETSC_DM_LIB}
	${RM} -f ex37.o
ex38:ex38.o   chkopts
	-${CLINKER} -o ex38 ex38.o  ${PETSC_DM_LIB}
	${RM} -f ex38.o
ex39:ex39.o   chkopts
	-${CLINKER} -o ex39 ex39.o  ${PETSC_DM_LIB}
	${RM} -f ex39.o
ex40:ex40.o   chkopts
	-${CLINKER} -o ex40 ex40.o  ${PETSC_DM_LIB}
	${RM} -f ex40.o
ex41:ex41.o   chkopts
	-${CLINKER} -o ex41 ex41.o  ${PETSC_DM_LIB}
	${RM} -f ex41.o
ex42:ex42.o   chkopts
	-${CLINKER} -o ex42 ex42.o  ${PETSC_DM_LIB}
	${RM} -f ex42.o
ex43:ex43.o   chkopts
	-${CLINKER} -o ex43 ex43.o  ${PETSC_DM_LIB}
	${RM} -f ex43.o
#-------------------------------------------------------------------------------
runex1:
	-@${MPIEXEC} -n 2 ./ex1 -nox | grep -v -i Object > ex1_1.tmp 2>&1;	  \
	   if (${DIFF} output/ex1_1.out ex1_1.tmp) then true; \
	   else printf "${PWD}\nPossible problem with ex1_1, diffs above\n=========================================\n"; fi; \
	   ${RM} -f ex1_1.tmp
runex1_cusp1:
	-@${MPIEXEC} -n 1 ./ex1 -dm_vec_type cusp -nox | grep -v -i Object > ex1_cusp1.tmp 2>&1;	  \
	   if (${DIFF} output/ex1_cusp1.out ex1_cusp1.tmp) then true; \
	   else printf "${PWD}\nPossible problem with with ex1_cusp1, diffs above\n=========================================\n"; fi; \
	   ${RM} -f ex1_cusp1.tmp
runex1_cusp2:
	-@${MPIEXEC} -n 2 ./ex1 -dm_vec_type cusp -nox | grep -v -i Object > ex1_cusp2.tmp 2>&1;	  \
	   if (${DIFF} output/ex1_cusp2.out ex1_cusp2.tmp) then true; \
	   else printf "${PWD}\nPossible problem with with ex1_cusp2, diffs above\n=========================================\n"; fi; \
	   ${RM} -f ex1_cusp2.tmp
runex2:
	-@${MPIEXEC} -n 2 ./ex2 -nox | grep -v "MPI processes" > ex2_1.tmp 2>&1;	  \
	   if (${DIFF} output/ex2_1.out ex2_1.tmp) then true; \
	   else printf "${PWD}\nPossible problem with ex2_1, diffs above\n=========================================\n"; fi; \
	   ${RM} -f ex2_1.tmp
runex2_2:
	-@${MPIEXEC} -n 3 ./ex2 -wrap none -local_print -nox > ex2_2.tmp 2>&1;	  \
	   if (${DIFF} output/ex2_2.out ex2_2.tmp) then true; \
	   else printf "${PWD}\nPossible problem with ex2_2, diffs above\n=========================================\n"; fi; \
	   ${RM} -f ex2_2.tmp
runex2_3:
	-@${MPIEXEC} -n 3 ./ex2 -wrap ghosted -local_print -nox > ex2_3.tmp 2>&1;	  \
	   if (${DIFF} output/ex2_3.out ex2_3.tmp) then true; \
	   else printf "${PWD}\nPossible problem with ex2_3, diffs above\n=========================================\n"; fi; \
	   ${RM} -f ex2_3.tmp
runex3:
	-@${MPIEXEC} -n 3 ./ex3 -time 50 -nox
runex4:
	-@${MPIEXEC} -n 4 ./ex4  -nox  | grep -v -i Object > ex4_1.tmp 2>&1;	  \
	   if (${DIFF} output/ex4_1.out ex4_1.tmp) then true; \
	   else printf "${PWD}\nPossible problem with ex4_1, diffs above\n=========================================\n"; fi; \
	   ${RM} -f ex4_1.tmp
runex4_2:
	-@${MPIEXEC} -n 1 ./ex4 -testorder -nox
runex6:
	-@${MPIEXEC} -n 6 ./ex6 -testorder -nox

runex7:
	-@${MPIEXEC} -n 8 ./ex7 -dof 3 -stencil_width 2 -M 50 -N 50 -periodic > ex7_1.tmp 2>&1;	  \
	   if (${DIFF} output/ex7_1.out ex7_1.tmp) then true; \
	   else printf "${PWD}\nPossible problem with ex7_1, diffs above\n=========================================\n"; fi; \
	   ${RM} -f ex7_1.tmp

runex7_2:
	-@${MPIEXEC} -n 8 ./ex7 -dof 3 -stencil_width 2 -M 50 -N 50 -periodic -grid2d > ex7_1.tmp 2>&1;	  \
	   if (${DIFF} output/ex7_1.out ex7_1.tmp) then true; \
	   else printf "${PWD}\nPossible problem with ex7_2, diffs above\n=========================================\n"; fi; \
	   ${RM} -f ex7_1.tmp

runex7_3:
	-@${MPIEXEC} -n 8 ./ex7 -dof 3 -stencil_width 2 -M 50 -N 50 -periodic -grid3d > ex7_1.tmp 2>&1;	  \
	   if (${DIFF} output/ex7_1.out ex7_1.tmp) then true; \
	   else printf "${PWD}\nPossible problem with ex7_2, diffs above\n=========================================\n"; fi; \
	   ${RM} -f ex7_1.tmp

runex11:
	-@${MPIEXEC} -n 1 ./ex11 -dof 2  | grep -v -i Object > ex11_1.tmp 2>&1;	  \
	   if (${DIFF} output/ex11_1.out ex11_1.tmp) then true; \
	   else printf "${PWD}\nPossible problem with ex11_1, diffs above\n=========================================\n"; fi; \
	   ${RM} -f ex11_1.tmp

runex11_2:
	-@${MPIEXEC} -n 2 ./ex11 -dof 2  | grep -v -i Object > ex11_2.tmp 2>&1;	  \
	   if (${DIFF} output/ex11_2.out ex11_2.tmp) then true; \
	   else printf "${PWD}\nPossible problem with ex11_2, diffs above\n=========================================\n"; fi; \
	   ${RM} -f ex11_2.tmp

runex11_3:
	-@${MPIEXEC} -n 3 ./ex11 -dof 2  | grep -v -i Object > ex11_3.tmp 2>&1;	  \
	   if (${DIFF} output/ex11_3.out ex11_3.tmp) then true; \
	   else printf "${PWD}\nPossible problem with ex11_3, diffs above\n=========================================\n"; fi; \
	   ${RM} -f ex11_3.tmp

runex12:
	-@echo "path([getenv('PETSC_DIR') '/share/petsc/matlab'],path); path([getenv('PETSC_DIR') '/' getenv('PETSC_ARCH') '/lib/petsc/matlab'],path); ex12(2) ; exit" | ${MATLAB_COMMAND} -nodesktop -display ${DISPLAY} > ex12_1.tmp 2>&1; grep -v flops ex12_1.tmp | grep -v Completed | grep -v About | grep -v Color | grep -v "at line 27" > ex12_1.tmp2 ; if (${DIFF} output/ex12_1.out ex12_1.tmp2) then true; \
	   else printf "${PWD}\nPossible problem with PETSC SOCKET MATLAB INTERFACE ex12_1, diffs above\n=========================================\n"; fi; \
	   ${RM} -f ex12_1.tmp ex12_1.tmp2

# ex13 uses the output of ex14
runex13:
	-@${MPIEXEC} -n 3 ./ex13
	-@${RM} -f daoutput daoutput.info
runex14:
	-@${MPIEXEC} -n 4 ./ex14 ; sleep 1

runex16:
	-@${MPIEXEC} -n 3 ./ex16 > ex16_1.tmp 2>&1; \
	  ${DIFF} output/ex16_1.out ex16_1.tmp || printf "${PWD}\nPossible problem with ex16, diffs above\n=========================================\n"; \
	  ${RM} -f ex16_1.tmp
runex16_2:
	-@${MPIEXEC} -n 3 ./ex16 -gather_add > ex16_2.tmp 2>&1; \
	  ${DIFF} output/ex16_2.out ex16_2.tmp || printf "${PWD}\nPossible problem with ex16_2, diffs above\n=========================================\n"; \
	  ${RM} -f ex16_2.tmp

runex21:
	-@for procs in '-da_processors_x 10' '-da_processors_y 10' '-da_processors_z 10' ''; do \
            ${MPIEXEC} -n 10 ./ex21 -mx 30 -my 30 -mz 30 -periodic 0 $procs ;\
            ${MPIEXEC} -n 10 ./ex21 -mx 29 -my 30 -mz 30 -periodic 1 $procs ;\
            ${MPIEXEC} -n 10 ./ex21 -mx 30 -my 29 -mz 30 -periodic 2 $procs ;\
            ${MPIEXEC} -n 10 ./ex21 -mx 30 -my 30 -mz 29 -periodic 3 $procs ;\
          done;

runex23:
	-@for d in one two three; do \
            for np in 1 2 3 4; do \
              for dof in 1 2 3; do \
                for stencil_type in 0 1; do \
                  ${MPIEXEC} -n $$np ./ex23 $$d -dof $$dof -stencil_type $$stencil_type ;\
                done; \
              done; \
            done; \
          done;
runex23_2:
	-@${MPIEXEC} -n 2 ./ex23 -two -native > ex23_2.tmp 2>&1; \
         ${DIFF} output/ex23_2.out ex23_2.tmp || printf "${PWD}\nPossible problem with ex23_2, diffs above\n=========================================\n"; \
         ${RM} ex23_2.tmp

runex24:
	-@${MPIEXEC} -n 1 ./ex24  | grep -v -i Process > ex24_1.tmp 2>&1;	  \
	   if (${DIFF} output/ex24_1.out ex24_1.tmp) then true; \
	   else printf "${PWD}\nPossible problem with ex24_1 1 process, diffs above\n=========================================\n"; fi; ${RM} -f ex24_1.tmp
	-@${MPIEXEC} -n 2 ./ex24  | grep -v -i Process > ex24_1.tmp 2>&1;	  \
	   if (${DIFF} output/ex24_2.out ex24_1.tmp) then true; \
	   else printf "${PWD}\nPossible problem with ex24_1 2 processes, diffs above\n=========================================\n"; fi; ${RM} -f ex24_1.tmp
	-@${MPIEXEC} -n 3 ./ex24  | grep -v -i Process > ex24_1.tmp 2>&1;	  \
	   if (${DIFF} output/ex24_2.out ex24_1.tmp) then true; \
	   else printf "${PWD}\nPossible problem with ex24_1 3 processes, diffs above\n=========================================\n"; fi; ${RM} -f ex24_1.tmp
	-@${MPIEXEC} -n 4 ./ex24  | grep -v -i Process > ex24_1.tmp 2>&1;	  \
	   if (${DIFF} output/ex24_2.out ex24_1.tmp) then true; \
	   else printf "${PWD}\nPossible problem with ex24_1 4 processes, diffs above\n=========================================\n"; fi; ${RM} -f ex24_1.tmp
	-@${MPIEXEC} -n 5 ./ex24  | grep -v -i Process > ex24_1.tmp 2>&1;	  \
	   if (${DIFF} output/ex24_2.out ex24_1.tmp) then true; \
	   else printf "${PWD}\nPossible problem with ex24_1 5 processes, diffs above\n=========================================\n"; fi; ${RM} -f ex24_1.tmp
	-@${MPIEXEC} -n 6 ./ex24  | grep -v -i Process > ex24_1.tmp 2>&1;	  \
	   if (${DIFF} output/ex24_2.out ex24_1.tmp) then true; \
	   else printf "${PWD}\nPossible problem with ex24_1 6 processes, diffs above\n=========================================\n"; fi; ${RM} -f ex24_1.tmp

runex25:
	-@${MPIEXEC} -n 1 ./ex25  | grep -v -i Process > ex25_1.tmp 2>&1;	  \
	   if (${DIFF} output/ex25_1.out ex25_1.tmp) then true; \
	   else printf "${PWD}\nPossible problem with ex25_1 1 process, diffs above\n=========================================\n"; fi; ${RM} -f ex25_1.tmp
	-@${MPIEXEC} -n 2 ./ex25  | grep -v -i Process > ex25_1.tmp 2>&1;	  \
	   if (${DIFF} output/ex25_2.out ex25_1.tmp) then true; \
	   else printf "${PWD}\nPossible problem with ex25_1 2 processes, diffs above\n=========================================\n"; fi; ${RM} -f ex25_1.tmp
	-@${MPIEXEC} -n 3 ./ex25  | grep -v -i Process > ex25_1.tmp 2>&1;	  \
	   if (${DIFF} output/ex25_2.out ex25_1.tmp) then true; \
	   else printf "${PWD}\nPossible problem with ex25_1 3 processes, diffs above\n=========================================\n"; fi; ${RM} -f ex25_1.tmp
	-@${MPIEXEC} -n 4 ./ex25  | grep -v -i Process > ex25_1.tmp 2>&1;	  \
	   if (${DIFF} output/ex25_2.out ex25_1.tmp) then true; \
	   else printf "${PWD}\nPossible problem with ex25_1 4 processes, diffs above\n=========================================\n"; fi; ${RM} -f ex25_1.tmp
	-@${MPIEXEC} -n 5 ./ex25  | grep -v -i Process > ex25_1.tmp 2>&1;	  \
	   if (${DIFF} output/ex25_2.out ex25_1.tmp) then true; \
	   else printf "${PWD}\nPossible problem with ex25_1 5 processes, diffs above\n=========================================\n"; fi; ${RM} -f ex25_1.tmp
	-@${MPIEXEC} -n 6 ./ex25  | grep -v -i Process > ex25_1.tmp 2>&1;	  \
	   if (${DIFF} output/ex25_2.out ex25_1.tmp) then true; \
	   else printf "${PWD}\nPossible problem with ex25_1 6 processes, diffs above\n=========================================\n"; fi; ${RM} -f ex25_1.tmp

runex30:
	-@${MPIEXEC} -n 2 ./ex30 -bs 2 -block 0 -sliced_mat_type baij -alpha 10 -u0 0.1 > ex30_1.tmp; \
	   ${DIFF} output/ex30_1.out ex30_1.tmp || printf "${PWD}\nPossible problem with ex30_1, diffs above\n=========================================\n"; \
	   ${RM} -f ex30_1.tmp
runex30_2:
	-@${MPIEXEC} -n 2 ./ex30 -bs 2 -block 1 -sliced_mat_type aij -alpha 10 -u0 0.1 > ex30_2.tmp; \
	   ${DIFF} output/ex30_2.out ex30_2.tmp || printf "${PWD}\nPossible problem with ex30_2, diffs above\n=========================================\n"; \
	   ${RM} -f ex30_2.tmp
runex30_3:
	-@${MPIEXEC} -n 2 ./ex30 -bs 2 -block 0 -sliced_mat_type aij -alpha 10 -u0 0.1 > ex30_3.tmp; \
	   ${DIFF} output/ex30_3.out ex30_3.tmp || printf "${PWD}\nPossible problem with ex30_3, diffs above\n=========================================\n"; \
	   ${RM} -f ex30_3.tmp
runex31:
	-@${MPIEXEC} -n 2 ./ex31
runex32:
	-@${MPIEXEC} -n 2 ./ex32 > ex32_1.tmp; \
	  ${DIFF} output/ex32_1.out ex32_1.tmp || printf "${PWD}\nPossible problem with ex32, diffs above\n=========================================\n"; \
	  ${RM} -f ex32_1.tmp
runex34:
	-@${MPIEXEC} -n 12 ./ex34 -dm_view -dim 3 -da_grid_x 11 -da_grid_y 5 -da_grid_z 7 > ex34_1.tmp; \
	  ${DIFF} output/ex34_1.out ex34_1.tmp || printf "${PWD}\nPossible problem with ex34, diffs above\n=========================================\n"; \
	  ${RM} -f ex34_1.tmp

runex36_1d:
	-@${MPIEXEC} -n 1 ./ex36 -mx 10 -nl 6 -dim 1 > ex36_1d.tmp; \
	  ${DIFF} output/ex36_1d.out ex36_1d.tmp || printf "${PWD}\nPossible problem with ex36_1d, diffs above\n=========================================\n"; \
	  ${RM} -f ex36_1d.tmp

runex36_2d:
	-@${MPIEXEC} -n 1 ./ex36 -mx 10 -my 10 -nl 6 -dim 2 -cmap 0 > ex36_2d.tmp; \
	  ${MPIEXEC} -n 1 ./ex36 -mx 10 -my 10 -nl 6 -dim 2 -cmap 1 >> ex36_2d.tmp; \
	  ${MPIEXEC} -n 1 ./ex36 -mx 10 -my 10 -nl 6 -dim 2 -cmap 2 >> ex36_2d.tmp; \
	  ${MPIEXEC} -n 1 ./ex36 -mx 10 -my 10 -nl 6 -dim 2 -cmap 3 >> ex36_2d.tmp; \
	  ${DIFF} output/ex36_2d.out ex36_2d.tmp || printf "${PWD}\nPossible problem with ex36_2d, diffs above\n=========================================\n"; \
	  ${RM} -f ex36_2d.tmp
runex36_2dp1:
	-@${MPIEXEC} -n 32 ./ex36 -mx 10 -my 10 -nl 4 -dim 2 -cmap 3 -da_refine_x 3 -da_refine_y 4 > ex36_2dp1.tmp; \
	  ${DIFF} output/ex36_2dp1.out ex36_2dp1.tmp || printf "${PWD}\nPossible problem with ex36_2dp1, diffs above\n=========================================\n"; \
	  ${RM} -f ex36_2dp1.tmp
runex36_2dp2:
	-@${MPIEXEC} -n 32 ./ex36 -mx 10 -my 10 -nl 4 -dim 2 -cmap 3 -da_refine_x 3 -da_refine_y 1 > ex36_2dp2.tmp; \
	  ${DIFF} output/ex36_2dp2.out ex36_2dp2.tmp || printf "${PWD}\nPossible problem with ex36_2dp1, diffs above\n=========================================\n"; \
	  ${RM} -f ex36_2dp2.tmp

runex36_3d:
	-@${MPIEXEC} -n 1 ./ex36 -mx 5 -my 5 -mz 5 -nl 4 -dim 3 -cmap 3 > ex36_3d.tmp; \
	  ${DIFF} output/ex36_3d.out ex36_3d.tmp || printf "${PWD}\nPossible problem with ex36_3d, diffs above\n=========================================\n"; \
	  ${RM} -f ex36_3d.tmp

runex36_3dp1:
	-@${MPIEXEC} -n 32 ./ex36 -mx 5 -my 5 -mz 5 -nl 3 -dim 3 -cmap 1 -da_refine_x 1 -da_refine_y 3 -da_refine_z 4 > ex36_3dp1.tmp; \
	  ${DIFF} output/ex36_3dp1.out ex36_3dp1.tmp || printf "${PWD}\nPossible problem with ex36_3dp1, diffs above\n=========================================\n" ; \
	  ${RM} -f ex36_3dp1.tmp

runex37:
	-@${MPIEXEC} -n 2 ./ex37 ;\
	  ${RM} -f ex32_1.tmp

runex42:
	-@${MPIEXEC} -n 2 ./ex42 ;\
	  ${RM} -f 2d_nocoord.vtr 2d.vtr 3d_nocoord.vtr 3d.vtr

runex43:
	-@${MPIEXEC} -n 2 ./ex43 > ex43.tmp; \
	  ${DIFF} output/ex43_1.out ex43.tmp || printf "${PWD}\nPossible problem with 43, diffs above\n=========================================\n" ; \
	  ${RM} -f ex43.tmp

TESTEXAMPLES_C		  = ex2.PETSc runex2_2 runex2_3 ex2.rm ex1.PETSc runex1 ex1.rm ex4.PETSc runex4 runex4_2 ex4.rm ex15.PETSc ex15.rm ex16.PETSc ex16.rm \
                            ex21.PETSc runex21 ex21.rm ex24.PETSc runex24 ex24.rm ex25.PETSc \
                            runex25 ex25.rm ex30.PETSc runex30 runex30_2 runex30_3 ex30.rm ex31.PETSc runex31 ex31.rm ex32.PETSc runex32 ex32.rm \
                            ex34.PETSc runex34 ex34.rm ex36.PETSc runex36_1d runex36_2d runex36_2dp1 runex36_2dp2 runex36_3d runex36_3dp1 ex36.rm \
                            ex43.PETSc runex43 ex43.rm
TESTEXAMPLES_C_X	  = ex2.PETSc runex2 ex2.rm ex3.PETSc runex3 ex3.rm ex6.PETSc runex6 \
                            ex6.rm ex7.PETSc ex7.rm  ex11.PETSc runex11 runex11_2 runex11_3 ex11.rm ex14.PETSc runex14 ex14.rm \
                            ex13.PETSc runex13 ex13.rm ex23.PETSc runex23 runex23_2 ex23.rm ex37.PETSc runex37 ex37.rm
TESTEXAMPLES_FORTRAN	  =
TESTEXAMPLES_C_X_MPIUNI = ex1.PETSc ex1.rm ex2.PETSc ex2.rm ex3.PETSc ex3.rm ex4.PETSc ex4.rm \
                            ex6.PETSc ex6.rm ex12.PETSc ex12.rm
TESTEXAMPLES_C_COMPLEX	  =
TESTEXAMPLES_C_NOCOMPLEX  = ex16.PETSc runex16 runex16_2 ex16.rm ex42.PETSc runex42 ex42.rm
TESTEXAMPLES_13		  = ex8.PETSc ex8.rm ex9.PETSc ex9.rm ex10.PETSc ex10.rm ex11.PETSc ex11.rm
TESTEXAMPLES_MATLAB	  = ex12.PETSc runex12 ex12.rm
TESTEXAMPLES_CUSP = ex1.PETSc runex1_cusp1 runex1_cusp2 ex1.rm

include ${PETSC_DIR}/lib/petsc/conf/test