![]() |
FIMS
v0.10.0
|
von Bertalanffy–Schnute growth model adapter implementing the generic growth-derived observation capability for catch-at-age. More...
#include <growth_model_adapter.hpp>
Public Types | |
| enum class | LengthReferenceParameterization { kEstimatedReferenceLengths = 0 , kConstantLengthYoungEstimatedLengthOld , kEstimatedLengthYoungBelowConstantLengthOld , kBothConstant } |
| Options for how the two reference lengths are supplied. | |
Public Member Functions | |
| void | UseEstimatedReferenceMeanLengths () |
| Estimate both reference mean lengths. | |
| void | UseConstantMeanLengthYoungWithEstimatedMeanLengthOld (Type constant_mean_length_young) |
| Fix young reference length and estimate older reference mean length. | |
| void | UseEstimatedMeanLengthYoungBelowConstantMeanLengthOld (Type constant_mean_length_old) |
| Estimate young reference length below a fixed old reference length. | |
| void | UseConstantReferenceMeanLengths (Type constant_mean_length_young, Type constant_mean_length_old) |
| Fix both young and old reference mean lengths. | |
| fims::Vector< Type > & | MeanLengthYoungVector () |
| Access the working-scale storage for the first reference-length parameter. | |
| fims::Vector< Type > & | MeanLengthOldVector () |
| Access the log-scale length-at-reference-age-2 parameter vector. | |
| fims::Vector< Type > & | GrowthCoefficientVector () |
| Access the log-scale VonBertalanffySchnute growth coefficient vector. | |
| fims::Vector< Type > & | ReferenceAgeForLengthYoungVector () |
| Access the first reference-age vector. | |
| fims::Vector< Type > & | ReferenceAgeForLengthOldVector () |
| Access the second reference-age vector. | |
| fims::Vector< Type > & | LengthWeightAVector () |
| Access the log-scale length-weight-a vector. | |
| fims::Vector< Type > & | LengthWeightBVector () |
| Access the log-scale length-weight-b vector. | |
| fims::Vector< Type > & | LengthAtAgeSdAtRefAgesVector () |
| Access the log-scale length-at-age SD vector at the two reference ages. | |
| fims::Vector< Type > & | LogSdLengthAtRefAgeYoungVector () |
| Access the log-SD vector for mean_length_young. | |
| fims::Vector< Type > & | LogSdLengthAtRefAgeOldVector () |
| Access the log-SD vector for mean_length_old. | |
| fims::Vector< Type > & | LogSdGrowthCoefficientVector () |
| Access the log-SD vector for growth_coefficient. | |
| fims::Vector< Type > & | LogitCorrLengthAtRefAgeYoungLengthAtRefAgeOldVector () |
| Access the transformed correlation vector for mean_length_young and mean_length_old. | |
| fims::Vector< Type > & | LogitCorrLengthAtRefAgeYoungKVector () |
| Access the transformed correlation vector for mean_length_young and growth_coefficient. | |
| fims::Vector< Type > & | LogitCorrLengthAtRefAgeOldKVector () |
| Access the transformed correlation vector for mean_length_old and growth_coefficient. | |
| void | SetAgeOffset (double min_age) override |
| Set the minimum modeled age used by cached growth products. | |
| void | Initialize (std::size_t n_years, std::size_t n_ages, std::size_t n_sexes=1) override |
| Initialize the backing growth model and cache dimensions. | |
| bool | SupportsAgeToLengthConversionDerived () const override |
| Report that the adapter supports growth-derived age-to-length conversion calculations. | |
| virtual const Type | evaluate (int year, const double &a) override |
| Calculates the growth at the independent variable value. | |
| void | PrepareGrowthProducts () override |
| Prepare growth products for the current model state. | |
| const GrowthProducts< Type > * | TryGetPreparedGrowthProducts () const override |
| Return prepared growth products without triggering preparation. | |
| Type | EvaluateWeightAtLength (const Type &length) const override |
| Evaluate the length-weight relationship at a supplied length. | |
Public Member Functions inherited from fims_popdy::GrowthBase< Type > | |
| GrowthBase () | |
| Constructor. | |
Public Member Functions inherited from fims_model_object::FIMSObject< Type > | |
| uint32_t | GetId () const |
| Getter that returns the unique id for parameters in the model. | |
| bool | CheckDimensions (size_t actual, size_t expected) |
| Check the dimensions of an object. | |
Public Member Functions inherited from fims_model_object::FIMSMemoryTracker | |
| void | register_self (const uint32_t id) |
| Registers a FIMSObject instance with the memory tracker. | |
Additional Inherited Members | |
Public Attributes inherited from fims_model_object::FIMSObject< Type > | |
| uint32_t | id |
| std::vector< Type * > | parameters |
| std::vector< Type * > | random_effects_parameters |
| std::vector< Type * > | fixed_effects_parameters |
Static Public Attributes inherited from fims_popdy::GrowthBase< Type > | |
| static uint32_t | id_g = 0 |
Static Public Attributes inherited from fims_model_object::FIMSMemoryTracker | |
| static int | total_active_objects = 0 |
| Total number of active FIMSObject instances currently in memory. | |
von Bertalanffy–Schnute growth model adapter implementing the generic growth-derived observation capability for catch-at-age.
|
inlineoverridevirtual |
Calculates the growth at the independent variable value.
| year | The year at which to return weight of the fish (in kg). |
| a | The age at which to return weight of the fish (in kg). |
Implements fims_popdy::GrowthBase< Type >.
|
inlineoverridevirtual |
Evaluate the length-weight relationship at a supplied length.
This is used by fleet-level derived quantities that need a bin-based expectation over the same length bins used in the dynamic age-to-length conversion path.
| length | Length on the natural scale. |
Implements fims_popdy::GrowthDerivedObservationBase< Type >.
|
inline |
Access the log-scale VonBertalanffySchnute growth coefficient vector.
|
inlineoverridevirtual |
Initialize the backing growth model and cache dimensions.
| n_years | Number of modeled years. |
| n_ages | Number of modeled ages. |
| n_sexes | Number of modeled sexes. |
Implements fims_popdy::GrowthDerivedObservationBase< Type >.
|
inline |
Access the log-scale length-at-age SD vector at the two reference ages.
|
inline |
Access the log-scale length-weight-a vector.
|
inline |
Access the log-scale length-weight-b vector.
|
inline |
Access the transformed correlation vector for mean_length_old and growth_coefficient.
|
inline |
Access the transformed correlation vector for mean_length_young and growth_coefficient.
|
inline |
Access the transformed correlation vector for mean_length_young and mean_length_old.
|
inline |
Access the log-SD vector for growth_coefficient.
|
inline |
Access the log-SD vector for mean_length_old.
|
inline |
Access the log-SD vector for mean_length_young.
|
inline |
Access the log-scale length-at-reference-age-2 parameter vector.
|
inline |
Access the working-scale storage for the first reference-length parameter.
|
inlineoverridevirtual |
Prepare growth products for the current model state.
Implements fims_popdy::GrowthDerivedObservationBase< Type >.
|
inline |
Access the second reference-age vector.
|
inline |
Access the first reference-age vector.
|
inlineoverridevirtual |
Set the minimum modeled age used by cached growth products.
| min_age | Minimum age on the natural scale. |
Implements fims_popdy::GrowthDerivedObservationBase< Type >.
|
inlineoverridevirtual |
Report that the adapter supports growth-derived age-to-length conversion calculations.
Implements fims_popdy::GrowthDerivedObservationBase< Type >.
|
inlineoverridevirtual |
Return prepared growth products without triggering preparation.
Implements fims_popdy::GrowthDerivedObservationBase< Type >.
|
inline |
Fix young reference length and estimate older reference mean length.
| constant_mean_length_young | Fixed mean length at the younger reference age. |
|
inline |
Fix both young and old reference mean lengths.
| constant_mean_length_young | Fixed mean length at the younger reference age. |
| constant_mean_length_old | Fixed mean length at the older reference age. |
|
inline |
Estimate young reference length below a fixed old reference length.
| constant_mean_length_old | Fixed mean length at the older reference age. |