当前位置: 首页>>代码示例>>C#>>正文


C# WFloInterface.EndWellFlo方法代码示例

本文整理汇总了C#中WFloInterface.EndWellFlo方法的典型用法代码示例。如果您正苦于以下问题:C# WFloInterface.EndWellFlo方法的具体用法?C# WFloInterface.EndWellFlo怎么用?C# WFloInterface.EndWellFlo使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在WFloInterface的用法示例。


在下文中一共展示了WFloInterface.EndWellFlo方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: LayerCollection_A2_CountAll

        public void LayerCollection_A2_CountAll()
        {
            using (new LifeTimeScope())
            {
                WFloInterface WFInt = new WFloInterface();
                WFInt.AddRef();

                string sfile = WellFloFileLocation.BaselineWPSModel("WPS_Layer\\layers active.wflx");

                WFInt.OpenFile(sfile);

                short Actual = WFInt.WellModel.AddRef().Layers.AddRef().CountAll;

                //short Expected = 2;

                WFInt.EndWellFlo();
                //Assert.AreEqual(Expected, Actual);
                AreEqual("CountAll", Actual);
            }
        }
开发者ID:prasannarhegde2015,项目名称:SampleUnitTests,代码行数:20,代码来源:WPS_Layer.cs

示例2: LayerCollection_A3_Item

        public void LayerCollection_A3_Item()
        {
            using (new LifeTimeScope())
            {
                WFloInterface WFInt = new WFloInterface();
                WFInt.AddRef();

                string sfile = WellFloFileLocation.BaselineWPSModel("WPS_Layer\\layer.wflx");

                WFInt.OpenFile(sfile);

                double Actual = Math.Round(WFInt.WellModel.AddRef().Layers.AddRef().Item(1).AddRef().DietzFactor, 1);

                //double Expected = 31.6;

                WFInt.EndWellFlo();
                //Assert.AreEqual(Expected, Actual, DeltaFraction.Default(Expected));
                AreEqual("DietzFactor", 31.6);
            }
        }
开发者ID:prasannarhegde2015,项目名称:SampleUnitTests,代码行数:20,代码来源:WPS_Layer.cs

示例3: LayerRate_Set4_A1_GetAt_Name

        public void LayerRate_Set4_A1_GetAt_Name()
        {
            using (new LifeTimeScope())
            {
                WFloInterface WFInt = new WFloInterface();
                WFInt.AddRef();

                string sfile = WellFloFileLocation.BaselineWPSModel("WPS_Layer\\layer rate - set 4.wflx");

                WFInt.OpenFile(sfile);

                double dRate = 21780.34;

                WFInt.GetLayerRateCalculator().AddRef().Calculate(dRate);

                int i = 0;

                string Actual = WFInt.GetLayerRateCalculator().AddRef().LayerRates.AddRef().GetAt(i).AddRef().Name;

                string Expected = "Layer 1";

                WFInt.EndWellFlo();
                Assert.AreEqual(Expected, Actual);
            }
        }
开发者ID:prasannarhegde2015,项目名称:SampleUnitTests,代码行数:25,代码来源:WPS_Layer.cs

示例4: LayerRate_Set3_A2_Item_WaterRate

        public void LayerRate_Set3_A2_Item_WaterRate()
        {
            using (new LifeTimeScope())
            {
                WFloInterface WFInt = new WFloInterface();
                WFInt.AddRef();

                string sfile = WellFloFileLocation.BaselineWPSModel("WPS_Layer\\one layer active and one is inactive.wflx");

                WFInt.OpenFile(sfile);

                double dRate = 92987.929;

                WFInt.GetLayerRateCalculator().AddRef().Calculate(dRate);

                string sName = "Layer 2";

                double Actual = Math.Round(WFInt.GetLayerRateCalculator().AddRef().LayerRates.AddRef().Item(sName).AddRef().WaterRate, 2);

                double Expected = 23246.98;

                WFInt.EndWellFlo();
                Assert.AreEqual(Expected, Actual, DeltaFraction.Default(Expected));
            }
        }
开发者ID:prasannarhegde2015,项目名称:SampleUnitTests,代码行数:25,代码来源:WPS_Layer.cs

