public BeamProperties(WR_Material mat, string section, WR_ReleaseBeam3d stRel, WR_ReleaseBeam3d enRel) { _mat = mat; _stRel = stRel; _enRel = enRel; _section = CrossSectionFormString(section); }
static internal bool CrossSectionFormString(string section, out WR_IXSec xSec) { CrossSectionType cst = CrossSectionTypeFromString(section); switch (cst) { case CrossSectionType.RectangularSolid: return(RectangularCrossSection(section, out xSec)); case CrossSectionType.RHS: return(RHSCrossSection(section, out xSec)); case CrossSectionType.CHS: return(CHSCrossSection(section, out xSec)); case CrossSectionType.CSS: // Not implemented yet return(CSSCrossSection(section, out xSec)); case CrossSectionType.Invalid: default: { xSec = null; return(false); } } }
public BeamProperties() { _section = null; _stRel = null; _enRel = null; _mat = null; }
internal static bool CrossSectionFormString(string section, out WR_IXSec xSec) { CrossSectionType cst = CrossSectionTypeFromString(section); switch (cst) { case CrossSectionType.RectangularSolid: return RectangularCrossSection(section, out xSec); case CrossSectionType.RHS: return RHSCrossSection(section, out xSec); case CrossSectionType.CHS: return CHSCrossSection(section, out xSec); case CrossSectionType.CSS: // Not implemented yet return CSSCrossSection(section, out xSec); case CrossSectionType.Invalid: default: { xSec = null; return false; } } }
//public BeamProperties(double matStiff, double poison, string section, WR_ReleaseBeam3d stRel, WR_ReleaseBeam3d enRel) //{ // // _stRel = stRel; // _enRel = enRel; // _section = CrossSectionFormString(section); // } public BeamProperties(BeamProperties other) { _mat = other._mat.Copy(); _section = other._section; _stRel = other._stRel.Copy(); _enRel = other._enRel.Copy(); }
public BeamProperties(WR_Material mat, WR_IXSec section, WR_ReleaseBeam3d stRel, WR_ReleaseBeam3d enRel, WR_Element3dOptProp elemOptProp) { _mat = mat; _stRel = stRel; _enRel = enRel; _section = section; _elemOptProp = elemOptProp; }
protected override void SolveInstance(IGH_DataAccess DA) { WR_IXSec xSec = null; if (!DA.GetData(0, ref xSec)) { return; } DA.SetData(0, xSec.Area); DA.SetData(1, xSec.Iy); DA.SetData(2, xSec.Iz); DA.SetData(3, xSec.Kv); }
protected override void SolveInstance(IGH_DataAccess DA) { // string crossSection = ""; WR_IXSec xSec = null; WR_ReleaseBeam3d stREl = null; WR_ReleaseBeam3d enREl = null; WR_Material mat = null; WR_Element3dOptProp optProp = null; if (!DA.GetData(0, ref xSec)) { return; } if (!DA.GetData(1, ref stREl)) { return; } if (!DA.GetData(2, ref enREl)) { return; } if (!DA.GetData(3, ref mat)) { return; } // Check releases if (!CheckReleases(stREl, enREl)) { return; } BeamProperties beamProp; if (!DA.GetData(4, ref optProp)) { beamProp = new BeamProperties(mat, xSec, stREl, enREl); } else { beamProp = new BeamProperties(mat, xSec, stREl, enREl, optProp); } DA.SetData(0, beamProp); }
// Circular solid section static private bool CSSCrossSection(string section, out WR_IXSec xSec) { double radius; if (!GetDimensionsCSS(section, out radius)) { xSec = null; return(false); } double factor = Utilities.GetScalingFactorFromRhino(); radius *= factor; xSec = new WR_XSecCSS(radius); return(true); }
static private bool RectangularCrossSection(string section, out WR_IXSec xSec) { double height, width; if (!GetDimensionsRectangle(section, out height, out width)) { xSec = null; return(false); } double factor = Utilities.GetScalingFactorFromRhino(); height *= factor; width *= factor; xSec = new WR_XSecRect(height, width); return(true); }
static private bool RHSCrossSection(string section, out WR_IXSec xSec) { double height, width, thickness; if (!GetDimensionsRHS(section, out height, out width, out thickness)) { xSec = null; return(false); } double factor = Utilities.GetScalingFactorFromRhino(); height *= factor; width *= factor; thickness *= factor; xSec = new WR_XSecRHS(height, width, thickness); return(true); }
private static bool RHSCrossSection(string section, out WR_IXSec xSec) { double height, width, thickness; if (!GetDimensionsRHS(section, out height, out width, out thickness)) { xSec = null; return false; } double factor = Utilities.GetScalingFactorFromRhino(); height *= factor; width *= factor; thickness *= factor; xSec = new WR_XSecRHS(height, width, thickness); return true; }
private static bool RectangularCrossSection(string section, out WR_IXSec xSec) { double height, width; if (!GetDimensionsRectangle(section, out height, out width)) { xSec = null; return false; } double factor = Utilities.GetScalingFactorFromRhino(); height *= factor; width *= factor; xSec = new WR_XSecRect(height, width); return true; }
// Circular solid section private static bool CSSCrossSection(string section, out WR_IXSec xSec) { double radius; if (!GetDimensionsCSS(section, out radius)) { xSec = null; return false; } double factor = Utilities.GetScalingFactorFromRhino(); radius *= factor; xSec = new WR_XSecCSS(radius); return true; }