Revision f841b8affc701382c44ad5a88be28532924f506b authored by Lars Bilke on 26 July 2021, 09:00:10 UTC, committed by Lars Bilke on 26 July 2021, 09:37:44 UTC
1 parent ded400f
Extrapolator.h
/**
* \file
* \copyright
* Copyright (c) 2012-2021, OpenGeoSys Community (http://www.opengeosys.org)
* Distributed under a Modified BSD License.
* See accompanying file LICENSE.txt or
* http://www.opengeosys.org/project/license
*
*/
#pragma once
#include <Eigen/Eigen>
#include <vector>
#include "ExtrapolatableElementCollection.h"
#include "NumLib/NumericsConfig.h"
namespace NumLib
{
class LocalToGlobalIndexMap;
//! Interface for classes that extrapolate integration point values to nodal
//! values.
class Extrapolator
{
public:
//! Extrapolates the given \c property from the given local assemblers.
virtual void extrapolate(
const unsigned num_components,
ExtrapolatableElementCollection const& extrapolatables,
const double t,
std::vector<GlobalVector*> const& x,
std::vector<NumLib::LocalToGlobalIndexMap const*> const& dof_table) = 0;
/*! Computes residuals from the extrapolation of the given \c property.
*
* The residuals are computed as element values.
*
* \pre extrapolate() must have been called before with the same arguments.
*/
virtual void calculateResiduals(
const unsigned num_components,
ExtrapolatableElementCollection const& extrapolatables,
const double t,
std::vector<GlobalVector*> const& x,
std::vector<NumLib::LocalToGlobalIndexMap const*> const& dof_table) = 0;
//! Returns the extrapolated nodal values.
//! \todo Maybe write directly to a MeshProperty.
virtual GlobalVector const& getNodalValues() const = 0;
//! Returns the extrapolation residuals.
//! \todo Maybe write directly to a MeshProperty.
virtual GlobalVector const& getElementResiduals() const = 0;
virtual ~Extrapolator() = default;
};
} // namespace NumLib
Computing file changes ...