⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 pnspssca.h

📁 PQDIF软件包(SDK,Software Development Kit),它能转换、生成并且显示PQDIF文件.对于开发电力系统的数据输出非常有用。
💻 H
字号:
/*
**  Class PQNodeSpectrumSSCalcs
**      This class caluclates and holds a number of steady state quantities
**      from spectrum information.  This object can take a voltage and
**      current pair and calculate power information.
**
*/

#ifndef PNSPSSCA_INC
#define PNSPSSCA_INC

class PQNodeSpectrum;

class PQNodeSpectrumSSCalcs
    {
    private:
        int idConnect;
        BOOL bVolt;
        int iVChannel;
        float fRMSV;
        BOOL bCurr;
        int iIChannel;
        float fRMSI;

        BOOL bPair;
        float fApp;
        float fP1;
        float fQ1;
        float fS1;
        float fTotPow;
        float fTotVar;
        float fTPF;
        float fDPF;
        float *pfRePow;
        float *pfImPow;

        void CalcPowerStuff(float *pfVMag,float *pfVAng,int iNumVPoints,
                            float *pfIMag,float *pfIAng,int iNumIPoints,
                            float fVoltGain);
    protected:


    public:

        /*
        ** Main form of the constructor usually called by one of the 
        ** disturbance decoder modules.  Not normally called by an app
        ** directly since app doesn't have direct access to some of the info.
        */
        PQNodeSpectrumSSCalcs(int iVChan,int iNumVPnt,
                              float *pVMag,float *pVAng,
                              int iIChan,int iNumIPnt,
                              float *pIData, float *pIAng,
                              int idConn, float fVoltGain);

        /*
        ** Main form of the constructor usually called by one of the 
        ** disturbance decoder modules.  Not normally called by an app
        ** directly since app doesn't have direct access to some of the info.
        */
        PQNodeSpectrumSSCalcs(PQNodeSpectrum * pVChan,
                              PQNodeSpectrum * pIChan,
                              int idConn, float fVoltGain);

        ~PQNodeSpectrumSSCalcs();

        /*
        ** Methods to report the channel numbers used to create this 
        ** object.  Standard channel numbering.
        */
        int GetVChannel() {return iVChannel;}
        int GetIChannel() {return iIChannel;}

        /*
        ** Methods to indicate if the voltage, current or power data
        ** in the object are valid.  The validity is based on what data is
        ** supplied at construction and the connection type.
        */
        BOOL IsVoltageValid() {return bVolt;}
        BOOL IsCurrentValid() {return bCurr;}
        BOOL IsPowerValid() {return bPair;}

        /*
        ** Methods to return the minimum, maximum, RMS and peak values 
        ** of the voltage waveform.  The voltages will be in the units 
        ** specified by the VoltPref parameter to the constructor.
        */
        float GetVRMS() {return fRMSV;}

        /*
        ** Methods to return the minimum, maximum, RMS and peak values 
        ** of the current waveform.  Always in amps.
        */
        float GetIRMS() {return fRMSI;}

        /*
        ** Methods to retun power, apparent power, real pf and kvar.
        */
        float GetPower(int iHarm = 1) {if (bPair) return pfRePow[iHarm]; else return 0.0f;}
        float GetQ(int iHarm = 1) {if (bPair) return pfImPow[iHarm]; else return 0.0f;}
        float GetTotPower() {return fTotPow;}
        float GetTotQ() {return fTotVar;}
        float GetAppPower() {return fApp;}
        float GetTruePF() {return fTPF;}
        float GetDispPF() {return fDPF;}

    };

#endif

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -