RNAlib-2.6.3
 
Loading...
Searching...
No Matches
2Dfold.h
Go to the documentation of this file.
1#ifndef VIENNA_RNA_PACKAGE_TWO_D_FOLD_H
2#define VIENNA_RNA_PACKAGE_TWO_D_FOLD_H
3
4#ifdef VRNA_WARN_DEPRECATED
5# if defined(__clang__)
6# define DEPRECATED(func, msg) func __attribute__ ((deprecated("", msg)))
7# elif defined(__GNUC__)
8# define DEPRECATED(func, msg) func __attribute__ ((deprecated(msg)))
9# else
10# define DEPRECATED(func, msg) func
11# endif
12#else
13# define DEPRECATED(func, msg) func
14#endif
15
39
54typedef struct vrna_sol_TwoD_t {
55 int k;
56 int l;
57 float en;
58 char *s;
60
61
91 int distance1,
92 int distance2);
93
94
114char *
116 int k,
117 int l,
118 unsigned int j);
119
120
121#ifndef VRNA_DISABLE_BACKWARD_COMPATIBILITY
122
123#define TwoDfold_solution vrna_sol_TwoD_t /* restore compatibility of struct rename */
124
132typedef struct TwoDfold_vars {
135 char *ptype;
136 char *sequence;
137 short *S, *S1;
138 unsigned int maxD1;
139 unsigned int maxD2;
142 unsigned int *mm1;
143 unsigned int *mm2;
145 int *my_iindx;
147 double temperature;
148
149 unsigned int *referenceBPs1;
150 unsigned int *referenceBPs2;
151 unsigned int *bpdist;
153 short *reference_pt1;
154 short *reference_pt2;
155 int circ;
156 int dangles;
157 unsigned int seq_length;
158
159 int ***E_F5;
160 int ***E_F3;
161 int ***E_C;
162 int ***E_M;
163 int ***E_M1;
164 int ***E_M2;
165
166 int **E_Fc;
167 int **E_FcH;
168 int **E_FcI;
169 int **E_FcM;
170
171 int **l_min_values;
172 int **l_max_values;
173 int *k_min_values;
174 int *k_max_values;
175
176 int **l_min_values_m;
177 int **l_max_values_m;
178 int *k_min_values_m;
179 int *k_max_values_m;
180
181 int **l_min_values_m1;
182 int **l_max_values_m1;
183 int *k_min_values_m1;
184 int *k_max_values_m1;
185
186 int **l_min_values_f;
187 int **l_max_values_f;
188 int *k_min_values_f;
189 int *k_max_values_f;
190
191 int **l_min_values_f3;
192 int **l_max_values_f3;
193 int *k_min_values_f3;
194 int *k_max_values_f3;
195
196 int **l_min_values_m2;
197 int **l_max_values_m2;
198 int *k_min_values_m2;
199 int *k_max_values_m2;
200
201 int *l_min_values_fc;
202 int *l_max_values_fc;
203 int k_min_values_fc;
204 int k_max_values_fc;
205
206 int *l_min_values_fcH;
207 int *l_max_values_fcH;
208 int k_min_values_fcH;
209 int k_max_values_fcH;
210
211 int *l_min_values_fcI;
212 int *l_max_values_fcI;
213 int k_min_values_fcI;
214 int k_max_values_fcI;
215
216 int *l_min_values_fcM;
217 int *l_max_values_fcM;
218 int k_min_values_fcM;
219 int k_max_values_fcM;
220
221 /* auxilary arrays for remaining set of coarse graining (k,l) > (k_max, l_max) */
222 int *E_F5_rem;
223 int *E_F3_rem;
224 int *E_C_rem;
225 int *E_M_rem;
226 int *E_M1_rem;
227 int *E_M2_rem;
228
229 int E_Fc_rem;
230 int E_FcH_rem;
231 int E_FcI_rem;
232 int E_FcM_rem;
233
234#ifdef COUNT_STATES
235 unsigned long ***N_F5;
236 unsigned long ***N_C;
237 unsigned long ***N_M;
238 unsigned long ***N_M1;
239#endif
240
241 vrna_fold_compound_t *compatibility;
243
262DEPRECATED(TwoDfold_vars *
263 get_TwoDfold_variables(const char *seq,
264 const char *structure1,
265 const char *structure2,
266 int circ),
267 "Use the new API and corresponding functions vrna_fold_compound_TwoD(), etc. instead");
268
279DEPRECATED(void
281 "Use the new API and vrna_fold_compound_free() instead");
282
308DEPRECATED(TwoDfold_solution *
310 int distance1,
311 int distance2),
312 "Use the new API and vrna_mfe_TwoD() instead");
313
335DEPRECATED(char *TwoDfold_backtrack_f5(unsigned int j,
336 int k,
337 int l,
338 TwoDfold_vars *vars),
339 "Use the new API and vrna_backtrack5_TwoD() instead");
340
344DEPRECATED(TwoDfold_solution **TwoDfold(TwoDfold_vars *our_variables,
345 int distance1,
346 int distance2),
347 "Use the new API and vrna_mfe_TwoD() instead");
348
349
350#endif
351
356#endif
Various data structures and pre-processor macros.
The Basic Fold Compound API.
The datastructure that contains temperature scaled energy parameters.
Definition basic.h:57
The most basic data structure required by many functions throughout the RNAlib.
Definition fold_compound.h:168
unsigned int maxD2
Maximum allowed base pair distance to second reference.
Definition 2Dfold.h:139
int * my_iindx
Index for moving in quadratic distancy dimensions.
Definition 2Dfold.h:145
unsigned int * mm2
Maximum matching matrix, reference struct 2 disallowed.
Definition 2Dfold.h:143
char * sequence
The input sequence
Definition 2Dfold.h:136
unsigned int * referenceBPs1
Matrix containing number of basepairs of reference structure1 in interval [i,j].
Definition 2Dfold.h:149
unsigned int maxD1
Maximum allowed base pair distance to first reference.
Definition 2Dfold.h:138
vrna_param_t * P
Precomputed energy parameters and model details.
Definition 2Dfold.h:133
float en
Free energy in kcal/mol.
Definition 2Dfold.h:57
unsigned int * mm1
Maximum matching matrix, reference struct 1 disallowed.
Definition 2Dfold.h:142
unsigned int * referenceBPs2
Matrix containing number of basepairs of reference structure2 in interval [i,j].
Definition 2Dfold.h:150
int l
Distance to second reference.
Definition 2Dfold.h:56
short * S1
The input sequences in numeric form.
Definition 2Dfold.h:137
int k
Distance to first reference.
Definition 2Dfold.h:55
char * s
MFE representative structure in dot-bracket notation.
Definition 2Dfold.h:58
int do_backtrack
Flag whether to do backtracing of the structure(s) or not.
Definition 2Dfold.h:134
char * ptype
Precomputed array of pair types.
Definition 2Dfold.h:135
unsigned int * bpdist
Matrix containing base pair distance of reference structure 1 and 2 on interval [i,...
Definition 2Dfold.h:151
void destroy_TwoDfold_variables(TwoDfold_vars *our_variables)
Destroy a TwoDfold_vars datastructure without memory loss.
char * vrna_backtrack5_TwoD(vrna_fold_compound_t *fc, int k, int l, unsigned int j)
Backtrack a minimum free energy structure from a 5' section of specified length.
vrna_sol_TwoD_t * vrna_mfe_TwoD(vrna_fold_compound_t *fc, int distance1, int distance2)
Compute MFE's and representative for distance partitioning.
char * TwoDfold_backtrack_f5(unsigned int j, int k, int l, TwoDfold_vars *vars)
Backtrack a minimum free energy structure from a 5' section of specified length.
TwoDfold_vars * get_TwoDfold_variables(const char *seq, const char *structure1, const char *structure2, int circ)
Get a structure of type TwoDfold_vars prefilled with current global settings.
TwoDfold_solution * TwoDfoldList(TwoDfold_vars *vars, int distance1, int distance2)
Compute MFE's and representative for distance partitioning.
Variables compound for 2Dfold MFE folding.
Definition 2Dfold.h:132
Solution element returned from vrna_mfe_TwoD()
Definition 2Dfold.h:54
int circ
backward compatibility variable.. this does not effect anything
Functions to deal with sets of energy parameters.