Alsvinn  0.5.3
The fast FVM simulator with UQ support
Public Member Functions | List of all members
alsfvm::functional::TimeIntegrationFunctional Class Reference

#include <alsfvm/functional/TimeIntegrationFunctional.hpp>

Inheritance diagram for alsfvm::functional::TimeIntegrationFunctional:
alsfvm::io::Writer

Public Member Functions

 TimeIntegrationFunctional (volume::VolumeFactory volumeFactory, io::WriterPointer writer, FunctionalPointer functional, double time, double timeRadius)
 
virtual void write (const volume::Volume &conservedVariables, const grid::Grid &grid, const simulator::TimestepInformation &timestepInformation) override
 write writes the data to disk More...
 
virtual void finalize (const grid::Grid &grid, const simulator::TimestepInformation &timestepInformation) override
 This method should be called at the end of the simulation. More...
 
- Public Member Functions inherited from alsfvm::io::Writer
virtual ~Writer ()
 
void addAttributes (const std::string &nameOfAttributes, const boost::property_tree::ptree &attributes)
 

Additional Inherited Members

- Static Public Member Functions inherited from alsfvm::io::Writer
static std::string getClassName ()
 
- Protected Attributes inherited from alsfvm::io::Writer
std::map< std::string, boost::property_tree::ptree > attributesMap
 

Detailed Description

This lets you time integrate a functional, that is, for a functional g (interpreted in the loose sense), this will compute

\[\int_{t-\tau}^{t+\tau} g(u(t))\; dt\]

Note
this computes the time integral without averaging, if you want to get the time averaged quantity, you have to divide the output by $2\tau$.
It is not really easy to combine this into the time integration class for writing. The reason for this is that we only selectively want to call the functional, to minimize computational work.

Constructor & Destructor Documentation

◆ TimeIntegrationFunctional()

alsfvm::functional::TimeIntegrationFunctional::TimeIntegrationFunctional ( volume::VolumeFactory  volumeFactory,
io::WriterPointer  writer,
FunctionalPointer  functional,
double  time,
double  timeRadius 
)

Member Function Documentation

◆ finalize()

void alsfvm::functional::TimeIntegrationFunctional::finalize ( const grid::Grid grid,
const simulator::TimestepInformation timestepInformation 
)
overridevirtual

This method should be called at the end of the simulation.

Reimplemented from alsfvm::io::Writer.

◆ write()

void alsfvm::functional::TimeIntegrationFunctional::write ( const volume::Volume conservedVariables,
const grid::Grid grid,
const simulator::TimestepInformation timestepInformation 
)
overridevirtual

write writes the data to disk

Parameters
conservedVariablesthe conservedVariables to write
gridthe grid that is used (describes the whole domain)
timestepInformation

Implements alsfvm::io::Writer.


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