/* SPDX-License-Identifier: MIT-0 */ #ifndef UNITS_H #define UNITS_H #define UNITS_DEFAULT METRIC #define SURFACE_PRESSURE_DEFAULT 1.01325 /* types */ enum UNITS { METRIC, IMPERIAL, }; /* global variables */ extern enum UNITS UNITS; extern double SURFACE_PRESSURE; /* functions */ double bar_to_msw(double bar); double msw_to_bar(double msw); double bar_to_fsw(double bar); double fsw_to_bar(double msw); double msw_or_fsw(double msw, double fsw); double xsw_to_bar(double xsw); double bar_to_xsw(double bar); double abs_depth(double gd); double gauge_depth(double ad); #endif /* end of include guard: UNITS_H */