示例5: LayerRate_Set2_A5_RemoveAll

        public void LayerRate_Set2_A5_RemoveAll()
        {
            using (new LifeTimeScope())
            {
                WFloInterface WFInt = new WFloInterface();
                WFInt.AddRef();

                string sfile1 = WellFloFileLocation.BaselineWPSModel("WPS_Layer\\get-one layer.wflx");

                string sfile2 = WellFloFileLocation.BaselineWPSModel("WPS_Layer\\get-one layer_RemoveAll.wflx");

                WFInt.OpenFile(sfile1);

                WFInt.SaveFile(sfile2);

                double dRate = 37100;

                WFInt.GetLayerRateCalculator().AddRef().Calculate(dRate);

                WFInt.GetLayerRateCalculator().AddRef().LayerRates.AddRef().RemoveAll();

                WFInt.SaveFile(sfile2);

                WFInt.OpenFile(sfile2);

                int Actual = WFInt.GetLayerRateCalculator().AddRef().LayerRates.AddRef().Count;

                int Expected = 0;

                WFInt.EndWellFlo();
                Assert.AreEqual(Expected, Actual);
            }
        }
开发者ID:prasannarhegde2015,项目名称:SampleUnitTests,代码行数:33,代码来源:WPS_Layer.cs

示例6: Layer_A3_PartingPressure

        public void Layer_A3_PartingPressure()
        {
            using (new LifeTimeScope())
            {
                WFloInterface WFInt = new WFloInterface();
                WFInt.AddRef();

                string sfile1 = WellFloFileLocation.BaselineWPSModel("WPS_Layer\\injection well.wflx");

                WFInt.OpenFile(sfile1);

                double Actual = Math.Round(WFInt.WellModel.AddRef().Layers.AddRef().Item(1).AddRef().PartingPressure, 0);

                double Expected = 7000;

                WFInt.EndWellFlo();
                Assert.AreEqual(Expected, Actual, DeltaFraction.Default(Expected));
            }
        }
开发者ID:prasannarhegde2015,项目名称:SampleUnitTests,代码行数:19,代码来源:WPS_Layer.cs

示例7: LayerRate_Set4_A3_Count

        public void LayerRate_Set4_A3_Count()
        {
            using (new LifeTimeScope())
            {
                WFloInterface WFInt = new WFloInterface();
                WFInt.AddRef();

                string sfile = WellFloFileLocation.BaselineWPSModel("WPS_Layer\\layer rate - set 4.wflx");

                WFInt.OpenFile(sfile);

                double dRate = 92987.929;

                WFInt.GetLayerRateCalculator().AddRef().Calculate(dRate);

                int Actual = WFInt.GetLayerRateCalculator().AddRef().LayerRates.AddRef().Count;

                int Expected = 1;

                WFInt.EndWellFlo();
                Assert.AreEqual(Expected, Actual);
            }
        }
开发者ID:prasannarhegde2015,项目名称:SampleUnitTests,代码行数:23,代码来源:WPS_Layer.cs

示例8: Layer_B2_SetTestPoint1Data_TestPoint1Rate

        public void Layer_B2_SetTestPoint1Data_TestPoint1Rate()
        {
            using (new LifeTimeScope())
            {
                WFloInterface WFInt = new WFloInterface();
                WFInt.AddRef();

                string sfile = WellFloFileLocation.BaselineWPSModel("WPS_Layer\\test rate.wflx");

                string sfileOutput2 = WellFloFileLocation.BaselineWPSModel("WPS_Layer\\SetTestPoint1Data_AfterSetting_2.wflx");

                WFInt.OpenFile(sfile);

                double dBHP = 4500;
                double dQLiq = 1050;

                WFInt.WellModel.AddRef().Layers.AddRef().Item(1).AddRef().SetTestPoint1Data(dBHP, dQLiq);

                WFInt.SaveFile(sfileOutput2);

                double Actual = WFInt.WellModel.AddRef().Layers.AddRef().Item(1).AddRef().TestPoint1Rate;

                double Expected = 1050;

                WFInt.EndWellFlo();
                Assert.AreEqual(Expected, Actual, DeltaFraction.Default(Expected));
            }
        }
