V3FIT
Data Types | Functions/Subroutines
v3fit_context Module Reference

Defines a v3fit_context_class object to contain all the memory for running v3fit. Contains methods to write memory to disk. More...

Data Types

type  v3fit_context_class
 Base class representing a v3fit context. This contains all memory needed to operate v3fit. More...
 

Functions/Subroutines

type(v3fit_context_class) function, pointer v3fit_context_construct (cl_parser)
 Construct a v3fit_context_class object. More...
 
subroutine v3fit_context_destruct (this)
 Deconstruct a v3fit_context_class object. More...
 
subroutine v3fit_context_resize (this)
 Resize the arrays. More...
 
subroutine v3fit_context_create_files (this)
 Create output files. More...
 
subroutine v3fit_context_close_files (this)
 Close output files. More...
 
subroutine v3fit_context_write (this)
 Write the v3fit_context_class out to disk. More...
 
subroutine v3fit_context_write_param_header (this, params, prefix, type_name)
 Write the param_class::correlation header out to disk. More...
 
subroutine v3fit_context_init_data (this, eq_steps)
 Initialize the dimensions and variables of the result file. More...
 
subroutine v3fit_context_write_step_data (this, first_step, eq_steps)
 Write step data to the defined variables. More...
 
integer function v3fit_context_restart (this, current_step)
 Restart the reconstruction. More...
 

Detailed Description

Defines a v3fit_context_class object to contain all the memory for running v3fit. Contains methods to write memory to disk.

Function/Subroutine Documentation

◆ v3fit_context_close_files()

subroutine v3fit_context::v3fit_context_close_files ( type (v3fit_context_class), intent(inout)  this)

Close output files.

Closes output files that reconstructed results are written to.

Parameters
[in,out]thisA v3fit_context_class instance.

Definition at line 419 of file v3fit_context.f.

◆ v3fit_context_construct()

type (v3fit_context_class) function, pointer v3fit_context::v3fit_context_construct ( type (commandline_parser_class), pointer  cl_parser)

Construct a v3fit_context_class object.

Allocates memory and initializes a v3fit_context_class object with an instance of a commandline_parser object. This opens files for the recout, runlog, and result files. Over allocates space for the number of signals.

Parameters
[in]cl_parserAn instance of a commandline parser object.
Returns
A pointer to a constructed v3fit_context_class object.

Definition at line 130 of file v3fit_context.f.

◆ v3fit_context_create_files()

subroutine v3fit_context::v3fit_context_create_files ( type (v3fit_context_class), intent(inout)  this)

Create output files.

Creates output files that reconstructed results are written to.

Parameters
[in,out]thisA v3fit_context_class instance.

Definition at line 339 of file v3fit_context.f.

◆ v3fit_context_destruct()

subroutine v3fit_context::v3fit_context_destruct ( type (v3fit_context_class), pointer  this)

Deconstruct a v3fit_context_class object.

Deallocates memory and uninitializes a v3fit_context_class object. This all the v3fit constructed objects are destroyed here.

Parameters
[in,out]thisA v3fit_context_class instance.

Definition at line 163 of file v3fit_context.f.

◆ v3fit_context_init_data()

subroutine v3fit_context::v3fit_context_init_data ( type (v3fit_context_class), intent(inout)  this,
integer, intent(in)  eq_steps 
)

Initialize the dimensions and variables of the result file.

Defines dimensions, variables and writes out the initial step of v3fit to result netcdf file. Multi dimensional arrays need to be transposed so arrays appear in the correct order in non fortran languages.

Parameters
[in,out]thisA v3fit_context_class instance.
[in]eq_stepsNumber of steps taken by the equilibrium.

Definition at line 808 of file v3fit_context.f.

◆ v3fit_context_resize()

subroutine v3fit_context::v3fit_context_resize ( type (v3fit_context_class), intent(inout)  this)

Resize the arrays.

Resizes the signal arrays to contain only the minimun necessary to hold all signals. If no signals were constructed, the signal array is not allocated.

Parameters
[in,out]thisA v3fit_context_class instance.

Definition at line 277 of file v3fit_context.f.

◆ v3fit_context_restart()

integer function v3fit_context::v3fit_context_restart ( type (v3fit_context_class), intent(inout)  this,
integer, intent(inout)  current_step 
)

Restart the reconstruction.

Reloads a reconstruction from the result file.

Parameters
[in,out]thisA v3fit_context_class instance.
[in,out]current_stepReconstruction step left off from.
Returns
The current step.

Definition at line 1285 of file v3fit_context.f.

◆ v3fit_context_write()

subroutine v3fit_context::v3fit_context_write ( type (v3fit_context_class), intent(inout)  this)

Write the v3fit_context_class out to disk.

Writes out the results of v3fit to the recout file.

Parameters
[in,out]thisA v3fit_context_class instance.
Note
The 'this' parameter is intent(inout) because signal::signal_write calls signal::signal_get_g2 which needs to be intent(inout).

Definition at line 455 of file v3fit_context.f.

◆ v3fit_context_write_param_header()

subroutine v3fit_context::v3fit_context_write_param_header ( type (v3fit_context_class), intent(inout)  this,
type (param_pointer), dimension(:)  params,
character (len=*)  prefix,
character (len=*)  type_name 
)

Write the param_class::correlation header out to disk.

Writes out the results of header for a correlation matric. This header is formatted by a an inital col left blank followed by eack parameter name spaced 14 spaced apart from each other.

Parameters
[in,out]thisA v3fit_context_class instance.
[in]paramsArray of parameter objects.
[in]prefixPrefix string to format the header.
[in]type_nameType name of the parameters.
Note
The 'this' parameter is intent(inout) because signal::signal_write calls signal::signal_get_g2 which needs to be intent(inout). @node The 'prefix' parameter must be an exact length string with all white space predefined.

Definition at line 685 of file v3fit_context.f.

◆ v3fit_context_write_step_data()

subroutine v3fit_context::v3fit_context_write_step_data ( type (v3fit_context_class), intent(inout)  this,
logical, intent(in)  first_step,
integer, intent(in)  eq_steps 
)

Write step data to the defined variables.

Writes out the data for a reconstruction step to the result file. If this is being called for the first time. Do not read the number of steps.

Parameters
[in,out]thisA v3fit_context_class instance.
[in]first_stepFlags to determine if this is the first instance this has been called.
[in]eq_stepsNumber of steps the equilibrium took.
Note
The only caller of this subrotine that should set first_step to true should be v3fit_context_init_data. All others should callers should set first_step to false.

Definition at line 1123 of file v3fit_context.f.