Loading...
Searching...
No Matches
ITHACAregularization.H
Go to the documentation of this file.
1/*---------------------------------------------------------------------------*\
2 ██╗████████╗██╗ ██╗ █████╗ ██████╗ █████╗ ███████╗██╗ ██╗
3 ██║╚══██╔══╝██║ ██║██╔══██╗██╔════╝██╔══██╗ ██╔════╝██║ ██║
4 ██║ ██║ ███████║███████║██║ ███████║█████╗█████╗ ██║ ██║
5 ██║ ██║ ██╔══██║██╔══██║██║ ██╔══██║╚════╝██╔══╝ ╚██╗ ██╔╝
6 ██║ ██║ ██║ ██║██║ ██║╚██████╗██║ ██║ ██║ ╚████╔╝
7 ╚═╝ ╚═╝ ╚═╝ ╚═╝╚═╝ ╚═╝ ╚═════╝╚═╝ ╚═╝ ╚═╝ ╚═══╝
8 * In real Time Highly Advanced Computational Applications for Finite Volumes
9 * Copyright (C) 2017 by the ITHACA-FV authors
10-------------------------------------------------------------------------------
11License
12 This file is part of ITHACA-FV
13 ITHACA-FV is free software: you can redistribute it and/or modify
14 it under the terms of the GNU Lesser General Public License as published by
15 the Free Software Foundation, either version 3 of the License, or
16 (at your option) any later version.
17 ITHACA-FV is distributed in the hope that it will be useful,
18 but WITHOUT ANY WARRANTY; without even the implied warranty of
19 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20 GNU Lesser General Public License for more details.
21 You should have received a copy of the GNU Lesser General Public License
22 along with ITHACA-FV. If not, see <http://www.gnu.org/licenses/>.
23Class
24 ITHACAregularization
25Description
26 Methods for regularizing ill-conditione linear systems
27SourceFiles
28 ITHACAregularization.C
29 ITHACAregularizationTemplates.C
30\*---------------------------------------------------------------------------*/
31
37
38#ifndef ITHACAregularization_H
39#define ITHACAregularization_H
40
41#include "fvCFD.H"
42#include "IOmanip.H"
43#include <stdio.h>
44#include <sys/types.h>
45#include <dirent.h>
46#include <algorithm>
47#include <fstream>
48#include <string>
49#include <stdexcept>
50#include <sstream>
51#include <vector>
52#include <cstdio>
53#include <typeinfo>
54#include <iostream>
55#include <cassert>
56#include <zlib.h>
57#include <map>
58#pragma GCC diagnostic push
59#pragma GCC diagnostic ignored "-Wold-style-cast"
60#pragma GCC diagnostic ignored "-Wignored-attributes"
61#include <Eigen/Eigen>
62#include "EigenFunctions.H"
63#include "ITHACAutilities.H"
64
65
66#include <unsupported/Eigen/CXX11/Tensor>
67#pragma GCC diagnostic pop
68
69#define MAXBUFSIZE (static_cast<int> (1e6))
70#define PBSTR "||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||"
71#define PBWIDTH 60
72
73
74// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
75
76
77/*---------------------------------------------------------------------------*\
78 Class reductionProblem Declaration
79\*---------------------------------------------------------------------------*/
80#pragma GCC diagnostic push
81#pragma GCC diagnostic ignored "-Wold-style-cast"
82#pragma GCC diagnostic pop
83
86{
87
88//--------------------------------------------------------------------------
97Eigen::VectorXd TSVD(Eigen::MatrixXd A, Eigen::MatrixXd b,
98 int filter);
99
100//--------------------------------------------------------------------------
109Eigen::VectorXd TSVD(Eigen::MatrixXd A, Eigen::MatrixXd b,
110 double noiseVariance, word parameterMethod);
111
112//--------------------------------------------------------------------------
120Eigen::VectorXd Tikhonov(Eigen::MatrixXd A, Eigen::MatrixXd b,
121 double regularizationParameter);
122
123};
124
125
126
127// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
128
129
130
131#endif
Header file of the EigenFunctions class.
Header file of the ITHACAutilities namespace.
volScalarField & A
Namespace for regularization of ill-conditione linear system.
Eigen::VectorXd Tikhonov(Eigen::MatrixXd A, Eigen::MatrixXd b, double regularizationParameter)
Truncated Singular Value regularization.
Eigen::VectorXd TSVD(Eigen::MatrixXd A, Eigen::MatrixXd b, int filter)
Truncated Singular Value regularization.