Stellarator-Tools
Loading...
Searching...
No Matches
netcdf_diff.cpp File Reference

Utility to check the difference between two netcdf files. More...

#include <cmath>
#include <iostream>
#include <vector>
#include <netcdf.h>
#include <algorithm>
#include "netcdf_test_commandline_parser.hpp"

Functions

std::vector< double > netcdf_quantity (const std::string netcdf_file, const std::string name)
 Load a quantity from a netcdf file.
int main (int argc, const char *argv[])
 Main test program.

Detailed Description

Utility to check the difference between two netcdf files.

Function Documentation

◆ main()

int main ( int argc,
const char * argv[] )

Main test program.

Parameters
[in]argcNumber of commandline arguments.
[in]argvArray of arguments strings.

◆ netcdf_quantity()

std::vector< double > netcdf_quantity ( const std::string netcdf_file,
const std::string name )

Load a quantity from a netcdf file.

Quantites are loaded into a flat vector for rapid comparison.

Parameters
[in]netcdf_fileNetcdf file name.
[in]nameName of the netcdf file quantity.