IMP logo
IMP Reference Guide  develop.7482b7c7af, 2026/12/05
The Integrative Modeling Platform
DecayPairContainerOptimizerState.h
Go to the documentation of this file.
1/**
2 * \file IMP/misc/DecayPairContainerOptimizerState.h
3 * \brief A pair container with a decaying list of pairs.
4 *
5 * Copyright 2007-2022 IMP Inventors. All rights reserved.
6 */
7
8#ifndef IMPMISC_DECAY_PAIR_CONTAINER_OPTIMIZER_STATE_H
9#define IMPMISC_DECAY_PAIR_CONTAINER_OPTIMIZER_STATE_H
10
11#include <IMP/misc/misc_config.h>
12#include <IMP/OptimizerState.h>
13#include <IMP/PairContainer.h>
14#include <IMP/PairContainer.h>
15#include <IMP/OptimizerState.h>
17#include <IMP/PairPredicate.h>
18#include <IMP/PairContainer.h>
19#include <IMP/Pointer.h>
20
21IMPMISC_BEGIN_NAMESPACE
22
23//! Maintain a pair container with a decaying list of pairs.
24/** The pair container passed to the constructor provides an initial
25 list of pairs. Periodically (see the set_period() method), the
26 predicate is applied to all the remaining pairs and ones for which
27 it evaluates to 0 are removed.
28 */
29class IMPMISCEXPORT DecayPairContainerOptimizerState
30 : public OptimizerState {
34
35 public:
36 DecayPairContainerOptimizerState(Model *m,
37 PairPredicate *pred, const ParticleIndexPairs &initial_list,
38 std::string name = "DecayPairContainerOptimizerState%1%");
39
40 PairContainer *get_output_container() const { return output_; }
41 virtual void do_update(unsigned int call_num) override;
42 IMP_OBJECT_METHODS(DecayPairContainerOptimizerState);
43};
44
45IMPMISC_END_NAMESPACE
46
47#endif /* IMPMISC_DECAY_PAIR_CONTAINER_OPTIMIZER_STATE_H */
Store a list of ParticlePairsTemp.
Shared optimizer state.
A container for Pairs.
Define PairPredicate.
A nullptr-initialized pointer to an IMP Object.
OptimizerState(Model *m, std::string name)
Constructor.
A shared container for Pairs.
Abstract predicate function.
virtual void do_update(unsigned int call_num) override
IMP::Vector< ParticleIndexPair, std::allocator< ParticleIndexPair > > ParticleIndexPairs
Definition base_types.h:208
#define IMP_OBJECT_METHODS(Name)
Define the basic things needed by any Object.
A smart pointer to a ref-counted Object that is a class member.
Definition Pointer.h:144
A smart pointer to a reference counted object.
Definition Pointer.h:88