Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Broken examples #2222

Closed
ZedThree opened this issue Feb 9, 2021 · 9 comments
Closed

Broken examples #2222

ZedThree opened this issue Feb 9, 2021 · 9 comments

Comments

@ZedThree
Copy link
Member

ZedThree commented Feb 9, 2021

I'm now been through all the examples, checking whether or not they can be run for a single timestep. Failures fall into three camps:

The following examples all use the d3d_119919.nc grid file which is missing ShiftAngle, and so fails because they need twistshift = True:

  • constraints/alfven-wave
  • jorek-compare
  • laplacexy/alfevn-wave

These examples all have various staggered grid issues:

  • 6field
  • dalf3
  • gas-compress
  • gyro-gem
  • reconnect-2fields
  • shear-alfven-wave
  • tokamak-2fluid

The following all have other fun issues after fixing the obvious ones:

  • 6field:
    • nl_filter fails an assertion that f.getDirectionY() == YDirectionType::Aligned in shiftedmetric
  • elm-pb:
    • after passing the correct sections to Laplacian::create, get Zero pivot in CyclicReduce::reduce
  • gas-compress:
    • MXG = 0 is not enough boundary points for the x-derivative. I suspect this should be 2 as nx = 5, but then there aren't enough interior points to calculate the boundary.
  • gravity-reduced:
    • 3D variable 'Vpar0' has incorrect size 15 (expecting 33)
  • gyro-gem:
    • NaNs in Grad_parP
  • IMEX/drift-wave-constraint runs but errors with "Too many failed steps" (and requires solver:type=imexbdf2)
  • preconditioning/wave
    • NaNs in something
@EdmundBenedict
Copy link

I just wanted to check, is the tokamak_2fluid example fixed now? It doesn't throw the "staggered grid" error for me, but I find that it runs for a number of iterations before it ceases to converge. This seems to be preceded by a number of steps with only a few RHS evaluations and very short walltimes:

Sim Time  |  RHS evals  | Wall Time |  Calc    Inv   Comm    I/O   SOLVER

0.000e+00          2       2.80e-02    45.4   10.6    4.3  101.8  -62.1
1.000e+01      144160       1.21e+03    74.9   10.2    4.0    0.0   10.9
2.000e+01      63543       5.36e+02    75.1   10.2    3.9    0.0   10.8
3.000e+01      71836       6.44e+02    73.5   10.0    4.8    0.0   11.8
4.000e+01      80228       6.79e+02    74.6   10.2    4.1    0.0   11.1
5.000e+01      15722       1.78e+02    63.2    8.8    9.8    0.0   18.2
6.000e+01         45       5.34e-01    58.9    8.3    7.2    5.4   20.2
7.000e+01         12       1.86e-01    56.9    8.3    1.6   19.0   14.2
8.000e+01         12       1.72e-01    44.1    6.2    8.6   18.0   23.1
9.000e+01          1       6.35e-02     8.9    1.2    2.9   37.8   49.2
1.000e+02          1       6.35e-02     9.0    1.2    2.8   37.8   49.2
1.100e+02         45       5.41e-01    48.8    6.6   13.3    4.5   26.8
1.200e+02         12       1.91e-01    36.6    5.0   11.9   12.5   34.0
1.300e+02         67       7.33e-01    61.6    8.5    7.3    4.3   18.3
1.400e+02         12       1.61e-01    54.4    7.7    1.9   19.6   16.4
1.500e+02         12       1.56e-01    44.4    6.0    8.2   17.7   23.7
1.600e+02          1       4.86e-02    11.9    1.6    3.0   52.4   31.1
1.700e+02         12       1.83e-01    54.0    7.8    1.3   21.8   15.1
1.800e+02          1       6.37e-02    14.3    2.1    0.3   56.7   26.6
1.900e+02          1       6.34e-02    14.3    2.1    0.3   56.8   26.5
2.000e+02          1       6.34e-02    14.4    2.1    0.3   56.8   26.5
2.100e+02          1       6.48e-02    14.1    2.1    0.3   57.7   25.9
2.200e+02         12       1.75e-01    50.7    7.2    2.7   21.6   17.7
2.300e+02          1       5.84e-02    10.4    1.3    2.5   56.5   29.2
2.400e+02          1       6.18e-02    12.4    2.3    0.3   57.4   27.6
2.500e+02          1       4.77e-02    12.0    1.7    2.5   52.5   31.3
2.600e+02          1       7.12e-02     8.0    1.1    2.5   34.3   54.1
2.700e+02          1       5.19e-02    11.1    1.5    0.4   46.8   40.2
2.800e+02          1       5.36e-02    10.7    1.4    2.9   57.1   27.9
|  Step 28 of 200. Elapsed 0:54:10.8 ETA 0:00:09.2CVode-- At t=289.264 and step size h=0.000297267, the corrector
convergence failed repeatedly or with |h| = hmin.

