1#ifndef _REMORA_NCTIMESEIRES_H_
2#define _REMORA_NCTIMESEIRES_H_
4#ifdef REMORA_USE_NETCDF
8#include <AMReX_AmrCore.H>
22 const std::string a_field_name,
23 const std::string a_time_name,
24 const amrex::Box& a_domain,
25 amrex::MultiFab* a_mf_var,
26 bool a_is2d,
bool a_save_interpolated);
A class to hold and interpolate time series data read from a NetCDF file.
bool is2d
Whether the field we're reading in is 2d.
void read_in_at_time(amrex::MultiFab *mf, int itime)
Read in data from file at time index itime and fill into mf.
amrex::Real time_after
Time in ocean_times immediately after the last time interpolated to.
amrex::Real time_before
Time in ocean_times immediately before the last time interpolated to.
void Initialize()
Read in time array from file and allocate data arrays.
amrex::MultiFab * mf_before
Multifab to store data at time_before.
int i_time_before
Time index immediately before the last time interpolated to.
std::string field_name
Field name in netcdf file.
amrex::MultiFab * mf_after
Multifab to store data at time_after.
amrex::MultiFab * mf_interpolated
std::string time_name
Field name for time series in netcdf file.
std::string file_name
File name to read from.
void update_interpolated_to_time(amrex::Real time)
Calculate interpolated values at time, reading in data as necessary.
amrex::Vector< amrex::Real > ocean_times
Time points in netcdf file.