Profile Section Libraries for Structural Engineering and beyond!

245

Comments

  • Would you like to be able to get data as csv out of BOLTS or would you like to use csv to get data into BOLTS?

    yes, basically use csv to export, validate, enrich and import back.

    I think the CSV formats are much nicer to display and edit than yaml :) But maybe not as "rich" structurally so I'm looking at it very superficially.

    Probably for a single table of values, the csv file is the most user-friendly, but including metadata for each table I'd say justifies the use of a dictionary.
    The problem with csv starts when you have no 1-1 relational data like a list of properties with variable length.

  • @Jesusbill another package which relates to this thread that I recently re-discovered is sectionproperties which can be used to calculate your sectional properties needed for structural design. Since I was taking another look at the work you have done on I-Beams in the BOLTS project and I'm again unsure whether I like the idea better of a "database" structure for structural section properties or whether calculating these "on the fly" would make better sense. Perhaps it could make sense to integrate a tool like sectionproperties (written in Python) to be used to compute the structural section properties and write these directly as a custom pset for the structural IFC element. As far as I am aware for simple cross-sections (i.e. I-beams, rectangular sections, etc.) calculating structural properties is fairly fast. Another benefit to this approach would be that more complex shapes that might result from parametric design scenarios could be easily accounted for. Look forward to hearing your perspective on this.

  • @jchkoch this looks like a great library! It would be useful to have so as to calculate section properties for any profile.
    I do think, however, that it would be better to have these properties already reported for standard steel profiles, or any other standardized shapes of other materials as well.
    For rectangular, circular or other simple profiles, it is true that these calculations can be fairly straightforward and most of the times may even not be needed as structural software do cover these cases defining directly only the profile shape and dimensions, or at least this is true for Code_Aster. For symmetric I-beams I have also written this code in ifc2ca to calculate section properties but for most standard I profiles that have also some curved parts these calculations are not exact and I would think it is better to have the exact values already given.
    Interestingly Code_Aster has also a macro command for calculating these properties for any shape, but I never used it and it would probably be more complex to implement compared with a python api.

    Would you be interested to look into sectionproperties and create a couple of examples so that we can evaluate the code and time needed to do the calculations for a profile? I am definitely in favor of having such a tool available to users.
    Thanks for chiming in

    jchkoch
  • @Jesusbill I have added the section-properties library on the OSArch Wiki.

    It is generally very fast to calculate the section properties for "standard" x-sections (i.e. I-sections, etc.). In my experience using the package 1-2 seconds is sufficient as long as the mesh_size is chosen appropriately (too small of a mesh can cause long calculation times); however, I think because of the flexibility of the library to also deal with complex geometrical x-sections where smaller meshes are needed this is usually a trade-off that is acceptable.

    what is the best way to share a couple simple examples? is it best to do so directly on the OSArch Wiki?

  • Sounds great @jchkoch , a page in the Wiki with a couple of examples could be nice or make a post in the forum?

  • I see so much resources, but I am confused on how to implement them in Blender straight away with a closed curve which can be used for modelling purposes.
    My workflow of getting profiles might be a bit cumbersome, but there are so much predefined dwg profiles. There are a lot on this website
    I use ODA file converter to convert them all at once to DXF, then I import them into Blender and set the scale and origin correctly.
    The CSV tables in thread might be interesting to make some script with Python which converts all these coordinates to useful curves. Or maybe it already exists? Or some existing add-on?

  • @Coen once we have tables for all standard sections and we can create ifc project libraries that we can import then these profiles will be drawn automatically in Blender. I am supposed to work on this (we started with Moult ~10 days ago) but didn't find the time yet. Let me create this first test library and then we can discuss again.
    Regarding the dxf polylines you have created, I tried sth similar in the past but I had difficulty meshing it to create the profile section which could be then extruded. I ended up using Salome to import dxf and convert to a face in stl format which was then imported in Blender.

    Coen
  • @Jesusbill

    I tried sth similar in the past but I had difficulty meshing it to create the profile section which could be then extruded. I ended up using Salome to import dxf and convert to a face in stl format which was then imported in Blender.

    I also extrude the profile sections of the mesh, but I ran into no problems. Please correct me if I'm wrong in my understanding. Or if you see any problems with my workflow.
    1) I imported the DXF and then Blender makes a Bezier curve from it?

    2) Object -> Convert to Mesh. I just get edges

    3) Select all Vertices with A and Pressing F I get the surface

    4) Using the Extrude tool

    Will the profile sections/or meshes also contain the structural data that goes with it? For example kg/m?

    The tool from DWG to DXF I used make is ODA file converter

    Here is the blend file with different dimension of UNP profiles

    I am very curious in your approach of getting all the profile sections and getting the IFC data attached to the mesh.

  • edited August 25

    @Coen for some reason when I tried it with an I section it was failing at the 3rd step that you show. Pressing "f" was not good enough to get the section mesh as it was creating a mesh that was partly outside the perimeter. Other than that, the approach I followed is exactly what you show here.

    I am very curious in your approach of getting all the profile sections and getting the IFC data attached to the mesh.

    I will report here as soon as the first test library is done, hopefully Friday

    Coen
  • @Coen said:

    The tool from DWG to DXF I used make is ODA file converter

    Are you using the 60 days Free Trial?
    If you do and the free trial stops after the 60 days. You could use LibreCAD. The experimental DWG import works fine for these files.
    Also, you can install nanoCAD 5.0 It is a freeware software.

    Coen
  • edited August 25

    @bitacovir

    Are you using the 60 days Free Trial?

    No, I don't think so. Atleast I have seen no mention of a trial period, seems like some batch tool.

    You could use LibreCAD. The experimental DWG import works fine for these files.

    Thanks for the tip. :-)

  • @Jesusbill said:
    @bernd I have done some work on the I beams, have a look at these commits
    What I did was:

    • Export into csv files all the tables of the selected collections in the "data/profile_i" folder
    • Validate existing input values compared to data from another source. From these I identified some small differences shown in the first commits
    • Enrich the csv files with extra column properties

    But when I update the blt/yaml file and attempt to write it back I get something much more ugly compared to the existing document and all the comments are lost, is there a specific way you prepare this file?

    I have not forgotten about this ... There has been a lot going in FreeCAD FEM and in FreeCAD officials. But much more time consuming is our new earth dweller. It`s a boy :-) Thus less sleep and much less time for development ...

    MeetlatbrunopostletheoryshawJesusbill
  • I really like the possibility of exporting csv data.

    You added the data as csv to the repo as well. Thus the data is duplicated. This is some risk IMHO. Should we not have one place in the repo where the data is saved? All existing YAML have been created manually AFAIK. May be we could add something to be able to convert the csv data into the yaml data?

    BTW: Before I came to BOLTS I did not know YAML either. Since than I use it everywhere in favour of xml, csv and whatever. Since it is so easy to read and write by Python and can be edited.

    Jesusbill
  • edited August 28

    Gratuliere zum open-source Nachwuchs :-) Besonders die Mutti :-), wie schafft Sie das zwischen Windeln und Tastaturen.

  • @Jesusbill

    I will report here as soon as the first test library is done, hopefully Friday

    Curious if you already found the time to show us a little part of the test library :-)

  • @bernd great to hear from you, congrats about the baby boy!
    I will respond to you as soon as I have time as I will be probably away from keyboard for the next two days.
    In general I agree with what you wrote, no need to duplicate data, I just pushed the csv tables to show what I did and then we can figure out the best way. Sorry I don't have time now to write more.

  • @Coen I did found sometime this morning but it is a very much work in progress and I have mixed up things a bit.
    I attach the ifc library file I created based on the HEA sections and I also created a short screencast in Blender.
    Bear in mind that right now we have a profile panel in the scene properties where you can see the profiles that you import from the project library but there is no way yet to assign this to a structural member. But you can see the properties and the mechanical property set (this latter is shown only for the first profile so this is a bug to fix and we also need to indicate units; the pset is in mm, while the profile properties were converted to meters before creating the project library).
    For this reason I also created IfcBeam and IfcColumn Types so that one can visualize the profile and even modify it from the object materialprofile panel, but eventually I think there will be no need for these Types if one is interested only in the profiles.
    This coming week I will continue working on this (after Monday) and with @Moult I think we can take care of things needed like being able to assign from the list of profiles to an element without need of Type, take care of units, make sure we can visualize sections of all type etc.

    Coen
  • @Jesusbill

    That is absolutely awesome!!!

  • edited August 28

    I was hobbying this saturday and tried to make some profile generator. It was more out of research and interest instead of a serious attempt.
    It's no way near as advanced as your IFC profile tool. @Jesusbill
    This was my attempt, I got a HEA profile table from internet and formatted it to CSV

    HEA;h;b;a;e;r;h1;kg/m;cm2;m2/m;m2/t
    100;96;100;5;8;12;56;16.7;21.2;0.562;33.7
    120;114;120;5;8;12;74;19.9;25.3;0.677;34.1
    140;133;140;5.5;8.5;12;92;24.7;31.4;0.794;32.2
    160;152;160;6;9;15;104;30.4;38.8;0.896;29.8
    180;171;180;6;9.5;15;122;35.5;45.3;1.02;28.9
    200;190;200;6.5;10;18;134;42.3;53.8;1.14;26.8
    220;210;220;7;11;18;152;50.5;64.3;1.26;24.9
    240;230;240;7.5;12;21;164;60.3;76.8;1.37;22.7
    260;250;260;7.5;12.5;24;177;68.2;86.8;1.48;21.8
    280;270;280;8;13;24;196;76.4;97.3;1.6;21
    300;290;300;8.5;14;27;208;88.3;112.5;1.72;19.4
    320;310;300;9;15.5;27;225;97.6;124.4;1.76;18
    340;330;300;9.5;16.5;27;243;105;133.5;1.79;17.1
    360;350;300;10;17.5;27;261;112;142.8;1.83;16.4
    400;390;300;11;19;27;298;125;159;1.91;15.3
    450;440;300;11.5;21;27;344;140;178;2.01;14.4
    500;490;300;12;23;27;390;155;197.5;2.11;13.6
    550;540;300;12.5;24;27;438;166;211.8;2.21;13.3
    600;590;300;13;25;27;486;178;226.5;2.31;13
    650;640;300;13.5;26;27;534;190;241.6;2.41;12.7
    700;690;300;14.5;27;27;582;204;260.5;2.5;12.3
    800;790;300;15;28;30;674;224;285.8;2.7;12
    900;890;300;16;30;30;770;252;320.5;2.9;11.5
    1000;990;300;16.5;31;30;868;272;346.8;3.1;11.4
    

    I wrote two functions which draw coordinates/edges from the CSV table


    import csv import bpy import mathutils from mathutils import Vector def get_hea_data(): hea_list = [] with open("C:\\Algemeen\\07_prive\\02_Blender_Python_scripts\\hea.csv") as csv_file: csv_reader = csv.reader(csv_file, delimiter=';') next(csv_reader, None) for row in csv_reader: print (row) hea_list.append(row) return hea_list def create_profile_HEA(profile_name, h,b,tw,tf): w = 1 cList = [ Vector((0,0,0)), Vector((0,tf,0)), Vector((b/2-tw,tf,0)), Vector((b/2-tw,h-tf,0)), Vector((0,h-tf,0)), Vector((0,h,0)), Vector((b,h,0)), Vector((b,h-tf,0)), Vector((b/2+tw,h-tf,0)), Vector((b/2+tw,tf,0)), Vector((b,tf,0)), Vector((b,0,0)), Vector((0,0,0)) ] curvedata = bpy.data.curves.new(name='Curve', type='CURVE') curvedata.dimensions = '3D' objectdata = bpy.data.objects.new(profile_name, curvedata) objectdata.location = (0,0,0) bpy.context.scene.collection.objects.link(objectdata) polyline = curvedata.splines.new('POLY') polyline.points.add(len(cList)-1) for num in range(len(cList)): x, y, z = cList[num] polyline.points[num].co = (x, y, z, w) scale_factor = 1000 move_factor = 0 for i in get_hea_data(): move_factor += 1 #create_profile_HEA(profile_name='HEA'+str(i[0], h=96,b=100,tw=5,tf=8) create_profile_HEA(profile_name=( 'HEA'+str(i[0])), h=float(i[1])/scale_factor, b=float(i[2])/scale_factor, tw=float(i[3])/scale_factor, tf=float(i[4])/scale_factor) hea_profile = bpy.data.objects['HEA'+str(i[0])] vec = mathutils.Vector((move_factor, 0.0, 0.0)) inv = hea_profile.matrix_world.copy() inv.invert() vec_rot = vec @ inv hea_profile.location = hea_profile.location + vec_rot

    It's not very elegant yet as I don't know how to make a fillet radius along the edges the flanges of the profile.

    This is my result:

    Jesusbill
  • @Jesusbill said:
    @bernd I have done some work on the I beams, have a look at these commits

    the fixes are merged. https://github.com/boltsparts/BOLTS/compare/cb2f514e858f13a95300083b05fcbf0b904d55a6...bfcabba17d9b0ec34ab4338c378d8597122de78b

    In the regard of the csv. How about your opinion ... see post https://community.osarch.org/discussion/comment/8493/#Comment_8493

  • @lukas said:
    Gratuliere zum open-source Nachwuchs :-) Besonders die Mutti :-), wie schafft Sie das zwischen Windeln und Tastaturen.

    vielen dank.

  • edited August 30

    @Jesusbill I took another look at your csv files for the section properties in the BOLTS repo and I think somehing must have slightly gone wrong as all of the profiles within each "table" (i.e. HEA, HEB, HEM, IPE, etc.) only seem to have the properties for the largest profile per table.
    To recalculate myself I used the sectionproperties python package to compute the structural section properties (see https://github.com/jchkoch/BOLTS/blob/profile_dev/misc/calc_structural_properties.py). I also attempted to write the updated tables directly back into the YAML files (i.e. profile_i.blt) using the pyyaml package in python; however, it turns out to not be as straightforward to write human readable values into the YAML file using python. So for now I wrote the data results as csv files (see https://github.com/jchkoch/BOLTS/tree/profile_dev/data/profile_i).
    UPDATE: managed to properly write structural section properties back into the YAML file (see https://github.com/jchkoch/BOLTS/blob/profile_dev/data/profile_i_2021.blt).

  • edited August 31

    @Jesusbill and @jchkoch
    Would it help if we would sparate the data key from the BOLTS yaml files. Thus we would have one structure file and for each class a file which only contains the pure data from data key. https://github.com/boltsparts/BOLTS/blob/72676c7d413e444/data/profile_i.blt#L60-L83

    profile_i.blt

    would split into:

    profile_i__struct.blt
    profile_i_ibeam_hea.blt
    profile_i_ibeam_heaa.blt
    profile_i_ibeam_heb.blt
    ...
    I like this idea because it would simplify reading the date by a human and tracking changes in the data would be much simpler. Changes in the data should happen only in rare cases wheras changes in the yaml class structure could happen.

  • edited August 31

    BTW: have you tried the BOLTS frontend for FreeCAD. It implements a nice gui to add all BOLTS profile data. The gui dependend on the params of the BOLTS part and is dynamically created out of the params in the blt files.
    In FreeCAD just got to the AddOn manager and install or update (I fixed some nasty import bug lately) BOLTSFC AddOn, than start it on the gui as one of the macros installed or by

    from BOLTS import show_widget as sw
    sw()
    

    most of it is FreeCAD independent PySide code https://github.com/boltsparts/BOLTS/blob/72676c7d413e44/backends/freecad/gui/freecad_bolts.py
    I have never created widgets for Blender thus ATM I have no idea if it would be possible to reuse the PySide code to create a gui for Blender.

  • some screen from FreeCAD BOLTSFC AddOn ...

    Jesusbill
  • @Jesusbill said:
    @bernd great to hear from you, congrats about the baby boy!

    thanks :-)

  • @Jesusbill said:
    I attach the ifc library file I created based on the HEA sections ...

    blenderbim-demo-library.ifc

    Is this some special ifc library file? Is this buildingSMART standard? There is not IfcProject inside the file thus none of my viewers displays anything. Some viewers even crash. I would send them the file if it was some standard.

    cheers bernd

  • edited August 31

    BTW:
    Did you know BOLTS has a webpage with all the parts too ... The page es even translated. Attached the German HEM page

    https://www.bolts-library.org/de/parts/index.html

    just realized the drawings are missing on the webpage ... it should look like this for I-Beams...

    carlopav
  • edited September 1

    I had a look at https://github.com/Jesusbill/BOLTS/blob/43d382a1c450/misc/export_data.py and https://github.com/jchkoch/BOLTS/blob/5b615689d313/misc/calc_structural_properties.py

    Mhh they both just use the data of BOLTS but do not use the BOLTS API to access the data. I must admit doing this is not straight forward ATM. I started to make improvements in this regard.

Sign In or Register to comment.