Class AdemData

Class Documentation

class AdemData

Data container for ADEM input parameters and results.

Upcoming refactor

The AdemData class is treated as a struct, whose contents are updated by a number of functions… But, the functions operating on this should be refactored into class methods. That way, appropriate validation of the contents can be undertaken prior to application of each function.

This refactor is captured in issue #34.

Public Functions

void load(std::string file_name, bool print_var = true)

Load data from a *.mat file containing eddy signature data.

Parameters
  • file_name: File name (including relative or absolute path)
  • print_var: Boolean, default true. Print variables as they are read in (not advised except for debugging!)

void save(std::string filename)

Save eddy signature data to a *.mat file.

Parameters
  • filename: File name (including relative or absolute path)

Public Members

std::vector<std::string> eddy_types = {"A", "B1+B2+B3+B4"}

Eddy types used to create the results.

double beta
double delta_c

Atmospheric boundary layer thickness \( \delta_c \) [m].

double kappa

von Karman constant \( \kappa \). Typically \( \kappa = 0.41 \).

double pi_coles

Coles wake parameter \( \Pi \).

double shear_ratio

Ratio between free-stream and skin friction velocities \( S = U_{inf}/U_{\tau} \).

double u_inf

Free-stream velocity \( U_{inf}|_{z = \delta_c} \)) [m/s].

double u_tau

Skin friction velocity [m/s].

double zeta

Scaled streamwise derivative \( \zeta \) of the Coles wake parameter \( \Pi \).

Eigen::VectorXd z

Vertical coordinates used in the analysis [m].

Eigen::VectorXd eta

Nondimensionalised vertical coordinates used in the analysis \( \eta = z/\delta_{c} \).

Eigen::VectorXd lambda_e

Parameterised nondimensional vertical coordinates used in the analysis.

Eigen::VectorXd u_horizontal

Horizontal mean velocity varying with vertical coordinate [m/s].

Eigen::ArrayXXd reynolds_stress

Reynolds stress profiles from all eddy types.

Eigen::ArrayXXd r13a_analytic

Reynolds Stress profile \(R_{13A}\) determined analytically from the parameter set.

Eigen::ArrayXXd r13b_analytic

Reynolds Stress profile \(R_{13B}\) determined analytically from the parameter set.

Eigen::ArrayXXd reynolds_stress_a

Reynolds Stress profiles, contributions from Type A eddies only.

Eigen::ArrayXXd reynolds_stress_b

Reynolds Stress profiles, contributions from Type B eddies only.

Eigen::ArrayXXd k1z

Wavenumbers \( k_{1}z \) for which spectra are defined at each vertical coordinate.

Eigen::Tensor<double, 3> psi

Turbulent Spectra \( \Psi \) (corresponding to wavenumber k1z) at each vertical coordinate.

Eigen::Tensor<double, 3> psi_a

Turbulent Spectra (corresponding to wavenumber k1z) at each vertical coordinate from Type A eddies only.

Eigen::Tensor<double, 3> psi_b

Turbulent Spectra (corresponding to wavenumber k1z) at each vertical coordinate from Type B eddies only.

Eigen::VectorXd t2wa

Negated convolution function \( -(T^2)\omega \) encapsulating variation of eddy strength and scale for Type A eddies.

Eigen::VectorXd t2wb

Negated convolution function \( -(T^2)\omega \) encapsulating variation of eddy strength and scale for Type B eddies.

Eigen::VectorXd residual_a

Fit residuals from the deconvolution of t2wa

Eigen::VectorXd residual_b

Fit residuals from the deconvolution of t2wb

Eigen::Index start_idx
Eigen::ArrayXXd ja_fine

Reynolds Stress profile \(R_{13A}\) determined analytically from the parameter set, finely interpolated.

Eigen::ArrayXXd jb_fine

Reynolds Stress profile \(R_{13B}\) determined analytically from the parameter set, finely interpolated.

Eigen::ArrayXd r13a_analytic_fine

Reynolds Stress profile \(R_{13A}\) determined analytically from the parameter set, finely interpolated.

Eigen::ArrayXd r13b_analytic_fine

Reynolds Stress profile \(R_{13B}\) determined analytically from the parameter set, finely interpolated.

Eigen::ArrayXd minus_t2wa_fine

Negated convolution function \( -(T^2)\omega \) encapsulating variation of eddy strength and scale for Type A eddies, on the grid of lambda_fine.

Eigen::ArrayXd minus_t2wb_fine

Negated convolution function \( -(T^2)\omega \) encapsulating variation of eddy strength and scale for Type B eddies, on the grid of lambda_fine.

Eigen::ArrayXd lambda_fine

Linearly, finely, spaced values of \( \lambda \) at which final.

Eigen::ArrayXd eta_fine

Linearly, finely, spaced values of \( \lambda \) at which final.