SMath For Engineering Calculations - How to create interconnected calculations - Сообщения
#61 Опубликовано: 23.11.2014 09:25:53
BeamFEA updated:
Unit support was non-trivial. I failed to make the solver unit-proof because matrix inversion with units is not robust in SMath (probably due to poor pivot scaling in the algorithm).
Also, you easily can create programs which will crash SMath immediately after opening them (if auto-recalculate is on). I added this to SS-1227.

- unit support. You can specify units as factors for the modeler units. The preprocessor eliminates the units such that the solver input is unit-free. In the output the appropriate units are applied and can be modified as usual for display. Note that you can define separate units for length ('l.0)and displacement ('w.0).
- separate diagrams for distributed load, transverse force, bending moment and displacement
- input color scheme changed:
- concentrated moment load and rotational constraint in red
- concentrated forces and vertical supports in green
- concentrated moment load and rotational constraint in red
Unit support was non-trivial. I failed to make the solver unit-proof because matrix inversion with units is not robust in SMath (probably due to poor pivot scaling in the algorithm).
Also, you easily can create programs which will crash SMath immediately after opening them (if auto-recalculate is on). I added this to SS-1227.
Martin Kraska
Pre-configured portable distribution of SMath Studio: https://en.smath.info/wiki/SMath%20with%20Plugins.ashx
1 пользователям понравился этот пост
IVR 25.11.2014 15:09:00
#62 Опубликовано: 23.12.2014 14:34:37
Martin,
Many beams designs are single ("simple" ) span beams. For improved efficiency, is it possible to set up an input base on matrices for a single span case similar to this:

