예제 #1
0
파일: Exodus.C 프로젝트: Gedema/moose
void
Exodus::output()
{
  // Clear the global variables (postprocessors and scalars)
  _global_names.clear();
  _global_values.clear();

  // Call the output methods
  OversampleOutput::output();

  // Write the global variables (populated by the output methods)
  if (!_global_values.empty())
  {
    if (!_exodus_initialized)
      outputEmptyTimestep();
    _exodus_io_ptr->write_global_data(_global_values, _global_names);
  }

  if (_output_input)
  {
    outputInput();
    _output_input = false;
  }

  // Increment output call counter, which is reset by outputSetup
  _exodus_num++;
}
예제 #2
0
파일: Exodus.C 프로젝트: Gedema/moose
void
Exodus::outputElementalVariables()
{
  // Make sure the the file is ready for writing of elemental data
  if (!_exodus_initialized || !hasNodalVariableOutput())
    outputEmptyTimestep();

  // Write the elemental data
  _exodus_io_ptr->set_output_variables(getElementalVariableOutput());
  _exodus_io_ptr->write_element_data(*_es_ptr);
}
예제 #3
0
파일: Exodus.C 프로젝트: rppawlo/moose
void
Exodus::outputElementalVariables()
{
  // Make sure the the file is ready for writing of elemental data
  if (!_exodus_initialized || !hasNodalVariableOutput())
    outputEmptyTimestep();

  // Write the elemental data
  std::vector<std::string> elemental(getElementalVariableOutput().begin(), getElementalVariableOutput().end());
  _exodus_io_ptr->set_output_variables(elemental);
  _exodus_io_ptr->write_element_data(*_es_ptr);
}
예제 #4
0
파일: Exodus.C 프로젝트: WilkAndy/moose
void
Exodus::outputElementalVariables()
{
  // Make sure the the file is ready for writing of elemental data
  if (!_initialized)
    outputEmptyTimestep();

  std::vector<std::string> v = getElementalVariableOutput();
  for (std::vector<std::string>::iterator it = v.begin(); it != v.end(); ++it)

  // Write the elemental data
  _exodus_io_ptr->set_output_variables(getElementalVariableOutput());
  _exodus_io_ptr->write_element_data(*_es_ptr);
}
예제 #5
0
파일: Exodus.C 프로젝트: huangh-inl/moose
void
Exodus::output(const ExecFlagType & type)
{
  // Do nothing if there is nothing to output
  if (!hasOutput(type))
    return;

  // Start the performance log
  Moose::perf_log.push("Exodus::output()", "Output");

  // Prepare the ExodusII_IO object
  outputSetup();
  LockFile lf(filename(), processor_id() == 0);

  // Adjust the position of the output
  if (_app.hasOutputPosition())
    _exodus_io_ptr->set_coordinate_offset(_app.getOutputPosition());

  // Clear the global variables (postprocessors and scalars)
  _global_names.clear();
  _global_values.clear();

  // Call the individual output methods
  AdvancedOutput::output(type);

  // Write the global variables (populated by the output methods)
  if (!_global_values.empty())
  {
    if (!_exodus_initialized)
      outputEmptyTimestep();
    _exodus_io_ptr->write_global_data(_global_values, _global_names);
  }

  // Write the input file record if it exists and the output file is initialized
  if (!_input_record.empty() && _exodus_initialized)
  {
    _exodus_io_ptr->write_information_records(_input_record);
    _input_record.clear();
  }

  // Reset the mesh changed flag
  _exodus_mesh_changed = false;

  // Stop the logging
  Moose::perf_log.pop("Exodus::output()", "Output");
}