开发者ID:prasannarhegde2015,项目名称:SampleUnitTests,代码行数:28,代码来源:WPS_Layer.cs

示例9: Layer_New_VogelPCoefficient

        public void Layer_New_VogelPCoefficient()
        {
            using (new LifeTimeScope())
            {
                WFloInterface WFInt = new WFloInterface();
                WFInt.AddRef();

                string sfile1 = WellFloFileLocation.BaselineWPSModel("WPS_Layer\\layers active.wflx");

                WFInt.OpenFile(sfile1);

                double Actual = Math.Round(WFInt.WellModel.AddRef().Layers.AddRef().Item(2).AddRef().VogelPCoefficient, 2);

                double Expected = 0.2;

                WFInt.EndWellFlo();
                Assert.AreEqual(Expected, Actual, DeltaFraction.Default(Expected));
            }
        }
开发者ID:prasannarhegde2015,项目名称:SampleUnitTests,代码行数:19,代码来源:WPS_Layer.cs

示例10: Layer_A9_GetRelPermTable_225_A

        public void Layer_A9_GetRelPermTable_225_A()
        {
            using (new LifeTimeScope())
            {
                WFloInterface WFInt = new WFloInterface();
                WFInt.AddRef();

                string sfile1 = WellFloFileLocation.BaselineWPSModel("WPS_Layer\\real perm table.wflx");

                WFInt.OpenFile(sfile1);

                Array psaRelParms3 = Array.CreateInstance(typeof(double), 3, 3, 10);

                WFInt.WellModel.AddRef().Layers.AddRef().Item(1).AddRef().GetRelPermTable(ref psaRelParms3);

                string i = psaRelParms3.GetValue(2, 1, 0).ToString();

                double Actual = System.Convert.ToDouble(i);

                double Expected = 0.0000085;

                WFInt.EndWellFlo();
                Assert.AreEqual(Expected, Actual, DeltaFraction.Default(Expected));
            }
        }
开发者ID:prasannarhegde2015,项目名称:SampleUnitTests,代码行数:25,代码来源:WPS_Layer.cs

示例11: Layer_B1_SetTabulatedIPRData


