RNAlib-2.4.8
neighbor.h
Go to the documentation of this file.
1 #ifndef VIENNA_RNA_PACKAGE_NEIGHBOR_H
2 #define VIENNA_RNA_PACKAGE_NEIGHBOR_H
3 
111 typedef struct vrna_move_s vrna_move_t;
112 
114 
119 #define VRNA_MOVESET_INSERTION 4
120 
125 #define VRNA_MOVESET_DELETION 8
126 
131 #define VRNA_MOVESET_SHIFT 16
132 
136 #define VRNA_MOVESET_NO_LP 32
137 
142 #define VRNA_MOVESET_DEFAULT (VRNA_MOVESET_INSERTION | VRNA_MOVESET_DELETION)
143 
144 
156 struct vrna_move_s {
157  int pos_5;
158  int pos_3;
161 };
162 
163 vrna_move_t vrna_move_init(int pos_5, int pos_3);
164 
168 void vrna_move_list_free(vrna_move_t *moves);
169 
176 void
177 vrna_move_apply(short *pt,
178  const vrna_move_t *m);
179 
180 
181 void
182 vrna_move_apply_to_db(char *structure,
183  const short *pt,
184  const vrna_move_t *m);
185 
186 
198 void
199 vrna_loopidx_update(int *loopidx,
200  const short *pt,
201  int length,
202  const vrna_move_t *m);
203 
204 
220 vrna_move_t *
222  const short *pt,
223  unsigned int options);
224 
225 
247 vrna_move_t *
249  const vrna_move_t *curr_move,
250  const short *prev_pt,
251  const vrna_move_t *prev_neighbors,
252  int size_prev_neighbors,
253  int *size_neighbors,
254  unsigned int options);
255 
256 
260 #endif /* VIENNA_RNA_PACKAGE_NEIGHBOR_H */
vrna_move_t * vrna_neighbors(vrna_fold_compound_t *vc, const short *pt, unsigned int options)
Generate neighbors of a secondary structure.
void vrna_loopidx_update(int *loopidx, const short *pt, int length, const vrna_move_t *m)
Alters the loopIndices array that was constructed with vrna_loopidx_from_ptable().
The most basic data structure required by many functions throughout the RNAlib.
Definition: fold_compound.h:132
int pos_5
Definition: neighbor.h:157
void vrna_move_apply(short *pt, const vrna_move_t *m)
Apply a particular move / transition to a secondary structure, i.e. transform a structure.
Various data structures and pre-processor macros.
vrna_move_t * vrna_neighbors_successive(const vrna_fold_compound_t *vc, const vrna_move_t *curr_move, const short *prev_pt, const vrna_move_t *prev_neighbors, int size_prev_neighbors, int *size_neighbors, unsigned int options)
Generate neighbors of a secondary structure (the fast way)
void vrna_move_list_free(vrna_move_t *moves)
An atomic representation of the transition / move from one structure to its neighbor.
Definition: neighbor.h:156
vrna_move_t * next
Definition: neighbor.h:159
int pos_3
Definition: neighbor.h:158