Segmentation fault while using a 3d model in mgdyn

Numerical methods and mathematical models of Elmer
Post Reply
mpactor
Posts: 1
Joined: 25 Jul 2019, 21:06
Antispam: Yes

Segmentation fault while using a 3d model in mgdyn

Post by mpactor » 25 Jul 2019, 21:23

I am new to Elmer and I am trying a 3d equivalent of a horseshoe magnet example (which worked fine) in Elmer. The 3d model has two magnets (cuboids) attached to an iron bar. All models are surrounded by air (large sphere with vanishing field as the boundary condition on the outer surface). I have the meshes made in salome 9.3. Everything imports well. When I run the solver, after the first iteration I see a segmentation error. The output I see is

Code: Select all

ELMER SOLVER (v 8.3) STARTED AT: 2019/07/25 13:49:07
ParCommInit:  Initialize #PEs:            1
MAIN: 
MAIN: =============================================================
MAIN: ElmerSolver finite element software, Welcome!
MAIN: This program is free software licensed under (L)GPL
MAIN: Copyright 1st April 1995 - , CSC - IT Center for Science Ltd.
MAIN: Webpage http://www.csc.fi/elmer, Email elmeradm@csc.fi
MAIN: Version: 8.3 (Rev: 432ee0dd, Compiled: 2018-12-18)
MAIN:  Running one task without MPI parallelization.
MAIN:  Running with just one thread per task.
MAIN:  Lua interpreted linked in.
MAIN: =============================================================
MAIN: 
MAIN: 
MAIN: -------------------------------------
MAIN: Reading Model: case.sif
LoadInputFile: Scanning input file: case.sif

LoadInputFile: Loading input file: case.sif
WARNING:: LoadInputFile: > Equation 2 < not used in any Body!
WARNING:: LoadInputFile: > Equation 3 < not used in any Body!
Loading user function library: [ResultOutputSolve]...[ResultOutputSolver_Init0]
Loading user function library: [MagnetoDynamics]...[MagnetoDynamicsCalcFields_Init0]
Loading user function library: [MagnetoDynamics]...[WhitneyAVSolver_Init0]
LoadMesh: Base mesh name: ./.

LoadMesh: Elapsed REAL time:     0.2150 (s)

MAIN: -------------------------------------
AddVtuOutputSolverHack: Adding ResultOutputSolver to write VTU output in file: case
Loading user function library: [ResultOutputSolve]...[ResultOutputSolver_Init]
Loading user function library: [ResultOutputSolve]...[ResultOutputSolver_bulk]
Loading user function library: [ResultOutputSolve]...[ResultOutputSolver]
Loading user function library: [MagnetoDynamics]...[MagnetoDynamicsCalcFields_Init]
Loading user function library: [MagnetoDynamics]...[MagnetoDynamicsCalcFields_bulk]
Loading user function library: [MagnetoDynamics]...[MagnetoDynamicsCalcFields]
Loading user function library: [MagnetoDynamics]...[WhitneyAVSolver_Init]
Loading user function library: [MagnetoDynamics]...[WhitneyAVSolver_bulk]
Loading user function library: [MagnetoDynamics]...[WhitneyAVSolver]
OptimizeBandwidth: ---------------------------------------------------------
OptimizeBandwidth: Computing matrix structure for: mgdyn...done.
OptimizeBandwidth: Half bandwidth without optimization: 26043
OptimizeBandwidth: 

OptimizeBandwidth: Bandwidth Optimization ...done.
OptimizeBandwidth: Half bandwidth after optimization: 1126
OptimizeBandwidth: ---------------------------------------------------------
Loading user function library: [ResultOutputSolve]...[ResultOutputSolver_Init]
Loading user function library: [ResultOutputSolve]...[ResultOutputSolver_bulk]
Loading user function library: [ResultOutputSolve]...[ResultOutputSolver]
MAIN: 
MAIN: -------------------------------------
MAIN:  Steady state iteration:            1
MAIN: -------------------------------------
MAIN: 
SingleSolver: Attempting to call solver
SingleSolver: Solver Equation string is: mgdynpost
Loading user function library: [MagnetoDynamics]...[MagnetoDynamicsCalcFields_post]
ComputeChange: SS (ITER=1) (NRM,RELC): (  0.0000000      0.0000000     ) :: mgdynpost
SingleSolver: Attempting to call solver
SingleSolver: Solver Equation string is: mgdyn
WhitneyAVSolver: Solving the AV equations with edge elements

MGDynAssembly: Elapsed REAL time:     0.4650 (s)
DefUtils::DefaultDirichletBCs: Setting Dirichlet boundary conditions
DefUtils::DefaultDirichletBCs: Dirichlet boundary conditions set
WhitneyAVSolver::  Boundary tree edges: 70 of total: 207
CRS_IncompleteLU: ILU(0) (Real), Starting Factorization:

CRS_IncompleteLU: ILU(0) (Real), NOF nonzeros:    426076
CRS_IncompleteLU: ILU(0) (Real), filling (%) :       100
CRS_IncompleteLU: ILU(0) (Real), Factorization ready at (s):     0.01
      10 0.4631E-04
      20 0.3323E-07

      30 0.8492E-09
      40 0.3096E-10
      40 0.3096E-10
ComputeChange: NS (ITER=1) (NRM,RELC): (  7106.8997      2.0000000     ) :: mgdyn

MGDynAssembly: Elapsed REAL time:     0.4650 (s)
DefUtils::DefaultDirichletBCs: Setting Dirichlet boundary conditions
DefUtils::DefaultDirichletBCs: Dirichlet boundary conditions set
WhitneyAVSolver::  Boundary tree edges: 70 of total: 207


Program received signal SIGSEGV: Segmentation fault - invalid memory reference.

Backtrace for this error:
#0  ffffffffffffffff
I have attached my case file. .unv file is large to include here. Can anyone suggest what could be going wrong?
Attachments
case.sif
(3.42 KiB) Downloaded 16 times

szewro
Posts: 28
Joined: 01 Feb 2014, 18:57
Antispam: Yes
Location: Warsaw, Poland

Re: Segmentation fault while using a 3d model in mgdyn

Post by szewro » 26 Jul 2019, 11:39

Hi!

The easiest way is to take the most similar test case (from tests subdirectory) and substitute step-by-step to your mesh.

It is difficult to say something on the base of .sif file only

With best regards,

Roman

Post Reply