You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
|
|
#pragma once
|
|
|
|
|
|
|
|
|
|
#include "zxAlgRegress.h"
|
|
|
|
|
#include "zxAlgRegressLinear.h"
|
|
|
|
|
|
|
|
|
|
//对数拟合
|
|
|
|
|
class I_ALGREGRESS_EXPORT zxAlgRegressLog : public zxAlgRegress
|
|
|
|
|
{
|
|
|
|
|
public:
|
|
|
|
|
zxAlgRegressLog(void);
|
|
|
|
|
virtual ~zxAlgRegressLog(void);
|
|
|
|
|
|
|
|
|
|
virtual double getValue(VecDouble& vMatrixX);
|
|
|
|
|
bool setFiltering();
|
|
|
|
|
bool cal();
|
|
|
|
|
bool setTransformation();
|
|
|
|
|
bool setReciprocalTransformation();
|
|
|
|
|
|
|
|
|
|
// 组织表达式
|
|
|
|
|
virtual QString getExpStr();
|
|
|
|
|
|
|
|
|
|
private:
|
|
|
|
|
double m_dK; //乘积项系数
|
|
|
|
|
double m_dB; //指数项系数
|
|
|
|
|
|
|
|
|
|
double m_dPlusAssistCoeff; //乘积项辅助系数。用于处理系数为负数的情况。
|
|
|
|
|
bool m_bAcceptNonLinearRestrain; //是否接受非线性约束。
|
|
|
|
|
|
|
|
|
|
// 在转换成线性回归时,约束方式可能发生改变,在当前条件为指定参数约束,
|
|
|
|
|
// 转换时可能变成约束矩阵约束。因此不采用当前计算类由CLinearRegressAlgo派生,
|
|
|
|
|
// 而记录CLinearRegressAlgo作为成员的方式。以免其它成员变量受到影响。
|
|
|
|
|
zxAlgRegressLinear* m_pLinearRegress;
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|