libMesh
|
Subclass of Solution History that stores the solutions and other important vectors onto disk. More...
#include <file_solution_history.h>
Public Member Functions | |
FileSolutionHistory (DifferentiableSystem &system) | |
Constructor, reference to system to be passed by user, set the stored_sols iterator to some initial value. More... | |
~FileSolutionHistory () | |
Destructor, defaulted out-of-line. More... | |
virtual void | store (bool is_adjoint_solve, Real time) override |
Virtual function store which we will be overriding to store timesteps. More... | |
virtual void | retrieve (bool is_adjoint_solve, Real time) override |
Virtual function retrieve which we will be overriding to retrieve timesteps. More... | |
virtual std::unique_ptr< SolutionHistory > | clone () const override |
Definition of the clone function needed for the setter function. More... | |
void | erase (Real time) |
Erase stored_data entry at time. More... | |
void | set_overwrite_previously_stored (bool val) |
Turn on overwrite_previously_stored to overwrite any already-saved data encountered during subsequent store() calls. More... | |
Protected Types | |
typedef std::map< Real, std::unique_ptr< HistoryData > > | map_type |
typedef map_type::iterator | stored_data_iterator |
Protected Member Functions | |
void | find_stored_entry (Real time, bool storing=false) |
Protected Attributes | |
bool | overwrite_previously_stored |
map_type | stored_data |
stored_data_iterator | stored_datum |
Private Attributes | |
DifferentiableSystem & | _system |
std::vector< std::unique_ptr< NumericVector< Number > > > | dual_solution_copies |
A vector of pointers to adjoint and old adjoint solutions at the last time step. More... | |
std::vector< std::unique_ptr< NumericVector< Number > > > | old_dual_solution_copies |
Subclass of Solution History that stores the solutions and other important vectors onto disk.
Definition at line 46 of file file_solution_history.h.
|
protectedinherited |
Definition at line 93 of file solution_history.h.
|
protectedinherited |
Definition at line 95 of file solution_history.h.
libMesh::FileSolutionHistory::FileSolutionHistory | ( | DifferentiableSystem & | system | ) |
Constructor, reference to system to be passed by user, set the stored_sols iterator to some initial value.
Constructor, reference to system to be passed by user, set the stored_datum iterator to some initial value.
Definition at line 36 of file file_solution_history.C.
References _system, dual_solution_copies, libMesh::System::n_qois(), and old_dual_solution_copies.
|
default |
Destructor, defaulted out-of-line.
|
overridevirtual |
Definition of the clone function needed for the setter function.
Implements libMesh::SolutionHistory.
Definition at line 49 of file file_solution_history.C.
References _system.
|
inherited |
Erase stored_data entry at time.
Definition at line 95 of file solution_history.C.
References libMesh::SolutionHistory::find_stored_entry(), libMesh::libmesh_assert(), libMesh::SolutionHistory::stored_data, and libMesh::SolutionHistory::stored_datum.
|
protectedinherited |
Definition at line 27 of file solution_history.C.
References libMesh::MeshTools::Subdivision::prev, libMesh::SolutionHistory::stored_data, libMesh::SolutionHistory::stored_datum, and libMesh::TOLERANCE.
Referenced by libMesh::SolutionHistory::erase(), libMesh::MemorySolutionHistory::retrieve(), retrieve(), libMesh::MemorySolutionHistory::store(), and store().
|
overridevirtual |
Virtual function retrieve which we will be overriding to retrieve timesteps.
Implements libMesh::SolutionHistory.
Definition at line 116 of file file_solution_history.C.
References _system, libMesh::NumericVector< T >::clone(), libMesh::DifferentiableSystem::deltat, dual_solution_copies, libMesh::SolutionHistory::find_stored_entry(), libMesh::System::get_adjoint_solution(), libMesh::System::get_vector(), libMesh::make_range(), libMesh::System::n_qois(), old_dual_solution_copies, libMesh::MeshTools::Subdivision::prev, libMesh::Real, libMesh::SolutionHistory::stored_data, libMesh::SolutionHistory::stored_datum, libMesh::TOLERANCE, and libMesh::System::update().
|
inlineinherited |
Turn on overwrite_previously_stored to overwrite any already-saved data encountered during subsequent store() calls.
Definition at line 80 of file solution_history.h.
References libMesh::SolutionHistory::overwrite_previously_stored.
|
overridevirtual |
Virtual function store which we will be overriding to store timesteps.
Implements libMesh::SolutionHistory.
Definition at line 55 of file file_solution_history.C.
References _system, libMesh::SolutionHistory::find_stored_entry(), libMesh::libmesh_assert(), libMesh::SolutionHistory::stored_data, libMesh::SolutionHistory::stored_datum, and libMesh::TOLERANCE.
|
private |
Definition at line 79 of file file_solution_history.h.
Referenced by clone(), FileSolutionHistory(), retrieve(), and store().
|
private |
A vector of pointers to adjoint and old adjoint solutions at the last time step.
These are used to prevent the zeroing of the adjoint and old adjoint by es::read.
Definition at line 85 of file file_solution_history.h.
Referenced by FileSolutionHistory(), and retrieve().
|
private |
Definition at line 86 of file file_solution_history.h.
Referenced by FileSolutionHistory(), and retrieve().
|
protectedinherited |
Definition at line 87 of file solution_history.h.
Referenced by libMesh::SolutionHistory::set_overwrite_previously_stored().
|
protectedinherited |
Definition at line 94 of file solution_history.h.
Referenced by libMesh::SolutionHistory::erase(), libMesh::SolutionHistory::find_stored_entry(), libMesh::MemorySolutionHistory::retrieve(), retrieve(), libMesh::MemorySolutionHistory::store(), and store().
|
protectedinherited |
Definition at line 96 of file solution_history.h.
Referenced by libMesh::SolutionHistory::erase(), libMesh::SolutionHistory::find_stored_entry(), libMesh::MemorySolutionHistory::retrieve(), retrieve(), libMesh::MemorySolutionHistory::store(), and store().