WarpX
Functions
FlushFormatPlotfile.cpp File Reference
#include "FlushFormatPlotfile.H"
#include "FieldSolver/Fields.H"
#include "Diagnostics/MultiDiagnostics.H"
#include "Diagnostics/ParticleDiag/ParticleDiag.H"
#include "Particles/Filter/FilterFunctors.H"
#include "Particles/WarpXParticleContainer.H"
#include "Particles/ParticleIO.H"
#include "Particles/PinnedMemoryParticleContainer.H"
#include "Utils/Interpolate.H"
#include "Utils/Parser/ParserUtils.H"
#include "Utils/TextMsg.H"
#include "Utils/WarpXProfilerWrapper.H"
#include "WarpX.H"
#include <AMReX.H>
#include <AMReX_Box.H>
#include <AMReX_BoxArray.H>
#include <AMReX_Config.H>
#include <AMReX_GpuAllocators.H>
#include <AMReX_GpuQualifiers.H>
#include <AMReX_IntVect.H>
#include <AMReX_MakeType.H>
#include <AMReX_MultiFab.H>
#include <AMReX_PODVector.H>
#include <AMReX_ParallelDescriptor.H>
#include <AMReX_ParmParse.H>
#include <AMReX_ParticleIO.H>
#include <AMReX_Particles.H>
#include <AMReX_PlotFileUtil.H>
#include <AMReX_Print.H>
#include <AMReX_REAL.H>
#include <AMReX_Utility.H>
#include <AMReX_VisMF.H>
#include <AMReX_buildInfo.H>
#include <omp.h>
#include <algorithm>
#include <array>
#include <cstring>
#include <fstream>
#include <map>
#include <memory>
#include <utility>
#include <vector>

Functions

void WriteRawMF (const MultiFab &F, const DistributionMapping &dm, const std::string &filename, const std::string &level_prefix, const std::string &field_name, const int lev, const bool plot_guards)
 Write the data from MultiFab F into the file filename as a raw field (i.e. no interpolation to cell centers). Write guard cells if plot_guards is True. More...
 
void WriteZeroRawMF (const MultiFab &F, const DistributionMapping &dm, const std::string &filename, const std::string &level_prefix, const std::string &field_name, const int lev, const IntVect ng)
 Write a multifab of the same shape as F but filled with 0. (The shape includes guard cells if plot_guards is True.) This is mainly needed because the yt reader requires all levels of the coarse/fine patch to be written, but WarpX does not have data for the coarse patch of level 0 (meaningless). More...
 
void WriteCoarseVector (const std::string &field_name, const MultiFab *Fx_cp, const MultiFab *Fy_cp, const MultiFab *Fz_cp, const MultiFab *Fx_fp, const MultiFab *Fy_fp, const MultiFab *Fz_fp, const DistributionMapping &dm, const std::string &filename, const std::string &level_prefix, const int lev, const bool plot_guards)
 Write the coarse vector multifab F*_cp to the file filename after sampling/interpolating its value on the fine grid corresponding to F*_fp. This is mainly needed because the yt reader requires the coarse and fine patch to have the same shape. More...
 
void WriteCoarseScalar (const std::string &field_name, const MultiFab *F_cp, const MultiFab *F_fp, const DistributionMapping &dm, const std::string &filename, const std::string &level_prefix, const int lev, const bool plot_guards, const int icomp)
 Write the coarse scalar multifab F_cp to the file filename after sampling/interpolating its value on the fine grid corresponding to F_fp. This is mainly needed because the yt reader requires the coarse and fine patch to have the same shape. More...
 

Function Documentation

◆ WriteCoarseScalar()

void WriteCoarseScalar ( const std::string &  field_name,
const MultiFab F_cp,
const MultiFab F_fp,
const DistributionMapping dm,
const std::string &  filename,
const std::string &  level_prefix,
const int  lev,
const bool  plot_guards,
const int  icomp 
)

Write the coarse scalar multifab F_cp to the file filename after sampling/interpolating its value on the fine grid corresponding to F_fp. This is mainly needed because the yt reader requires the coarse and fine patch to have the same shape.

◆ WriteCoarseVector()

void WriteCoarseVector ( const std::string &  field_name,
const MultiFab Fx_cp,
const MultiFab Fy_cp,
const MultiFab Fz_cp,
const MultiFab Fx_fp,
const MultiFab Fy_fp,
const MultiFab Fz_fp,
const DistributionMapping dm,
const std::string &  filename,
const std::string &  level_prefix,
const int  lev,
const bool  plot_guards 
)

Write the coarse vector multifab F*_cp to the file filename after sampling/interpolating its value on the fine grid corresponding to F*_fp. This is mainly needed because the yt reader requires the coarse and fine patch to have the same shape.

◆ WriteRawMF()

void WriteRawMF ( const MultiFab F,
const DistributionMapping dm,
const std::string &  filename,
const std::string &  level_prefix,
const std::string &  field_name,
const int  lev,
const bool  plot_guards 
)

Write the data from MultiFab F into the file filename as a raw field (i.e. no interpolation to cell centers). Write guard cells if plot_guards is True.

◆ WriteZeroRawMF()

void WriteZeroRawMF ( const MultiFab F,
const DistributionMapping dm,
const std::string &  filename,
const std::string &  level_prefix,
const std::string &  field_name,
const int  lev,
const IntVect  ng 
)

Write a multifab of the same shape as F but filled with 0. (The shape includes guard cells if plot_guards is True.) This is mainly needed because the yt reader requires all levels of the coarse/fine patch to be written, but WarpX does not have data for the coarse patch of level 0 (meaningless).