ReadMpas

Read MPAS files

Purpose

This module can be used to import data from NetCDF files generated by MPAS simulations.

Data Preparation

Files must be in NetCDF format (type classic, 64-bit offset or cdf-5).

The underlying data structure is assumed to be a Voronoi grid.

For dynamic data, data for each timestep must be present in a separate file.

Ports

ReadMpas grid_out grid (grid_out) data_out_0 scalar data (data_out_0) data_out_1 scalar data (data_out_1) data_out_2 scalar data (data_out_2) data_out_3 scalar data (data_out_3) velocity composed cartesian velocity (velocity)

Parameters

name

description

type

first_step

first timestep to read

Int

last_step

last timestep to read (-1: last)

Int

step_increment

number of steps to increment

Int

first_rank

rank for first partition of first timestep

Int

grid_file

File containing the grid

String

zGrid_file_dir

File containing the vertical coordinates (elevation of cell from mean sea level

String

data_file

File containing data

String

part_file

File containing the grid partitions

String

numParts

Number of partitions (-1: automatic)

Int

numLevels

Number of vertical cell layers to read (0: only one 2D level)

Int

bottomLevel

Lower bound for altitude levels

Int

altitudeScale

value to scale the grid altitude (zGrid)

Float

var_dim

Dimension of variables (2D, 3D)

String

Variable_0

Variable_0 ((NONE))

String

Variable_1

Variable_1 ((NONE))

String

Variable_2

Variable_2 ((NONE))

String

Variable_3

Variable_3 ((NONE))

String

u_zonal

u_zonal ((NONE))

String

u_meridional

u_meridional ((NONE))

String

w

w ((NONE))

String

radial_scale

scale radial velocity component with height

Int

cell_mode

grid (based on Voronoi cells, Delaunay trianguelation, or Delaunay projected down) (Voronoi, Delaunay, DelaunayProjected)

Int

Required parameters

File must provide at least the following variables:

  • grid file : Path to a file describing the ground layer (typically retrieved from the MPAS standard mesh sets (‘x1. … .grid.nc’) ).

  • part file : Path to a file containing information on the grid paritioning (typically retrieved from the MPAS standard mesh sets; for N partitions (’ x1. … .graph.info.part.N’) )

Important Optional Parameters

  • data file : Path to a file containing additional variables

  • zGrid file : Path to the file containing the altitude of grid layers

  • var dim : Dimension of variables to be read

  • Variable 0…2 : Name of variables to be read

Usage Examples

Build Requirements

This module requires the PnetCDF library.