|
Bsoft
2.1.0
Bernard's software package
|
Library routines used for model processing. More...
#include "model_util.h"#include "model_transform.h"#include "model_select.h"#include "model_links.h"#include "mol_transform.h"#include "mol_compare.h"#include "mol_util.h"#include "symmetry.h"#include "matrix_linear.h"#include "matrix_util.h"#include "Matrix3.h"#include "random_numbers.h"#include "linked_list.h"#include "utilities.h"Go to the source code of this file.
Functions | |
| long | models_process (Bmodel *model, long(modfunc)(Bmodel *)) |
| Process a list of models using the specified function. More... | |
| long | models_process (Bmodel *model, long i, long(modfunc)(Bmodel *, long)) |
| long | models_process (Bmodel *model, double d, long(modfunc)(Bmodel *, double)) |
| long | models_process (Bmodel *model, Bstring &str, long(modfunc)(Bmodel *, Bstring &str)) |
| long | model_list (Bmodel *model) |
| Lists models in table form. More... | |
| long | model_list_comp (Bmodel *model) |
| Lists models with component counts in table form. More... | |
| long | model_replace_components (Bmodel *model, Bmodel *modref) |
| Replaces all components in a model with reference components. More... | |
| long | model_merge (Bmodel *model) |
| Merges components from all models into one. More... | |
| long | model_number_ids (Bmodel *model) |
| Add a number to each model id. More... | |
| long | model_rename_components (Bmodel *model) |
| Rename components. More... | |
| double | model_mass (Bmodel *model) |
| Calculates the mass of a model from component masses. More... | |
| long | model_mass_all (Bmodel *model) |
| Calculates the masses of all the models in the list. More... | |
| Vector3< double > | model_center_of_mass_nu (Bmodel *model) |
| Calculates the center-of-mass of a model. More... | |
| Vector3< double > | model_center_of_mass (Bmodel *model) |
| double | model_gyration_radius (Bmodel *model) |
| Calculates the radius of gyration for a model. More... | |
| Vector3< double > | model_principal_axes (Bmodel *model, Vector3< double > *eigenvec) |
| Calculates the principal axes of a model. More... | |
| long | model_principal_axes (Bmodel *model) |
| long | model_radial_distribution (Bmodel *model, double interval) |
| Calculates the radial distribution function of a model. More... | |
| long | molgroup_write_into_grid (Bmolgroup *molgroup, Vector3< int > size, Vector3< double > min, double sampling, int *grid) |
| Bmolgroup * | model_assemble (Bmodel *model, Bstring ¶mfile, int separate) |
| Concatenates selected molecules into one group. More... | |
| Bmodel * | model_generate_com (Bmolgroup *molgroup) |
| Calculates the centers-of-mass of molecule group components and generates a new model. More... | |
| long | model_update_centers_of_mass (Bmodel *model, Bmolgroup *molgroup) |
| Updates the centers-of-mass of molecule group components. More... | |
| long | model_average_components (Bmodel *model, int number) |
| Averages sequential components. More... | |
| Bcomponent ** | component_get_array (Bmodel *model, long &n) |
| Generates an array of pointers to component structures. More... | |
| Vector3< double > | component_plane (Bcomponent **comparray, double &offset) |
| Calculates a plane through an array of components. More... | |
Variables | |
| int | verbose |
Library routines used for model processing.
Definition in file model_util.cpp.
| Bcomponent** component_get_array | ( | Bmodel * | model, |
| long & | n | ||
| ) |
Generates an array of pointers to component structures.
| *model | model structure. |
| &n | pointer to number of comps found. |
Definition at line 903 of file model_util.cpp.
| Vector3<double> component_plane | ( | Bcomponent ** | comparray, |
| double & | offset | ||
| ) |
Calculates a plane through an array of components.
| **comparray | array of components. |
| &offset | offset from plane. |
A plane is fit through the polygon vertices and the normal calculated from:
n•p = d
where n is the normal vector, p is a point in the plane, and d is the offset.
The polygon planarity is defined as the root-mean-square-deviation from
the fitted plane.
Definition at line 933 of file model_util.cpp.
Concatenates selected molecules into one group.
| *model | model parameters. |
| ¶mfile | atomic parameter file. |
| separate | flag to generate separate molecule groups. |
Only the first model in the linked list is processed.
Definition at line 688 of file model_util.cpp.
| long model_average_components | ( | Bmodel * | model, |
| int | number | ||
| ) |
Averages sequential components.
| *model | model structure to be modified. |
| number | number of components to average. |
Only the first component in each set with modified coordinates is kept.
Definition at line 866 of file model_util.cpp.
Definition at line 475 of file model_util.cpp.
Calculates the center-of-mass of a model.
| *model | model parameters. |
Only the first model in the list is processed.
Definition at line 469 of file model_util.cpp.
Calculates the centers-of-mass of molecule group components and generates a new model.
| *molgroup | list of molecule groups. |
Each molecule is assumed to be a component.
Definition at line 790 of file model_util.cpp.
| double model_gyration_radius | ( | Bmodel * | model | ) |
Calculates the radius of gyration for a model.
| *model | model parameters. |
Only the first model in the list is processed.
Definition at line 503 of file model_util.cpp.
| long model_list | ( | Bmodel * | model | ) |
Lists models in table form.
| *model | model parameters. |
Definition at line 127 of file model_util.cpp.
| long model_list_comp | ( | Bmodel * | model | ) |
Lists models with component counts in table form.
| *model | model parameters. |
Definition at line 158 of file model_util.cpp.
| double model_mass | ( | Bmodel * | model | ) |
Calculates the mass of a model from component masses.
| *model | model parameters. |
The component type masses must be provided. Only the first model in the list is processed.
Definition at line 416 of file model_util.cpp.
| long model_mass_all | ( | Bmodel * | model | ) |
Calculates the masses of all the models in the list.
| *model | linked list of model parameters. |
The component type masses must be provided.
Definition at line 445 of file model_util.cpp.
| long model_merge | ( | Bmodel * | model | ) |
Merges components from all models into one.
| *model | model parameters. |
Definition at line 299 of file model_util.cpp.
| long model_number_ids | ( | Bmodel * | model | ) |
Add a number to each model id.
| *model | model parameters. |
The intention is to give unique id's to models.
Definition at line 356 of file model_util.cpp.
| long model_principal_axes | ( | Bmodel * | model | ) |
Definition at line 574 of file model_util.cpp.
Calculates the principal axes of a model.
| *model | model structure. |
| *eigenvec | eigen vectors (can be NULL). |
Only the first model in the list is processed.
Definition at line 534 of file model_util.cpp.
| long model_radial_distribution | ( | Bmodel * | model, |
| double | interval | ||
| ) |
Calculates the radial distribution function of a model.
| *model | model structure. |
| interval | interval between bins. |
Only the first model in the list is processed.
Definition at line 605 of file model_util.cpp.
| long model_rename_components | ( | Bmodel * | model | ) |
Rename components.
| *model | model parameters. |
The number of links to a component determines its new name. Only the first model is processed.
Definition at line 378 of file model_util.cpp.
Replaces all components in a model with reference components.
| *model | model structure to be modified. |
| *modref | reference model. |
Only the first model in the reference is used. All models will have identical sets of components.
Definition at line 227 of file model_util.cpp.
Updates the centers-of-mass of molecule group components.
| *model | model parameters. |
| *molgroup | list of molecule groups. |
The identifiers of the molecule groups must correspond to the component identifiers.
Definition at line 839 of file model_util.cpp.
Definition at line 108 of file model_util.cpp.
Definition at line 84 of file model_util.cpp.
Definition at line 60 of file model_util.cpp.
Process a list of models using the specified function.
| *model | list of models. |
| modfunc | function to be called. |
The function called process only one model.
Definition at line 36 of file model_util.cpp.
| long molgroup_write_into_grid | ( | Bmolgroup * | molgroup, |
| Vector3< int > | size, | ||
| Vector3< double > | min, | ||
| double | sampling, | ||
| int * | grid | ||
| ) |
Definition at line 644 of file model_util.cpp.
|
extern |