//.........这里部分代码省略.........
                psaPress1.SetValue(416.418, 1);
                psaPress1.SetValue(818.185, 2);
                psaPress1.SetValue(1219.953, 3);
                psaPress1.SetValue(1621.720, 4);
                psaPress1.SetValue(2023.488, 5);
                psaPress1.SetValue(2425.255, 6);
                psaPress1.SetValue(2827.022, 7);
                psaPress1.SetValue(3228.790, 8);
                psaPress1.SetValue(3630.558, 9);
                psaPress1.SetValue(4032.325, 10);
                psaPress1.SetValue(4434.093, 11);
                psaPress1.SetValue(4835.860, 12);
                psaPress1.SetValue(5237.637, 13);
                psaPress1.SetValue(5639.395, 14);
                psaPress1.SetValue(6041.163, 15);
                psaPress1.SetValue(6442.930, 16);
                psaPress1.SetValue(6844.698, 17);
                psaPress1.SetValue(7246.465, 18);
                psaPress1.SetValue(7648.233, 19);
                psaPress1.SetValue(8050.000, 20);

                psaFlowRate1.SetValue(0.1239, 0);
                psaFlowRate1.SetValue(0.1177, 1);
                psaFlowRate1.SetValue(0.1115, 2);
                psaFlowRate1.SetValue(0.1053, 3);
                psaFlowRate1.SetValue(0.0991, 4);
                psaFlowRate1.SetValue(0.0929, 5);
                psaFlowRate1.SetValue(0.0867, 6);
                psaFlowRate1.SetValue(0.0805, 7);
                psaFlowRate1.SetValue(0.0743, 8);
                psaFlowRate1.SetValue(0.0681, 9);
                psaFlowRate1.SetValue(0.0620, 10);
                psaFlowRate1.SetValue(0.0558, 11);
                psaFlowRate1.SetValue(0.0496, 12);
                psaFlowRate1.SetValue(0.0434, 13);
                psaFlowRate1.SetValue(0.0372, 14);
                psaFlowRate1.SetValue(0.0310, 15);
                psaFlowRate1.SetValue(0.0248, 16);
                psaFlowRate1.SetValue(0.0186, 17);
                psaFlowRate1.SetValue(0.0124, 18);
                psaFlowRate1.SetValue(0.0062, 19);
                psaFlowRate1.SetValue(0, 20);

                psaPhaseRate1.SetValue(6666.6665, 0);
                psaPhaseRate1.SetValue(6666.6665, 1);
                psaPhaseRate1.SetValue(6666.6665, 2);
                psaPhaseRate1.SetValue(6666.6665, 3);
                psaPhaseRate1.SetValue(6666.6665, 4);
                psaPhaseRate1.SetValue(6666.6665, 5);
                psaPhaseRate1.SetValue(6666.6665, 6);
                psaPhaseRate1.SetValue(6666.6665, 7);
                psaPhaseRate1.SetValue(6666.6665, 8);
                psaPhaseRate1.SetValue(6666.6665, 9);
                psaPhaseRate1.SetValue(6666.6665, 10);
                psaPhaseRate1.SetValue(6666.6665, 11);
                psaPhaseRate1.SetValue(6666.6665, 12);
                psaPhaseRate1.SetValue(6666.6665, 13);
                psaPhaseRate1.SetValue(6666.6665, 14);
                psaPhaseRate1.SetValue(6666.6665, 15);
                psaPhaseRate1.SetValue(6666.6665, 16);
                psaPhaseRate1.SetValue(6666.6665, 17);
                psaPhaseRate1.SetValue(6666.6665, 18);
                psaPhaseRate1.SetValue(6666.6665, 19);
                psaPhaseRate1.SetValue(6666.6665, 20);

                psaWaterRate1.SetValue(0.5000, 0);
                psaWaterRate1.SetValue(0.5000, 1);
                psaWaterRate1.SetValue(0.5000, 2);
                psaWaterRate1.SetValue(0.5000, 3);
                psaWaterRate1.SetValue(0.5000, 4);
                psaWaterRate1.SetValue(0.5000, 5);
                psaWaterRate1.SetValue(0.5000, 6);
                psaWaterRate1.SetValue(0.5000, 7);
                psaWaterRate1.SetValue(0.5000, 8);
                psaWaterRate1.SetValue(0.5000, 9);
                psaWaterRate1.SetValue(0.5000, 10);
                psaWaterRate1.SetValue(0.5000, 11);
                psaWaterRate1.SetValue(0.5000, 12);
                psaWaterRate1.SetValue(0.5000, 13);
                psaWaterRate1.SetValue(0.5000, 14);
                psaWaterRate1.SetValue(0.5000, 15);
                psaWaterRate1.SetValue(0.5000, 16);
                psaWaterRate1.SetValue(0.5000, 17);
                psaWaterRate1.SetValue(0.5000, 18);
                psaWaterRate1.SetValue(0.5000, 19);
                psaWaterRate1.SetValue(0.5000, 20);

                WFInt.WellModel.AddRef().Layers.AddRef().Item(1).AddRef().SetTabulatedIPRData(indexArray, ref psaPress1, ref psaFlowRate1, ref psaPhaseRate1, ref psaWaterRate1);

                WFInt.SaveFile(sfileOutputSetTabulatedIPRData);

                short Actual = WFInt.ErrorStatus;

                short Expected = 0;

                WFInt.EndWellFlo();
                Assert.AreEqual(Expected, Actual);

            }
        }
开发者ID:prasannarhegde2015,项目名称:SampleUnitTests,代码行数:101,代码来源:WPS_Layer.cs