CVode-- At t=289.264 and step size h=0.000297267, the corrector
convergence failed repeatedly or with |h| = hmin.

CVode-- At t=289.264 and step size h=0.000297267, the corrector
convergence failed repeatedly or with |h| = hmin.

CVode-- At t=289.264 and step size h=0.000297267, the corrector
convergence failed repeatedly or with |h| = hmin.

ERROR CVODE step failed, flag = -6
Timestep failed. Aborting
Error encountered in solver run
PVODE timestep failed
Error encountered
----------------------

The compile time options for this calculation were:

Compile-time options:
    Checking enabled, level 2
    Signal handling enabled
    netCDF4 support enabled
    Parallel NetCDF support disabled
    OpenMP parallelisation disabled
    Compiled with flags : "-DMD5SUM=5092520b5cad0e2f42bd13d7d3efc0fa -DREVISION=Unknown -g -DHAS_PRETTY_FUNCTION -Wall -Wextra -Wnull-dereference -Wno-cast-function-type -O2 -DCHECK=2 -DSIGHANDLE -DLOGCOLOR -DBOUT_VERSION_STRING=\"4.4.0\" -DBOUT_VERSION_DOUBLE=4.40 -DBACKTRACE -DBOUT_HAS_FFTW -DNCDF4 -DHDF5 -DLAPACK -DBOUT_HAS_PVODE -DBOUT_HAS_GETTEXT -DBOUT_LOCALE_PATH=/usr/local/share/locale"
    Command line options for this run : 2fluid
Reading options file data/BOUT.inp
Writing options to file data/BOUT.settings
    Option grid = data/uedge.grd.nc (data/BOUT.inp)

And it was run with 4 processors, although when run with 2 processors, it is around the 18th iteration rather than the 9th that the solver starts acting strangely:


Sim Time  |  RHS evals  | Wall Time |  Calc    Inv   Comm    I/O   SOLVER

0.000e+00          2       2.17e-02    56.1   15.1   10.0   80.3  -61.6
1.000e+01      138666       1.25e+03    75.8   12.9    1.7    0.0    9.6
2.000e+01      67143       6.10e+02    75.6   12.9    1.9    0.0    9.7
3.000e+01        133       1.21e+00    73.7   12.6    1.8    1.6   10.2
4.000e+01      83150       7.56e+02    75.9   12.9    1.7    0.0    9.5
5.000e+01      60696       6.25e+02    75.4   12.8    2.1    0.0    9.7
6.000e+01      39350       5.11e+02    74.4   12.5    2.9    0.0   10.1
7.000e+01      98643       1.15e+03    75.5   12.7    2.1    0.0    9.6
8.000e+01      60305       6.89e+02    76.2   12.9    1.7    0.0    9.2
9.000e+01      128452       1.93e+03    75.3   12.5    2.8    0.0    9.4
1.000e+02      108863       1.93e+03    74.7   12.3    3.4    0.0    9.6
1.100e+02      106411       1.87e+03    74.7   12.3    3.4    0.0    9.6
1.200e+02      48546       8.58e+02    74.7   12.4    3.4    0.0    9.5
1.300e+02      60096       8.74e+02    74.9   12.4    3.2    0.0    9.6
1.400e+02         34       5.21e-01    67.5   11.8    2.8    5.2   12.8
1.500e+02         34       5.70e-01    65.7   13.6    4.2    5.0   11.5
1.600e+02         23       3.70e-01    64.6   10.1    5.9    7.4   12.1
1.700e+02         12       1.81e-01    62.0   10.2    1.0   13.9   12.9
1.800e+02          1       4.82e-02    19.6    3.2    0.3   51.8   25.0
1.900e+02         12       2.15e-01    59.4    8.6    1.5   11.7   18.8
2.000e+02          1       4.87e-02    19.5    3.4    0.3   52.1   24.7
2.100e+02         12       2.33e-01    52.2    8.0   13.3   11.0   15.6
2.200e+02          1       4.92e-02    19.2    3.1    0.3   51.6   25.8
2.300e+02          1       5.10e-02    18.6    3.2    0.6   50.3   27.4
2.400e+02          1       5.62e-02    16.8    2.9    0.2   52.2   27.8
2.500e+02         12       2.00e-01    57.0    9.3    1.1   12.8   19.8
2.600e+02          1       5.50e-02    17.2    3.0    0.3   57.7   21.9
2.700e+02          1       5.44e-02    17.4    3.1    0.2   47.0   32.4
2.800e+02          1       4.91e-02    19.2    3.3    0.3   52.3   24.8
2.900e+02          1       5.97e-02    16.0    2.6   14.9   42.8   23.7
3.000e+02          1       4.93e-02    19.1    3.3    1.3   51.9   24.4
3.100e+02          1       4.96e-02    19.1    3.3    1.5   51.8   24.3
\  Step 31 of 200. Elapsed 3:37:35.1 ETA 0:00:08.4CVode-- At t=319.973 and step size h=0.000481297, the corrector

