![]() |
Bsoft 2.1.4
Bernard's software package
|
Library routines used for analyzing the views of components in models. More...
#include "rwimg.h"
#include "model_views.h"
#include "model_util.h"
#include "model_neighbors.h"
#include "mol_compare.h"
#include "Matrix3.h"
#include "linked_list.h"
#include "utilities.h"
Functions | |
list< View2< float > > | views_from_model (Bmodel *model) |
Returns a list of component views. More... | |
list< View2< float > > | views_from_models (Bmodel *model) |
Returns a list of component views. More... | |
long | model_set_views (Bmodel *model, View2< float > view) |
Sets views. More... | |
long | model_invert_views (Bmodel *model) |
Invert views. More... | |
long | model_find_views (Bmodel *model, Bstring &reffile, Bstring ¶mfile) |
Finds the molecule views with respect to a reference. More... | |
Vector3< double > | component_normal (Bcomponent *comp) |
View2< float > | component_view (Bcomponent *comp) |
long | model_calculate_views (Bmodel *model, Bstring &mode) |
Calculates the views associated with each component. More... | |
long | model_calculate_local_views (Bmodel *model) |
Calculates the views associated with each component based on neighbors. More... | |
long | model_view_directions (Bmodel *model, int bin_width, int ref_flag) |
Analyzes view directions in a model. More... | |
int | component_hand (Bstring s) |
Determines the hand of a component. More... | |
Variables | |
int | verbose |
Library routines used for analyzing the views of components in models.
int component_hand | ( | Bstring | s | ) |
Determines the hand of a component.
&s | string with encoded order. |
Requirement: The string must be either a 3 or 6-digit code. The reverse of the string is generated and the canonical version compared to the canonical version of the original string. The handedness is then returned as the sign of the comparison. The reverse of the 6-digit code is defined as reversing the first and last 3 digits separately.
Vector3< double > component_normal | ( | Bcomponent * | comp | ) |
View2< float > component_view | ( | Bcomponent * | comp | ) |
long model_calculate_local_views | ( | Bmodel * | model | ) |
Calculates the views associated with each component based on neighbors.
*model | model structure (views modified). |
The view for a vertex is calculated from the vertex vector and the first link. The vertex vector points away from the origin and is calculated as follows: Angles defined for the vertex: vv = normalized sum of the cross products for each pair of links constituting an angle Angles not defined: vv = component coordinates - origin The origin is defined as the current zero coordinates, the center-of-mass, or from the map.
Calculates the views associated with each component.
*model | model structure (views modified). |
&mode | none=current, com, map, local. |
The view for a vertex is calculated from the vertex vector and the first link. The vertex vector points away from the origin and is calculated as follows: Angles defined for the vertex: vv = normalized sum of the cross products for each pair of links constituting an angle Angles not defined: vv = component coordinates - origin The origin is defined as the current zero coordinates, the center-of-mass, or from the map.
Finds the molecule views with respect to a reference.
*model | model parameters. |
&reffile | reference molecule file name. |
¶mfile | atomic parameter file. |
The positioning of each molecule is based on the center of mass of the reference.
long model_invert_views | ( | Bmodel * | model | ) |
Invert views.
*model | model parameters. |
It calculates the inverse of each component view. Only the first model is processed.
Sets views.
*model | model parameters. |
view | set view. |
Each component view is set tot the given view.
long model_view_directions | ( | Bmodel * | model, |
int | bin_width, | ||
int | ref_flag | ||
) |
Analyzes view directions in a model.
*model | model parameters. |
bin_width | bin width in degrees. |
ref_flag | flag to select the reference vector (0=z-axis, 1=component location) |
The angle between the component view and a reference vector is calculated. A histogram of the angles is constructed and reported. The reference vector can be the z-axis, or the component location.
Returns a list of component views.
*model | model parameters. |
Only the first model is processed.
Returns a list of component views.
*model | model parameters. |
All models are processed.
|
extern |