Ejemplo n.º 1
0
        public void CheckSteelBasePart()
        {
            SteelColumnBase steelColumnBase = new SteelColumnBase();

            steelColumnBase.Width     = 1;
            steelColumnBase.Length    = 1;
            steelColumnBase.Thickness = 0.05;
            BarLoadSet columnLoadSet = new BarLoadSet(steelColumnBase);

            columnLoadSet.Force_Nz            = -100000;
            columnLoadSet.PartialSafetyFactor = 1;
            SteelBasePart steelBasePart = new SteelBasePart(steelColumnBase);

            steelBasePart.FixLeft   = true;
            steelBasePart.FixRight  = true;
            steelBasePart.FixTop    = false;
            steelBasePart.FixBottom = false;
            steelBasePart.Width     = 1;
            steelBasePart.Length    = 1;
            SteelColumnBaseProcessor columBaseProcessor = new SteelColumnBaseProcessor();
            ColumnBaseResult         columnResult       = columBaseProcessor.GetResult(steelColumnBase);
            ColumnBasePartResult     baseResult         = SteelColumnBasePartProcessor.GetResult(steelBasePart);

            Assert.AreEqual(300, baseResult.MaxStress / 1000000, 10);
        }
Ejemplo n.º 2
0
        private void EditItemFromColumnBasePart(ListViewItem Item, SteelBasePart basePart)
        {
            Item.SubItems.Clear();
            Item.Text = basePart.Name;
            Item.SubItems.Add(Convert.ToString(basePart.Width * 1000) + "x" + Convert.ToString(basePart.Length * 1000));
            ColumnBasePartResult result = SteelColumnBasePartProcessor.GetResult(basePart);
            double maxStress            = result.MaxStress;

            maxStress = Math.Round(maxStress / 1000) / 1000;
            Item.SubItems.Add(Convert.ToString(maxStress));
        }