Example #1
0
        /// <summary>
        /// Calculate the acting forces to Cracking forces ratio.
        /// </summary>
        /// <param name="inNMM">The acting forces.</param>
        /// <param name="crackingStress">Stress limit for cracking/uncracking section.</param>
        /// <returns></returns>
        public double ForcesToCrackingForces(InternalForcesContainer inNMM, double crackingStress)
        {
            if (!CalculationUtility.IsZeroM(inNMM.MomentMz))
            {
                throw new Exception("Deflection calculation is not aviable for biaxial bending.");
            }
            double crackigForcesToForces = Double.MaxValue;

            solver.SolveResistance(inNMM.ForceFx, inNMM.MomentMy, 0);
            double strainMin = solver.GetStrainMin(Autodesk.CodeChecking.Concrete.ResultType.Concrete);

            if (strainMin < 0.0)
            {
                double      ActingForceToResistance = 1.0;
                SetOfForces ResistanceForces        = solver.GetInternalForces(Autodesk.CodeChecking.Concrete.ResultType.Section);
                if (Math.Abs(inNMM.MomentMy) > Math.Abs(inNMM.ForceFx))
                {
                    ActingForceToResistance = inNMM.MomentMy / ResistanceForces.MomentX;
                }
                else
                {
                    ActingForceToResistance = inNMM.ForceFx / ResistanceForces.AxialForce;
                }
                Autodesk.CodeChecking.Concrete.Concrete concrete = solver.GetConcrete();
                double noCrackingTensonStress = -strainMin * concrete.ModulusOfElasticity * ActingForceToResistance;
                crackigForcesToForces = crackingStress / noCrackingTensonStress;
            }
            return(crackigForcesToForces);
        }
Example #2
0
        /// <summary>
        /// Calculates the safety factor.
        /// </summary>
        /// <param name="inNMM">The acting forces.</param>
        /// <returns>Safety factor. Resistance forces to acting forces ratio.</returns>
        public double SafetyFactor(InternalForcesContainer inNMM)
        {
            double safetyFactor = -1.0;

            solver.SolveResistance(inNMM.ForceFx, -inNMM.MomentMy, inNMM.MomentMz);
            SetOfForces solveNMM = solver.GetInternalForces(Autodesk.CodeChecking.Concrete.ResultType.Section);

            if (Math.Abs(inNMM.ForceFx) > Math.Abs(inNMM.MomentMy))
            {
                if (Math.Abs(inNMM.ForceFx) > Math.Abs(inNMM.MomentMz))
                {
                    safetyFactor = solveNMM.AxialForce / inNMM.ForceFx;
                }
                else
                {
                    safetyFactor = solveNMM.MomentY / inNMM.MomentMz;
                }
            }
            else if (Math.Abs(inNMM.MomentMy) > Math.Abs(inNMM.MomentMz))
            {
                safetyFactor = solveNMM.MomentX / -inNMM.MomentMy;
            }
            else
            {
                safetyFactor = solveNMM.MomentY / inNMM.MomentMz;
            }
            return(safetyFactor);
        }
        /// <summary>
        /// Calculate the acting forces to Cracking forces ratio.
        /// </summary>
        /// <param name="inNMM">The acting forces.</param>
        /// <param name="crackingStress">Stress limit for cracking/uncracking section.</param>
        /// <returns>Acting forces to cracking forces ratio</returns>
        public double ForcesToCrackingForces(InternalForcesContainer inNMM, double crackingStress)
        {
            double forcesToCrackigForces = 0;

            if (!CalculationUtility.IsZeroM(inNMM.MomentMz))
            {
                throw new Exception("Deflection calculation is not aviable for biaxial bending.");
            }
            double actingForcesStress = 0;

            if (!CalculationUtility.IsZeroM(inNMM.MomentMy))
            {
                double w = solverGeometry.MomentOfInertiaX;
                w /= inNMM.MomentMy > 0.0 ? (geometryMaxY - solverGeometry.CenterOfInertia.Y) : (solverGeometry.CenterOfInertia.Y - geometryMinY);
                actingForcesStress += Math.Abs(inNMM.MomentMy) / w;
            }
            if (!CalculationUtility.IsZeroN(inNMM.ForceFx))
            {
                actingForcesStress += -inNMM.ForceFx / solverGeometry.Area;
            }
            if (actingForcesStress >= 0)
            {
                forcesToCrackigForces = actingForcesStress / crackingStress;
            }
            return(forcesToCrackigForces);
        }
        /// <structural_toolkit_2015>

        /// <summary>
        /// Calculate the moment of inertia for cracking section.
        /// </summary>
        /// <param name="inNMM">The acting forces.</param>
        /// <returns>Returns moment of inertia for cracking section.</returns>
        public double InertiaOfCrackingSection(InternalForcesContainer inNMM)
        {
            double momentOfInertiaCrackingConcreteSection = 0.0;

            SafetyFactor(inNMM);
            SetOfForces solverNMM       = solver.GetInternalForces(Autodesk.CodeChecking.Concrete.ResultType.Section);
            double      neutralAxisDist = solver.GetNeutralAxisDistance();
            double      stressArea      = solver.GetConcreteStressArea();
            double      comprHeight     = 0.5 * totalHeight + neutralAxisDist;
            Steel       steel           = solver.GetSteel();

            Autodesk.CodeChecking.Concrete.Concrete concrete = solver.GetConcrete();
            double n = steel.ModulusOfElasticity / concrete.ModulusOfElasticity;

            switch (crossSectionType)
            {
            case SectionShapeType.RectangularBar:
            {
                momentOfInertiaCrackingConcreteSection = comprHeight * comprHeight * stressArea / 3.0; // bh^3/12 + b*h*(0.5*h)^2, b*h=stressArea
            }
            break;

            default:
                throw new Exception("InertiaOfCrackingSection. Unhandled cross section type. Only rectangular cross-section can be used on this path. 3th party implementation is necessary.");
            }
            foreach (Rebar bar in solver.GetRebars())
            {
                momentOfInertiaCrackingConcreteSection += n * bar.Area * Math.Pow((bar.Y + neutralAxisDist), 2);
            }
            return(momentOfInertiaCrackingConcreteSection);
        }
