public void AwaresSystemResult()
        {
            this.systemResults = new sResultRange();

            foreach (IFrameSet fs in this.frameSets)
            {
                this.systemResults.UpdateMaxValues(fs.results_Max);
            }
        }
Exemple #2
0
        public void UpdateBeamResults(double dataLenTol, double du)
        {
            if (this.FEsystem != null)
            {
                foreach (IFrameSet bs in this.frameSets)
                {
                    sResultRange bsRe = new sResultRange();

                    foreach (sFrame sb in bs.frames)
                    {
                        AwaresBeamResult(sb, ref bsRe, dataLenTol);
                    }

                    bs.results_Max = bsRe;
                }
            }
        }
        public void TransfersSystemBasis(ISystem ssys)
        {
            this.systemSettings = ssys.systemSettings.DuplicatesSystemSetting();
            if (ssys.meshes != null && ssys.meshes.Count > 0)
            {
                this.meshes = new List <sMesh>();
                foreach (sMesh m in ssys.meshes)
                {
                    this.meshes.Add(m.DuplicatesMesh());
                }
            }

            //sElement Part
            if (ssys.systemResults != null)
            {
                this.systemResults = ssys.systemResults.DuplicatesResultRange();
            }

            if (ssys.nodes != null)
            {
                this.nodes = new List <sNode>();
                foreach (sNode ns in ssys.nodes)
                {
                    this.nodes.Add(ns.DuplicatesNode());
                }
            }

            if (ssys.loadPatterns != null)
            {
                this.loadPatterns = ssys.loadPatterns.ToList();
            }

            if (ssys.loadCombinations != null)
            {
                this.loadCombinations = new List <sLoadCombination>();
                foreach (sLoadCombination com in ssys.loadCombinations)
                {
                    this.loadCombinations.Add(com.DuplicatesLoadCombination());
                }
            }

            this.estimatedMaxD   = ssys.estimatedMaxD;
            this.estimatedWeight = ssys.estimatedWeight;
        }
Exemple #4
0
        private void AwaresBeamResult(sFrame sb, ref sResultRange bsRe, double dataLenTol)
        {
            StatBeamResults br   = new StatBeamResults();
            sStatConverter  conv = new sStatConverter();

            StatBeam b = sb.extraData as StatBeam;

            b.RecoverForces();

            sb.beamWeight = b.Weight;
            sb.results    = new List <sFrameResult>();

            double len   = sb.axis.length;
            int    count = (int)(len / dataLenTol);

            if (count < 1)
            {
                count = 1;
            }

            double step = 1.0 / (double)(count);

            for (int i = 0; i < count + 1; ++i)
            {
                double tNow = step * i;
                br.t = tNow;
                b.GetInterpolatedResultsAt(new C_vector(0, 0, -1), this.FEsystem.DeadLoadFactor, br);

                sFrameResult bre = new sFrameResult();
                bre.moment             = new sXYZ(br.MomentL.x, br.MomentL.y, br.MomentL.z);
                bre.force              = new sXYZ(-br.ForceL.x, br.ForceL.y, br.ForceL.z); /// force X negate?????????
                bre.deflection_mm      = conv.TosXYZ(b.Csys.LocalToGlobalVector(br.DeflL * 1000));
                bre.deflectionLocal_mm = conv.TosXYZ(br.DeflL * 1000);

                bre.parameterAt = tNow;


                sPlane secPlane = new sPlane(sb.axis.PointAt(tNow), sb.localPlane.Xaxis, sb.localPlane.Yaxis);

                List <sXYZ> secVertices = new List <sXYZ>();
                if (sb.crossSection.sectionType == eSectionType.AISC_I_BEAM)
                {
                    secVertices = sb.crossSection.GetWbeamFaceVertices(secPlane).ToList();
                }
                else if (sb.crossSection.sectionType == eSectionType.HSS_REC)
                {
                    secVertices = sb.crossSection.GetHSSRecFaceVertices_Simple(secPlane).ToList();
                }
                else if (sb.crossSection.sectionType == eSectionType.HSS_ROUND)
                {
                    secVertices = sb.crossSection.GetHSSRoundFaceVertices_Simple(secPlane).ToList();
                }
                else if (sb.crossSection.sectionType == eSectionType.SQUARE)
                {
                    secVertices = sb.crossSection.GetSquareFaceVertices_Simple(secPlane).ToList();
                }
                else if (sb.crossSection.sectionType == eSectionType.RECTANGLAR)
                {
                    secVertices = sb.crossSection.GetRecFaceVertices_Simple(secPlane).ToList();
                }
                else if (sb.crossSection.sectionType == eSectionType.ROUND)
                {
                    secVertices = sb.crossSection.GetRoundFaceVertices_Simple(secPlane).ToList();
                }

                if (secVertices != null)
                {
                    for (int j = 0; j < secVertices.Count; ++j)
                    {
                        sXYZ svp      = secVertices[j];
                        sXYZ localDir = svp - sb.axis.PointAt(tNow);

                        sXYZ ToLocalZ = localDir.ProjectTo(secPlane.Zaxis);
                        sXYZ ToLocalY = localDir.ProjectTo(secPlane.Yaxis);

                        double len_ToLocalZ = ToLocalZ.Z; // vertical like
                        double len_ToLocalY = ToLocalY.Y; // horizontal like

                        br.zL = len_ToLocalZ;             // vertical like
                        br.yL = len_ToLocalY;             // horizontal like

                        double axialStress_X = (br.ForceL.x / b.CrossSection.Area);
                        //double axialStress_Y = ??;
                        //double axialStress_Z = ??;

                        double MyStress = ((br.MomentL.y * br.zL) / b.CrossSection.Iyy);
                        double MzStress = ((br.MomentL.z * br.yL) / b.CrossSection.Izz);
                        //double MxStress = ??

                        double stressTest = axialStress_X + MyStress - MzStress; //why negate?...(StatBeamResult does this)

                        //do I need?
                        //b.GetSectionPointResult(br);

                        sFrameSectionResult secRe = new sFrameSectionResult();
                        secRe.location      = svp;
                        secRe.deflection_mm = conv.TosXYZ(b.Csys.LocalToGlobalVector(br.DeflL * 1000));

                        secRe.stress_Combined = Math.Abs(stressTest);
                        secRe.stress_Axial_X  = axialStress_X;
                        secRe.stress_Moment_Y = MyStress;
                        secRe.stress_Moment_Z = MzStress;

                        bre.sectionResults.Add(secRe);
                    }
                }

                bsRe.UpdateMaxValues(bre);
                sb.results.Add(bre);
            }
        }