ana1Tests.energyLineTest

Energy line test This module runs a DFA simulation extracts the center of mass path and compares it to the analytic geometric/alpha line solution

Functions

generateCom1DFAEnergyPlot

Make energy test analysis and plot results :Parameters: * avalancheDir (pathlib) – avalanche directory pathlib path * energyLineTestCfg (configParser) – energy line test config * com1DFACfg (configParser) – com1DFA config * avaProfileMass (dict) – particle mass averaged properties * dem (dict) – com1DFA simulation dictionary * fieldsList (list) – field dictionary list * simName (str) – simulation name

getAlphaProfileIntersection

Extend the profile path and compute the intersection between the theoretical energy line and the path profile The profile is extended by a line. The line slope is computed from the slope of the regression on the las points of the profile :Parameters: * energyLineTestCfg (configParser) – energy test config * avaProfileMass (dict) – particle mass average properties * mu (float) – friction coefficient * csz (float) – dem cell size.

getEnergyInfo

Compute energy dots and errors :Parameters: * avaProfileMass (dict) – particle mass average properties * g (float) – gravity * mu (float) – friction coefficient * sIntersection (float) – s coord of the intersection between the line of slope mu and the mass average path profile * zIntersection (float) – z coord of the intersection between the line of slope mu and the mass average path profile * runOutAngleRad (float) – center of mass runout angle in radians * runOutAngleDeg (float) – center of mass runout angle in degrees

getRunOutAngle

Compute the center of mass runout angle :Parameters: * avaProfileMass (dict) – particle mass average properties * indStart (int) – index of the start of the mass averaged path (to enable e.g. to discard the top extension). 0 by default - so full mass averaged path from top * indEnd (int) – index of the start of the mass averaged pass (to discard the bottom extension). -1 by default.

mainEnergyLineTest

This is the core function of the energyLineTest module This module extracts the center of mass path from a DFA simulation and compares it to he analytic geometric/alpha line solution