I seem to be struggling to implement this into the BEAM FEA... not sure if you could lend a hand... sorry to be a bother.
Many beams designs are single ("simple" ) span beams. For improved efficiency, is it possible to set up an input base on matrices for a single span case similar to this:
I seem to be struggling to implement this into the BEAM FEA... not sure if you could lend a hand... sorry to be a bother.
#63 Опубликовано: 23.12.2014 16:13:52
WroteMartin,
Many beams designs are single ("simple" ) span beams. For improved efficiency, is it possible to set up an input base on matrices for a single span case similar to this:
I seem to be struggling to implement this into the BEAM FEA... not sure if you could lend a hand... sorry to be a bother.
I see two options for integration with Beam FEA:
- either you generate a fake modeller output and feed that into the preprocessor
- or you write your own preprocessor and create the node and element matrices directly.
The same applies to the postprocessing. For modularity, I would recommend to write a separate postprocessing function working on the output of the solver.
Let me know what road you are going to go and what problems you face. Then I might be more specific.
Martin Kraska
Pre-configured portable distribution of SMath Studio: https://en.smath.info/wiki/SMath%20with%20Plugins.ashx
#64 Опубликовано: 23.12.2014 20:11:45
I was thinking that I would have a matrix for each loading option you have available in the modeller.
The loads from these matrix would be shown in the modeller. So I guess I'm not sure how to how to do that.
I suppose it does not have to be a simple span beam, but maybe there is a matrix where you list distance between supports (or absolute distance, either is fine).
Does this make sense or am I still too Vague?
I suppose one drawback to going this route could be that if I plan to use this on a page with many other variable there is risk of overwriting the variables defined in the "Templates area". Do you see issues with repeating beam fea on the page multiple times?
The loads from these matrix would be shown in the modeller. So I guess I'm not sure how to how to do that.
I suppose it does not have to be a simple span beam, but maybe there is a matrix where you list distance between supports (or absolute distance, either is fine).
Does this make sense or am I still too Vague?
I suppose one drawback to going this route could be that if I plan to use this on a page with many other variable there is risk of overwriting the variables defined in the "Templates area". Do you see issues with repeating beam fea on the page multiple times?
#65 Опубликовано: 28.12.2014 07:14:40
I think that one could create a function with local definition of templates, pre- and postprocessing, solving and modeler object generation. Then you would just call that function with whatever you define the input to be and get the required objects from the argument slots of the function. If these objects are properly initialized inside the function, then the same names can be used for each call.
Beam(Input, T, P, Out)
with
Input being a list of whatever matrices you want to use as input
T being the template list for the modeler
P being a matrix of predefined objects in the modeler
(both used to display the model and/or the solution)
Out is a list of whatever numeric results you want.
Beam(Input, T, P, Out)
with
Input being a list of whatever matrices you want to use as input
T being the template list for the modeler
P being a matrix of predefined objects in the modeler
(both used to display the model and/or the solution)
Out is a list of whatever numeric results you want.
Martin Kraska
Pre-configured portable distribution of SMath Studio: https://en.smath.info/wiki/SMath%20with%20Plugins.ashx
#66 Опубликовано: 05.01.2015 20:31:20
Martin I am trying to understand what I'm doing wrong with this calculation, see attached.
I am trying to evaluate a 10' long beam. Moment of inertia = 1 in^4, E=1500 ksi, uniform load = 200 lbf/ft.
Obviously these numbers are just arbitrary but I can't seem to get the correct deflection.
Also how do I rescale the graph? Just zoom with mouse?
BeamFEA -Test Simple Span 10ft beam.sm (178 КиБ) скачан 99 раз(а).
I am trying to evaluate a 10' long beam. Moment of inertia = 1 in^4, E=1500 ksi, uniform load = 200 lbf/ft.
Obviously these numbers are just arbitrary but I can't seem to get the correct deflection.
Also how do I rescale the graph? Just zoom with mouse?
BeamFEA -Test Simple Span 10ft beam.sm (178 КиБ) скачан 99 раз(а).
#67 Опубликовано: 23.01.2015 00:54:57
OK, I am going to try and finally get to work on this.
I will take the approach "either you generate a fake modeller output and feed that into the preprocessor"
Maybe Oxel has done some work on this?
I'm not sure which is best though. I could have the user input span lengths or input the location of the supports/hinges. My instinct says that maybe entering nodes is best then you can also define if the node is a hinge. So you have:
All inputs would have units
Support/hinge Matrix:
Row 1: location of support
Row 2: 1/0 (support / hinge)
Uniform Load matrix (uniform over all spans):
Row 1: Load
Partial load matrix:
Row 1: Start magnitude
Row 2: Start location
Row 3: End magnitude
Row 4: End location
Point Load matrix:
Row 1: Load magnitude
Row 2: Location
Sooo....
We would then create a matrix for the supports. We would call on template 2, set the X, set the y=0 say, not sure what to use to define there width/height.
I will start here see how it goes.
Also I hope to keep in mind that everything should be function oriented and repeatable on the same page.
Modeller input.sm (29 КиБ) скачан 68 раз(а).
I will take the approach "either you generate a fake modeller output and feed that into the preprocessor"
Maybe Oxel has done some work on this?
I'm not sure which is best though. I could have the user input span lengths or input the location of the supports/hinges. My instinct says that maybe entering nodes is best then you can also define if the node is a hinge. So you have:
All inputs would have units
Support/hinge Matrix:
Row 1: location of support
Row 2: 1/0 (support / hinge)
Uniform Load matrix (uniform over all spans):
Row 1: Load
Partial load matrix:
Row 1: Start magnitude
Row 2: Start location
Row 3: End magnitude
Row 4: End location
Point Load matrix:
Row 1: Load magnitude
Row 2: Location
Sooo....
We would then create a matrix for the supports. We would call on template 2, set the X, set the y=0 say, not sure what to use to define there width/height.
I will start here see how it goes.
Also I hope to keep in mind that everything should be function oriented and repeatable on the same page.
Modeller input.sm (29 КиБ) скачан 68 раз(а).
#68 Опубликовано: 25.01.2015 07:51:10
RFreund, sorry for not being responsive lately. Quite busy at the moment.
I think for the supports you succeeded to implement the translation function from your favorite input format to modeler output. I just made some modifications:
- better readibility by introduction of temporary variables and by replacing nested ifs by cases()
- better robustness by creating valid modeler input even in case of unknown support type. In that case, a detailed error message is written to the output window via trace(). This is essential, as the input selection in the modeler gets lost whenever the input renders invalid. This is annoying, because you have to re-select the pre-defined layout in the modeler again.

