Exemple #1
0
        public static string Description(this GeneralisedTSectionProfile profile)
        {
            if (profile == null)
            {
                return("null profile");
            }

            return($"GenT {profile.Height:G3}x{profile.WebThickness}x" +
                   $"{profile.LeftOutstandWidth:G3}x{profile.LeftOutstandThickness:G3}x" +
                   $"{profile.RightOutstandWidth:G3}x{profile.RightOutstandThickness:G3}");
        }
        /***************************************************/

        public static GeneralisedTSectionProfile InterpolateProfile(GeneralisedTSectionProfile startProfile, GeneralisedTSectionProfile endProfile, double parameter, int interpolationOrder,
                                                                    double domainStart = 0, double domainEnd = 1)
        {
            return(Create.GeneralisedTSectionProfile(
                       Interpolate(startProfile.Height, endProfile.Height, parameter, interpolationOrder, domainStart, domainEnd),
                       Interpolate(startProfile.WebThickness, endProfile.WebThickness, parameter, interpolationOrder, domainStart, domainEnd),
                       Interpolate(startProfile.LeftOutstandWidth, endProfile.LeftOutstandWidth, parameter, interpolationOrder, domainStart, domainEnd),
                       Interpolate(startProfile.LeftOutstandThickness, endProfile.LeftOutstandThickness, parameter, interpolationOrder, domainStart, domainEnd),
                       Interpolate(startProfile.RightOutstandWidth, endProfile.RightOutstandWidth, parameter, interpolationOrder, domainStart, domainEnd),
                       Interpolate(startProfile.RightOutstandThickness, endProfile.RightOutstandThickness, parameter, interpolationOrder, domainStart, domainEnd),
                       startProfile.MirrorAboutLocalY));
        }
        public static double TorsionalConstant(this GeneralisedTSectionProfile profile)
        {
            if (profile.IsNull())
            {
                return(0);
            }

            bool leftOutstand = profile.LeftOutstandWidth > 0 && profile.LeftOutstandThickness > 0;
            bool rightOustand = profile.RightOutstandWidth > 0 && profile.RightOutstandThickness > 0;

            if (!leftOutstand && !rightOustand)
            {
                //No outstands => Rectangle

                double a = Math.Max(profile.Height, profile.WebThickness) / 2;
                double b = Math.Min(profile.Height, profile.WebThickness) / 2;
                return(a * Math.Pow(b, 3) * (16 / 3 - 3.36 * b / a * (1 - Math.Pow(b, 4) / (12 * Math.Pow(a, 4)))));
            }

            if (Math.Abs(profile.RightOutstandThickness - profile.LeftOutstandThickness) < Tolerance.Distance &&
                Math.Abs(profile.RightOutstandWidth - profile.LeftOutstandWidth) < Tolerance.Distance)
            {
                //Symmetric T
                double totalWidth = profile.RightOutstandWidth * 2 + profile.WebThickness;
                double totalDepth = profile.Height;
                double tf         = profile.RightOutstandThickness;
                double tw         = profile.WebThickness;

                return((totalWidth * Math.Pow(tf, 3) + (totalDepth - tf / 2) * Math.Pow(tw, 3)) / 3);
            }


            if (leftOutstand && !rightOustand || !leftOutstand && rightOustand)
            {
                //One outstand => angle
                double totalWidth = (leftOutstand ? profile.LeftOutstandWidth : profile.RightOutstandWidth) + profile.WebThickness;
                double totalDepth = profile.Height;
                double tf         = leftOutstand ? profile.LeftOutstandThickness : profile.RightOutstandThickness;
                double tw         = profile.WebThickness;

                return(((totalWidth - tw / 2) * Math.Pow(tf, 3) + (totalDepth - tf / 2) * Math.Pow(tw, 3)) / 3);
            }


            Reflection.Compute.RecordWarning("Can only calculate torsional constant of symmetric T sections or angles");
            return(0);
        }
Exemple #4
0
        /***************************************************/

        public static string Description(this GeneralisedTSectionProfile profile)
        {
            return("GenT " + profile.Height + "x" + profile.WebThickness + "x" + profile.LeftOutstandWidth + "x" + profile.LeftOutstandThickness + "x" + profile.RightOutstandWidth + "x" + profile.RightOutstandThickness);
        }
Exemple #5
0
        /***************************************************/

        private bool CreateProfile(string name, GeneralisedTSectionProfile profile)
        {
            Engine.Base.Compute.RecordError("GeneralisedTSectionProfile not supported in Lusas_Toolkit");
            return(false);
        }