This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Reads output vtk files from the spectral code, SNOOPY | |
# Currently only for 3D MHD runs | |
# Output data is by default float 32 binary | |
# Big endian vs Little endian: depends on the machine | |
# <f4 means read as np.float32 type little endian byter order | |
# >f4 means read as np.float32 type big endian byter order | |
import numpy as np |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from mpi4py import MPI | |
import numpy as np | |
from shenfun import * | |
nu = 0.000625 | |
eta = 0.01 | |
end_time = 0.1 | |
dt = 0.01 # no adaptive time stepping | |
comm = MPI.COMM_WORLD | |
N = (2**5, 2**5, 2**5) # 32^3 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
python -m pytest . | |
============================= test session starts ============================== | |
platform linux -- Python 3.6.7, pytest-4.1.1, py-1.7.0, pluggy-0.8.1 | |
rootdir: /home/fnauman/python3/shenfun, inifile: | |
collected 3563 items | |
test_curl.py .... [ 0%] | |
test_demos.py F [ 0%] | |
test_forms.py ........................... [ 0%] |