If I run it with OpenMPI enabled, it fails even earlier:


Sim Time  |  RHS evals  | Wall Time |  Calc    Inv   Comm    I/O   SOLVER

0.000e+00          1       3.32e-01   -30.3   17.0   92.5   12.3    8.6
1.000e+01      259135       9.24e+03    57.2    6.5   11.9    0.0   24.4
2.000e+01         13       1.62e-01    59.1    8.3    1.1   12.1   19.4
3.000e+01          7       1.00e-01    51.6    7.2    1.0   19.4   20.8
4.000e+01          7       1.00e-01    51.4    7.3    1.0   19.4   20.9
5.000e+01          1       3.88e-02    19.2    2.9    0.3   50.4   27.2
6.000e+01          1       3.95e-02    19.1    2.6    0.4   50.0   27.9
-  Step 6 of 200. Elapsed 2:33:56.4 ETA 0:00:07.7
[CVODE ERROR]  CVode
  At t = 69.0894 and h = 0.00023859, the corrector convergence test failed repeatedly or with |h| = hmin.
Error encountered in solver run
ERROR CVODE solve failed at t = 6.908941e+01, flag = -4
Error encountered
====== Exception path ======
[bt] #6 2fluid(+0x722ee) [0x556465d652ee]
_start at ??:?
[bt] #5 /lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0xf3) [0x7f54a50bb0b3]
__libc_start_main at /build/glibc-eX1tMB/glibc-2.31/csu/../csu/libc-start.c:342
[bt] #4 2fluid(+0x6ba9e) [0x556465d5ea9e]
std::default_delete<BoutMonitor>::operator()(BoutMonitor*) const at /usr/include/c++/9/bits/unique_ptr.h:81
 (inlined by) std::unique_ptr<BoutMonitor, std::default_delete<BoutMonitor> >::~unique_ptr() at /usr/include/c++/9/bits/unique_ptr.h:292
 (inlined by) main at /home/edders/programs/BOUT-dev/examples/tokamak-2fluid/2fluid.cxx:919
[bt] #3 2fluid(+0x16b52d) [0x556465e5e52d]
Solver::solve(int, double) at /home/edders/programs/BOUT-dev/src/solver/solver.cxx:508
[bt] #2 2fluid(+0x2909c9) [0x556465f839c9]
CvodeSolver::run() at /home/edders/programs/BOUT-dev/src/solver/impls/cvode/cvode.cxx:471
[bt] #1 2fluid(+0x59550) [0x556465d4c550]
CvodeSolver::run(double) at /home/edders/programs/BOUT-dev/src/solver/impls/cvode/cvode.cxx:580 (discriminator 2)
====== Back trace ======
 -> Ncxx4::close on line 266 of 'ncxx4.cxx'
 -> Running solver: solver::run(7.000000e+01) on line 540 of 'cvode.cxx'
 -> CvodeSolver::run() on line 459 of 'cvode.cxx'

====== Exception thrown ======
ERROR CVODE solve failed at t = 6.908941e+01, flag = -4

