added: <restartstride> under <postprocessing>

use this to control the restart data output stride.
defaults to 0 (no restart data output).
This commit is contained in:
Arne Morten Kvarving 2017-03-24 09:19:34 +01:00
parent 02ce95de8c
commit 0c582050c3
2 changed files with 7 additions and 1 deletions

View File

@ -48,6 +48,7 @@ SIMoptions::SIMoptions ()
dtSave = 0.0;
pSolOnly = false;
enableController = false;
restartInc = 0;
nGauss[0] = nGauss[1] = 4;
nViz[0] = nViz[1] = nViz[2] = 2;
@ -121,6 +122,7 @@ bool SIMoptions::parseDiscretizationTag (const TiXmlElement* elem)
bool SIMoptions::parseOutputTag (const TiXmlElement* elem)
{
const char* value = nullptr;
if (!strcasecmp(elem->Value(),"vtfformat")) {
if (elem->FirstChild()) {
if (!strcasecmp(elem->FirstChild()->Value(),"ascii"))
@ -136,11 +138,14 @@ bool SIMoptions::parseOutputTag (const TiXmlElement* elem)
}
else if (!strcasecmp(elem->Value(),"stride")) {
const char* value = utl::getValue(elem,"stride");
value = utl::getValue(elem,"stride");
if (value) saveInc = atoi(value);
utl::getAttribute(elem,"dt",dtSave);
}
else if ((value = utl::getValue(elem,"restartstride")))
restartInc = atoi(value);
else if (!strcasecmp(elem->Value(),"hdf5")) {
if (elem->FirstChild()) {
hdf5 = elem->FirstChild()->Value();

View File

@ -83,6 +83,7 @@ public:
int format; //!< VTF-file format (-1=NONE, 0=ASCII, 1=BINARY)
int nViz[3]; //!< Number of visualization points over each knot-span
int saveInc; //!< Number of load/time increments between each result output
int restartInc;//!< Number of load/time increments between each restart output
double dtSave; //!< Time interval between each result output
bool pSolOnly; //!< If \e true, don't save secondary solution variables