I think for the supports you succeeded to implement the translation function from your favorite input format to modeler output. I just made some modifications:
- better readibility by introduction of temporary variables and by replacing nested ifs by cases()
- better robustness by creating valid modeler input even in case of unknown support type. In that case, a detailed error message is written to the output window via trace(). This is essential, as the input selection in the modeler gets lost whenever the input renders invalid. This is annoying, because you have to re-select the pre-defined layout in the modeler again.
Martin Kraska
Pre-configured portable distribution of SMath Studio: https://en.smath.info/wiki/SMath%20with%20Plugins.ashx
#69 Опубликовано: 25.01.2015 10:33:22
Excellent Martin. Thank you. I will post back soon, hopefully, with loading, etc.
#70 Опубликовано: 25.01.2015 11:57:59
Martin,
Again thank you for the response. Attached is an updated version, probably with poor scripting again by myself (side question, is "scripting" the correct term to use here?).
So a few questions/comments:
Thanks again! I think once I have a figured this out I will have an efficient beam calculator and I can start posting more analysis / design examples/snippets.
Modeller input.sm (82 КиБ) скачан 97 раз(а).
Again thank you for the response. Attached is an updated version, probably with poor scripting again by myself (side question, is "scripting" the correct term to use here?).
So a few questions/comments:
- Could you elaborate on cases()? When I type in cases its description is "Define piecewise functions"
- Also (maybe this is cases) but how did you create the system using if and otherwise?
- I'm not sure the best/simplest way to handle the scaling of the beam and loads. If I understand correctly, the beam height from the modeler is given to the preproccesor and used for EI. Likewise the height of the loads are used to determine magnitude in the preprocessor. Therefore it would seem that I need to relate the scaling of the beam to the E and I input and the loads to the load input. However I think that maybe it would be more 'robust' if the scaling was separate from the loading input. That way you can change the scaling to proportion things as you'd like. Or mabye all items should be in proportion to the length of the beam. Maybe this is wrong though. In any case, I think that direct input into the preprocessor would be too challenging for me or creating unnecessary work and my main objective is to have a functioning script and maybe we can modify later. I'm looking for input on what you think is the best approach.
- Another issue is Varying loads that are trapezoidal in shape. Really I need to send the w.p# input to a script which checks for this condition and creates a new matrix with a partial uniform load a triangular load over the same length of beam. In the attached a put a small section of script showing my intent.
Thanks again! I think once I have a figured this out I will have an efficient beam calculator and I can start posting more analysis / design examples/snippets.
Modeller input.sm (82 КиБ) скачан 97 раз(а).
#71 Опубликовано: 28.01.2015 11:43:46
cases(): You find them under cases() in the function index of the interactive handbook.
trapezoidal distributed loads: You indeed have to stack them from uniform and triangular loads in the modeller, because trapezoidal templates would have a fixed ratio of left to right value regardless of scaling.
In the element matrix, however, you can specify the corner values directly.
Units and scaling: there is a cloud version with units: http://smath.info/cloud/file/NESDC.
trapezoidal distributed loads: You indeed have to stack them from uniform and triangular loads in the modeller, because trapezoidal templates would have a fixed ratio of left to right value regardless of scaling.
In the element matrix, however, you can specify the corner values directly.
Units and scaling: there is a cloud version with units: http://smath.info/cloud/file/NESDC.
Martin Kraska
Pre-configured portable distribution of SMath Studio: https://en.smath.info/wiki/SMath%20with%20Plugins.ashx
#72 Опубликовано: 08.02.2015 15:41:34
It should be noted that cases does NOT handle units or atleast it does not appear to. Very odd behavior if trying to compare units using cases.
EDIT:
OK, maybe it is not cases see here:
http://en.smath.info/forum/yaf_postsm19047_BeamFEA-Questions.aspx#post19047
EDIT:
OK, maybe it is not cases see here:
http://en.smath.info/forum/yaf_postsm19047_BeamFEA-Questions.aspx#post19047
-
Новые сообщения
-
Нет новых сообщений