Example #5
0
        /// <summary>
        /// Calculate the moment of inertia for cracking section.
        /// </summary>
        /// <param name="inNMM">The acting forces.</param>
        /// <returns>Returns moment of inertia for cracking section.</returns>
        public double InertiaOfCrackingSection(InternalForcesContainer inNMM)
        {
            double momentOfInertiaCrackingConcreteSection = 0.0;

            solver.SolveResistance(inNMM.ForceFx, inNMM.MomentMy, 0.0);
            SetOfForces solverNMM        = solver.GetInternalForces(Autodesk.CodeChecking.Concrete.ResultType.Section);
            double      neutralAxisDist  = solver.GetNeutralAxisDistance();
            double      centerOfInertiaY = solverGeometry.CenterOfInertia.Y;
            double      stressArea       = solver.GetConcreteStressArea();
            double      comprHeight      = -neutralAxisDist;
            Steel       steel            = solver.GetSteel();

            Autodesk.CodeChecking.Concrete.Concrete concrete = solver.GetConcrete();
            double bottomWidth = solverGeometry.Point(1).X - solverGeometry.Point(0).X;
            double n           = steel.ModulusOfElasticity / concrete.ModulusOfElasticity;

            momentOfInertiaCrackingConcreteSection  = comprHeight * comprHeight * comprHeight * bottomWidth / 3.0; // bh^3/12 + b*h*(0.5*h)^2
            momentOfInertiaCrackingConcreteSection += n * (solver.GetMomentOfInertiaX(Autodesk.CodeChecking.Concrete.ResultType.Rebars) + Math.Abs(neutralAxisDist) * solver.GetArea(Autodesk.CodeChecking.Concrete.ResultType.Rebars));
            switch (crossSectionType)
            {
            case SectionShapeType.RectangularBar:
                break;

            case SectionShapeType.T:
            {
                bool   bottomMoreCompression = inNMM.MomentMy >= 0.0;
                double TotalWidth            = solverGeometry.Point(4).X - solverGeometry.Point(5).X;
                if (bottomMoreCompression)
                {
                    double WithoutSlabHeight = solverGeometry.Point(2).Y - solverGeometry.Point(1).Y;
                    if (comprHeight > WithoutSlabHeight)
                    {
                        double partT = (comprHeight - WithoutSlabHeight);
                        momentOfInertiaCrackingConcreteSection += Math.Pow(comprHeight - 0.5 * partT, 2) * (TotalWidth - bottomWidth);
                        momentOfInertiaCrackingConcreteSection += (TotalWidth - bottomWidth) * partT * partT * partT / 12.0;
                    }
                }
                else
                {
                    double SlabHeight = solverGeometry.Point(4).Y - solverGeometry.Point(3).Y;
                    SlabHeight = Math.Min(SlabHeight, comprHeight);
                    momentOfInertiaCrackingConcreteSection += Math.Pow(comprHeight - 0.5 * SlabHeight, 2) * (TotalWidth - bottomWidth);
                    momentOfInertiaCrackingConcreteSection += (TotalWidth - bottomWidth) * SlabHeight * SlabHeight * SlabHeight / 12.0;
                }
            }
            break;

            default:
                throw new Exception("InertiaOfCrackingSection. Unhandled cross section type. Only R and T cross-sections can be used on this path.");
            }
            return(momentOfInertiaCrackingConcreteSection);
        }
