|
|
|
|
#pragma once
|
|
|
|
|
|
|
|
|
|
#include "iWxPvtUtilItem.h"
|
|
|
|
|
|
|
|
|
|
class iWxPseudoCSub;
|
|
|
|
|
class iWxPseudoCSubSo;
|
|
|
|
|
class iWxPseudoCSubInput;
|
|
|
|
|
class iWxPseudoCSubPseu;
|
|
|
|
|
class iPseudoCInfo;
|
|
|
|
|
class M_TOOL_PVT_EXPORT iWxPvtUtilItemPseudoC : public iWxPvtUtilItem
|
|
|
|
|
{
|
|
|
|
|
Q_OBJECT
|
|
|
|
|
|
|
|
|
|
public:
|
|
|
|
|
|
|
|
|
|
explicit iWxPvtUtilItemPseudoC(QWidget *parent = 0);
|
|
|
|
|
~iWxPvtUtilItemPseudoC();
|
|
|
|
|
|
|
|
|
|
// 初始化
|
|
|
|
|
virtual void initUI();
|
|
|
|
|
|
|
|
|
|
// 传递参数
|
|
|
|
|
virtual void setInfos(QString sFluidType, QString sPhaseType, QString sPara);
|
|
|
|
|
|
|
|
|
|
// 最后一个SubWx
|
|
|
|
|
iWxPseudoCSub* getSubWxPseu();
|
|
|
|
|
iWxPseudoCSub* getSubWxBy(QString sName);
|
|
|
|
|
iWxPseudoCSubInput* getSubWxInputs();
|
|
|
|
|
|
|
|
|
|
// 传递参数
|
|
|
|
|
//void calAndFreshBy(VecDouble& vecX);
|
|
|
|
|
|
|
|
|
|
// 最终的计算函数
|
|
|
|
|
//bool calPseudoC(VecDouble& vecP, VecDouble& vecPs, QString& sAllExpr, bool bLogging);
|
|
|
|
|
|
|
|
|
|
// 刷新最终的Sub图表
|
|
|
|
|
//bool freshFinalPs(VecDouble& vecP, VecDouble& vecPs, QString sAllExpr);
|
|
|
|
|
|
|
|
|
|
// 返回数据,触发信息
|
|
|
|
|
bool getPvtPseuInfos(VVecDouble& vvec, \
|
|
|
|
|
QMap<QString, iPseudoCInfo*>& mapPsInfos, \
|
|
|
|
|
QMap<QString, double>& mapOthers);
|
|
|
|
|
|
|
|
|
|
// 保存
|
|
|
|
|
// void saveBkInfos();
|
|
|
|
|
|
|
|
|
|
// 文件标识
|
|
|
|
|
virtual QString getFilePvtTag();
|
|
|
|
|
virtual bool savePvt();
|
|
|
|
|
|
|
|
|
|
virtual void fuzzyLayoutWH(int n, int& szW, int& szH);
|
|
|
|
|
|
|
|
|
|
private:
|
|
|
|
|
|
|
|
|
|
virtual void initUI_MethodOptions();
|
|
|
|
|
|
|
|
|
|
// 除了第一个之外,其它Radio隐藏与显示
|
|
|
|
|
void showMostRadios(bool bVisible, VVecDouble* pVVecResults);
|
|
|
|
|
|
|
|
|
|
// 算法有多少种
|
|
|
|
|
virtual void dealwithMethods();
|
|
|
|
|
|
|
|
|
|
// 算法切换
|
|
|
|
|
void refreshByMethod(QString s);
|
|
|
|
|
|
|
|
|
|
// 准备
|
|
|
|
|
void preparePsInfos(QMap<QString, iPseudoCInfo*>& mapInfos, bool bOut);
|
|
|
|
|
void prepareOthers();
|
|
|
|
|
|
|
|
|
|
// 根据名称查找FitAlg
|
|
|
|
|
iPseudoCInfo* findAlgFitInfo(QString sName);
|
|
|
|
|
|
|
|
|
|
void freshSubWxSo(iWxPseudoCSubSo* pSub);
|
|
|
|
|
void freshSubWxPseu(iWxPseudoCSubPseu* pSub);
|
|
|
|
|
bool fuzzyFitAboutInfos(QMap<QString, iPseudoCInfo*>& map, \
|
|
|
|
|
QStringList& listFitNames, \
|
|
|
|
|
VecDouble& vecX, int& nSplitIndex);
|
|
|
|
|
|
|
|
|
|
signals:
|
|
|
|
|
|
|
|
|
|
private slots:
|
|
|
|
|
void slotInputRefresh(bool bVisible, VVecDouble* pVVecResults);
|
|
|
|
|
void slotSubWxChanged(int);
|
|
|
|
|
// void slotRefreshPseu();
|
|
|
|
|
|
|
|
|
|
private:
|
|
|
|
|
|
|
|
|
|
QStackedWidget* m_pStackedWx;
|
|
|
|
|
|
|
|
|
|
VecDouble m_vecX;
|
|
|
|
|
QMap<QString, double> m_mapOthers;
|
|
|
|
|
|
|
|
|
|
// 临时,对应Input的计算结果数据
|
|
|
|
|
VVecDouble* m_pVVecPtrOfPE;
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|