Vlasiator ebf0dd394 on dev (v5.4.0 + 1054 commits)
Loading...
Searching...
No Matches
iowrite.h
Go to the documentation of this file.
1/*
2 * This file is part of Vlasiator.
3 * Copyright 2010-2016 Finnish Meteorological Institute
4 *
5 * For details of usage, see the COPYING file and read the "Rules of the Road"
6 * at http://www.physics.helsinki.fi/vlasiator/
7 *
8 * This program is free software; you can redistribute it and/or modify
9 * it under the terms of the GNU General Public License as published by
10 * the Free Software Foundation; either version 2 of the License, or
11 * (at your option) any later version.
12
13 * This program is distributed in the hope that it will be useful,
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 * GNU General Public License for more details.
17
18 * You should have received a copy of the GNU General Public License along
19 * with this program; if not, write to the Free Software Foundation, Inc.,
20 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
21 */
22#ifndef IOWRITE_H
23#define IOWRITE_H
24#include "grid.h"
25#include "mpi.h"
26#include <dccrg.hpp>
27#include <dccrg_cartesian_geometry.hpp>
28#include <string>
29#include <vector>
30#include <vlsv_writer.h>
31
32#include "definitions.h"
35
45bool writeGrid(
46 dccrg::Dccrg<SpatialCell, dccrg::Cartesian_Geometry>& mpiGrid,
47 const FieldSolverData& fieldSolverData,
49 const std::string& versionInfo,
50 const std::string& configInfo,
51 DataReducer* dataReducer,
52 const uint& index,
53 const int& stripe,
54 const bool writeGhosts,
55 bool compress_vdfs=false
56);
57
82 dccrg::Dccrg<SpatialCell, dccrg::Cartesian_Geometry>& mpiGrid,
83 const FieldSolverData& fieldSolverData,
85 const std::string& versionInfo,
86 const std::string& configInfo,
87 DataReducer& dataReducer,
88 const std::string& name,
89 const uint& fileIndex,
90 const bool dateInFileName,
91 const int& stripe,
92 bool compress_vdfs
93);
94
102bool writeDiagnostic(const dccrg::Dccrg<SpatialCell,dccrg::Cartesian_Geometry>& mpiGrid,DataReducer& dataReducer);
103
104bool writeVelocitySpace(dccrg::Dccrg<SpatialCell,dccrg::Cartesian_Geometry>& mpiGrid,
105 vlsv::Writer& vlsvWriter,int index,const std::vector<uint64_t>& cells);
106
107bool writeVelocityDistributionData(vlsv::Writer& vlsvWriter,const dccrg::Dccrg<SpatialCell,dccrg::Cartesian_Geometry>& mpiGrid,
108 const std::vector<uint64_t>& cells,MPI_Comm comm);
109
110bool writeIonosphereGridMetadata(vlsv::Writer& vlsvWriter);
111#endif
bool writeRestart(dccrg::Dccrg< SpatialCell, dccrg::Cartesian_Geometry > &mpiGrid, const FieldSolverData &fieldSolverData, fsgrids::consttechnicalspan technical, const std::string &versionInfo, const std::string &configInfo, DataReducer &dataReducer, const std::string &name, const uint &fileIndex, const bool dateInFileName, const int &stripe, bool compress_vdfs)
Write out a restart of the simulation into a vlsv file. All block data in remote cells will be reset.
bool writeDiagnostic(const dccrg::Dccrg< SpatialCell, dccrg::Cartesian_Geometry > &mpiGrid, DataReducer &dataReducer)
Write out simulation diagnostics into diagnostic.txt.
Definition iowrite.cpp:2422
bool writeIonosphereGridMetadata(vlsv::Writer &vlsvWriter)
Definition iowrite.cpp:1496
bool writeGrid(dccrg::Dccrg< SpatialCell, dccrg::Cartesian_Geometry > &mpiGrid, const FieldSolverData &fieldSolverData, fsgrids::consttechnicalspan technical, const std::string &versionInfo, const std::string &configInfo, DataReducer *dataReducer, const uint &index, const int &stripe, const bool writeGhosts, bool compress_vdfs=false)
Write out system into a vlsv file.
Definition iowrite.cpp:1829
bool writeVelocityDistributionData(vlsv::Writer &vlsvWriter, const dccrg::Dccrg< SpatialCell, dccrg::Cartesian_Geometry > &mpiGrid, const std::vector< uint64_t > &cells, MPI_Comm comm)
bool writeVelocitySpace(dccrg::Dccrg< SpatialCell, dccrg::Cartesian_Geometry > &mpiGrid, vlsv::Writer &vlsvWriter, int index, const std::vector< uint64_t > &cells)
#define index(i, j, k)
std::span< const technical > consttechnicalspan
Definition common.h:453