Distance path matrix
Descriptor Category : topological
c++ entity: member
Description
A square symmetric matrix AxA whose off diagonal entries i, j is the counts
of all paths of any lenght m (1 <= m <= dij) that are included in the
shortest path from vertex vi to vertex vj. The diagonal entries
are cero. Each entry of the distance path matrix is calculated from the
distance matrix as: Dpij =
(dij^2 + dij) / 2.
The property accessor selector is distance_path_matrixS
Prototype
Where defined
morpho/cdl/descriptors/properties/desc_mol_properties.hpp
For the property, and
morpho/cdl/descriptors/properties/desc_mol_props_selectors.hpp
For the property selector
Namespace
morpho::cdl
Inherits from
Arguments
Example
// suppose you're streaming a mol format from the stdin:
// and you want to get a const reference to the matrix:
typedef desc_molecular_properties<> desc_mol_props_t;
typedef boost::property<mol_propsS, molecular_properties<>,
boost::property<descriptors_mol_propsS, desc_mol_props_t> > descr_props_t;
typedef molecule<double,descr_props_t> M;
morpho::cdl::juice<M> j;
morpho::cdl::get_juice_from_stream(std::cin, j, 0, sdf_formatT());
M mol(j);
const MolProperty<distance_path_matrixS,M>& LM = MolProperty<distance_path_matrixS,M>::get(mol);
for (int i=0; i<LM.size1(); ++i) {
for (int j=0; j<LM.size2(); ++j) {
std::cout << LM(i,j) << '\t';
}
std::cout << '\n';
}
Related Items
hyper_distance_path_index
References
- Todeschini, R.; Consonni, V. "Handbook of Molecular Descriptors". Wiley-VCH,
Methods and Principles in Medicinal Chemistry. Volume 11. 2000.
Copyright (c) Vladimir Josef Sykora and Morphochem AG 2003