| 1 |
#ifndef BALL_STRUCTURE_BONDORDERS_KGREEDYBONDORDERSTRATEGY_H |
| 2 |
#define BALL_STRUCTURE_BONDORDERS_KGREEDYBONDORDERSTRATEGY_H |
| 3 |
|
| 4 |
#ifndef BALL_STRUCTURE_BONDORDERS_BONDORDERASSIGNMENTSTRATEGY_H |
| 5 |
# include <BALL/STRUCTURE/BONDORDERS/bondOrderAssignmentStrategy.h> |
| 6 |
#endif |
| 7 |
|
| 8 |
#ifndef BALL_STRUCTURE_BONDORDERS_BONDORDERASSIGNMENT_H |
| 9 |
# include <BALL/STRUCTURE/BONDORDERS/bondOrderAssignment.h> |
| 10 |
#endif |
| 11 |
|
| 12 |
#ifndef BALL_STRUCTURE_BONDORDERS_ASTARBONDORDERSTRATEGY_H |
| 13 |
# include <BALL/STRUCTURE/BONDORDERS/AStarBondOrderStrategy.h> |
| 14 |
#endif |
| 15 |
|
| 16 |
namespace BALL |
| 17 |
{ |
| 18 |
|
| 19 |
|
| 20 |
|
| 21 |
|
| 22 |
|
| 23 |
|
| 24 |
|
| 25 |
|
| 26 |
|
| 27 |
class KGreedyBondOrderStrategy |
| 28 |
: public AStarBondOrderStrategy |
| 29 |
{ |
| 30 |
public: |
| 31 |
|
| 32 |
|
| 33 |
|
| 34 |
|
| 35 |
struct BALL_EXPORT Option |
| 36 |
{ |
| 37 |
|
| 38 |
|
| 39 |
|
| 40 |
|
| 41 |
|
| 42 |
|
| 43 |
static const char* GREEDY_K_SIZE; |
| 44 |
}; |
| 45 |
|
| 46 |
struct BALL_EXPORT Default |
| 47 |
{ |
| 48 |
static const int GREEDY_K_SIZE; |
| 49 |
}; |
| 50 |
|
| 51 |
|
| 52 |
KGreedyBondOrderStrategy(AssignBondOrderProcessor* parent); |
| 53 |
virtual ~KGreedyBondOrderStrategy(); |
| 54 |
|
| 55 |
virtual void clear(); |
| 56 |
virtual void init(); |
| 57 |
|
| 58 |
virtual bool readOptions(const Options& options); |
| 59 |
virtual void setDefaultOptions(); |
| 60 |
|
| 61 |
virtual boost::shared_ptr<BondOrderAssignment> computeNextSolution(); |
| 62 |
|
| 63 |
protected: |
| 64 |
|
| 65 |
float greedy_atom_type_penalty_; |
| 66 |
float greedy_bond_length_penalty_; |
| 67 |
|
| 68 |
Size greedy_k_; |
| 69 |
|
| 70 |
vector<PartialBondOrderAssignment> greedy_set_; |
| 71 |
|
| 72 |
Position current_solution_; |
| 73 |
|
| 74 |
int greedy_node_expansions_; |
| 75 |
}; |
| 76 |
} |
| 77 |
|
| 78 |
#endif |