Commit Graph

4299 Commits

Author SHA1 Message Date
Uwe
962dd41734 [FEM] Transform constraint overhaul
- fix warning about local scope
- make the angles a PropertyAngle to handle the unit
- also fix some too long code lines
2023-03-28 02:11:36 +02:00
Uwe
cc6c98c1d4 [FEM] Temperature constraints overhaul
- fix bug that changing constraint type in dialog lost flux value
- accept and not immediately save any changed value
- make the temperatures a PropertyTemperature to get rid of hacks
- also fix some too long code lines
2023-03-28 01:23:47 +02:00
Uwe
7d17ecfeba [FEM] ConstraintDisplacement: fix property conversion
- as the comment correctly wrote it was a PropertyFloat before and PropertyDistance after - fox the routine accordingly
2023-03-27 21:29:52 +02:00
Uwe
9ebca4aec5 [FEM] [skip ci] add tooltip to a preferences option 2023-03-27 02:53:11 +02:00
Chris Hennes
fd1a8dc85a Merge pull request #9067 from Pesc0/removesix
remove remaining six dependencies
2023-03-26 17:36:47 -05:00
Pesc0
1c093e8729 remove remaining six dependencies 2023-03-26 23:39:00 +02:00
Uwe
afecf62faf [FEM] [skip ci] add tooltip to preferences options 2023-03-26 21:25:33 +02:00
Uwe
e90347e3f7 [FEM] fix binary check
- the current implementation only considers explicitly given binaries (with full path) and ignores the setting to check the environment paths
- also remove 2 trailing whitespaces
2023-03-26 19:35:20 +02:00
Uwe
bd2b95562b [FEM] proper support for transient analyses
- for the first time ever you get now for every time step a result in FreeCAD
- this way also change output filename prefix to "FreeCAD" to avoid we depend on the default name Elmer gives and that was already changed in the past and to distinguish the *.vtu files from those created e.g. directly by ElmerGui
- also remove an unnecessary output to the case.sif file
2023-03-26 10:00:45 +02:00
Uwe
b0eec67163 [FEM] change example file
- make mesh more coarse to save calculation time
- since it is the example for transient solving, get one more result
2023-03-26 09:52:32 +02:00
Uwe
e0695a18c8 [FEM] Elmer: add missing deformation info
- also some formatting changes done by clang
2023-03-26 09:32:56 +02:00
Uwe
3ddb996c04 [FEM] App: improve PreCompiled.h
- remove unused includes
- sort entries and remove duplicates
2023-03-25 19:22:57 +01:00
Uwe
a76403df4c [FEM] Gui: improve PreCompiled.h
- only include necessary Qt files
- remove unused OCC includes
- sort entries and remove duplicates
2023-03-25 18:34:01 +01:00
Uwe
f0796014bc [FEM] Elmer: fix transient analyses
- different time results were never output, only the final one
  the reason is that the Output Intervals intervals property was missing
- a second reason was that the result scaling solver must be executed every time an output should be generated
- the BDF Order property is a transient-only property
2023-03-25 12:29:10 +01:00
Uwe
79842733ac [FEM] revert f3cebc81379 2023-03-25 11:38:03 +01:00
marioalexis
fc8cc7e728 Fem: Remove unnecessary type check for active analysis 2023-03-25 08:54:01 +01:00
Uwe
831f001026 [FEM] update transient analysis example file
- get outputs every 25 % and the last one is the final time
2023-03-25 05:48:14 +01:00
Uwe
954fa3f506 [FEM] Elmer: fix transient analyses
- different time results were never output, only the final one
  the reason is that the Output Intervals intervals property was missing
- a second reason was that the result scaling solver must be executed every time an output should be generated
- the BDF Order property is a transient-only property
2023-03-25 05:48:02 +01:00
Uwe
96d1fb6e50 [FEM] only show toolbar button for available solvers
- if there is e.g. no Z88 solver available, there is no need to pollute the toolbar with an icon for it
2023-03-24 22:41:48 +01:00
Uwe
5b5431b650 [FEM] fine-tune default solver setting
- if the default solver has not yet been set and there is only one solver available, set this as default
2023-03-24 21:46:26 +01:00
Uwe
05d675364c [FEM] improve new default solver setting
- fix bug if no solver should be default
- only provide solvers that are available to be the default
- also add commit opened transactions
- also remove unused include and correct an include
2023-03-24 20:24:02 +01:00
Uwe
a0c885829b [FEM] improve recently added addition method
- for the solvers the workflow should be that one can directly after adding a solver child to it via the toolbar
  Therefore select the added solver object
2023-03-24 17:32:53 +01:00
marioalexis
c97de6c038 Fem: Add option to select default solver when creating Analysis 2023-03-24 15:40:54 +01:00
Uwe
7e3d37a5fe [FEM] implement further object addition mode
- for e.g. the solver objects it is important that the added equations are visible in the TreeView
- also improve activation of analyses for documents with multiple analyses: one activates one and can then subsequently add an object to it because the activation will also select
2023-03-24 07:22:27 +01:00
Uwe
1bd5739708 [FEM] auto-activate Analyses
- this PR addresses a long-standing annoying issue: You are already in the FEM WB and load a file.
  Then you cannot just start but first have to activate the Analysis. But one is in the FEM WB to work with analyses.
