Exemple #1
0
        private double CalculateTotalCollectionEfficiency(ArrayList particleDistributionList)
        {
            double cutDiameter = cutParticleDiameter.Value;
            double collectionEff;
            double pDiameter;
            double diamRatio;
            double totalEfficiency = 0.0;
            double loading         = owner.InletParticleLoading.Value;

            if (loading == Constants.NO_VALUE)
            {
                loading = owner.CalculateParticleLoading(owner.GasInlet);
            }
            foreach (ParticleSizeFractionAndEfficiency psf in particleDistributionList)
            {
                pDiameter        = psf.Diameter.Value;
                diamRatio        = pDiameter / cutDiameter;
                collectionEff    = CycloneUtil.CalculateCollectionEfficiency(diamRatio, inletConfiguration);
                collectionEff    = CycloneUtil.CorrectedCollectionEfficiency(collectionEff, particleType, loading);
                totalEfficiency += collectionEff * psf.WeightFraction.Value;
                //psf.ToCutDiameterRatio.Value = diamRatio;
                psf.Efficiency.Value = collectionEff;
            }

            return(totalEfficiency);
        }
Exemple #2
0
        public void DoRatingCalculation()
        {
            double volumeFlow = owner.GasInlet.VolumeFlowRate.Value;

            double inletW              = inletWidth.Value;
            double inletH              = inletHeight.Value;
            double inletHToWRatio      = inletHeightToWidthRatio.Value;
            double diamOutlet          = outletInnerDiameter.Value;
            double wallThicknessOutlet = outletWallThickness.Value;
            double diamCyclone         = cycloneDiameter.Value;
            int    numOfCyclones       = numberOfCyclones.Value;

            volumeFlow /= numOfCyclones;

            double outletTL = outletTubeLengthBelowRoof.Value;
            double outletTLToInletHRatio = outletBelowRoofToInletHeightRatio.Value;

            double loading = owner.InletParticleLoading.Value;

            if (loading == Constants.NO_VALUE)
            {
                loading = owner.CalculateParticleLoading(owner.GasInlet);
            }

            if (inletW != Constants.NO_VALUE && inletHToWRatio != Constants.NO_VALUE)
            {
                inletH = inletW * inletHToWRatio;
                ownerUnitOp.Calculate(inletHeight, inletH);
            }
            else if (inletW != Constants.NO_VALUE && inletH != Constants.NO_VALUE)
            {
                inletHToWRatio = inletH / inletW;
                ownerUnitOp.Calculate(inletHeightToWidthRatio, inletHToWRatio);
            }
            else if (inletH != Constants.NO_VALUE && inletHToWRatio != Constants.NO_VALUE)
            {
                inletW = inletH / inletHToWRatio;
                ownerUnitOp.Calculate(inletWidth, inletW);
            }

            if (inletH != Constants.NO_VALUE && outletTLToInletHRatio != Constants.NO_VALUE)
            {
                outletTL = inletH * outletTLToInletHRatio;
                ownerUnitOp.Calculate(outletTubeLengthBelowRoof, outletTL);
            }
            else if (inletH != Constants.NO_VALUE && outletTL != Constants.NO_VALUE)
            {
                outletTLToInletHRatio = outletTL / inletH;
                ownerUnitOp.Calculate(outletBelowRoofToInletHeightRatio, outletTLToInletHRatio);
            }
            else if (outletTL != Constants.NO_VALUE && outletTLToInletHRatio != Constants.NO_VALUE)
            {
                inletH = outletTL / outletTLToInletHRatio;
                ownerUnitOp.Calculate(inletHeight, inletH);
            }

            if (diamOutlet != Constants.NO_VALUE && wallThicknessOutlet != Constants.NO_VALUE && inletW != Constants.NO_VALUE &&
                diamCyclone == Constants.NO_VALUE)
            {
                diamCyclone = 2.0 * inletW + diamOutlet + 2.0 * wallThicknessOutlet;
                ownerUnitOp.Calculate(cycloneDiameter, diamCyclone);
            }

            double inletArea       = Constants.NO_VALUE;
            double outletArea      = Constants.NO_VALUE;
            double inletV          = Constants.NO_VALUE;
            double numOfTurns      = Constants.NO_VALUE;
            double viscGas         = owner.GasInlet.GetGasViscosity(owner.GasInlet.Temperature.Value);
            double densityParticle = ParticleDensity.Value;
            double densityGas      = owner.GasInlet.Density.Value;
            double cutDiameter     = cutParticleDiameter.Value;
            double collectionEff   = owner.CollectionEfficiency.Value;
            double temp;

            //if (volumeFlow != Constants.NO_VALUE && viscGas != Constants.NO_VALUE) {
            //the above condition has already been guarded by IsRatingCalcReady()
            if (inletW != Constants.NO_VALUE && inletH != Constants.NO_VALUE)
            {
                inletArea = inletW * inletH;
                if (diamOutlet != Constants.NO_VALUE)
                {
                    outletArea = Math.PI * diamOutlet * diamOutlet / 4.0;
                    inletArea  = inletArea < outletArea ? inletArea : outletArea;
                }
                inletV      = volumeFlow / inletArea;
                numOfTurns  = CalculateNumOfTurns(inletV);
                cutDiameter = Math.Sqrt(9 * viscGas * inletW / (Math.PI * numOfTurns * inletV * (densityParticle - densityGas)));
                ownerUnitOp.Calculate(cutParticleDiameter, cutDiameter);
                ownerUnitOp.Calculate(inletVelocity, inletV);

                collectionEff = CalculateTotalCollectionEfficiency(particleSizeFractionAndEfficiencyList);
                ownerUnitOp.Calculate(owner.CollectionEfficiency, collectionEff);

                //solveState = SolveState.Solved;
                //if (dp != Constants.NO_VALUE) {
                //   double diamRatio = cutDiameter/dp;
                //   collectionEff = 1.0/(1.0 + diamRatio * diamRatio);
                //   Calculate(collectionEfficiency, ce);
                //   solveState = SolveState.Solved;
                //}
            }
            else if (cutDiameter != Constants.NO_VALUE && inletHToWRatio != Constants.NO_VALUE && inletW == Constants.NO_VALUE)
            {
                //double diamRatio = cutDiameter/dp;
                //collectionEff = 1.0/(1.0 + diamRatio * diamRatio);
                collectionEff = CalculateTotalCollectionEfficiency(particleSizeFractionAndEfficiencyList);
                ownerUnitOp.Calculate(owner.CollectionEfficiency, collectionEff);

                //Assume initail number of spirals is 3.5
                numOfTurns = 3.5;
                int    i         = 0;
                double inletWOld = 0;
                double diff;
                do
                {
                    i++;
                    temp       = cutDiameter * cutDiameter * Math.PI * numOfTurns * volumeFlow * (densityParticle - densityGas) / (9.0 * viscGas * inletHToWRatio);
                    inletW     = Math.Pow(temp, 1.0 / 3.0);
                    inletV     = volumeFlow / (inletW * inletW * inletHToWRatio);
                    numOfTurns = CalculateNumOfTurns(inletV);
                    diff       = inletW - inletWOld;
                    inletWOld  = inletW;
                } while (i <= 500 && Math.Abs(diff) > 1.0e-6);

                if (i < 500)
                {
                    ownerUnitOp.Calculate(inletWidth, inletW);
                    ownerUnitOp.Calculate(inletHeight, inletW * inletHToWRatio);
                    ownerUnitOp.Calculate(inletVelocity, inletV);
                }

                if (diamOutlet != Constants.NO_VALUE && wallThicknessOutlet != Constants.NO_VALUE && inletW != Constants.NO_VALUE &&
                    diamCyclone == Constants.NO_VALUE)
                {
                    diamCyclone = 2.0 * inletW + diamOutlet + 2.0 * wallThicknessOutlet;
                    ownerUnitOp.Calculate(cycloneDiameter, diamCyclone);
                }
            }
            //}

            double vesselDiam = externalVesselDiameter.Value;

            if (loading != Constants.NO_VALUE && inletV != Constants.NO_VALUE &&
                densityGas != Constants.NO_VALUE && vesselDiam != Constants.NO_VALUE &&
                inletW != Constants.NO_VALUE && inletH != Constants.NO_VALUE)
            {
                double vesselArea = Math.PI * vesselDiam * vesselDiam / 4.0;
                double vesselV    = volumeFlow / vesselArea;
                vesselArea /= numOfCyclones;
                double areaRatio = inletArea / vesselArea;
                if (areaRatio > 1.0)
                {
                    //something is wrong
                }

                double contractionFactor  = CycloneUtil.CalculateDPContractionFactor(areaRatio);
                double dpInletContraction = 0.5 * densityGas * ((1.0 + contractionFactor) * inletV * inletV - vesselV * vesselV);

                double dpParticleAcceleration = loading * inletV * (inletV - vesselV);

                double diamInlet        = 4.0 * inletW * inletH / (2.0 * (inletW + inletH));
                double Re               = diamInlet * inletV * densityGas / viscGas;
                double frictionFactor   = FrictionFactorCalculator.CalculateFrictionFactor(Re);
                double dpBarrelFriction = 2.0 * frictionFactor * densityGas * inletV * inletV * Math.PI * diamCyclone * numOfTurns / diamInlet;

                double dpGasFlowReversal = densityGas * inletV * inletV / 2.0;

                double barrelArea = Math.PI * diamCyclone * diamCyclone / 4.0;
                double barrelV    = volumeFlow / barrelArea;
                double outletV    = volumeFlow / outletArea;
                areaRatio = inletArea / barrelArea;
                if (areaRatio > 1.0)
                {
                    //something is wrong
                }
                contractionFactor = CycloneUtil.CalculateDPContractionFactor(areaRatio);
                double dpOutletContraction = 0.5 * densityGas * ((1.0 + contractionFactor) * outletV * outletV - barrelV * barrelV);

                double dpTotal = dpInletContraction + dpParticleAcceleration + dpBarrelFriction + dpGasFlowReversal + dpOutletContraction;
                double loadingCorrectionFactor = CycloneUtil.CalculateDPLoadingCorrectionFactor(loading);
                dpTotal *= loadingCorrectionFactor;
                ownerUnitOp.Calculate(owner.GasPressureDrop, dpTotal);
                //ownerUnitOp.BalancePressure(ownerUnitOp.MixtureInlet, ownerUnitOp.FluidOutlet, ownerUnitOp.PressureDrop);
            }

            double diamDipleg  = Constants.NO_VALUE;
            double densityBulk = ParticleBulkDensity.Value;

            if (loading != Constants.NO_VALUE && volumeFlow != Constants.NO_VALUE &&
                densityGas != Constants.NO_VALUE && densityBulk != Constants.NO_VALUE)
            {
                temp       = volumeFlow * loading * Math.Sqrt(Math.Tan(Math.PI * 62.0 / 180)) / (Math.Sqrt(Constants.G) * densityBulk * Math.Sqrt((densityBulk - densityGas) / densityBulk));
                diamDipleg = Math.Pow(temp, 0.4);
                if (diamDipleg < 0.0254 * 4.0)
                {
                    diamDipleg = 0.0254 * 4.0;
                }
                ownerUnitOp.Calculate(diplegDiameter, diamDipleg);
            }
            double vortexLength = Constants.NO_VALUE;

            if (diamOutlet != Constants.NO_VALUE && volumeFlow != Constants.NO_VALUE)
            {
                //FLUIDIZATION, SOLIDS HANDLING, AND PROCESSING--Industrial Applications
                //Edited by Wen-Ching Yang, Siemens Westinghouse Power Corporation, Pittsburgh, Pennsylvania
                //Chapter 12--Cyclone Desgn, page 779
                vortexLength = volumeFlow / (Math.PI * diamOutlet * 5.0);
                ownerUnitOp.Calculate(naturalVortexLength, vortexLength);
            }
            double coneAngleValue        = coneAngle.Value / 2.0;
            double coneLengthValue       = coneLength.Value;
            double coneLengthUnderVortex = Constants.NO_VALUE;

            if (coneAngleValue != Constants.NO_VALUE && diamDipleg != Constants.NO_VALUE)
            {
                if (diamCyclone != Constants.NO_VALUE)
                {
                    coneLengthValue = Math.Tan(coneAngleValue) * (diamCyclone - diamDipleg) / 2.0;
                    ownerUnitOp.Calculate(coneLength, coneLengthValue);
                }

                if (diamOutlet != Constants.NO_VALUE)
                {
                    double vortexGap = 0.0254 * 2 / Math.Sin(coneAngleValue);
                    coneLengthUnderVortex = ((diamOutlet - diamDipleg) / 2.0 + vortexGap) * Math.Tan(coneAngleValue);
                }
            }

            if (vortexLength != Constants.NO_VALUE && coneLengthUnderVortex != Constants.NO_VALUE &&
                outletTL != Constants.NO_VALUE)
            {
                double totalLength = vortexLength + coneLengthUnderVortex + outletTL;
                ownerUnitOp.Calculate(barrelPlusConeLength, totalLength);
                double barrelL = totalLength - coneLengthValue;
                ownerUnitOp.Calculate(barrelLength, barrelL);
            }
        }