And with one processor it runs to the last iteration, but a lot of the iterations only have single RHS evaluations:

Sim Time  |  RHS evals  | Wall Time |  Calc    Inv   Comm    I/O   SOLVER

0.000e+00          2       2.96e-02    97.7   20.9    2.0   67.6  -88.2
1.000e+01      83273       1.90e+03    75.9   14.7    0.5    0.0    8.9
2.000e+01        155       2.06e+00    73.2   14.2    0.5    1.0   11.2
3.000e+01         23       3.09e-01    69.8   13.6    0.4    5.0   11.2
4.000e+01        287       3.70e+00    74.8   14.6    0.5    0.4    9.8
5.000e+01         34       4.62e-01    71.2   13.9    0.4    3.5   11.0
6.000e+01         89       1.13e+00    73.7   14.4    0.5    1.4   10.2
7.000e+01      109421       1.52e+03    75.3   14.7    0.5    0.0    9.6
8.000e+01      81919       1.16e+03    75.3   14.7    0.5    0.0    9.6
9.000e+01      44901       5.68e+02    75.2   14.7    0.5    0.0    9.7
1.000e+02         34       4.49e-01    71.3   13.9    0.4    3.4   10.9
1.100e+02      122207       1.98e+03    75.5   14.7    0.5    0.0    9.3
1.200e+02      110336       1.57e+03    75.3   14.7    0.5    0.0    9.6
1.300e+02      77903       1.34e+03    75.7   14.7    0.5    0.0    9.1
1.400e+02      45413       6.97e+02    75.3   14.6    0.5    0.0    9.5
1.500e+02      78806       1.30e+03    75.4   14.6    0.5    0.0    9.5
1.600e+02         34       6.44e-01    69.1   13.6    0.4    5.2   11.7
1.700e+02      75034       1.34e+03    75.6   14.7    0.5    0.0    9.2
1.800e+02      10045       1.53e+02    75.3   14.6    0.5    0.0    9.6
1.900e+02         78       1.20e+00    73.6   14.3    0.5    1.6   10.1
2.000e+02         34       5.66e-01    71.5   14.0    0.5    3.6   10.5
2.100e+02         23       4.26e-01    70.0   13.5    0.4    5.1   10.9
2.200e+02          1       4.72e-02    27.5    5.3    0.2   45.3   21.7
2.300e+02          1       4.78e-02    27.8    6.0    0.2   44.4   21.6
2.400e+02         34       5.72e-01    71.6   13.9    0.5    3.6   10.4
2.500e+02          1       4.15e-02    27.4    5.3    0.2   45.1   22.1
2.600e+02         12       2.08e-01    65.6   12.7    0.4    9.1   12.2
2.700e+02          1       4.21e-02    27.0    5.2    0.2   45.9   21.7
2.800e+02         12       2.08e-01    65.4   12.7    0.4    9.1   12.3
2.900e+02          1       4.18e-02    27.1    5.2    0.2   44.7   22.8
3.000e+02          1       4.20e-02    26.9    5.2    0.2   45.6   22.2
3.100e+02          1       4.18e-02    27.2    5.2    0.2   45.2   22.2
3.200e+02          1       4.18e-02    27.2    5.3    0.2   45.2   22.2
3.300e+02          1       4.24e-02    26.7    5.2    0.2   45.0   22.9
3.400e+02          1       4.23e-02    27.6    5.2    0.2   45.5   21.6
3.500e+02          1       4.24e-02    28.0    5.2    0.2   45.2   21.5
3.600e+02          1       4.23e-02    27.0    5.2    0.2   46.2   21.4
3.700e+02         56       8.70e-01    73.1   14.1    0.5    2.2   10.1
3.800e+02         12       2.09e-01    65.5   12.7    0.5    9.2   12.2
3.900e+02         12       2.08e-01    65.5   12.7    0.4    9.1   12.2
4.000e+02          1       4.34e-02    27.5    5.2    0.2   45.3   21.9
4.100e+02          1       4.34e-02    26.8    5.1    0.2   45.5   22.4
4.200e+02         12       2.09e-01    65.4   12.7    0.5    9.3   12.2
4.300e+02          1       4.23e-02    28.1    5.2    0.2   45.0   21.5
4.400e+02          1       4.24e-02    26.8    5.2    0.2   46.1   21.8
4.500e+02          1       4.29e-02    26.9    5.1    0.2   45.7   22.1
4.600e+02          1       4.41e-02    26.1    5.0    0.2   46.4   22.3
4.700e+02         12       2.24e-01    65.7   12.6    0.5    8.9   12.3
4.800e+02          1       4.76e-02    27.2    5.3    0.2   45.6   21.7
4.900e+02          1       4.75e-02    27.3    5.3    0.2   45.5   21.8
5.000e+02          1       4.69e-02    27.6    5.4    0.2   45.1   21.7
5.100e+02          1       4.68e-02    27.5    5.4    0.2   44.9   22.0
5.200e+02          1       4.71e-02    27.5    5.4    0.2   45.3   21.7
5.300e+02          1       4.74e-02    27.5    5.3    0.2   45.4   21.7
5.400e+02          1       4.74e-02    27.5    5.3    0.2   45.6   21.5
5.500e+02          1       4.80e-02    27.2    5.2    0.2   45.8   21.6
5.600e+02         12       2.41e-01    65.8   12.7    0.5    8.9   12.1
5.700e+02          1       4.95e-02    28.4    5.1    0.2   44.6   21.6
5.800e+02          1       4.85e-02    27.9    5.3    0.2   45.2   21.4
5.900e+02          1       4.83e-02    28.2    5.2    0.2   45.1   21.4
6.000e+02          1       4.80e-02    27.8    5.3    0.2   44.9   21.9
6.100e+02          1       4.83e-02    26.9    5.3    0.2   45.1   22.6
6.200e+02          1       4.44e-02    25.6    5.0    0.2   47.1   22.2
6.300e+02          1       4.19e-02    27.1    5.3    0.2   45.5   21.8
6.400e+02          1       4.21e-02    27.0    5.3    0.2   45.5   22.0
6.500e+02          1       4.20e-02    27.1    5.3    0.2   45.5   21.9
6.600e+02          1       4.21e-02    27.1    5.2    0.2   45.6   21.9
6.700e+02          1       4.19e-02    27.1    5.3    0.2   45.5   21.9
6.800e+02          1       4.21e-02    27.0    5.3    0.2   45.4   22.1
6.900e+02          1       4.24e-02    26.6    5.3    0.2   45.8   22.1
7.000e+02          1       4.21e-02    27.2    5.2    0.2   45.4   22.1
7.100e+02          1       4.21e-02    27.0    5.2    0.2   44.9   22.7
7.200e+02         12       2.08e-01    65.6   12.7    0.4    9.2   12.2
7.300e+02          1       4.22e-02    27.2    5.4    0.2   45.3   21.9
7.400e+02          1       4.24e-02    26.9    5.2    0.2   45.6   22.1
7.500e+02          1       4.29e-02    26.5    5.1    0.2   46.7   21.5
7.600e+02          1       4.30e-02    26.8    5.1    0.2   46.8   21.2
7.700e+02          1       4.50e-02    26.5    7.3    0.2   45.0   21.1
7.800e+02          1       4.53e-02    25.2    5.6    0.2   47.8   21.2
7.900e+02          1       4.52e-02    25.4    6.4    0.2   47.4   20.7
8.000e+02          1       4.49e-02    31.5    5.1    0.2   42.4   20.9
8.100e+02          1       4.50e-02    25.9    7.3    0.2   46.1   20.5
8.200e+02          1       4.50e-02    25.4    5.5    0.2   48.0   21.0
8.300e+02          1       4.47e-02    25.7    7.0    0.2   46.5   20.6
8.400e+02          1       4.48e-02    25.4    6.1    0.2   47.8   20.6
8.500e+02          1       4.50e-02    25.7    7.3    0.2   46.3   20.5
8.600e+02          1       4.47e-02    25.6    5.8    0.2   47.7   20.7
8.700e+02          1       4.44e-02    25.6    7.0    0.2   46.6   20.6
8.800e+02          1       4.48e-02    25.4    5.6    0.2   48.3   20.5
8.900e+02          1       4.46e-02    25.6    7.0    0.2   46.5   20.7
9.000e+02          1       4.47e-02    25.3    6.1    0.2   47.8   20.6
9.100e+02          1       4.48e-02    25.9    7.3    0.2   46.0   20.6
9.200e+02          1       4.51e-02    25.4    5.4    0.2   48.5   20.5
9.300e+02          1       4.49e-02    25.5    7.1    0.2   46.3   20.9
9.400e+02          1       4.47e-02    25.4    6.0    0.2   47.9   20.6
9.500e+02          1       4.51e-02    25.8    7.3    0.2   46.4   20.4
9.600e+02          1       4.58e-02    24.9    5.2    0.2   49.1   20.6
9.700e+02         12       2.12e-01    64.5   13.1    0.4    9.9   12.1
9.800e+02          1       4.48e-02    25.5    5.7    0.2   48.0   20.6
9.900e+02          1       4.50e-02    25.4    6.5    0.2   47.5   20.4
1.000e+03          1       4.69e-02    25.7    5.7    0.2   47.7   20.7
1.010e+03          1       5.08e-02    25.5    4.9    0.2   48.9   20.5
1.020e+03          1       5.13e-02    25.2    4.9    0.2   49.4   20.4
1.030e+03          1       5.15e-02    25.1    4.9    0.2   49.2   20.6
1.040e+03          1       5.13e-02    25.2    4.9    0.2   49.3   20.4
1.050e+03          1       5.16e-02    25.0    4.9    0.2   49.8   20.1
1.060e+03          1       5.15e-02    25.3    4.9    0.2   49.2   20.4
1.070e+03          1       5.16e-02    25.1    4.9    0.2   49.5   20.3
1.080e+03          1       5.10e-02    25.4    4.9    0.2   49.2   20.4
1.090e+03          1       4.82e-02    26.9    5.3    0.2   45.8   21.8
1.100e+03          1       4.81e-02    27.1    5.2    0.2   45.8   21.7
1.110e+03          1       4.84e-02    27.0    5.2    0.2   45.8   21.8
1.120e+03          1       4.84e-02    26.8    5.2    0.2   46.0   21.8
1.130e+03          1       4.90e-02    26.5    5.2    0.2   45.9   22.2
1.140e+03          1       5.00e-02    26.0    5.2    0.2   47.4   21.1
1.150e+03          1       5.00e-02    26.0    5.0    0.2   47.5   21.3
1.160e+03          1       4.98e-02    26.1    5.2    0.2   47.3   21.2
1.170e+03          1       4.89e-02    26.7    5.5    0.2   46.0   21.6
1.180e+03          1       4.93e-02    27.3    5.8    0.2   45.2   21.5
1.190e+03          1       4.95e-02    26.1    5.9    0.2   46.0   21.8
1.200e+03          1       4.65e-02    25.5    6.1    0.2   46.5   21.7
1.210e+03          1       4.27e-02    27.4    5.1    0.2   45.6   21.7
1.220e+03          1       4.34e-02    26.4    5.2    0.2   45.4   22.8
1.230e+03          1       4.31e-02    26.5    5.2    0.2   46.3   21.9
1.240e+03          1       4.28e-02    26.5    5.8    0.2   45.2   22.3
1.250e+03          1       4.30e-02    26.5    5.1    0.2   46.7   21.5
1.260e+03          1       4.37e-02    26.5    5.1    0.2   46.4   21.8
1.270e+03          1       4.32e-02    26.3    5.7    0.2   45.9   22.0
1.280e+03          1       4.35e-02    27.0    5.1    0.2   46.1   21.7
1.290e+03          1       4.31e-02    27.7    5.1    0.2   45.6   21.4
1.300e+03          1       4.25e-02    27.2    5.1    0.2   45.4   22.0
1.310e+03          1       4.28e-02    27.5    5.1    0.2   45.2   22.0
1.320e+03          1       4.29e-02    26.4    5.2    0.2   46.2   22.0
1.330e+03          1       4.32e-02    26.2    5.1    0.2   46.5   22.0
1.340e+03          1       4.32e-02    26.2    5.1    0.2   45.4   23.1
1.350e+03          1       4.31e-02    27.3    5.2    0.2   45.5   21.8
1.360e+03          1       4.38e-02    26.0    5.0    0.2   47.0   21.8
1.370e+03          1       4.24e-02    27.4    5.2    0.2   45.3   21.9
1.380e+03          1       4.28e-02    27.5    5.2    0.2   45.5   21.7
1.390e+03          1       4.30e-02    26.3    5.1    0.2   46.4   22.0
1.400e+03          1       4.37e-02    27.0    6.4    0.3   44.7   21.6
1.410e+03          1       4.40e-02    27.1    5.1    0.2   45.9   21.6
1.420e+03          1       4.31e-02    26.4    5.1    0.2   45.4   22.9
1.430e+03          1       4.44e-02    25.5    5.0    0.2   46.9   22.4
1.440e+03          1       4.84e-02    26.8    5.2    0.2   45.6   22.2
1.450e+03          1       4.91e-02    26.9    5.3    0.2   45.9   21.8
1.460e+03          1       4.87e-02    26.7    5.2    0.2   46.3   21.7
1.470e+03          1       4.87e-02    26.7    5.2    0.2   46.3   21.6
1.480e+03          1       4.85e-02    26.8    5.2    0.2   46.1   21.7
1.490e+03          1       6.03e-02    32.2    7.3    0.3   41.8   18.5
1.500e+03          1       4.84e-02    26.8    5.3    0.2   45.8   22.0
1.510e+03          1       4.82e-02    26.9    5.2    0.2   45.6   22.1
1.520e+03          1       4.87e-02    26.7    5.2    0.2   46.2   21.7
1.530e+03          1       4.88e-02    26.7    5.2    0.2   46.1   21.8
1.540e+03          1       4.90e-02    26.7    5.2    0.2   46.2   21.7
1.550e+03          1       4.94e-02    26.4    5.1    0.2   46.3   21.9
1.560e+03         34       5.92e-01    71.4   14.0    0.5    3.7   10.4
1.570e+03          1       4.27e-02    26.8    5.2    0.2   45.6   22.2
1.580e+03          1       4.25e-02    26.7    5.1    0.2   45.8   22.1
1.590e+03          1       4.35e-02    26.0    5.0    0.2   46.8   22.0
1.600e+03          1       4.43e-02    26.5    5.0    0.2   46.5   21.7
1.610e+03          1       4.63e-02    25.4    6.8    0.2   47.3   20.3
1.620e+03          1       4.61e-02    25.0    4.7    0.2   49.5   20.5
1.630e+03          1       4.62e-02    25.1    5.0    0.2   48.8   20.9
1.640e+03          1       4.65e-02    24.6    4.7    0.2   50.0   20.5
1.650e+03          1       4.64e-02    24.9    4.9    0.2   49.3   20.8
1.660e+03          1       4.52e-02    25.4    6.1    0.2   47.8   20.5
1.670e+03          1       4.53e-02    26.1    6.5    0.2   46.4   20.8
1.680e+03          1       4.30e-02    26.6    5.1    0.2   45.5   22.6
1.690e+03          1       4.35e-02    27.0    5.0    0.2   46.5   21.3
1.700e+03          1       4.29e-02    26.3    5.1    0.2   46.4   22.0
1.710e+03          1       4.30e-02    27.0    5.2    0.2   45.7   22.0
1.720e+03          1       4.48e-02    27.3    5.0    0.2   45.5   22.0
1.730e+03          1       4.49e-02    26.5    5.0    0.2   45.9   22.4
1.740e+03          1       4.44e-02    26.8    5.0    0.2   46.0   22.0
1.750e+03          1       4.53e-02    25.9    5.0    0.2   44.6   24.3
1.760e+03          1       4.33e-02    27.3    5.1    0.2   45.7   21.7
1.770e+03          1       4.26e-02    27.2    5.1    0.2   45.6   21.9
1.780e+03          1       4.33e-02    28.4    5.1    0.2   44.8   21.6
1.790e+03          1       4.30e-02    26.4    5.3    0.2   46.3   21.9
1.800e+03          1       4.31e-02    27.3    5.1    0.2   45.3   22.1
1.810e+03          1       4.37e-02    26.2    5.1    0.2   46.1   22.4
1.820e+03          1       4.28e-02    26.6    5.1    0.2   45.9   22.2
1.830e+03          1       4.34e-02    26.3    5.1    0.2   46.2   22.2
1.840e+03          1       4.25e-02    26.8    5.2    0.2   46.0   21.8
1.850e+03          1       4.33e-02    26.4    5.3    0.2   45.4   22.7
1.860e+03          1       4.31e-02    26.4    5.1    0.2   46.5   21.8
1.870e+03         12       2.11e-01    65.3   12.8    0.4    9.2   12.3
1.880e+03          1       4.29e-02    26.6    5.1    0.2   45.6   22.5
1.890e+03          1       4.34e-02    26.4    5.1    0.2   46.8   21.6
1.900e+03          1       4.30e-02    26.3    5.1    0.2   46.3   22.2
1.910e+03          1       4.27e-02    26.8    5.2    0.2   45.6   22.2
1.920e+03          1       4.29e-02    26.8    5.1    0.2   46.2   21.6
1.930e+03          1       4.28e-02    26.6    5.1    0.2   46.0   22.1
1.940e+03          1       4.27e-02    26.7    5.1    0.2   46.1   21.9
1.950e+03          1       4.28e-02    26.6    5.2    0.2   46.1   22.0
1.960e+03          1       4.61e-02    29.6    4.8    0.2   44.0   21.4
1.970e+03          1       4.34e-02    26.2    5.0    0.2   45.9   22.7
1.980e+03          1       4.26e-02    26.8    5.3    0.2   45.7   22.0
1.990e+03          1       4.25e-02    26.7    5.2    0.2   45.7   22.2
2.000e+03          1       4.37e-02    27.5    5.3    0.2   44.7   22.3
|  Step 200 of 200. Elapsed 3:45:45.8 ETA 0:00:00.0
Run finished at  : Wed 08 Sep 2021 13:11:12 BST
Run time : 3 h 45 m 46 s
    Option datadir = data ()
    Option settingsfile = BOUT.settings ()
