params.h
Go to the documentation of this file.
#ifndef VIENNA_RNA_PACKAGE_PARAMS_H
#define VIENNA_RNA_PACKAGE_PARAMS_H
#ifdef DEPRECATION_WARNINGS
# ifdef __GNUC__
# define DEPRECATED(func) func __attribute__ ((deprecated))
# else
# define DEPRECATED(func) func
# endif
#else
# define DEPRECATED(func) func
#endif
/* make this interface backward compatible with RNAlib < 2.2.0 */
#define VRNA_BACKWARD_COMPAT
typedef struct vrna_param_s vrna_param_t;
typedef struct vrna_exp_param_s vrna_exp_param_t;
#include <ViennaRNA/energy_const.h>
#include <ViennaRNA/data_structures.h>
#include <ViennaRNA/model.h>
#define VRNA_GQUAD_MAX_STACK_SIZE 7
#define VRNA_GQUAD_MIN_STACK_SIZE 2
#define VRNA_GQUAD_MAX_LINKER_LENGTH 15
#define VRNA_GQUAD_MIN_LINKER_LENGTH 1
#define VRNA_GQUAD_MIN_BOX_SIZE ((4*VRNA_GQUAD_MIN_STACK_SIZE)+(3*VRNA_GQUAD_MIN_LINKER_LENGTH))
#define VRNA_GQUAD_MAX_BOX_SIZE ((4*VRNA_GQUAD_MAX_STACK_SIZE)+(3*VRNA_GQUAD_MAX_LINKER_LENGTH))
struct vrna_param_s {
int id;
int stack[NBPAIRS+1][NBPAIRS+1];
int hairpin[31];
int bulge[MAXLOOP+1];
int internal_loop[MAXLOOP+1];
int mismatchExt[NBPAIRS+1][5][5];
int mismatchI[NBPAIRS+1][5][5];
int mismatch1nI[NBPAIRS+1][5][5];
int mismatch23I[NBPAIRS+1][5][5];
int mismatchH[NBPAIRS+1][5][5];
int mismatchM[NBPAIRS+1][5][5];
int dangle5[NBPAIRS+1][5];
int dangle3[NBPAIRS+1][5];
int int11[NBPAIRS+1][NBPAIRS+1][5][5];
int int21[NBPAIRS+1][NBPAIRS+1][5][5][5];
int int22[NBPAIRS+1][NBPAIRS+1][5][5][5][5];
int ninio[5];
double lxc;
int MLbase;
int MLintern[NBPAIRS+1];
int MLclosing;
int TerminalAU;
int DuplexInit;
int Tetraloop_E[200];
char Tetraloops[1401];
int Triloop_E[40];
char Triloops[241];
int Hexaloop_E[40];
char Hexaloops[1801];
int TripleC;
int MultipleCA;
int MultipleCB;
int gquad [VRNA_GQUAD_MAX_STACK_SIZE + 1]
[3*VRNA_GQUAD_MAX_LINKER_LENGTH + 1];
double temperature;
vrna_md_t model_details;
};
struct vrna_exp_param_s {
int id;
double expstack[NBPAIRS+1][NBPAIRS+1];
double exphairpin[31];
double expbulge[MAXLOOP+1];
double expinternal[MAXLOOP+1];
double expmismatchExt[NBPAIRS+1][5][5];
double expmismatchI[NBPAIRS+1][5][5];
double expmismatch23I[NBPAIRS+1][5][5];
double expmismatch1nI[NBPAIRS+1][5][5];
double expmismatchH[NBPAIRS+1][5][5];
double expmismatchM[NBPAIRS+1][5][5];
double expdangle5[NBPAIRS+1][5];
double expdangle3[NBPAIRS+1][5];
double expint11[NBPAIRS+1][NBPAIRS+1][5][5];
double expint21[NBPAIRS+1][NBPAIRS+1][5][5][5];
double expint22[NBPAIRS+1][NBPAIRS+1][5][5][5][5];
double expninio[5][MAXLOOP+1];
double lxc;
double expMLbase;
double expMLintern[NBPAIRS+1];
double expMLclosing;
double expTermAU;
double expDuplexInit;
double exptetra[40];
double exptri[40];
double exphex[40];
char Tetraloops[1401];
double expTriloop[40];
char Triloops[241];
char Hexaloops[1801];
double expTripleC;
double expMultipleCA;
double expMultipleCB;
double expgquad[VRNA_GQUAD_MAX_STACK_SIZE + 1]
[3*VRNA_GQUAD_MAX_LINKER_LENGTH + 1];
double kT;
double pf_scale;
double temperature;
double alpha;
vrna_md_t model_details;
};
vrna_param_t *
vrna_params(vrna_md_t *md);
vrna_param_t *
vrna_params_copy(vrna_param_t *par);
vrna_exp_param_t *
vrna_exp_params(vrna_md_t *md);
vrna_exp_param_t *
vrna_exp_params_comparative(unsigned int n_seq,
vrna_md_t *md);
vrna_exp_param_t *
vrna_exp_params_copy(vrna_exp_param_t *par);
void
vrna_params_subst( vrna_fold_compound_t *vc,
vrna_param_t *par);
void
vrna_exp_params_subst(vrna_fold_compound_t *vc,
vrna_exp_param_t *params);
void
vrna_exp_params_rescale(vrna_fold_compound_t *vc,
double *mfe);
void vrna_params_reset( vrna_fold_compound_t *vc,
vrna_md_t *md_p);
void vrna_exp_params_reset( vrna_fold_compound_t *vc,
vrna_md_t *md_p);
#ifdef VRNA_BACKWARD_COMPAT
typedef struct vrna_param_s paramT;
typedef struct vrna_exp_param_s pf_paramT;
DEPRECATED(vrna_param_t *get_parameter_copy(vrna_param_t *par));
DEPRECATED(vrna_exp_param_t *get_scaled_pf_parameters(void));
DEPRECATED(vrna_exp_param_t *get_boltzmann_factors(double temperature, double betaScale, vrna_md_t md, double pf_scale));
DEPRECATED(vrna_exp_param_t *get_boltzmann_factor_copy(vrna_exp_param_t *parameters));
DEPRECATED(vrna_exp_param_t *get_scaled_alipf_parameters(unsigned int n_seq));
DEPRECATED(vrna_exp_param_t *get_boltzmann_factors_ali(unsigned int n_seq, double temperature, double betaScale, vrna_md_t md, double pf_scale));
DEPRECATED(vrna_param_t *scale_parameters(void));
DEPRECATED(vrna_param_t *get_scaled_parameters(double temperature, vrna_md_t md));
DEPRECATED(vrna_param_t *copy_parameters(void));
DEPRECATED(vrna_param_t *set_parameters(vrna_param_t *dest));
DEPRECATED(vrna_exp_param_t *scale_pf_parameters(void));
DEPRECATED(vrna_exp_param_t *copy_pf_param(void));
DEPRECATED(vrna_exp_param_t *set_pf_param(vrna_param_t *dest));
#endif
#endif
vrna_params
vrna_param_t * vrna_params(vrna_md_t *md)
Get a data structure containing prescaled free energy parameters.
get_scaled_parameters
vrna_param_t * get_scaled_parameters(double temperature, vrna_md_t md)
Get precomputed energy contributions for all the known loop types.
MAXLOOP
#define MAXLOOP
Definition: energy_const.h:28
vrna_param_s::model_details
vrna_md_t model_details
Model details to be used in the recursions.
Definition: params.h:88
vrna_exp_param_s::pf_scale
double pf_scale
Scaling factor to avoid over-/underflows.
Definition: params.h:134
vrna_exp_param_s::model_details
vrna_md_t model_details
Model details to be used in the recursions.
Definition: params.h:144
vrna_fc_s
The most basic data structure required by many functions throughout the RNAlib.
Definition: data_structures.h:390
vrna_exp_param_s::temperature
double temperature
Temperature used for loop contribution scaling.
Definition: params.h:136
get_scaled_alipf_parameters
vrna_exp_param_t * get_scaled_alipf_parameters(unsigned int n_seq)
Get precomputed Boltzmann factors of the loop type dependent energy contributions (alifold variant) ...
temperature
double temperature
Rescale energy parameters to a temperature in degC.
model.h
The model details data structure and its corresponding modifiers.
vrna_param_s
The datastructure that contains temperature scaled energy parameters.
Definition: params.h:50
vrna_exp_params_copy
vrna_exp_param_t * vrna_exp_params_copy(vrna_exp_param_t *par)
Get a copy of the provided free energy parameters (provided as Boltzmann factors) ...
vrna_exp_params_subst
void vrna_exp_params_subst(vrna_fold_compound_t *vc, vrna_exp_param_t *params)
Update the energy parameters for subsequent partition function computations.
vrna_exp_params_reset
void vrna_exp_params_reset(vrna_fold_compound_t *vc, vrna_md_t *md_p)
Reset Boltzmann factors for partition function computations within a vrna_fold_compound_t according t...
vrna_params_copy
vrna_param_t * vrna_params_copy(vrna_param_t *par)
Get a copy of the provided free energy parameters.
vrna_exp_params_rescale
void vrna_exp_params_rescale(vrna_fold_compound_t *vc, double *mfe)
Rescale Boltzmann factors for partition function computations.
energy_const.h
data_structures.h
vrna_md_s
The data structure that contains the complete model details used throughout the calculations.
Definition: model.h:187
vrna_exp_param_s::alpha
double alpha
Scaling factor for the thermodynamic temperature.
Definition: params.h:137
vrna_exp_param_s
The datastructure that contains temperature scaled Boltzmann weights of the energy parameters...
Definition: params.h:94
pf_scale
double pf_scale
A scaling factor used by pf_fold() to avoid overflows.
get_scaled_pf_parameters
vrna_exp_param_t * get_scaled_pf_parameters(void)
vrna_param_s::temperature
double temperature
Temperature used for loop contribution scaling.
Definition: params.h:86
vrna_exp_params_comparative
vrna_exp_param_t * vrna_exp_params_comparative(unsigned int n_seq, vrna_md_t *md)
Get a data structure containing prescaled free energy parameters already transformed to Boltzmann fac...
get_boltzmann_factor_copy
vrna_exp_param_t * get_boltzmann_factor_copy(vrna_exp_param_t *parameters)
Get a copy of already precomputed Boltzmann factors.
NBPAIRS
#define NBPAIRS
Definition: energy_const.h:24
get_boltzmann_factors_ali
vrna_exp_param_t * get_boltzmann_factors_ali(unsigned int n_seq, double temperature, double betaScale, vrna_md_t md, double pf_scale)
Get precomputed Boltzmann factors of the loop type dependent energy contributions (alifold variant) w...
get_boltzmann_factors
vrna_exp_param_t * get_boltzmann_factors(double temperature, double betaScale, vrna_md_t md, double pf_scale)
Get precomputed Boltzmann factors of the loop type dependent energy contributions with independent th...
vrna_params_reset
void vrna_params_reset(vrna_fold_compound_t *vc, vrna_md_t *md_p)
Reset free energy parameters within a vrna_fold_compound_t according to provided, or default model de...
vrna_exp_param_s::id
int id
An identifier for the data structure.
Definition: params.h:95
vrna_exp_params
vrna_exp_param_t * vrna_exp_params(vrna_md_t *md)
Get a data structure containing prescaled free energy parameters already transformed to Boltzmann fac...
scale_parameters
vrna_param_t * scale_parameters(void)
Get precomputed energy contributions for all the known loop types.
vrna_params_subst
void vrna_params_subst(vrna_fold_compound_t *vc, vrna_param_t *par)
Update/Reset energy parameters data structure within a vrna_fold_compound_t.