37#ifndef ReducedUnsteadyNST_H
38#define ReducedUnsteadyNST_H
44#include <unsupported/Eigen/NonLinearOptimization>
45#include <unsupported/Eigen/NumericalDiff>
60 int operator()(
const Eigen::VectorXd& x, Eigen::VectorXd& fvec)
const;
61 int df(
const Eigen::VectorXd& x, Eigen::MatrixXd& fjac)
const;
84 int operator()(
const Eigen::VectorXd& x, Eigen::VectorXd& fvec)
const;
85 int df(
const Eigen::VectorXd& x, Eigen::MatrixXd& fjac)
const;
Header file of the reducedUnsteadyNS class.
Template object created to solve non linear problems using the Eigen library.
Eigen::MatrixXd vel_now
Online inlet velocity vector.
Class where it is implemented a reduced problem for the unsteady Navier-stokes weakly coupled with t...
Eigen::MatrixXd B_matrix
Diffusion Term.
Eigen::MatrixXd MT_matrix
Mass Matrix Term for temperature.
PtrList< volScalarField > TREC
Reconstructed temperature field.
scalar finalTime
Scalar to store the final time if the online simulation.
int N_BC_t
Number of parametrized boundary conditions related to temperature field.
Eigen::VectorXd z_old
Vector to store the previous temperature solution during the Newton procedure.
Eigen::MatrixXd P_matrix
Divergence of velocity.
PtrList< volScalarField > Tmodes
List of pointers to store the modes for temperature.
Eigen::MatrixXd K_matrix
Gradient of pressure.
void reconstruct_supt(fileName folder="./ITHACAOutput/online_rec", int printevery=1)
Method to reconstruct a solution from an online solve with a supremizer stabilisation technique for t...
PtrList< volScalarField > T_rec
Reconstructed temperature field.
reducedUnsteadyNST()
Construct Null.
List< Eigen::MatrixXd > online_solutiont
List of Eigen matrices to store the online solution for temperature equation.
List< Eigen::MatrixXd > S_matrix
Turbulent thermal term.
newton_unsteadyNST_sup_t newton_object_sup_t
Functor object to call the non linear solver sup. approach for temperature case.
Eigen::MatrixXd D_matrix
Laplacian of pressure.
scalar tstart
Scalar to store the final time if the online simulation.
unsteadyNST * problem
pointer to the FOM problem
List< Eigen::MatrixXd > Q_matrix
Convective Term for temperature transport equation.
List< Eigen::MatrixXd > G_matrix
Divergence of momentum.
Eigen::MatrixXd M_matrix
Mass Matrix Term.
int Nphi_t
Number of temperature modes.
void reconstruct_sup(fileName folder="./ITHACAOutput/online_rec", int printevery=1)
Method to reconstruct a solution from an online solve with a supremizer stabilisation technique.
scalar dt
Scalar to store the time increment.
Eigen::MatrixXd Y_matrix
Laplacian Term for temperature trasnport equation.
newton_unsteadyNST_sup newton_object_sup
Functor object to call the non linear solver sup. approach for velocity case.
Eigen::VectorXd z
Vector to store the temperature solution during the Newton procedure.
List< Eigen::MatrixXd > C_matrix
Convective Term.
PtrList< volScalarField > Tsnapshots
List of pointers to store the snapshots for temperature.
scalar time
Scalar to store the current time.
void solveOnline_sup(Eigen::MatrixXd &vel_now, Eigen::MatrixXd &temp_now, int startSnap=0)
Method to perform an online solve using a supremizer stabilisation method.
Class where it is implemented a reduced problem for the unsteady Navier-stokes problem.
Implementation of a parametrized full order unsteady NS problem weakly coupled with the energy equat...
newton_unsteadyNST_sup_t()
int operator()(const Eigen::VectorXd &x, Eigen::VectorXd &fvec) const
int df(const Eigen::VectorXd &x, Eigen::MatrixXd &fjac) const
newton_unsteadyNST_sup_t(int Nx, int Ny, unsteadyNST &problem)
Newton object for the resolution of the reduced problem using a supremizer approach.
newton_unsteadyNST_sup(int Nx, int Ny, unsteadyNST &problem)
int operator()(const Eigen::VectorXd &x, Eigen::VectorXd &fvec) const
int df(const Eigen::VectorXd &x, Eigen::MatrixXd &fjac) const
Header file of the unsteadyNST class.