📄 cresolveeqonludecomp.h
字号:
#ifndef SOLVEEQONLU_h
#define SOLVEEQONLU_h
//三角矩阵类
struct LU_Type
{
double value; //值
int col; //列号
};
struct SparseTriangleMatrix
{
int * Jjs, *Jis;
int *Jj,*Ji;
int *jtoi;
};
class SolveEqOnLU
{
public:
SolveEqOnLU(){bDecomposed=false; bLUflag=true;}
~SolveEqOnLU();
void SetDecompTyepFlag(bool IsLU){bLUflag=IsLU;} //设置分解类型标记
void SpareLDLDecompose(int wide,int SpareElementNumber,int* Jjs,int* Jj);
void SpareLUDecompose(int wide,int SpareElementNumber,int* Jlowjs, int* Jupjs,int* Jlowj,int* Jupj);
bool SpareLUfilldata(int wide,double* constant,double* Jlowa,double* Jupa,double* JD,int* Jlowjs,int* Jupjs,int* Jlowj,int* Jupj);
bool SpareLDLfilldata(int wide,double* constant,int* Jjs,int* Jj,double* Ja,double* JD);
int GetSpareElementNum(){return SpareElementNum;};
private:
bool bDecomposed; //识别是否分解了
bool bLUflag; //如果是LU分解,则为true;如果为LDL则为false
int SpareElementNum;
SparseTriangleMatrix m_LSpare, m_USpare;
bool Formjtoi(int wide,int* jtoiJjs, int* jtoiJj,int* jtoiJis,int * jtoiArray);
};
#endif
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -