https://mooseframework.inl.gov
Loading...
Searching...
No Matches
DenseMatrixADReal.C
Go to the documentation of this file.
1//* This file is part of the MOOSE framework
2//* https://mooseframework.inl.gov
3//*
4//* All rights reserved, see COPYRIGHT for full restrictions
5//* https://github.com/idaholab/moose/blob/master/COPYRIGHT
6//*
7//* Licensed under LGPL 2.1, please see LICENSE for details
8//* https://www.gnu.org/licenses/lgpl-2.1.html
9
10#include "DenseMatrix.h"
11#include "ADReal.h"
12#include "MooseError.h"
13
14#include "libmesh/dense_matrix_base_impl.h"
15#include "libmesh/dense_matrix_impl.h"
16
17namespace libMesh
18{
19template <>
20void
21DenseMatrix<ADReal>::_multiply_blas(const DenseMatrixBase<ADReal> &, _BLAS_Multiply_Flag)
22{
23 mooseError("No blas/lapack support for type ", demangle(typeid(ADReal).name()));
24}
25
26template <>
27void
29{
30 mooseError("No blas/lapack support for type ", demangle(typeid(ADReal).name()));
31}
32
33template <>
34void
36{
37 mooseError("No blas/lapack support for type ", demangle(typeid(ADReal).name()));
38}
39
40template <>
41void
42DenseMatrix<ADReal>::_svd_lapack(DenseVector<Real> &, DenseMatrix<Number> &, DenseMatrix<Number> &)
43{
44 mooseError("No blas/lapack support for type ", demangle(typeid(ADReal).name()));
45}
46
47template <>
48void
50 char, char, std::vector<Real> &, std::vector<Number> &, std::vector<Number> &)
51{
52 mooseError("No blas/lapack support for type ", demangle(typeid(ADReal).name()));
53}
54
55template <>
56void
57DenseMatrix<ADReal>::_svd_solve_lapack(const DenseVector<ADReal> & /*rhs*/,
58 DenseVector<ADReal> & /*x*/,
59 Real /*rcond*/) const
60{
61 mooseError("No blas/lapack support for type ", demangle(typeid(ADReal).name()));
62}
63
64template <>
65void
66DenseMatrix<ADReal>::_evd_lapack(DenseVector<ADReal> &,
67 DenseVector<ADReal> &,
68 DenseMatrix<ADReal> *,
69 DenseMatrix<ADReal> *)
70{
71 mooseError("No blas/lapack support for type ", demangle(typeid(ADReal).name()));
72}
73
74template <>
75void
76DenseMatrix<ADReal>::_lu_back_substitute_lapack(const DenseVector<ADReal> &, DenseVector<ADReal> &)
77{
78 mooseError("No blas/lapack support for type ", demangle(typeid(ADReal).name()));
79}
80
81template <>
82void
84 ADReal, ADReal, DenseVector<ADReal> &, const DenseVector<ADReal> &, bool) const
85{
86 mooseError("No blas/lapack support for type ", demangle(typeid(ADReal).name()));
87}
88
89template <>
90DenseMatrix<ADReal>::DenseMatrix(const unsigned int new_m, const unsigned int new_n)
91 : DenseMatrixBase<ADReal>(new_m, new_n), use_blas_lapack(false), _val(), _decomposition_type(NONE)
92{
93 this->resize(new_m, new_n);
94}
95
96template class DenseMatrixBase<ADReal>;
97template class DenseMatrix<ADReal>;
98
99template void DenseMatrix<ADReal>::vector_mult_add(DenseVector<ADReal> &,
100 const int,
101 const DenseVector<ADReal> &) const;
102template void DenseMatrix<ADReal>::vector_mult_add(DenseVector<ADReal> &,
103 const double,
104 const DenseVector<ADReal> &) const;
105
106template void DenseMatrix<Real>::vector_mult(DenseVector<ADReal> &,
107 const DenseVector<ADReal> &) const;
108template void DenseMatrix<ADReal>::vector_mult(DenseVector<ADReal> &,
109 const DenseVector<Real> &) const;
110
111template void DenseMatrix<ADReal>::cholesky_solve(const DenseVector<ADReal> & b,
112 DenseVector<ADReal> & x);
113}
DualNumber< Real, DNDerivativeType, true > ADReal
void mooseError(Args &&... args)
Emit an error message with the given stringified, concatenated args and terminate the application.
Definition MooseError.h:311
DenseMatrix(const unsigned int new_m=0, const unsigned int new_n=0)
void _evd_lapack(DenseVector< T > &lambda_real, DenseVector< T > &lambda_imag, DenseMatrix< T > *VL=nullptr, DenseMatrix< T > *VR=nullptr)
void _svd_lapack(DenseVector< Real > &sigma)
void _svd_solve_lapack(const DenseVector< T > &rhs, DenseVector< T > &x, Real rcond) const
void _svd_helper(char JOBU, char JOBVT, std::vector< Real > &sigma_val, std::vector< Number > &U_val, std::vector< Number > &VT_val)
void _matvec_blas(T alpha, T beta, DenseVector< T > &dest, const DenseVector< T > &arg, bool trans=false) const
void _multiply_blas(const DenseMatrixBase< T > &other, _BLAS_Multiply_Flag flag)
void _lu_back_substitute_lapack(const DenseVector< T > &b, DenseVector< T > &x)
std::string name(const ElemQuality q)
The following methods are specializations for using the libMesh::Parallel::packed_range_* routines fo...
std::string demangle(const char *name)
template class LIBMESH_EXPORT DenseVector< Real >
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real