2023-03-24 06:05:54 +01:00
Uwe
5a0f8436c2 [FEM] don't add CCX solver by default for new analyses
- if there are other solvers found, we should handle all solvers equally
- also reduce amount of console output on every analysis run
2023-03-24 03:25:02 +01:00
Uwe
ce62cfae95 [FEM] implement new object addition mode
- for e.g. the Elmer equations it is important that one can add several equations subsequently and that the added equations are visible in the TreeView
2023-03-24 02:43:01 +01:00
Uwe
a377a5e490 [FEM] remove unused code
- remove commented-out code that is in Python since years
2023-03-24 02:42:19 +01:00
Uwe
7edea318ea [FEM] Elmer: group mechanical equations
- also simplify code to check for existing analysis
2023-03-24 01:59:46 +01:00
Uwe
4c9afb4546 [FEM] activate spring constraint
- the spring constraint is currently unused but it can be used for Elmer mechanical analyses
This PR does so and also overhaul the dialog UI.
- use the spring constraint also in an example file
2023-03-23 15:14:50 +01:00
Uwe
3bced92364 [FEM] add example file for deformation 2023-03-23 06:17:09 +01:00
Uwe
45743d4fbd [FEM] improve displacement constraint
- use a Distance and Angle property to get the unit handling right
2023-03-23 00:50:40 +01:00
wmayer
9fa3cf8d8d Fem: fix warning field 'dimension' will be initialized after field 'ui' [-Wreorder-ctor] 2023-03-22 20:37:29 +01:00
Uwe
9d45d40ec5 [FEM] use std::unique_ptr for all dialog objects
- also fix too long line
- also further clang automatic code style changes
2023-03-22 20:08:13 +01:00
luzpaz
f1bbcd9e13 Fix typos and whitespace 2023-03-22 17:10:38 +01:00
Uwe
c9cb01531f [FEM] extend displacement constraint
- add fields to specify a formula for the displacement, this is necessary to make transient deformation analyses with Elmer
- add option to set displacement from result of flow equation
- this way also a major overhaul -> simpler dialog logic etc.
2023-03-22 15:23:32 +01:00
wmayer
cbd0f792bb C++17: remove workaround for external smesh to fix build failure on Conda 2023-03-22 13:24:21 +01:00
Uwe
14c88f41fb [FEM] several Elmer fixes
- fix whitespace in the SIF writer
- Elmer GUI uses only 20 nonlinear iterations, so we should do the same (500 were also not sensible)
- don't restrict nonlinear-Newton iterations to 100, 500 might be necessary for turbulent flow
- update author
2023-03-22 07:27:20 +01:00
Uwe
333cf5fdd7 [FEM] fixes for deformation equation
- deformation is a nonlinear equation
- use the default that Elmer GUI uses for this equation
2023-03-22 07:20:51 +01:00
Uwe
0fcea8b3bb [FEM] Elmer add support for nonlinear elasticity solver
- adds new equation "Deformation" (this name since the stress solver got in FreeCAD the misleading name "elasticity")

- this way change icon of elastic solver to make the difference clear
2023-03-22 03:27:27 +01:00
luzpaz
818c66d663 FEM: [skip ci] fix grammar for console message 2023-03-21 01:39:09 +01:00
luzpaz
f87b919e0d Fix various whitespace issues 2023-03-20 16:38:40 +01:00
Uwe
f1799f27b0 [FEM] fine-tune flow examples
- use a more sensible velocity distribution
- change inlet temperature for 2 examples

- also change step size for nonlinear iterations for more convenience for practical usage
2023-03-20 07:17:11 +01:00
Uwe
866ea2551d [FEM] rewrite initial velocity constraint
- same as #8963 but for initial velocity

- add an example file that demonstrates the influence of the initial velocity
- some fine-tuning for the existing flow example
2023-03-20 04:58:24 +01:00
Uwe
b496a41cd1 [FEM] rewrite velocity constraint
- complete revision of the constraint.

This is a breaking change, meaning existing constraints won't work.

This is possible because since 2 days ago the whole flow equation did not work at all. Also the existing constraint implementation if buggy and cannot be used to do the Elmer tutorial. Also, the constraint is only used by Elmer and only be the flow equation.

Since nobody complained about the obvious wrong results, we can assume the flow equation was not yet in practical usage (and for FC 0.20 we known that it does not work at all, first with FC 0.20.1).

It is necessary since it must be possible to either input a velocity or an equation. With an equation, a velocity profile can be specified.

- update the flow examples accordingly:
-- simplify them since an initial and and output velocity is not necessary to specify
-- use a formula as input velocity for the non-turbulent example
2023-03-20 01:57:09 +01:00
Uwe
715472a991 [FEM] Elmer: support for variable strings
- Elmer offers the "Variable" calls do define variables via math equations. These are for example used to define as constraint a certain velocity profile
2023-03-20 01:14:34 +01:00
Uwe
0e0ba00987 [FEM] output less messages
- the message how to use the feature is not useful since it is triggered by the GUI selection and in the GUI has already the info in form of tooltips how to use
2023-03-20 01:13:46 +01:00
Uwe
6dc12e0c19 [FEM] update a file license
- like in #8933
2023-03-18 01:04:17 +01:00
Chris Hennes
5e6a63be24 Fem: Fix licensing of Calculix test FCStd files (#8933)
* Fem: Fix licensing of Calculix test FCStd files
2023-03-18 00:47:02 +01:00
Uwe
cf29318063 [FEM] add an example for a turbulent flow 2023-03-17 17:57:09 +01:00