[petsc-users] HDF5 vec output with DMPlex

Adrian Croucher a.croucher at auckland.ac.nz
Thu Oct 15 22:51:30 CDT 2015


hi,

I am wanting to output time-stepped simulation results to an HDF5 file, 
from a PETSc Vec created on a DMPlex using DMCreateGlobalVector().

I tried doing it the way it's done in 
src/vec/vec/examples/tutorials/ex19.c, using PetscViewerHDF5Open(), 
PetscViewerHDF5PushGroup() and PetscViewerHDF5SetTimestep(), but the 
resulting HDF5 file only ever seems to have results for the last time 
step in it.

It works OK for a Vec created simply using VecCreate(), as in the ex19 
example. Is there any reason it shouldn't work with DMPlex?

Cheers, Adrian

-- 
Dr Adrian Croucher
Senior Research Fellow
Department of Engineering Science
University of Auckland, New Zealand
email: a.croucher at auckland.ac.nz
tel: +64 (0)9 923 84611



More information about the petsc-users mailing list