1#ifndef ADOLC_SPARSE_INFOS_H
2#define ADOLC_SPARSE_INFOS_H
12template <CompressionMode CM>
27 double **Seed_{
nullptr};
31 std::vector<uint *>
JP_;
51 void setJP(std::vector<uint *> &&JPIn) {
55 JP_ = std::move(JPIn);
56 depen_ =
static_cast<int>(JP_.size());
59 std::vector<uint *> &
getJP() {
return JP_; }
102 int numSwitches)
const;
123 int *p,
const std::string &coloringVariant);
135 double **Hcomp_{
nullptr};
136 double ***Xppp_{
nullptr};
137 double ***Yppp_{
nullptr};
138 double ***Zppp_{
nullptr};
139 double **Upp_{
nullptr};
156 std::vector<uint *> &
getHP() {
return HP_; }
157 void setHP(
int indep, std::vector<uint *> &&HPIn) {
162 HP_ = std::move(HPIn);
170 void directRecover(
unsigned int **rind,
unsigned int **cind,
double **values);
#define ADOLC_API
Definition adolcexport.h:16
Owning sparse matrix container in coordinate-format.
Definition sparsematrix.h:81
Definition adtl_indo.h:46
void generateSeedHess(int dimIn, const std::span< uint * > HP, double ***Seed, int *p, const std::string &coloringVariant)
Generate a Hessian seed matrix using ColPack.
void generateSeedJac(int, int, const std::span< uint * >, double ***, int *)
Definition sparseinfos.h:13
Stores the abs-normal form in sparse format.
Definition sparsematrix.h:247
Cached sparse Hessian recovery data stored on a tape.
Definition sparseinfos.h:131
void setHP(int indep, std::vector< uint * > &&HPIn)
Definition sparseinfos.h:157
void indirectRecoverUserMem(unsigned int **rind, unsigned int **cind, double **values)
void directRecover(unsigned int **rind, unsigned int **cind, double **values)
SparseHessInfos & operator=(const SparseHessInfos &)=delete
SparseHessInfos(SparseHessInfos &&other) noexcept
std::unique_ptr< Impl > pimpl_
Definition sparseinfos.h:133
SparseHessInfos & operator=(SparseHessInfos &&other) noexcept
std::vector< uint * > HP_
Definition sparseinfos.h:142
void initColoring(int dimIn)
std::vector< uint * > & getHP()
Definition sparseinfos.h:156
void indirectRecover(unsigned int **rind, unsigned int **cind, double **values)
void generateSeedHess(double ***Seed, const std::string &coloringVariant)
SparseHessInfos(const SparseHessInfos &)=delete
void directRecoverUserMem(unsigned int **rind, unsigned int **cind, double **values)
Cached sparse Jacobian recovery data stored on a tape.
Definition sparseinfos.h:21
std::vector< uint * > JP_
Definition sparseinfos.h:31
void setJP(std::vector< uint * > &&JPIn)
Replace the cached sparsity pattern.
Definition sparseinfos.h:51
std::unique_ptr< Impl > pimpl_
Definition sparseinfos.h:23
SparseJacInfos & operator=(SparseJacInfos &&other) noexcept
void recoverRowFormatUserMem(SparseMatrix &sparseJac) const
Recover row-compressed sparse Jacobian entries into SparseMatrix.
void recoverColFormatUserMem(SparseMatrix &sparseJac) const
Recover column-compressed sparse Jacobian entries into SparseMatrix.
void generateSeedJac(const std::string &coloringVariant)
Generate and cache a Jacobian seed matrix.
SparseJacInfos & operator=(const SparseJacInfos &)=delete
void recoverColFormat(SparseMatrix &sparseJac) const
Resize and recover a column-compressed sparse Jacobian.
void initColoring(int dimOut, int dimIn)
Initialize ColPack coloring state for the given matrix shape.
std::vector< uint * > & getJP()
Access the cached CRS Jacobian pattern.
Definition sparseinfos.h:59
void recoverANFUserMem(SparseANF &sparseANF, int indep, int numSwitches) const
Split the recovered extended Jacobian into caller-sized ANF blocks.
SparseJacInfos(SparseJacInfos &&other) noexcept
void recoverANF(SparseANF &sparseANF, int indep, int numSwitches) const
Split the recovered extended Jacobian into abs-normal blocks.
SparseJacInfos(const SparseJacInfos &)=delete
void recoverRowFormat(SparseMatrix &sparseJac) const
Resize and recover a row-compressed sparse Jacobian.