Commit Graph

3695 Commits

Author SHA1 Message Date
wmayer
7ae9fc0d67 Fem: modernize C++11
* use nullptr
2022-03-23 19:26:15 +01:00
Uwe
348562ddcc [FEM] header files: remove unused includes 2022-03-23 17:36:08 +01:00
Uwe
ec113193ef [FEM] revert incorrect header removal
- also add comment to prevent this in future
2022-03-23 16:22:57 +01:00
Uwe
0419d2f756 [FEM] Electrostatic: read values with its unit 2022-03-23 16:03:35 +01:00
Yorik van Havre
1dd773e7b3 Translations: Merged crowdin strings 2022-03-23 10:37:50 +01:00
Uwe
cb82d8e97a [FEM] remove some unused includes 2022-03-23 05:43:40 +01:00
Uwe
876b694230 [skip CI] [FEM] whitespace fix 2022-03-23 05:21:48 +01:00
Uwe
389ae0ab39 [FEM] SI unit fixes for Elmer
- since we use consistently SI units (as recommended my the Elmer forum), we need to scale the input mesh (we use ElmerGrid that has an option fur this purpose)
- Since the result will be in the scaled mesh, we need to scale it back

With this PR, one gets now correct result independent of
- the used unit scheme
- the simulation type (electrical or thermo-mechanical)
2022-03-23 05:00:40 +01:00
Uwe
b935de6851 [FEM] fix unit for Elmer
to assure we use SI units
2022-03-22 05:11:02 +01:00
Uwe
d5604e0e89 [FEM] remove Python.h and Xerces 2022-03-21 01:22:59 +01:00
Ajinkya Dahale
300fbc22ea [FEM] Refactor TaskFemConstraintOnBoundary (#6615)
* Now the behavior is consistent with behavior of PD fillets, for example.
See https://forum.freecadweb.org/viewtopic.php?f=18&t=67135#p580192. In the
future it may be possible to reuse some code from there.

* When the last selected item is removed we need to reset the existing
highlighting separately.

* Use `Gui::ButtonGroup` in `TaskFemConstraintOnBoundary`
2022-03-21 01:02:10 +01:00
wmayer
cf7fd5d2ac lgtm: removes unused imports in Python scripts 2022-03-20 23:00:55 +01:00
wmayer
fdf5df5645 Fem: [skip ci] change include order to fix compiler warning due to a re-defition of a macro in a Python header 2022-03-20 13:44:55 +01:00
Uwe
8ccc661379 [FEM] adapt a test to previous commit
(I run of course all tests using the Test Framework WB but did not get an error.)
2022-03-19 18:09:14 +01:00
Uwe
29f5e78583 [FEM] proper Elmer input file write solution
- assure that independent on the used unit scheme, SI units are written to the Elmer input file
- reverts commits https://github.com/FreeCAD/FreeCAD/commit/4a7f7a0faa and https://github.com/FreeCAD/FreeCAD/commit/28a4f6aef
2022-03-19 17:48:11 +01:00
wmayer
90d546d1e7 Fem: replace raw pointer with WeakPtrT to check if the object has been deleted, fix crash in destructor of TaskFemConstraintOnBoundary 2022-03-19 15:37:31 +01:00
Uwe
00ea879bfd [FEM] change example to fit with Elmer's tutorial
- this example is the Elmer tutorial number 13: https://www.nic.funet.fi/pub/sci/physics/elmer/doc/ElmerTutorials.pdf and they use a potential of 1.0, since Elmer uses SI units, it is 1.0 V
2022-03-19 15:29:55 +01:00
Uwe
c360c6e5f5 [FEM] electrostatic dialog revision
- use a quantity spinbox and do simple signal/slot handling in the UI file
2022-03-19 05:01:23 +01:00
Uwe
aba3d40b2f [FEM] forgot this test case in previous commit 2022-03-19 03:51:06 +01:00
Uwe
258bce7261 [FEM] update test files to previous Elmer fixes 2022-03-19 03:34:18 +01:00
Uwe
28a4f6aefa [FEM] fix vacuum permittivity for the Elmer solver
also a missing fix for the density
2022-03-19 03:06:27 +01:00
Uwe
4a7f7a0faa [FEM] fix the Elmer solver writer
- fixes #6604
as it was, Elmer was almost unusable because most values were input with wrong units to Elmer.
Elmer uses pure SI units

ToDo: fix the still wrong Vacuum permittivity
2022-03-19 01:53:26 +01:00
Uwe
4fa884a2cf [FEM] [skip CI] improve electrostatic dialog
- to gain more horizontal space
2022-03-19 01:50:37 +01:00
Uwe
e3f6fa6661 [skip CI] [FEM] cleanup SVG code of new icon 2022-03-18 00:45:08 +01:00
Uwe
1293eb2116 [FEM] add icon for the new supported MYSTRAN solver 2022-03-18 00:18:25 +01:00
Uwe
5f5e5a4b35 [skip CI] [FEM] save an icon as plain SVG 2022-03-18 00:16:57 +01:00
Uwe
2cb9ddddae [FEM] task dialogs: remove unused includes
- also some code style fixes from MSVC
2022-03-17 23:31:17 +01:00
Uwe
7d692a82db [FEM] save new icon as plain SVG 2022-03-17 22:38:09 +01:00
Uwe
4e7b96d250 [FEM] add missing preferences settings
- since 0.19 we support to check meshes
- since 0.20 we support buckling

- also revise dialog to get rid of arbitrary limits etc.
2022-03-17 22:33:56 +01:00
Uwe
9590317cd9 [FEM] settings dialogs: uniform width
- some minor changes automatically done by Qt Designer
2022-03-17 21:47:58 +01:00
Uwe
d00e52c81d [FEM] settings dialogs: remove unused includes 2022-03-17 21:27:46 +01:00
Uwe
1ddb4d27e7 [FEM] remove unused headers from WBs main files
- also some code style fixes by MSVC
2022-03-17 20:33:33 +01:00
Uwe
2e084ed18a [FEM] remove some unused includes for some dialogs
- also some style fixes made by MSVC
2022-03-17 19:53:12 +01:00
wmayer
9160f06e1c Base: rename BaseExceptionFreeCADError to PyExc_FC_GeneralError 2022-03-17 14:45:48 +01:00
wmayer
d69defaa3c Py: replace BaseExceptionFreeCADError with more suitable exception types 2022-03-17 13:54:23 +01:00
Uwe
c0ceecbcf6 [FEM] Contact and Displacement: remove unused headers 2022-03-17 03:46:41 +01:00
Uwe
dead2fc8f1 [FEM] Bearing and FluidBoundary: code improvements
- get rid of UI-coded limits
- fix layout issues
- code simplifications
- remove unused headers
2022-03-17 03:45:38 +01:00
Uwe
c6ac4affc8 [FEM] sanitize some dialogs
- uniform button layout
- uniform width
- fix layout issues reported by Qt Designer
2022-03-17 03:02:05 +01:00
Uwe
122e137939 [FEM] fixes for displacement dialog
- add missing global dialog layout (reported by Qt Designer)
- get rid of arbitrary spinbox limits
- uniform UI element names
- simplify code
2022-03-16 01:29:46 +01:00
Uwe
e6f488393a [FEM] fix logic in electric potential dialog
if capacitance is not specified the spinbox must not be enabled
2022-03-15 04:53:59 +01:00
Uwe
14dd46a0fd [FEM] add tooltips for electrostatic dialog 2022-03-15 04:27:31 +01:00
Uwe
0f05a7d378 [FEM] fixes for electrostatic dialog
- fix form layout, fix distance between objects etc. (most reported by Qt's designer)
2022-03-15 03:06:15 +01:00
Uwe
ac52b39328 [FEM] fix Results dialog size
- reduce to a sensible size and get rid of unneeded spacer
- further changes automatically done by Qt's Designer
2022-03-14 22:14:06 +01:00
Uwe
075276e215 [FEM] fix Centrif dialog size
- reduce to a sensible size and get git on unneeded spacer
2022-03-14 20:51:27 +01:00
Yorik van Havre
6efe74a554 Merged crowdin translations 2022-03-14 12:21:01 +01:00
wmayer
0054cbddaa Fix coverity issue:
* CID 332682: Resource leak
* CID 350607: Resource leak
* CID 332677: Resource leak
2022-03-14 11:35:04 +01:00
wmayer
76d1180283 Fem: Fix several coverity issues:
* make SelectionChangeModes an enum class
* CID 350596: Uninitialized scalar field
* CID 350572: Uncaught exception
* CID 350647: Uncaught exception
2022-03-13 14:09:04 +01:00
Anders Torger
08552c6e68 Apply multi-thread configuration for Calculix also when started via task panel 2022-03-13 13:32:30 +01:00
Anders Torger
65718f0e51 Add General.NumThreads = CPU core count setting to Gmsh
settings file to enable multi-threaded meshing (much faster
for larger models)
2022-03-12 23:26:55 +01:00
wmayer
8d3c66cf18 Core/Mod: modernize C++11
* use nullptr
2022-03-09 21:55:31 +01:00