getdp issueshttps://gitlab.onelab.info/getdp/getdp/-/issues2024-03-12T07:15:26Zhttps://gitlab.onelab.info/getdp/getdp/-/issues/167Compilation error when building getdp 3.6.0. on FreeBSD,2024-03-12T07:15:26ZStephen Montgomery-SmithCompilation error when building getdp 3.6.0. on FreeBSD,In line 120 of src/kernel/LinAlg_SPARSKIT.cpp, the function declaration of LinAlg_CreateMatrix conflicts with its prototype defined on line 99 src/kernel/LinAlg.h. Using the clang-17.0.6 compiler gives the error:
ld: error: undefined sy...In line 120 of src/kernel/LinAlg_SPARSKIT.cpp, the function declaration of LinAlg_CreateMatrix conflicts with its prototype defined on line 99 src/kernel/LinAlg.h. Using the clang-17.0.6 compiler gives the error:
ld: error: undefined symbol: LinAlg_CreateMatrix(gMatrix\*, gSolver\*, int, int, bool)
> > > referenced by EigenSolve_ARPACK.cpp CMakeFiles/getdp.dir/src/kernel/EigenSolve_ARPACK.cpp.o:(EigenSolve_ARPACK(DofData\*, int, double, double, int)) referenced by Cal_AssembleTerm.cpp CMakeFiles/getdp.dir/src/kernel/Cal_AssembleTerm.cpp.o:(Cal_AssembleTerm_NoDt(Dof\*, Dof\*, double\*)) referenced by Cal_AssembleTerm.cpp CMakeFiles/getdp.dir/src/kernel/Cal_AssembleTerm.cpp.o:(Cal_AssembleTerm_DtDof(Dof\*, Dof\*, double\*)) referenced 34 more times did you mean: LinAlg_CreateMatrix(gMatrix\*, gSolver\*, int, int) defined in: CMakeFiles/getdp.dir/src/kernel/LinAlg_SPARSKIT.cpp.o c++: error: linker command failed with exit code 1 (use -v to see invocation)
I could fix it with the following patch (which will be mangled by the editor, but is easy to do by hand):
`--- src/kernel/LinAlg_SPARSKIT.cpp.orig 2024-03-08 06:48:58 UTC`
`+++ src/kernel/LinAlg_SPARSKIT.cpp`
`@@ -117,7 +117,7 @@ void LinAlg_CreateVector(gVector *V, gSolver *Solver, V->N = n; }`
`-void LinAlg_CreateMatrix(gMatrix *M, gSolver *Solver, int n, int m)`
`+void LinAlg_CreateMatrix(gMatrix *M, gSolver *Solver, int n, int m, bool silent )`
`{`
`init_matrix(n, &M->M, &Solver->Params);`
`}`https://gitlab.onelab.info/getdp/getdp/-/issues/165TimeLoopAdaptive + PostOperation Convergence Criterion + MPI --> PetSC Error2024-02-28T21:06:56ZErik SchnaubeltTimeLoopAdaptive + PostOperation Convergence Criterion + MPI --> PetSC ErrorHi @geuzaine,
It seems that the combination of `TimeLoopAdaptive` and `PostOperation`-based convergence criterion does not work with MPI.
I've attached a simple `.pro` and `.geo` below to reproduce the behavior. When calling `mpirun -...Hi @geuzaine,
It seems that the combination of `TimeLoopAdaptive` and `PostOperation`-based convergence criterion does not work with MPI.
I've attached a simple `.pro` and `.geo` below to reproduce the behavior. When calling `mpirun -n 2 getdp mpi_test_adaptive_postpro.pro -solve resolution -pos postop`, I get the following error message:
<details><summary>Error Message</summary>
`
Warning : [rank 0] PETSc error: Object is in wrong state Warning : [rank 1] PETSc error: Object is in wrong state [0]PETSC ERROR: #1 VecAXPY() at /petsc-3.19.4/src/vec/vec/interface/rvector.c:595 [0]PETSC ERROR: #2 _try() at /cerngetdp/src/kernel/LinAlg_PETSC.cpp:58 #1 VecAXPY() at /petsc-3.19.4/src/vec/vec/interface/rvector.c:595 [1]PETSC ERROR: #2 _try() at /cerngetdp/src/kernel/LinAlg_PETSC.cpp:58 Warning : [rank 0] Time step 1 Try 17 Time = 2.3283064e-12 s rejected: Warning : [rank 0] No valid solution found (PETSc-Error: 73)! Info : Time step 1 Try 18 Time = 1e-12 s Stepsize = 1e-12 s Integr. Order = 1 Warning : [rank 1] Time step 1 Try 17 Time = 2.3283064e-12 s rejected: Warning : [rank 1] No valid solution found (PETSc-Error: 73)! [0]PETSC ERROR: --------------------- Error Message -------------------------------------------------------------- [0]PETSC ERROR: Object is in wrong state [0]PETSC ERROR: Not for unassembled vector, did you call VecAssemblyBegin()/VecAssemblyEnd()? [0]PETSC ERROR: See https://petsc.org/release/faq/ for trouble shooting. [0]PETSC ERROR: Petsc Release Version 3.19.4, Jul 31, 2023 [0]PETSC ERROR: init_from_res_mpi_test.pro on a real_mumps_mpi named 1c96e047515d by Unknown Fri Dec 29 19:51:45 2023 [0]PETSC ERROR: [1]PETSC ERROR: --------------------- Error Message -------------------------------------------------------------- [1]PETSC ERROR: Object is in wrong state [1]PETSC ERROR: Not for unassembled vector, did you call VecAssemblyBegin()/VecAssemblyEnd()? [1]PETSC ERROR: See https://petsc.org/release/faq/ for trouble shooting. [1]PETSC ERROR: Petsc Release Version 3.19.4, Jul 31, 2023 [1]PETSC ERROR: init_from_res_mpi_test.pro on a real_mumps_mpi named 1c96e047515d by Unknown Fri Dec 29 19:51:45 2023 [1]PETSC ERROR: Configure options --with-blaslapack-lib=/usr/lib64/libopenblasp.so --with-clanguage=cxx --with-debugging=0 --download-mumps=1 --download-metis=1 --download-parmetis=1 --download-scalapack=1 --download-blacs=1 --with-shared-libraries=0 --with-x=0 --with-scalar-type=real --download-suitesparse Configure options --with-blaslapack-lib=/usr/lib64/libopenblasp.so --with-clanguage=cxx --with-debugging=0 --download-mumps=1 --download-metis=1 --download-parmetis=1 --download-scalapack=1 --download-blacs=1 --with-shared-libraries=0 --with-x=0 --with-scalar-type=real --download-suitesparse [0]PETSC ERROR: #1 VecAXPY() at /petsc-3.19.4/src/vec/vec/interface/rvector.c:595 [0]PETSC ERROR: #2 _try() at /cerngetdp/src/kernel/LinAlg_PETSC.cpp:58 [1]PETSC ERROR: #1 VecAXPY() at /petsc-3.19.4/src/vec/vec/interface/rvector.c:595 [1]PETSC ERROR: #2 _try() at /cerngetdp/src/kernel/LinAlg_PETSC.cpp:58
`
</details>
Removing the `PostOperation` inside the `TimeLoopAdaptive` gets rid of the error message. Furthermore, running the `.pro` without `MPI` works fine.
Thank you very much for your help!
Erik
[mpi_test_adaptive_postpro.geo](/uploads/40cf0d8b56ea23206d929dcd47fdae31/mpi_test_adaptive_postpro.geo)
[mpi_test_adaptive_postpro.pro](/uploads/dd3ca40d51981533502f53191f93256e/mpi_test_adaptive_postpro.pro)https://gitlab.onelab.info/getdp/getdp/-/issues/166Typo in material properties for Aluminum2024-02-28T08:08:24ZChristopher JonesTypo in material properties for AluminumI believe that the electrical conductivity for aluminum has an extra digit in the exponent.I believe that the electrical conductivity for aluminum has an extra digit in the exponent.https://gitlab.onelab.info/getdp/getdp/-/issues/164Pre-processing of GroupOfEdgesOf Cohomology Basis for Complex Geometry2023-12-30T17:19:19ZErik SchnaubeltPre-processing of GroupOfEdgesOf Cohomology Basis for Complex GeometryHi Christophe,
We are trying to run a transient simulation of two (or more) insulated spiral pancake coils connected in series using an $\vec{H}-\phi$ formulation, see below for the geometry. Unfortunately, we could not reproduce the p...Hi Christophe,
We are trying to run a transient simulation of two (or more) insulated spiral pancake coils connected in series using an $\vec{H}-\phi$ formulation, see below for the geometry. Unfortunately, we could not reproduce the problem with easier geometries...
![geo](/uploads/e1d4f014ad61e715149887ffe1a78899/geo.jpg)
This model setup then has two cohomology basis functions. We follow Section 5 of the Gmsh cohomology paper to create a cohomology basis of 2 elements with evident physical interpretation:
![first_one_chain](/uploads/c5820bdcc2ac5257495f924b1115fb81/first_one_chain.jpg)
![second_one_chain](/uploads/48e429da66b8db5e9f6fe8cc3550fcf8/second_one_chain.jpg)
We then set up a very simple .pro file that only calls `InitSolution` in the `Resolution` and enforce a current of 1A in the first cut and 0A in the second (effectively "disabling" it). This should yield the following initial solution (log scale) with currents only in the conducting parts:
![12turns_okay](/uploads/0e49feea7697e8d9359b22356d96f985/12turns_okay.jpg)
The above picture is for a spiral of 12 turns. When increasing the number of turns to 13, we have non-zero currents in the air domain:
![13turns_ko](/uploads/2e605d6027b324dcca166b3b34f281a2/13turns_ko.jpg)
A few more symptoms:
- Removing the second cut region, i.e. `DOM_airHoleCut = Region[{ }];`, there are no currents in non-conducting domains.
- Switching to the cohomology basis originally created from the `HomologyComputation` (Regions 8 and 9 as commented in the `.pro`) without the rearranging to make homology and cohomology compatible, again no currents in the non-conducting domain.
- Below 13 turns (exclusive), no air currents. Above 13 turns, air currents.
Do you have an idea what's going on? Thanks for the help!
Please find below the simple .pro and two meshes for the two cases. We tested it with the official `GetDP 3.5.0` release.
[simple_init.pro](/uploads/59c5526761147e82431cf944e1bfab62/simple_init.pro)
[12_turns_okay.msh](/uploads/521b8989ccd3457614e7d8e633e30341/12_turns_okay.msh)
[13_turns_not_okay.msh](/uploads/101c21c367b4e001b145c1902bba72d2/13_turns_not_okay.msh)
Thank you!
Erikhttps://gitlab.onelab.info/getdp/getdp/-/issues/121Incorrect work of Interactive_Elasticity.pro template for 3D tasks2023-10-24T13:35:01ZDenIncorrect work of Interactive_Elasticity.pro template for 3D tasksFor subsequent **non-interactive** use of the ".pro" file for 3D tasks, the **Interactive_Elasticity.pro** file must be modified.
```
// insert modelDim for correct operation in 3d
If(export&&modelDim==3)
Printf(StrCat['modelDim = 3;'...For subsequent **non-interactive** use of the ".pro" file for 3D tasks, the **Interactive_Elasticity.pro** file must be modified.
```
// insert modelDim for correct operation in 3d
If(export&&modelDim==3)
Printf(StrCat['modelDim = 3;'])
>> Str[exportFile];
EndIf
```
</details>
![image](/uploads/d70bac4d2bb50b6c03da31c3c623d019/image.png)https://gitlab.onelab.info/getdp/getdp/-/issues/109Mortaring Method for Non-Conforming Meshes2023-10-24T12:08:46ZErik SchnaubeltMortaring Method for Non-Conforming MeshesHi Christophe and the GetDP community,
We are currently looking into mortaring methods in order to handle non-conforming meshes on interface curves/surfaces for scalar problems. To achieve the interface matching, we would need to compu...Hi Christophe and the GetDP community,
We are currently looking into mortaring methods in order to handle non-conforming meshes on interface curves/surfaces for scalar problems. To achieve the interface matching, we would need to compute surface/line integrals of nodal basis/test functions of the form
```math
I_{12} = \int_{\Gamma_1} v_1 \, \lambda_2' \, \text{d}\Gamma,
```
where $`v_1`$ is supported on $`\Gamma_1`$ while $`\lambda_2'`$ is supported on $`\Gamma_2`$ and the meshes discretizing $`\Gamma_1`$ and $`\Gamma_2`$ (which may be coincident) are non-matching. Hence, it is not possible (?) to use a `Link` constraint. To compute $`I_{12}`$, we would thus need an appropriate quadrature rule. The interested reader can find more information in Section 2.5.1 (in particular Remark 2.5.1) in [1].
Do you know if someone has done mortaring in GetDP in the past without using iterative methods? Would you have some insights on how to tackle integrals such as $`I_{12}`$?
Please let me know if you need more details, many thanks for all your help!
_[1]: A. Quarteroni and A. Valli, “Domain Decomposition Methods for Partial Differential Equations,” Oxford Science Publications, Oxford, 1999._https://gitlab.onelab.info/getdp/getdp/-/issues/104Error : GetDP - PETSc error: Unable to open file2023-10-19T12:25:55ZButrint AvdijajError : GetDP - PETSc error: Unable to open filehttps://gitlab.onelab.info/getdp/getdp/-/issues/134Perfect electric insulation boundary in 3D simulations2023-09-10T16:36:53ZCrisBabPerfect electric insulation boundary in 3D simulationsHi,
Would it be possible to set the "perfect electric insulation sheet" constraint to the faces of a magnet 3d as shown in the figure? The target is to simulate the magnet insulation without adding small air gaps or circuits. Is there a...Hi,
Would it be possible to set the "perfect electric insulation sheet" constraint to the faces of a magnet 3d as shown in the figure? The target is to simulate the magnet insulation without adding small air gaps or circuits. Is there any example that deals with this topic?
Thanks
![Immagine](/uploads/478adfa7cb0ab28d25fbca405eef9088/Immagine.png)https://gitlab.onelab.info/getdp/getdp/-/issues/75Electrical machine tutorial with magnet losses computation2023-09-10T16:36:42ZCrisBabElectrical machine tutorial with magnet losses computationThanks for all the tutorials shared with the community: they are very useful and detailed.
Among the Electrical machines tutorials, there is not a model which computes the magnet losses in time-domain simulations.
Do you think it is poss...Thanks for all the tutorials shared with the community: they are very useful and detailed.
Among the Electrical machines tutorials, there is not a model which computes the magnet losses in time-domain simulations.
Do you think it is possible to add this feature to one of the tutorials in the future release?
If not, Since I've not many skills with GetDP, could you suggest which computation should be added?
Thankshttps://gitlab.onelab.info/getdp/getdp/-/issues/135Creating a multivalues constraint defined by lines2023-09-10T16:36:19ZCrisBabCreating a multivalues constraint defined by linesHi,
I would like to create a constraint of the field A as shown in the figure.
Every line is a physical region.
![Az_BC](/uploads/f0a6ab1946743fca464f456b9149ac03/Az_BC.png)
I defined a function for each constraint:
```
Function {
az...Hi,
I would like to create a constraint of the field A as shown in the figure.
Every line is a physical region.
![Az_BC](/uploads/f0a6ab1946743fca464f456b9149ac03/Az_BC.png)
I defined a function for each constraint:
```
Function {
az_0[] = Vector[0, 0, -0.01838712666517017] ;
az_1[] = Vector[0, 0, -0.01837903738726093] ;
...
}
```
Then, I created a constraint for each line
```
Constraint {
{ Name az_0 ; Case { { Region Az_BoundaryLine_0 ; Value az_0[] ; } } }
{ Name az_1 ; Case { { Region Az_BoundaryLine_1 ; Value az_1[] ; } } }
{ Name az_2 ; Case { { Region Az_BoundaryLine_2 ; Value az_2[] ; } } }
...
}
```
where Az_BoundaryLine~{} is the region associated with the line.
I added the definition to the Functionspace:
```
Constraint {
{ NameOfCoef ae; EntityType EdgesOf ; NameOfConstraint a; }
For ii In {0:NumBoundaryPoints-1}
{ NameOfCoef ae; EntityType NodesOf ; NameOfConstraint az~{ii}; }
EndFor
}
```
I don't get any error from the solver, but it seems the constraints are not set when I display the A solution.
what is wrong with my procedure? I can share my files if needed.
PS: This is the solution I thought to set a field constraint defined by points. Please, tell me If you know any smarter solutions.
Thankshttps://gitlab.onelab.info/getdp/getdp/-/issues/113Correctly setting boundary condition for linear elasticity problem2023-08-26T16:41:27ZDenCorrectly setting boundary condition for linear elasticity problemDear all,
How to set the boundary condition on the dXdY boundary (problem - Elasticity, with templates GetDP), a rotating disk.
Thanks!
Denis
![ipm1](/uploads/d4e40aee9f7483157af73e6e7e880f6e/ipm1.png)
![ipm2](/uploads/d00f84b4685b4c25...Dear all,
How to set the boundary condition on the dXdY boundary (problem - Elasticity, with templates GetDP), a rotating disk.
Thanks!
Denis
![ipm1](/uploads/d4e40aee9f7483157af73e6e7e880f6e/ipm1.png)
![ipm2](/uploads/d00f84b4685b4c25f8c674de71bee259/ipm2.png)https://gitlab.onelab.info/getdp/getdp/-/issues/138GetDP, PETSc and hybrid mode of MUMPS (MPI+OpenMP)2023-05-10T11:12:04ZArtem KhoroshevGetDP, PETSc and hybrid mode of MUMPS (MPI+OpenMP)Hello!
I'm not sure if the problem is from GetDP, but I can't localize it yet.
Starting from PETSc 3.17.0, GetDP began to "hang" before starting MUMPS if the MPI + OpenMP hybrid mode is set (for example, the `-mat_mumps_use_omp_threads`...Hello!
I'm not sure if the problem is from GetDP, but I can't localize it yet.
Starting from PETSc 3.17.0, GetDP began to "hang" before starting MUMPS if the MPI + OpenMP hybrid mode is set (for example, the `-mat_mumps_use_omp_threads` option is set to 3, and GetDP is started via `mpirun -np 3` ; [https://petsc.org /main/docs/manualpages/Mat/MATSOLVERMUMPS/](url)).
Example:
```
...
E n d P r e - P r o c e s s i n g
P r o c e s s i n g . . .
Info : InitSolution[Sys_Mag]
Info : GenerateJac[Sys_Mag]
Info : SolveJac[Sys_Mag]
_hang here_
```
If you add "-v 10" for `getdp` command, then the last output line will also be an empty line after "SolveJac". If you add "-info" into .petscrc file then the last line will be empty after something like:
```
[0] PetscCommDuplicate(): Using internal PETSc communicator 93875196336640 93875202320384
[1] PetscShmCommGet(): Shared memory rank 0 global rank 0
[1] PetscShmCommGet(): Shared memory rank 1 global rank 1
[1] PetscShmCommGet(): Shared memory rank 2 global rank 2
[0] PetscShmCommGet(): Shared memory rank 0 global rank 0
[0] PetscShmCommGet(): Shared memory rank 1 global rank 1
[0] PetscShmCommGet(): Shared memory rank 2 global rank 2
[2] PetscShmCommGet(): Shared memory rank 0 global rank 0
[2] PetscShmCommGet(): Shared memory rank 1 global rank 1
[2] PetscShmCommGet(): Shared memory rank 2 global rank 2
```
This behavior is observed on all versions of PETSc branch 3.17, regardless of the version of GetDP or the problem being tested. Tested on Ubuntu 20.04 and 22.04.
PETSc configure command: `./configure --prefix=/opt/petsc --with-openmp --with-hwloc --with-mpi --download-mumps --download-scalapack --download-slepc --download-scotch --download-ptscotch --with-debugging=0`
GetDP config:
```
getdp --info
Version : 3.5.0-git-1c7570cd
Build OS : Linux64
Build options : 64Bit Arpack[contrib] Blas Gmsh Gsl Kernel Lapack MPI OpenMP PETSc PeWe Python SLEPc
PETSc version : 3.17.3 (real arithmetic)
Gmsh lib version : 4.9.5 (20220314)
Gmsh lib options : 64Bit ALGLIB[contrib] ANN[contrib] Bamg Blossom Cgns DIntegration Dlopen DomHex Eigen[contrib] Fltk GMP Gmm[contrib] Hxt Jpeg Kbipack LinuxJoystick MathEx[contrib] Mesh Metis[contrib] Mpeg Netgen ONELAB ONELABMetamodel OSMesa OpenACC OpenCASCADE OpenCASCADE-CAF OpenGL OpenMP OptHom Parser Plugins Png Post QuadMeshingTools QuadTri Solver TCMalloc TetGen/BR Voro++[contrib] WinslowUntangler Zlib
```
There are some possibly related lines in the PETSc 3.17.0 changelog (but I have no idea what this might mean in practice):
1. Reuse PETSc-installed hwloc when installing OpenMPI
2. Add PetscCommGetComm() and PetscCommRestoreComm() to allow reuse of MPI communicator with external packages, as some MPI implementations have broken MPI_Comm_free()
More information about PETSc configuration:
```
Compilers:
C Compiler: mpicc -O3 -pipe -fopenmp -march=native -fPIC -fopenmp
Version: gcc (Ubuntu 9.4.0-1ubuntu1~20.04.1) 9.4.0
C++ Compiler: mpicxx -O3 -pipe -fopenmp -march=native -fopenmp -std=gnu++17 -fPIC -fopenmp
Version: g++ (Ubuntu 9.4.0-1ubuntu1~20.04.1) 9.4.0
Fortran Compiler: mpif90 -fPIC -Wall -ffree-line-length-0 -Wno-lto-type-mismatch -Wno-unused-dummy-argument -march=native -O3 -fopenmp -fopenmp
Version: GNU Fortran (Ubuntu 9.4.0-1ubuntu1~20.04.1) 9.4.0
Linkers:
Shared linker: mpicc -fopenmp -fopenmp -shared -O3 -pipe -fopenmp -march=native -fPIC -fopenmp
Dynamic linker: mpicc -fopenmp -fopenmp -shared -O3 -pipe -fopenmp -march=native -fPIC -fopenmp
Libraries linked against: -lrt -lquadmath -lstdc++ -ldl
BlasLapack:
Library: -llapack -lblas
Unknown if this uses OpenMP (try export OMP_NUM_THREADS=<1-4> yourprogram -log_view)
uses 4 byte integers
MPI:
Version: 3
mpiexec: /usr/bin/mpiexec
Implementation: openmpi
OMPI_VERSION: 4.0.3
hwloc:
Version: 2.1.0
Library: -lhwloc
X:
Library: -lX11
openmp:
Version: 201511
pthread:
cmake:
Version: 3.16.3
/usr/bin/cmake
slepc:
Includes: -I/opt/petsc/include
Library: -Wl,-rpath,/opt/petsc/lib -L/opt/petsc/lib -lslepc
PTScotch:
Version: 6.1.2
Includes: -I/opt/petsc/include
Library: -Wl,-rpath,/opt/petsc/lib -L/opt/petsc/lib -lptesmumps -lptscotchparmetis -lptscotch -lptscotcherr -lesmumps -lscotch -lscotcherr
regex:
MUMPS:
Version: 5.4.1
Includes: -I/opt/petsc/include
Library: -Wl,-rpath,/opt/petsc/lib -L/opt/petsc/lib -lcmumps -ldmumps -lsmumps -lzmumps -lmumps_common -lpord
uses OpenMP; use export OMP_NUM_THREADS=<p> or -omp_num_threads <p> to control the number of threads
scalapack:
Library: -Wl,-rpath,/opt/petsc/lib -L/opt/petsc/lib -lscalapack
hpddm:
Version: 2.2.1
Includes: -I/opt/petsc/include
sowing:
Version: 1.1.26
/mnt/500GB/Sources/petsc/petsc-3.17.3/arch-linux-c-opt/bin/bfort
Language used to compile PETSc: C
PETSc:
PETSC_ARCH: arch-linux-c-opt
PETSC_DIR: /mnt/500GB/Sources/petsc/petsc-3.17.3
Prefix: /opt/petsc
Scalar type: real
Precision: double
Support for __float128
Integer size: 4 bytes
Single library: yes
Shared libraries: yes
Memory alignment from malloc(): 16 bytes
Using GNU make: /usr/bin/make
```
An example of a simple test task is in the attached files. But the problem is reproduced on any task.
[.petscrc](/uploads/1cae477e993a24bdb9a0bead959a5255/.petscrc)
[test.geo](/uploads/4fb39dce475a19dc8512e23b1b67473e/test.geo)
[test.pro](/uploads/983188685f2959d39b1c273a09c52f3a/test.pro)https://gitlab.onelab.info/getdp/getdp/-/issues/151Getting/setting solution vector via gmsh/onelab from Python2023-05-05T12:57:18ZErik SchnaubeltGetting/setting solution vector via gmsh/onelab from PythonHi Christophe,
We're trying to set and get the solution vector in GetDP from Python using the Onelab interface via the Gmsh API.
- Setting the solution vector (e.g., an initial solution computed by a previous run of getDP) works fine...Hi Christophe,
We're trying to set and get the solution vector in GetDP from Python using the Onelab interface via the Gmsh API.
- Setting the solution vector (e.g., an initial solution computed by a previous run of getDP) works fine. This makes use of `CopySolution` and an iterable ONELAB parameter.
- Getting the solution vector after GetDP is done computing is not possible. `CopySolution` does not update the ONELAB iterable and `SetNumberRunTime` does not (?) take lists as input.
Attached is a minimum example, where `set_get_solution.py` will run `thermal.pro` on `thermal.msh`. Non-working trys have been commented. The `getdp_path` variable on top might need to be changed.
Thanks a lot for your help!!
Erik
[set_get_solution.py](/uploads/5ab6a5fe49afa487b7a61f756eda5e10/set_get_solution.py)
[thermal.msh](/uploads/86da476b1a6affea370bea700b856b59/thermal.msh)
[thermal.pro](/uploads/11e4be2503872e6247e128408b19039e/thermal.pro)https://gitlab.onelab.info/getdp/getdp/-/issues/145Magnetostatic 3D problem - Issue with Hexahedral mesh2023-01-31T16:11:31ZFrederic TrillaudMagnetostatic 3D problem - Issue with Hexahedral meshDear all,
I am trying different types of mesh to benchmark some code. While the tetrahedral mesh works fine, the hexahedral mesh (with ad without recombination) do not produce the correct result. There is certainly a subtlety that escap...Dear all,
I am trying different types of mesh to benchmark some code. While the tetrahedral mesh works fine, the hexahedral mesh (with ad without recombination) do not produce the correct result. There is certainly a subtlety that escapes me there as I would imagine that the resolution should not be affected, at least that much by the type of mesh.
I am joining the case study. There is knob in the onelab interface to choose between the different meshes. I have selected by default the hexahedral mesh.
[Hexahedron.zip](/uploads/e307aea533bf2f8d93b51206b4e21625/Hexahedron.zip)
Best regards,
Frederichttps://gitlab.onelab.info/getdp/getdp/-/issues/118Hand calc for verification and validation of modal analysis results2023-01-26T16:23:29ZDenHand calc for verification and validation of modal analysis resultsHi, tell me what the problem is.
**Disk modal and harmonic analyses: Steel disk - 75 mm radius and 3 mm radius center hole, and 0.34 mm thickness. Modulus = 200000 MPa, Poisson’s Ratio = 0.3, Density = 7850 kg/m^3.
Support: simply-sup...Hi, tell me what the problem is.
**Disk modal and harmonic analyses: Steel disk - 75 mm radius and 3 mm radius center hole, and 0.34 mm thickness. Modulus = 200000 MPa, Poisson’s Ratio = 0.3, Density = 7850 kg/m^3.
Support: simply-supported, (no translation: UX = UY = UZ = 0) at the edge of the hole.**
![image](/uploads/8c1a0104e799c8b40d3dd0666d18ab4b/image.png)
---------------------
![image](/uploads/6675f2e7165f49f44430d60fc84dc875/image.png)
---------------------
![image](/uploads/cb98eca4db788f46e00e998040e47059/image.png)
1. Calculations do not match.
2. The Freq_Target-parameter (frequency target for modal simulations) does not affect the calculations.https://gitlab.onelab.info/getdp/getdp/-/issues/122Error with new template Lib_Elasticity_u.pro2023-01-26T16:21:26ZDenError with new template Lib_Elasticity_u.proTest benchmark "Natural frequencies of a square plate with a clamped side"
![image](/uploads/f7e71880df7d38fa24590c8c0f1f96d1/image.png)
**With "Old" template**
![image](/uploads/bf643cd627bd86cf64e98c9556b8037d/image.png)
![image](/up...Test benchmark "Natural frequencies of a square plate with a clamped side"
![image](/uploads/f7e71880df7d38fa24590c8c0f1f96d1/image.png)
**With "Old" template**
![image](/uploads/bf643cd627bd86cf64e98c9556b8037d/image.png)
![image](/uploads/be15d9e9574de8ecb8b250ba6934e0f2/image.png)
![image](/uploads/00367b0e8a99a9eecb133d288171da1e/image.png)
The error came after changing "support 2nd order Lagrange elements" https://gitlab.onelab.info/getdp/getdp/-/commit/acaefd41dffe77932badf811d652eedb04f5c073https://gitlab.onelab.info/getdp/getdp/-/issues/147A point charge q near a grounded conducting sphere2023-01-26T16:17:55ZDenA point charge q near a grounded conducting sphereHello, please tell me where is the error...
Best regards
The model consists of:
- a 1 m radius sphere set at zero volts, located at x=y=z=0
- a 0.001 m radius sphere with a total charge of 1 microCoulomb located at x=z=0,y=1.5m
...Hello, please tell me where is the error...
Best regards
The model consists of:
- a 1 m radius sphere set at zero volts, located at x=y=z=0
- a 0.001 m radius sphere with a total charge of 1 microCoulomb located at x=z=0,y=1.5m
![image](/uploads/2907c48af944ec28de6ccbfe123176e5/image.png)
**COULOMB6.0**
![image](/uploads/5d51f542283ead8cf7e77444a1b567ee/image.png)
![image](/uploads/e9ca0f877dff9fe37c083ec9e59c5ff5/image.png)
**3D Model**
![image](/uploads/02987c4cab9e478651a236381a3aa239/image.png)
**Axisymmetric Model**
![image](/uploads/5f9aa6fd74254b1365320e69d3d59c04/image.png)
**FEMM & Agros2D**
![image](/uploads/84a30a033c236ee048b414431f0dcbde/image.png)https://gitlab.onelab.info/getdp/getdp/-/issues/141Error compilation GetDP with MPI and SLEPC2022-11-27T11:50:31ZFrederic TrillaudError compilation GetDP with MPI and SLEPCThere is an issue on debian-based OS during the compilation of GetDP with MPI support.
```
curl -L -O http://ftp.mcs.anl.gov/pub/petsc/release-snapshots/petsc-3.16.0.tar.gz
tar zxvf petsc-3.16.0.tar.gz
cd petsc-3.16.0
export PETSC_DIR=$...There is an issue on debian-based OS during the compilation of GetDP with MPI support.
```
curl -L -O http://ftp.mcs.anl.gov/pub/petsc/release-snapshots/petsc-3.16.0.tar.gz
tar zxvf petsc-3.16.0.tar.gz
cd petsc-3.16.0
export PETSC_DIR=$PWD
export PETSC_ARCH=complex_mumps_mpi
./configure --with-debugging=0 --with-clanguage=cxx --with-shared-libraries=0 --with-x=0 --download-mumps=1 --download-metis=1 --download-parmetis=1 --download-scalapack=1 --download-blacs=1 --with-scalar-type=complex
# Notes:
# * if the BLAS/LAPACK libraries are not installed in standard locations, you will have to specify their location by hand with options --with-blas-lib=/path/to/libblas and --with-lapack-lib=/path/to/liblapack
make
cd ../..
```
The third line should be replaced by: "export PETSC_ARCH=arch-linux-cxx-opt" instead of "export PETSC_ARCH=complex_mumps_mpi"
Hence the slepc library can be compiled agaisnt PETSC following the remaining instruction.
Best,
Frederichttps://gitlab.onelab.info/getdp/getdp/-/issues/105Question about current density in solid conductor2022-11-23T13:24:34ZJan WiegardQuestion about current density in solid conductorHi,
I am new to GetDP and want to simulate an inductor. So far, I am just able to simulate stranded windings with homogeny current density in the frequency domain (your inductor.pro example was very helpful). Now I planned to measure th...Hi,
I am new to GetDP and want to simulate an inductor. So far, I am just able to simulate stranded windings with homogeny current density in the frequency domain (your inductor.pro example was very helpful). Now I planned to measure the skin and proximity effect.
I started with the definition of a current density in a solid conductor but get stuck…
Does someone of you have a small solver for a solid conductor with implemented current density I can begin with? Or maybe a link to some code?https://gitlab.onelab.info/getdp/getdp/-/issues/143Compilation of source code in Cygwin (Windows 10)2022-09-26T14:26:59ZElia ScolaroCompilation of source code in Cygwin (Windows 10)Hi,
I am trying to compile GetDP source code (version 3.5.0) in Cygwin (version 3.3.6-1 on a Windows 10 system) with PETSc (with serial MUMPS), SLEPc, Python 3.9 (in Cygwin) and a minimal Gmsh library (without GUI and other features). I ...Hi,
I am trying to compile GetDP source code (version 3.5.0) in Cygwin (version 3.3.6-1 on a Windows 10 system) with PETSc (with serial MUMPS), SLEPc, Python 3.9 (in Cygwin) and a minimal Gmsh library (without GUI and other features). I don't want MPI for the moment. The shell script that I am using is attached here [myconf_getdp_cygwin.sh](/uploads/79d45ec1228bfaceb19877fb1c2846ed/myconf_getdp_cygwin.sh).
All the needed libraries (PETSc with serial MUMPS, SLEPC and Gmsh) have been successfully compiled within Cygwin using Cygwin 64-bit GNU compilers, namely gcc.exe, g++.exe and gfortran.exe, with their toolchain x86_64-pc-cygwin.
So, as first attempt, I tried to compile also GetDP with the same compilers. The CMake configuration was good, but then I got the following error at the very last stage of the building procedure (`make`), while linking the executable getdp.exe (linking to what? which libraries? ...):
```
[100%] Linking CXX executable getdp.exe
g++: error: unrecognized command-line option ‘-municode’
make[2]: *** [CMakeFiles/getdp.dir/build.make:2013: getdp.exe] Error 1
make[1]: *** [CMakeFiles/Makefile2:222: CMakeFiles/getdp.dir/all] Error 2
make: *** [Makefile:166: all] Error 2
```
I found that a guy had the same issue (trying to compile another software) [here (stackoverflow)](https://stackoverflow.com/questions/56524776/gcc-error-unrecognized-command-line-option-municode-in-cygwin-windows-on-ru), but I don't understand how he fixed it. I have asked there and I am waiting for an answer.
Searching in the net, I discovered that the problem is that the toolchain of the compilers (in this case x86_64-pc-cygwin) does not implement the UNICODE feature [(sourgeforce-mingw-w64)](https://sourceforge.net/p/mingw-w64/wiki2/Unicode%20apps/). So, I decided to try with the MINGW-w64 compilers available within Cygwin. In this case, the building process stops at the beginning due to many conflicting declaration errors and included files not found. This issue is related to the compilation of Python.h within Cygwin, thus I disabled the PYTHON option for GetDP in cmake (even if I want it!). Howevere, the building process gives errors again during the very last stage (linking executable getdp.exe). This time the error messagge is different (skipping incompatible files???):
```
[100%] Linking CXX executable getdp.exe
/usr/lib/gcc/x86_64-w64-mingw32/11/../../../../x86_64-w64-mingw32/bin/ld: cannot find -llapack: No such file or directory
/usr/lib/gcc/x86_64-w64-mingw32/11/../../../../x86_64-w64-mingw32/bin/ld: cannot find -lblas: No such file or directory
/usr/lib/gcc/x86_64-w64-mingw32/11/../../../../x86_64-w64-mingw32/bin/ld: cannot find -ldl: No such file or directory
/usr/lib/gcc/x86_64-w64-mingw32/11/../../../../x86_64-w64-mingw32/bin/ld: skipping incompatible /usr/i686-w64-mingw32/sys-root/mingw/lib/libm.a when searching for -lm
/usr/lib/gcc/x86_64-w64-mingw32/11/../../../../x86_64-w64-mingw32/bin/ld: skipping incompatible /usr/i686-w64-mingw32/sys-root/mingw/lib/libadvapi32.a when searching for -ladvapi32
/usr/lib/gcc/x86_64-w64-mingw32/11/../../../../x86_64-w64-mingw32/bin/ld: skipping incompatible /usr/i686-w64-mingw32/sys-root/mingw/lib/libshell32.a when searching for -lshell32
```
...many similar ...
```
/usr/lib/gcc/x86_64-w64-mingw32/11/../../../../x86_64-w64-mingw32/bin/ld: skipping incompatible /usr/i686-w64-mingw32/sys-root/mingw/lib/libkernel32.a when searching for -lkernel32
collect2: error: ld returned 1 exit status
make[2]: *** [CMakeFiles/getdp.dir/build.make:2007: getdp.exe] Error 1
make[1]: *** [CMakeFiles/Makefile2:222: CMakeFiles/getdp.dir/all] Error 2
make: *** [Makefile:166: all] Error 2
```
I would like to compile with the Cygwin 64-bit GNU compilers, as I used them also to build all the needed libraries ad they don't complain about Python.h, but I don't know how to enable the -municode command in their toolchain. I don't even know if it is possible. Are there any ways to fix this problem?
Alternatively, how can I manage the building process with the MINGW-w64 compilers within Cygwin, also enabling python in cmake configuration?
I am quite sure that this is a compiler-related issue, but I decided to post it anyway, with the hope that someone can help me.