Example #6
0
        /// <summary>
        /// Calculates the safety factor and sets additional result in the lists.
        /// </summary>
        /// <param name="inNMM">The acting forces.</param>
        /// <param name="concreteStresses">
        /// Reference to modify object. The list is set after safety factor calculation. Includes stresses on every corner of the cross section.
        /// </param>
        /// <param name="steelStresses">
        /// Reference to modify object. The list is set after safety factor calculation. Includes stresses on every rebar.
        /// </param>
        /// <returns>Safety factor. Resistance forces to acting forces ratio.</returns>
        public double SafetyFactor(InternalForcesContainer inNMM, ref List <double> concreteStresses, ref List <double> steelStresses)
        {
            double safetyFactor = SafetyFactor(inNMM);
            int    no           = solverGeometry.Count;
            double stress       = 0;

            for (int i = 0; i < no; i++)
            {
                stress = solver.GetStress(Autodesk.CodeChecking.Concrete.ResultType.Concrete, i);
                concreteStresses.Add(stress);
            }
            no = solver.GetRebars().Count;
            for (int i = 0; i < no; i++)
            {
                stress = solver.GetStress(Autodesk.CodeChecking.Concrete.ResultType.Rebars, i);
                steelStresses.Add(stress);
            }
            return(safetyFactor);
        }
        public InternalForcesContainer Forces(ConcreteTypes.DimensioningDirection direction)
        {
            InternalForcesContainer forces = new InternalForcesContainer();

            forces.CaseName   = ForceDescription;
            forces.LimitState = LimitState;

            if (direction == ConcreteTypes.DimensioningDirection.X)
            {
                forces.ForceFx  = -ForceFxx;  // Due to ResultBuilder conventions of the forces sign.
                forces.MomentMy = -MomentMxx; // Due to ResultBuilder conventions of the forces sign.
                forces.ForceFz  = ForceQxx;
            }
            else
            {
                forces.ForceFx  = -ForceFyy;  // Due to ResultBuilder conventions of the forces sign.
                forces.MomentMy = -MomentMyy; // Due to ResultBuilder conventions of the forces sign.
                forces.ForceFz  = ForceQyy;
            }

            return(forces);
        }
Example #8
0
 /// <summary>
 /// Creates default
 /// </summary>
 public InternalForcesLinear()
 {
     Forces = new InternalForcesContainer();
 }