/** * \file restraints_utils.h * \brief restraints setup utilities * * Copyright 2007-2010 IMP Inventors. All rights reserved. * */ #ifndef IMPMULTIFIT_RESTRAINTS_UTILS_H #define IMPMULTIFIT_RESTRAINTS_UTILS_H #include #include #include #include #include #include "multifit_config.h" #include "FittingSolutionRecord.h" IMPMULTIFIT_BEGIN_NAMESPACE //! Generates filenames for precalculated restraint scores class IMPMULTIFITEXPORT PairsValues { public: PairsValues(Int first_len,Int second_len) { first_len_=first_len; second_len_=second_len; values_.insert(values_.end(),first_len_*second_len_,0.); } inline Float get_value(Int first_ind, Int second_ind) const { Int ind = first_ind*second_len_+second_ind; IMP_INTERNAL_CHECK(static_cast(ind)(ind)