Writing options to file data/BOUT.settings
    Option time_report:show = 0 (default)

Due to the fact that this seems to change so much with the number of processors, I had assumed that the problem was with MPI, and so have been trying to fix that, but maybe I'm trying to solve a problem that doesn't exist?

Also, the ion density, Ni, seems to become negative after the beginning:
t=0
Ni_t0

t=50
Ni_t50

And it only gets more negative as it continues:
t=200
Ni_t200

@bendudson
Copy link
Contributor

Hi @EdmundBenedict thanks for checking this. Unfortunately many of the examples were useful at one time but are not routinely used or tested. It looks like this case is running into problems with negative density, and something a bit odd is going on with the time integration. If I get a moment I'll try to take a look. I guess either this should be fixed or deleted...

For these kind of 2D transport or turbulence simulations in tokamak geometry, I can recommend https://github.com/bendudson/hermes-2 or maybe https://github.com/bendudson/hermes-3 if you want something which is being used and under development (full disclosure: I am a bit biased!). There is also STORM (https://github.com/boutproject/STORM) which is quite robust and is used to run 2D and 3D turbulence simulations. All of these are quite large & complicated codes though, so may be more difficult to pick up than the examples, depending on your needs.

@EdmundBenedict
Copy link

Thank you very much for your reply! No, to be honest I was more running these examples to get to grips with the code. I was looking to eventually move to trying to simulate the process of plasma formation for double-null merging with 2D resistive MHD, following the methodology of Tara Ahmadi in her paper: https://iopscience.iop.org/article/10.1088/1741-4326/abebce/meta

@bendudson
Copy link
Contributor

Thanks for the link; I didn't know about that paper. There is a 2D model of double null merging here: https://github.com/boutproject/merging-filaments which has a Hall-MHD branch https://github.com/boutproject/merging-filaments/tree/hall

@EdmundBenedict
Copy link

Fantastic! Thank you so much, I'll start looking into this now

@EdmundBenedict
Copy link

Hi, I am very sorry to keep bothering you, I just wanted to check whether the results I was getting from the 2D model of double null merging were due to an issue with the way my code was compiled, or whether it was due to mistakes in how I carried out the examples, I raised this as an issue here: boutproject/merging-filaments#4

@bendudson
Copy link
Contributor

Hi @EdmundBenedict No problem; it's good to have someone check, as code rot is a thing and it's high time for a clearout of what works and what doesn't. We should probably have more automated tests for these examples, to make sure that changes to the model code or library don't break things. Sorry there may be some delay, but I'll try to look into that merging-filaments issue.

@EdmundBenedict
Copy link

Thank you very much!

@ZedThree
Copy link
Member Author

This is being dealt with in #2811

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants