PRISMS-PF Manual
Loading...
Searching...
No Matches
FieldOutputParameters Struct Reference

Simple struct for field output. More...

#include <io_parameters.h>

Inheritance diagram for FieldOutputParameters:
[legend]
Collaboration diagram for FieldOutputParameters:
[legend]

Public Types

enum  OutputType { VTU , VTK , PVTU , XDMF }
 VTK output types. More...
 

Public Member Functions

void assign (dealii::ParameterHandler &parameter_handler, unsigned int n_subsections=Numbers::default_subsections) override
 Assign the parameters from file.
 
void assign (dealii::ParameterHandler &parameter_handler, unsigned int n_increments, unsigned int n_subsections=Numbers::default_subsections)
 Assign the parameters from file.
 
void validate (const std::vector< FieldAttributes > &field_attributes, const std::vector< SolveBlock > &solve_blocks) const override
 Validate.
 
bool should_output (unsigned int increment) const
 Whether a given increment should be outputted.
 
- Public Member Functions inherited from ParameterBase
 ParameterBase ()=default
 
virtual ~ParameterBase ()=default
 
 ParameterBase (const ParameterBase &)=default
 
 ParameterBase (ParameterBase &&)=default
 
ParameterBaseoperator= (const ParameterBase &)=default
 
ParameterBaseoperator= (ParameterBase &&)=default
 

Static Public Member Functions

static void declare (dealii::ParameterHandler &parameter_handler, unsigned int n_subsections=Numbers::default_subsections)
 Declare the parameters to be read from file.
 

Public Attributes

OutputType file_type = OutputType::VTU
 File type for field output.
 
unsigned int patch_subdivisions = 0
 Number of subdivisions to apply when building patches.
 
dealii::DataOutBase::CompressionLevel compression_level
 Compression level for output.
 
std::string folder = "solutions"
 Folder for field output.
 
std::string file_name = "solution"
 Base filename for field output.
 
std::set< unsigned int > output_list = {0}
 A list of output steps.
 
std::set< std::string > output_fields
 A list of fields that are output.
 

Detailed Description

Simple struct for field output.

Member Enumeration Documentation

◆ OutputType

VTK output types.

Enumerator
VTU 
VTK 
PVTU 
XDMF 

Member Function Documentation

◆ assign() [1/2]

void FieldOutputParameters::assign ( dealii::ParameterHandler & parameter_handler,
unsigned int n_increments,
unsigned int n_subsections = Numbers::default_subsections )

Assign the parameters from file.

◆ assign() [2/2]

void FieldOutputParameters::assign ( dealii::ParameterHandler & parameter_handler,
unsigned int n_subsections = Numbers::default_subsections )
overridevirtual

Assign the parameters from file.

WARN: This one should not be used

Implements ParameterBase.

◆ declare()

PRISMS_PF_BEGIN_NAMESPACE void FieldOutputParameters::declare ( dealii::ParameterHandler & parameter_handler,
unsigned int n_subsections = Numbers::default_subsections )
static

Declare the parameters to be read from file.

◆ should_output()

bool FieldOutputParameters::should_output ( unsigned int increment) const
nodiscard

Whether a given increment should be outputted.

◆ validate()

void FieldOutputParameters::validate ( const std::vector< FieldAttributes > & field_attributes,
const std::vector< SolveBlock > & solve_blocks ) const
overridevirtual

Validate.

Implements ParameterBase.

Member Data Documentation

◆ compression_level

dealii::DataOutBase::CompressionLevel FieldOutputParameters::compression_level
Initial value:
=
dealii::DataOutBase::CompressionLevel::default_compression

Compression level for output.

Since zlib is always available, users can select what sort of compression to use for binary output. The options are no compression, best speed, best size, and default (a balance of speed and size).

◆ file_name

std::string FieldOutputParameters::file_name = "solution"

Base filename for field output.

This is the base filename for the outputs. For example, solution-*.vtu or file_name-*.vtu

◆ file_type

OutputType FieldOutputParameters::file_type = OutputType::VTU

File type for field output.

This determines what type of files are output. For examples, vtu, pvtu, and vtk. The pvtu files are written in parallel and should be the fastest to output when working with large simulations; however, they can become numerous and harder to visualize when you have many threads, as each thread outputs.

◆ folder

std::string FieldOutputParameters::folder = "solutions"

Folder for field output.

Choosing this will give you your results like solutions/solution-*.vtu

◆ output_fields

std::set<std::string> FieldOutputParameters::output_fields

A list of fields that are output.

This determines which fields are output during output steps. Each entry corresponds to a field index and the dependency type. Typically, the dependency type will always be normal; however, one may want to visualize change and old fields for debugging.

Additionally, this variable is useful when runnings simulation with multiple order parameters. Most times, we don't need to output all of the order parameters because we only care about combined fields (e.g., grain ids). When we don't output all of the order parameters we save lots of disk space because we go from n fields to 1.

◆ output_list

std::set<unsigned int> FieldOutputParameters::output_list = {0}

A list of output steps.

This is determined by a combination of the number of outputs and the total number of steps. When we reach a step contained in the list, we output.

◆ patch_subdivisions

unsigned int FieldOutputParameters::patch_subdivisions = 0

Number of subdivisions to apply when building patches.

By default this is the element degree. You can choose higher or lower in order to control how much interpolation should be done to the fields when outputting them. The element degree is the default value to show the increase in DoFs and accuracy when using higher order elements.


The documentation for this struct was generated from the following files: