public void SetConfigFiltrate( U50Filtrate filtrate )
        {
            m_ConfigBControlSub1.CheckBoxAllow.Checked = filtrate.PDU.Enabled;

            if ( filtrate.PDU.Select == U50SelectType.Any )
            {
                m_ConfigBControlSub1.RadioButtonAny.Checked = true;
            }
            else if ( filtrate.PDU.Select == U50SelectType.Big )
            {
                m_ConfigBControlSub1.RadioButtonBig.Checked = true;
            }
            else if ( filtrate.PDU.Select == U50SelectType.BigAndSmall )
            {
                m_ConfigBControlSub1.RadioButtonBigAndSmall.Checked = true;
            }
            else if ( filtrate.PDU.Select == U50SelectType.Small )
            {
                m_ConfigBControlSub1.RadioButtonSmall.Checked = true;
            }

            m_ConfigBControlSub1.MaskedTextBoxBig.Text = filtrate.PDU.Big.ToString( "000.0" );
            m_ConfigBControlSub1.MaskedTextBoxBig2.Text = filtrate.PDU.Big2.ToString( "000.0" );

            m_ConfigBControlSub1.MaskedTextBoxSmall.Text = filtrate.PDU.Small.ToString( "000.0" );
            m_ConfigBControlSub1.MaskedTextBoxSmall2.Text = filtrate.PDU.Small2.ToString( "000.0" );


            // 
            m_ConfigBControlSub2.CheckBoxAllow.Checked = filtrate.PCU.Enabled;

            if ( filtrate.PCU.Select == U50SelectType.Any )
            {
                m_ConfigBControlSub2.RadioButtonAny.Checked = true;
            }
            else if ( filtrate.PCU.Select == U50SelectType.Big )
            {
                m_ConfigBControlSub2.RadioButtonBig.Checked = true;
            }
            else if ( filtrate.PCU.Select == U50SelectType.BigAndSmall )
            {
                m_ConfigBControlSub2.RadioButtonBigAndSmall.Checked = true;
            }
            else if ( filtrate.PCU.Select == U50SelectType.Small )
            {
                m_ConfigBControlSub2.RadioButtonSmall.Checked = true;
            }

            m_ConfigBControlSub2.MaskedTextBoxBig.Text = filtrate.PCU.Big.ToString( "000.0" );
            m_ConfigBControlSub2.MaskedTextBoxBig2.Text = filtrate.PCU.Big2.ToString( "000.0" );

            m_ConfigBControlSub2.MaskedTextBoxSmall.Text = filtrate.PCU.Small.ToString( "000.0" );
            m_ConfigBControlSub2.MaskedTextBoxSmall2.Text = filtrate.PCU.Small2.ToString( "000.0" );


            // 
            m_ConfigBControlSub3.CheckBoxAllow.Checked = filtrate.TDU.Enabled;

            if ( filtrate.TDU.Select == U50SelectType.Any )
            {
                m_ConfigBControlSub3.RadioButtonAny.Checked = true;
            }
            else if ( filtrate.TDU.Select == U50SelectType.Big )
            {
                m_ConfigBControlSub3.RadioButtonBig.Checked = true;
            }
            else if ( filtrate.TDU.Select == U50SelectType.BigAndSmall )
            {
                m_ConfigBControlSub3.RadioButtonBigAndSmall.Checked = true;
            }
            else if ( filtrate.TDU.Select == U50SelectType.Small )
            {
                m_ConfigBControlSub3.RadioButtonSmall.Checked = true;
            }

            m_ConfigBControlSub3.MaskedTextBoxBig.Text = filtrate.TDU.Big.ToString( "000.0" );
            m_ConfigBControlSub3.MaskedTextBoxBig2.Text = filtrate.TDU.Big2.ToString( "000.0" );

            m_ConfigBControlSub3.MaskedTextBoxSmall.Text = filtrate.TDU.Small.ToString( "000.0" );
            m_ConfigBControlSub3.MaskedTextBoxSmall2.Text = filtrate.TDU.Small2.ToString( "000.0" );


            // 
            m_ConfigBControlSub4.CheckBoxAllow.Checked = filtrate.TCD.Enabled;

            if ( filtrate.TCD.Select == U50SelectType.Any )
            {
                m_ConfigBControlSub4.RadioButtonAny.Checked = true;
            }
            else if ( filtrate.TCD.Select == U50SelectType.Big )
            {
                m_ConfigBControlSub4.RadioButtonBig.Checked = true;
            }
            else if ( filtrate.TCD.Select == U50SelectType.BigAndSmall )
            {
                m_ConfigBControlSub4.RadioButtonBigAndSmall.Checked = true;
            }
            else if ( filtrate.TCD.Select == U50SelectType.Small )
            {
                m_ConfigBControlSub4.RadioButtonSmall.Checked = true;
            }

            m_ConfigBControlSub4.MaskedTextBoxBig.Text = filtrate.TCD.Big.ToString( "000.0" );
            m_ConfigBControlSub4.MaskedTextBoxBig2.Text = filtrate.TCD.Big2.ToString( "000.0" );

            m_ConfigBControlSub4.MaskedTextBoxSmall.Text = filtrate.TCD.Small.ToString( "000.0" );
            m_ConfigBControlSub4.MaskedTextBoxSmall2.Text = filtrate.TCD.Small2.ToString( "000.0" );

            // 
            m_ConfigBControlSub5.CheckBoxAllow.Checked = filtrate.TBU.Enabled;

            if ( filtrate.TBU.Select == U50SelectType.Any )
            {
                m_ConfigBControlSub5.RadioButtonAny.Checked = true;
            }
            else if ( filtrate.TBU.Select == U50SelectType.Big )
            {
                m_ConfigBControlSub5.RadioButtonBig.Checked = true;
            }
            else if ( filtrate.TBU.Select == U50SelectType.BigAndSmall )
            {
                m_ConfigBControlSub5.RadioButtonBigAndSmall.Checked = true;
            }
            else if ( filtrate.TBU.Select == U50SelectType.Small )
            {
                m_ConfigBControlSub5.RadioButtonSmall.Checked = true;
            }

            m_ConfigBControlSub5.MaskedTextBoxBig.Text = filtrate.TBU.Big.ToString( "000.0" );
            m_ConfigBControlSub5.MaskedTextBoxBig2.Text = filtrate.TBU.Big2.ToString( "000.0" );

            m_ConfigBControlSub5.MaskedTextBoxSmall.Text = filtrate.TBU.Small.ToString( "000.0" );
            m_ConfigBControlSub5.MaskedTextBoxSmall2.Text = filtrate.TBU.Small2.ToString( "000.0" );

            // 
            m_ConfigBControlSub6.CheckBoxAllow.Checked = filtrate.VacUC.Enabled;

            if ( filtrate.VacUC.Select == U50SelectType.Any )
            {
                m_ConfigBControlSub6.RadioButtonAny.Checked = true;
            }
            else if ( filtrate.VacUC.Select == U50SelectType.Big )
            {
                m_ConfigBControlSub6.RadioButtonBig.Checked = true;
            }
            else if ( filtrate.VacUC.Select == U50SelectType.BigAndSmall )
            {
                m_ConfigBControlSub6.RadioButtonBigAndSmall.Checked = true;
            }
            else if ( filtrate.VacUC.Select == U50SelectType.Small )
            {
                m_ConfigBControlSub6.RadioButtonSmall.Checked = true;
            }

            m_ConfigBControlSub6.MaskedTextBoxBig.Text = filtrate.VacUC.Big.ToString( "000.0" );
            m_ConfigBControlSub6.MaskedTextBoxBig2.Text = filtrate.VacUC.Big2.ToString( "000.0" );

            m_ConfigBControlSub6.MaskedTextBoxSmall.Text = filtrate.VacUC.Small.ToString( "000.0" );
            m_ConfigBControlSub6.MaskedTextBoxSmall2.Text = filtrate.VacUC.Small2.ToString( "000.0" );
        }
        public U50Filtrate GetConfigFiltrate()
        {
            U50Filtrate filtrate = new U50Filtrate();

            filtrate.PDU.Enabled = m_ConfigBControlSub1.CheckBoxAllow.Checked;

            if ( m_ConfigBControlSub1.RadioButtonAny.Checked == true )
            {
                filtrate.PDU.Select = U50SelectType.Any;
            }
            else if ( m_ConfigBControlSub1.RadioButtonBig.Checked == true )
            {
                filtrate.PDU.Select = U50SelectType.Big;
            }
            else if ( m_ConfigBControlSub1.RadioButtonBigAndSmall.Checked == true )
            {
                filtrate.PDU.Select = U50SelectType.BigAndSmall;
            }
            else if ( m_ConfigBControlSub1.RadioButtonSmall.Checked == true )
            {
                filtrate.PDU.Select = U50SelectType.Small;
            }

            filtrate.PDU.Big = float.Parse( m_ConfigBControlSub1.MaskedTextBoxBig.Text );
            filtrate.PDU.Big2 = float.Parse( m_ConfigBControlSub1.MaskedTextBoxBig2.Text );

            filtrate.PDU.Small = float.Parse( m_ConfigBControlSub1.MaskedTextBoxSmall.Text );
            filtrate.PDU.Small2 = float.Parse( m_ConfigBControlSub1.MaskedTextBoxSmall2.Text );


            // 
            filtrate.PCU.Enabled = m_ConfigBControlSub2.CheckBoxAllow.Checked;

            if ( m_ConfigBControlSub2.RadioButtonAny.Checked == true )
            {
                filtrate.PCU.Select = U50SelectType.Any;
            }
            else if ( m_ConfigBControlSub2.RadioButtonBig.Checked == true )
            {
                filtrate.PCU.Select = U50SelectType.Big;
            }
            else if ( m_ConfigBControlSub2.RadioButtonBigAndSmall.Checked == true )
            {
                filtrate.PCU.Select = U50SelectType.BigAndSmall;
            }
            else if ( m_ConfigBControlSub2.RadioButtonSmall.Checked == true )
            {
                filtrate.PCU.Select = U50SelectType.Small;
            }

            filtrate.PCU.Big = float.Parse( m_ConfigBControlSub2.MaskedTextBoxBig.Text );
            filtrate.PCU.Big2 = float.Parse( m_ConfigBControlSub2.MaskedTextBoxBig2.Text );

            filtrate.PCU.Small = float.Parse( m_ConfigBControlSub2.MaskedTextBoxSmall.Text );
            filtrate.PCU.Small2 = float.Parse( m_ConfigBControlSub2.MaskedTextBoxSmall2.Text );

            // 
            filtrate.TDU.Enabled = m_ConfigBControlSub3.CheckBoxAllow.Checked;

            if ( m_ConfigBControlSub3.RadioButtonAny.Checked == true )
            {
                filtrate.TDU.Select = U50SelectType.Any;
            }
            else if ( m_ConfigBControlSub3.RadioButtonBig.Checked == true )
            {
                filtrate.TDU.Select = U50SelectType.Big;
            }
            else if ( m_ConfigBControlSub3.RadioButtonBigAndSmall.Checked == true )
            {
                filtrate.TDU.Select = U50SelectType.BigAndSmall;
            }
            else if ( m_ConfigBControlSub3.RadioButtonSmall.Checked == true )
            {
                filtrate.TDU.Select = U50SelectType.Small;
            }

            filtrate.TDU.Big = float.Parse( m_ConfigBControlSub3.MaskedTextBoxBig.Text );
            filtrate.TDU.Big2 = float.Parse( m_ConfigBControlSub3.MaskedTextBoxBig2.Text );

            filtrate.TDU.Small = float.Parse( m_ConfigBControlSub3.MaskedTextBoxSmall.Text );
            filtrate.TDU.Small2 = float.Parse( m_ConfigBControlSub3.MaskedTextBoxSmall2.Text );

            // 
            filtrate.TCD.Enabled = m_ConfigBControlSub4.CheckBoxAllow.Checked;

            if ( m_ConfigBControlSub4.RadioButtonAny.Checked == true )
            {
                filtrate.TCD.Select = U50SelectType.Any;
            }
            else if ( m_ConfigBControlSub4.RadioButtonBig.Checked == true )
            {
                filtrate.TCD.Select = U50SelectType.Big;
            }
            else if ( m_ConfigBControlSub4.RadioButtonBigAndSmall.Checked == true )
            {
                filtrate.TCD.Select = U50SelectType.BigAndSmall;
            }
            else if ( m_ConfigBControlSub4.RadioButtonSmall.Checked == true )
            {
                filtrate.TCD.Select = U50SelectType.Small;
            }

            filtrate.TCD.Big = float.Parse( m_ConfigBControlSub4.MaskedTextBoxBig.Text );
            filtrate.TCD.Big2 = float.Parse( m_ConfigBControlSub4.MaskedTextBoxBig2.Text );

            filtrate.TCD.Small = float.Parse( m_ConfigBControlSub4.MaskedTextBoxSmall.Text );
            filtrate.TCD.Small2 = float.Parse( m_ConfigBControlSub4.MaskedTextBoxSmall2.Text );


            // 
            filtrate.TBU.Enabled = m_ConfigBControlSub5.CheckBoxAllow.Checked;

            if ( m_ConfigBControlSub5.RadioButtonAny.Checked == true )
            {
                filtrate.TBU.Select = U50SelectType.Any;
            }
            else if ( m_ConfigBControlSub5.RadioButtonBig.Checked == true )
            {
                filtrate.TBU.Select = U50SelectType.Big;
            }
            else if ( m_ConfigBControlSub5.RadioButtonBigAndSmall.Checked == true )
            {
                filtrate.TBU.Select = U50SelectType.BigAndSmall;
            }
            else if ( m_ConfigBControlSub5.RadioButtonSmall.Checked == true )
            {
                filtrate.TBU.Select = U50SelectType.Small;
            }

            filtrate.TBU.Big = float.Parse( m_ConfigBControlSub5.MaskedTextBoxBig.Text );
            filtrate.TBU.Big2 = float.Parse( m_ConfigBControlSub5.MaskedTextBoxBig2.Text );

            filtrate.TBU.Small = float.Parse( m_ConfigBControlSub5.MaskedTextBoxSmall.Text );
            filtrate.TBU.Small2 = float.Parse( m_ConfigBControlSub5.MaskedTextBoxSmall2.Text );

            // 
            filtrate.VacUC.Enabled = m_ConfigBControlSub6.CheckBoxAllow.Checked;

            if ( m_ConfigBControlSub6.RadioButtonAny.Checked == true )
            {
                filtrate.VacUC.Select = U50SelectType.Any;
            }
            else if ( m_ConfigBControlSub6.RadioButtonBig.Checked == true )
            {
                filtrate.VacUC.Select = U50SelectType.Big;
            }
            else if ( m_ConfigBControlSub6.RadioButtonBigAndSmall.Checked == true )
            {
                filtrate.VacUC.Select = U50SelectType.BigAndSmall;
            }
            else if ( m_ConfigBControlSub6.RadioButtonSmall.Checked == true )
            {
                filtrate.VacUC.Select = U50SelectType.Small;
            }

            filtrate.VacUC.Big = float.Parse( m_ConfigBControlSub6.MaskedTextBoxBig.Text );
            filtrate.VacUC.Big2 = float.Parse( m_ConfigBControlSub6.MaskedTextBoxBig2.Text );

            filtrate.VacUC.Small = float.Parse( m_ConfigBControlSub6.MaskedTextBoxSmall.Text );
            filtrate.VacUC.Small2 = float.Parse( m_ConfigBControlSub6.MaskedTextBoxSmall2.Text );

            return filtrate;
        }
        public static bool IsPassGeneral( StockData[] stockDataArray, Demo.Stock.X.Common.StockInfo stockInfo, U50Filtrate filtrateInfo, U50Extend extendInfo, ref U50ReportSub reportSub )
        {
            if ( stockDataArray == null )
                return false;

            if ( stockDataArray.Length < 3 )
                return false;

            // IsPassGeneral
            int iSKn = 1;

            int iH1Kn = GetStockInfoHighReturnKN( stockDataArray );
            if ( iH1Kn <= iSKn ) // iH1Kn > iSKn
                return false;

            int iL1Kn = GetStockInfoLowReturnKN( stockDataArray );
            if ( iL1Kn < iH1Kn ) // iL1Kn >= iH1Kn
                return false;

            int iL2Kn = GetStockInfoLow2ReturnKN( stockDataArray, iH1Kn - 1 );
            if ( iL2Kn < iSKn ) // iL2Kn >= iSKn
                return false;

            if ( iL2Kn >= iH1Kn ) // iL2Kn < iH1Kn
                return false;

            StockData stockDataS = stockDataArray[0];
            StockData stockDataH1 = stockDataArray[iH1Kn - 1];
            StockData stockDataL1 = stockDataArray[iL1Kn - 1];
            StockData stockDataL2 = stockDataArray[iL2Kn - 1];

            if ( stockDataL1.MinimumPrice >= stockDataL2.MinimumPrice )
                return false;

            if ( stockDataL1.MinimumPrice >= stockDataH1.HighestPrice )
                return false;

            if ( stockDataL1.MinimumPrice >= stockDataS.HighestPrice )
                return false;

            if ( stockDataL2.MinimumPrice >= stockDataH1.HighestPrice )
                return false;

            if ( stockDataL2.MinimumPrice >= stockDataS.HighestPrice )
                return false;

            if ( stockDataS.HighestPrice >= stockDataH1.HighestPrice )
            {
                float fRatio = ( stockDataS.HighestPrice - stockDataH1.HighestPrice ) / ( stockDataS.HighestPrice - stockDataL2.MinimumPrice );

                if ( fRatio >= 0.5 )
                    return false;
            }

            // IsPassFiltrate
            float fP_Up = stockDataH1.HighestPrice - stockDataL1.MinimumPrice; // 主升浪价格幅度
            float fP_Down = stockDataH1.HighestPrice - stockDataL2.MinimumPrice; // 下跌浪价格幅度
            float fP_Con = stockDataS.HighestPrice - stockDataL2.MinimumPrice; // 盘整浪价格幅度

            int iKn_Up = iL1Kn - iH1Kn + 1; // 主升浪K线总数
            int iKn_Down = iH1Kn - iL2Kn + 1; // 下跌浪的K线总数
            int iKn_Con = iL2Kn - iSKn + 1; // 盘整浪的K线总数
            int iKn_Conf = iH1Kn - iSKn + 1; // 整理区间的K线数量
            int iKn_U50 = iL1Kn; // U50形态的总K线数

            float fVa_Up = 0F; // 主升浪平均成交量
            for ( int i = 0; i < iKn_Up; i++ )
            {
                StockData stockData = stockDataArray[( iH1Kn - 1 ) + i];
                fVa_Up += stockData.TradingVolume;
            }
            fVa_Up = fVa_Up / iKn_Up;

            float fVa_Down = 0F; // 下跌浪平均成交量
            for ( int i = 0; i < iKn_Down; i++ )
            {
                StockData stockData = stockDataArray[( iL2Kn - 1 ) + i];
                fVa_Down += stockData.TradingVolume;
            }
            fVa_Down = fVa_Down / iKn_Down;

            float fVa_Con = 0F; // 盘整浪的平均成交量
            for ( int i = 0; i < iKn_Con; i++ )
            {
                StockData stockData = stockDataArray[( iSKn - 1 ) + i];
                fVa_Con += stockData.TradingVolume;
            }
            fVa_Con = fVa_Con / iKn_Con;

            float fVa_Conf = 0F; // 整理区间平均成交量
            for ( int i = 0; i < iKn_Conf; i++ )
            {
                StockData stockData = stockDataArray[( iSKn - 1 ) + i];
                fVa_Conf += stockData.TradingVolume;
            }
            fVa_Conf = fVa_Conf / iKn_Conf;

            float fVa_U50 = 0F; // U50形态平均成交量
            for ( int i = 0; i < iKn_U50; i++ )
            {
                StockData stockData = stockDataArray[( iSKn - 1 ) + i];
                fVa_U50 += stockData.TradingVolume;
            }
            fVa_U50 = fVa_U50 / iKn_U50;


            // 下面是价格比
            float fRatioPDU = ( fP_Down / fP_Up ) * 100;
            if ( filtrateInfo.PDU.Enabled == true )
            {
                if ( filtrateInfo.PDU.Select == U50SelectType.Big )
                {
                    if ( fRatioPDU <= filtrateInfo.PDU.Big )
                        return false;
                }
                else if ( filtrateInfo.PDU.Select == U50SelectType.Small )
                {

                    if ( fRatioPDU >= filtrateInfo.PDU.Small )
                        return false;
                }
                else if ( filtrateInfo.PDU.Select == U50SelectType.BigAndSmall )
                {
                    if ( fRatioPDU <= filtrateInfo.PDU.Big2 || fRatioPDU >= filtrateInfo.PDU.Small2 )
                        return false;
                }
            }

            float fRatioPCU = ( fP_Con / fP_Down ) * 100;
            if ( filtrateInfo.PCU.Enabled == true )
            {
                if ( filtrateInfo.PCU.Select == U50SelectType.Big )
                {
                    if ( fRatioPCU <= filtrateInfo.PCU.Big )
                        return false;
                }
                else if ( filtrateInfo.PCU.Select == U50SelectType.Small )
                {
                    if ( fRatioPCU >= filtrateInfo.PCU.Small )
                        return false;
                }
                else if ( filtrateInfo.PCU.Select == U50SelectType.BigAndSmall )
                {
                    if ( fRatioPCU <= filtrateInfo.PCU.Big2 || fRatioPCU >= filtrateInfo.PCU.Small2 )
                        return false;
                }
            }

            // 下面是K线比
            float fRatioTDU = ( (float)iKn_Down / (float)iKn_Up ) * 100;
            if ( filtrateInfo.TDU.Enabled == true )
            {
                if ( filtrateInfo.TDU.Select == U50SelectType.Big )
                {
                    if ( fRatioTDU <= filtrateInfo.TDU.Big )
                        return false;
                }
                else if ( filtrateInfo.TDU.Select == U50SelectType.Small )
                {
                    if ( fRatioTDU >= filtrateInfo.TDU.Small )
                        return false;
                }
                else if ( filtrateInfo.TDU.Select == U50SelectType.BigAndSmall )
                {
                    if ( fRatioTDU <= filtrateInfo.TDU.Big2 || fRatioTDU >= filtrateInfo.TDU.Small2 )
                        return false;
                }
            }

            float fRatioTCD = ( (float)iKn_Con / (float)iKn_Down ) * 100;
            if ( filtrateInfo.TCD.Enabled == true )
            {
                if ( filtrateInfo.TCD.Select == U50SelectType.Big )
                {
                    if ( fRatioTCD <= filtrateInfo.TCD.Big )
                        return false;
                }
                else if ( filtrateInfo.TCD.Select == U50SelectType.Small )
                {
                    if ( fRatioTCD >= filtrateInfo.TCD.Small )
                        return false;
                }
                else if ( filtrateInfo.TCD.Select == U50SelectType.BigAndSmall )
                {
                    if ( fRatioTCD <= filtrateInfo.TCD.Big2 || fRatioTCD >= filtrateInfo.TCD.Small2 )
                        return false;
                }
            }

            float fRatioTBU = ( (float)iKn_Conf / (float)iKn_Up ) * 100;
            if ( filtrateInfo.TBU.Enabled == true )
            {
                if ( filtrateInfo.TBU.Select == U50SelectType.Big )
                {
                    if ( fRatioTBU <= filtrateInfo.TBU.Big )
                        return false;
                }
                else if ( filtrateInfo.TBU.Select == U50SelectType.Small )
                {
                    if ( fRatioTBU >= filtrateInfo.TBU.Small )
                        return false;
                }
                else if ( filtrateInfo.TBU.Select == U50SelectType.BigAndSmall )
                {
                    if ( fRatioTBU <= filtrateInfo.TBU.Big2 || fRatioTBU >= filtrateInfo.TBU.Small2 )
                        return false;
                }
            }

            // 下面是成交量比
            float fRatioVac_UC = ( fVa_Up / fVa_Con ) * 100;
            if ( filtrateInfo.VacUC.Enabled == true )
            {
                if ( filtrateInfo.VacUC.Select == U50SelectType.Big )
                {
                    if ( fRatioVac_UC <= filtrateInfo.VacUC.Big )
                        return false;
                }
                else if ( filtrateInfo.VacUC.Select == U50SelectType.Small )
                {
                    if ( fRatioVac_UC >= filtrateInfo.VacUC.Small )
                        return false;
                }
                else if ( filtrateInfo.VacUC.Select == U50SelectType.BigAndSmall )
                {
                    if ( fRatioVac_UC <= filtrateInfo.VacUC.Big2 || fRatioVac_UC >= filtrateInfo.VacUC.Small2 )
                        return false;
                }
            }

            // IsPassExtend
            // H1的价格数据
            if ( extendInfo.Info01.Enabled == true )
            {
                if ( extendInfo.Info01.Select == U50ExtendInfo01Type.High )
                {
                    StockData[] stockDataArray2 = stockInfo.GetStockDataRangeByTime( stockDataL1.TradingDate );
                    foreach ( StockData stockData in stockDataArray2 )
                    {
                        if ( stockDataH1.HighestPrice <= stockData.HighestPrice )
                            return false;
                    }
                }
                else if ( extendInfo.Info01.Select == U50ExtendInfo01Type.HighNumber )
                {
                    StockData[] stockDataArray2 = stockInfo.GetStockDataRangeByKn( stockDataL1.TradingDate, extendInfo.Info01.HighNumber );
                    foreach ( StockData stockData in stockDataArray2 )
                    {
                        if ( stockDataH1.HighestPrice <= stockData.HighestPrice )
                            return false;
                    }
                }
            }

            // U50形态的平均成交量
            if ( extendInfo.Info02.Enabled == true )
            {
                if ( extendInfo.Info02.Select == U50SelectType.Big )
                {
                    if ( fVa_U50 <= extendInfo.Info02.Big )
                        return false;
                }
                else if ( extendInfo.Info02.Select == U50SelectType.Small )
                {
                    if ( fVa_U50 >= extendInfo.Info02.Small )
                        return false;
                }
                else if ( extendInfo.Info02.Select == U50SelectType.BigAndSmall )
                {
                    if ( fVa_U50 <= extendInfo.Info02.Big2 || fVa_U50 >= extendInfo.Info02.Small2 )
                        return false;
                }
            }

            // 当日成交量与U50形态平均成交量比值
            if ( extendInfo.Info03.Enabled == true )
            {
                float fVsc = ( stockDataH1.TradingVolume / fVa_U50 ) * 100;

                if ( extendInfo.Info03.Select == U50SelectType.Big )
                {
                    if ( fVsc <= extendInfo.Info03.Big )
                        return false;
                }
                else if ( extendInfo.Info03.Select == U50SelectType.Small )
                {
                    if ( fVsc >= extendInfo.Info03.Small )
                        return false;
                }
                else if ( extendInfo.Info03.Select == U50SelectType.BigAndSmall )
                {
                    if ( fVsc <= extendInfo.Info03.Big2 || fVsc >= extendInfo.Info03.Small2 )
                        return false;
                }
            }

            // PS≧PH1?
            if ( extendInfo.Info04.Enabled == true )
            {
                if ( extendInfo.Info04.Select == U50ExtendInfo04Type.No )
                {
                    if ( stockDataS.HighestPrice > stockDataH1.HighestPrice ) // PS <= PH1
                        return false;
                }
                else if ( extendInfo.Info04.Select == U50ExtendInfo04Type.Yes )
                {
                    if ( stockDataS.HighestPrice < stockDataH1.HighestPrice ) // PS >= PH1
                        return false;
                }
            }

            // S点所属K线的收盘价
            if ( extendInfo.Info05.Enabled == true )
            {
                if ( extendInfo.Info05.Select == U50SelectType.Big )
                {
                    if ( stockDataS.ClosePrice <= extendInfo.Info05.Big )
                        return false;
                }
                else if ( extendInfo.Info05.Select == U50SelectType.Small )
                {
                    if ( stockDataS.ClosePrice >= extendInfo.Info05.Small )
                        return false;
                }
                else if ( extendInfo.Info05.Select == U50SelectType.BigAndSmall )
                {
                    if ( stockDataS.ClosePrice <= extendInfo.Info05.Big2 || stockDataS.ClosePrice >= extendInfo.Info05.Small2 )
                        return false;
                }
            }


            reportSub.Q_U50 = 0;
            reportSub.KLineNumber = iKn_U50;
            reportSub.Va_U50 = fVa_U50;
            reportSub.Vsc = stockDataS.TradingVolume;
            reportSub.Close = stockDataS.ClosePrice;

            Debug.WriteLine( " " );
            Debug.WriteLine( " " );
            Debug.WriteLine( " " );
            Debug.WriteLine( " --- --- --- --- ---" );

            Debug.WriteLine( "StockSymbol: --- " + " stockInfo.StockSymbol = " + stockInfo.StockSymbol );
            Debug.WriteLine( "H1TradingDateTime: --- " + " stockDataH1.TradingDateTime = " + stockDataH1.TradingDateTime.ToString() );
            Debug.WriteLine( "L1TradingDateTime: --- " + " stockDataL1.TradingDateTime = " + stockDataL1.TradingDateTime.ToString() );
            Debug.WriteLine( "L2TradingDateTime: --- " + " stockDataL2.TradingDateTime = " + stockDataL2.TradingDateTime.ToString() );
            Debug.WriteLine( "fP_Down: --- " + " stockDataH1.HighestPrice = " + stockDataH1.HighestPrice.ToString() + " stockDataL2.MinimumPrice = " + stockDataL2.MinimumPrice.ToString() );
            Debug.WriteLine( "fP_Up: --- " + " stockDataH1.HighestPrice = " + stockDataH1.HighestPrice.ToString() + " stockDataL1.MinimumPrice = " + stockDataL1.MinimumPrice.ToString() );
            Debug.WriteLine( "fRatioPDU: --- " + " fP_Down = " + fP_Down.ToString() + " fP_Up = " + fP_Up.ToString() + " fRatioPDU = " + fRatioPDU.ToString() );
            Debug.WriteLine( "PDU.Small: --- " + "Select = " + filtrateInfo.PDU.Select.ToString() + " filtrateInfo.PDU.Small = " + filtrateInfo.PDU.Small.ToString() );
            Debug.WriteLine( "stockDataS.Close: --- " + "reportSub.Close = " + reportSub.Close.ToString() );
            Debug.WriteLine( "Kn_U50: --- " + "reportSub.KLineNumber= " + reportSub.KLineNumber.ToString() );

            Debug.WriteLine( " --- --- --- --- ---" );

            return true;
        }