add new function to fem module
Moderator: bernd
Forum rules
and Helpful information for the FEM forum
and Helpful information for the FEM forum
Re: add new function to fem module
wow cool! We should definately add this to the examples.
-
- Posts: 991
- Joined: Wed Mar 27, 2019 10:45 am
Re: add new function to fem module
Regarding the buckling case shown last, might I suggest to lock the end supporting the force in X&Y, this way instead of a full "free end" deflection we see actual buckling?
Re: add new function to fem module
Ok, then I will add this as well.
I found out what was causing the small difference in results. In the verification example the load are divided equal between all the top nodes, not regarding to the influenced area of the load.
Calculix verification example beam8b.inp
Code: Select all
*NSET,NSET=LAST
65,
66,
67,
68,
101,
102,
135,
136,
169,
170,
203,
204,
221,
238,
255,
288,
289,
306,
323,
340,
373,
374,
391,
408,
425,
*STEP
*BUCKLE
10,0.01
*CLOAD
LAST,3,-0.84
Code: Select all
***********************************************************
** constraints force node loads
** written by write_constraints_force function
*CLOAD
** ConstraintForce
** node loads on shape: Box:Face6
65,3,-3.2812500000000E-01
66,3,-6.5625000000000E-01
67,3,-6.5625000000000E-01
68,3,-1.3125000000000E+00
101,3,-6.5625000000000E-01
102,3,-1.3125000000000E+00
135,3,-6.5625000000000E-01
136,3,-1.3125000000000E+00
169,3,-3.2812500000000E-01
170,3,-6.5625000000000E-01
203,3,-6.5625000000000E-01
204,3,-1.3125000000000E+00
221,3,-1.3125000000000E+00
238,3,-1.3125000000000E+00
255,3,-6.5625000000000E-01
288,3,-6.5625000000000E-01
289,3,-1.3125000000000E+00
306,3,-1.3125000000000E+00
323,3,-1.3125000000000E+00
340,3,-6.5625000000000E-01
373,3,-3.2812500000000E-01
374,3,-6.5625000000000E-01
391,3,-6.5625000000000E-01
408,3,-6.5625000000000E-01
425,3,-3.2812500000000E-01
[code]
Re: add new function to fem module
The main goal with that example is to verify that the input file that are generated from FreeCAD match with the verification example from Calculix.RatonLaveur wrote: ↑Fri Mar 19, 2021 2:22 pm Regarding the buckling case shown last, might I suggest to lock the end supporting the force in X&Y, this way instead of a full "free end" deflection we see actual buckling?
Boring, I know. But still it qualify as actual buckling
Re: add new function to fem module
I'm trying to semi-grasp the unit test without reading all the code. Can someone explain to me how it works?
I'm looking at this: https://github.com/FreeCAD/FreeCAD/comm ... 77ec8afd06
It compares the inp file when compiling?
I'm looking at this: https://github.com/FreeCAD/FreeCAD/comm ... 77ec8afd06
It compares the inp file when compiling?
Re: add new function to fem module
no it does not. This file was mady by me to very easy compile FreeCAD and run a specific unit test manually because a complete unit test run of FreeCAD could take some minutes. It is not used at all from FreeCAD itself. If I need to compile FreeCAD and run a spcific unit test or unit test class I only need to copy the command from this file into my bash and wait a few seconds.twangrt wrote: ↑Tue Mar 30, 2021 7:28 am I'm trying to semi-grasp the unit test without reading all the code. Can someone explain to me how it works?
I'm looking at this: https://github.com/FreeCAD/FreeCAD/comm ... 77ec8afd06
It compares the inp file when compiling?
Re: add new function to fem module
But you are correct. The unit test wors the way you foud yourself. The inp file written by the unit test is compared with a inp file saved in unit test case data directory for calculix test cases. See https://github.com/FreeCAD/FreeCAD/tree ... a/calculix
Re: add new function to fem module
BTW: The file test_commands.sh is created by Python because I am lazy. Sudhanshu did add the lines manually since he did not know how to create the file by Python. If only one test is added this might even be faster than update the file by Python. https://github.com/FreeCAD/FreeCAD/blob ... ls.py#L103
Re: add new function to fem module
I added it manually. Seemed like the easiest way for me.bernd wrote: ↑Tue Mar 30, 2021 11:32 am BTW: The file test_commands.sh is created by Python because I am lazy. Sudhanshu did add the lines manually since he did not know how to create the file by Python. If only one test is added this might even be faster than update the file by Python. https://github.com/FreeCAD/FreeCAD/blob ... ls.py#L103
I'm having second thoughts about the LTB example. I think the example is good, but it would be great to find another verification example, maybe it don't need to be an example from Calculix?
Re: add new function to fem module
Now I have updated my lateral torsional buckling example. Hopefully fixed all the CMake/compiling stuff that went wrong in my earlier commits.
To simplify everything the example builds on a verification example from another FEA program.
Example 3.3 in: http://download.strusoft.com/FEM-Design ... amples.pdf
With the current mesh it's within 5% of the example. With more refined mesh(double the current size of the meshpy file) I'm able to get under 3% difference. To note, it that the mesh already is quite big for an example file.
Bernd, have you had time to check anything? I've been struggling a bit with the tests/compiling but I think I've almost got it
Im thinking of trying to fix the name of the returned result files(importCcxFrdResults.py). When calculating with 'buckling' the result is now displayed as 'Time'.
But I have not figured out a specific way to tell that a '.frd' is a buckling analysis result file. My now best bet is to read in the '.dat' file for determining the resultfile.
To simplify everything the example builds on a verification example from another FEA program.
Example 3.3 in: http://download.strusoft.com/FEM-Design ... amples.pdf
With the current mesh it's within 5% of the example. With more refined mesh(double the current size of the meshpy file) I'm able to get under 3% difference. To note, it that the mesh already is quite big for an example file.
Bernd, have you had time to check anything? I've been struggling a bit with the tests/compiling but I think I've almost got it
Im thinking of trying to fix the name of the returned result files(importCcxFrdResults.py). When calculating with 'buckling' the result is now displayed as 'Time'.
But I have not figured out a specific way to tell that a '.frd' is a buckling analysis result file. My now best bet is to read in the '.dat' file for determining the resultfile.