示例12: Layer_A8_GetRelPermParmsGasOil_3_psaExp_1

        public void Layer_A8_GetRelPermParmsGasOil_3_psaExp_1()
        {
            using (new LifeTimeScope())
            {
                WFloInterface WFInt = new WFloInterface();
                WFInt.AddRef();

                string sfile1 = WellFloFileLocation.BaselineWPSModel("WPS_Layer\\real perm.wflx");

                WFInt.OpenFile(sfile1);

                Array psaRelParms2 = Array.CreateInstance(typeof(double), 2);
                Array psaIrrSat2 = Array.CreateInstance(typeof(double), 2);
                Array psaExp2 = Array.CreateInstance(typeof(double), 2);

                WFInt.WellModel.AddRef().Layers.AddRef().Item(1).AddRef().GetRelPermParmsGasOil(ref psaRelParms2, ref psaIrrSat2, ref psaExp2);

                string i = psaExp2.GetValue(1).ToString();

                double Actual = Math.Round(System.Convert.ToDouble(i), 2);

                double Expected = 1.7;

                WFInt.EndWellFlo();
                Assert.AreEqual(Expected, Actual, DeltaFraction.Default(Expected));
            }
        }
开发者ID:prasannarhegde2015,项目名称:SampleUnitTests,代码行数:27,代码来源:WPS_Layer.cs

示例13: Layer_A5_CalcBHPOfOilWell

        public void Layer_A5_CalcBHPOfOilWell()
        {
            using (new LifeTimeScope())
            {
                WFloInterface WFInt = new WFloInterface();
                WFInt.AddRef();

                string sfile1 = WellFloFileLocation.BaselineWPSModel("WPS_Layer\\oil well BHP.wflx");

                WFInt.OpenFile(sfile1);

                double fQOil = 2696.4;
                double fGOR = 500;
                double fWCT = 0.25;
                double fTHP = 100;

                double Actual = Math.Round(WFInt.WellModel.AddRef().Layers.AddRef().Item(1).AddRef().CalcBHPOfOilWell(fQOil, fGOR, fWCT, fTHP), 3);

                double Expected1 = 4043.613;
                double Expected = Math.Round(Expected1, 3);

                WFInt.EndWellFlo();
                Assert.AreEqual(Expected, Actual, DeltaFraction.Default(Expected));
            }
        }
开发者ID:prasannarhegde2015,项目名称:SampleUnitTests,代码行数:25,代码来源:WPS_Layer.cs

示例14: Layer_A4_CalcBHPOfGasWell

        public void Layer_A4_CalcBHPOfGasWell()
        {
            using (new LifeTimeScope())
            {
                WFloInterface WFInt = new WFloInterface();
                WFInt.AddRef();

                string sfile1 = WellFloFileLocation.BaselineWPSModel("WPS_Layer\\gas well BHP.wflx");

                WFInt.OpenFile(sfile1);

                double fQGas = 1.98;
                double fCGR = 0;
                double fWGR = 350;
                double fTHP = 200;

                double Actual = Math.Round(WFInt.WellModel.AddRef().Layers.AddRef().Item(1).AddRef().CalcBHPOfGasWell(fQGas, fCGR, fWGR, fTHP), 2);

                double Expected = 378.71;

                WFInt.EndWellFlo();
                Assert.AreEqual(Expected, Actual, DeltaFraction.Default(Expected));
            }
        }
开发者ID:prasannarhegde2015,项目名称:SampleUnitTests,代码行数:24,代码来源:WPS_Layer.cs

示例15: LayerRate_Set4_A1_GetAt_OilRate

        public void LayerRate_Set4_A1_GetAt_OilRate()
        {
            using (new LifeTimeScope())
            {
                WFloInterface WFInt = new WFloInterface();
                WFInt.AddRef();

                string sfile = WellFloFileLocation.BaselineWPSModel("WPS_Layer\\layer rate - set 4.wflx");

                WFInt.OpenFile(sfile);

                double dRate = 21780.34;

                WFInt.GetLayerRateCalculator().AddRef().Calculate(dRate);

                int i = 0;

                double Actual = Math.Round(WFInt.GetLayerRateCalculator().AddRef().LayerRates.AddRef().GetAt(i).AddRef().OilRate, 2);

                double Expected = 16335.25;

                WFInt.EndWellFlo();
                Assert.AreEqual(Expected, Actual, DeltaFraction.Default(Expected));
            }
        }
开发者ID:prasannarhegde2015,项目名称:SampleUnitTests,代码行数:25,代码来源:WPS_Layer.cs


注:本文中的WFloInterface.EndWellFlo方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。