| [246e13] | 1 | /*
|
|---|
| 2 | * Fragmentation.hpp
|
|---|
| 3 | *
|
|---|
| 4 | * Created on: Oct 18, 2011
|
|---|
| 5 | * Author: heber
|
|---|
| 6 | */
|
|---|
| 7 |
|
|---|
| 8 | #ifndef FRAGMENTATION_HPP_
|
|---|
| 9 | #define FRAGMENTATION_HPP_
|
|---|
| 10 |
|
|---|
| 11 |
|
|---|
| 12 | #ifdef HAVE_CONFIG_H
|
|---|
| 13 | #include <config.h>
|
|---|
| 14 | #endif
|
|---|
| 15 |
|
|---|
| 16 | #include "Graph/DepthFirstSearchAnalysis.hpp"
|
|---|
| 17 |
|
|---|
| [07a47e] | 18 | #include "Fragmentation/HydrogenSaturation_enum.hpp"
|
|---|
| [ba94c5] | 19 | #include "Fragmentation/fragmentation_helpers.hpp"
|
|---|
| [d4d7a1] | 20 | #include "types.hpp"
|
|---|
| [dadc74] | 21 |
|
|---|
| [d4d7a1] | 22 | #include <map>
|
|---|
| [99b0dc] | 23 | #include <string>
|
|---|
| 24 | #include <vector>
|
|---|
| 25 |
|
|---|
| [246e13] | 26 | class atom;
|
|---|
| [f96874] | 27 | class AtomMask_t;
|
|---|
| [dadc74] | 28 | class Graph;
|
|---|
| [f0674a] | 29 | class KeySet;
|
|---|
| [246e13] | 30 | class molecule;
|
|---|
| 31 |
|
|---|
| 32 | class Fragmentation
|
|---|
| 33 | {
|
|---|
| 34 | public:
|
|---|
| [07a47e] | 35 | Fragmentation(molecule *_mol, const enum HydrogenSaturation _saturation);
|
|---|
| [246e13] | 36 | ~Fragmentation();
|
|---|
| 37 |
|
|---|
| [2a0eb0] | 38 | int FragmentMolecule(const std::vector<atomId_t> &atomids, int Order, std::string prefix, DepthFirstSearchAnalysis &DFS);
|
|---|
| [99b0dc] | 39 |
|
|---|
| 40 | void setOutputTypes(const std::vector<std::string> &types);
|
|---|
| [246e13] | 41 |
|
|---|
| 42 | private:
|
|---|
| 43 |
|
|---|
| 44 | void FragmentBOSSANOVA(molecule *mol, Graph *&FragmentList, KeyStack &RootStack);
|
|---|
| 45 | int GuesstimateFragmentCount(int order);
|
|---|
| 46 |
|
|---|
| [d4d7a1] | 47 | bool CreateMappingLabelsToConfigSequence(std::map<atomId_t, int> &SortIndex);
|
|---|
| [246e13] | 48 |
|
|---|
| 49 | // order at site
|
|---|
| [f96874] | 50 | bool CheckOrderAtSite(AtomMask_t &AtomMask, Graph *GlobalKeySetList, int Order, std::string path, bool LoopDoneAlready);
|
|---|
| [246e13] | 51 | bool StoreOrderAtSiteFile(std::string &path);
|
|---|
| [2a0eb0] | 52 | bool ParseOrderAtSiteFromFile(const std::vector<atomId_t> &atomids, std::string &path);
|
|---|
| [246e13] | 53 |
|
|---|
| 54 | // storing fragments
|
|---|
| 55 | molecule * StoreFragmentFromKeySet(KeySet &Leaflet, bool IsAngstroem);
|
|---|
| [f7307f] | 56 | int StoreFragmentFromKeySet_Init(molecule *mol, molecule *Leaf, KeySet &Leaflet, ListOfLocalAtoms_t &SonList);
|
|---|
| 57 | void CreateInducedSubgraphOfFragment(molecule *mol, molecule *Leaf, ListOfLocalAtoms_t &SonList, bool IsAngstroem);
|
|---|
| [246e13] | 58 |
|
|---|
| 59 | private:
|
|---|
| [99b0dc] | 60 | //!> pointer to molecule that is fragmented
|
|---|
| [246e13] | 61 | molecule *mol;
|
|---|
| [07a47e] | 62 | //!> whether to saturate dangling bonds with hydrogen and hence treat hydrogen special
|
|---|
| 63 | const enum HydrogenSaturation saturation;
|
|---|
| [99b0dc] | 64 | //!> list of parser types for which a configuration file per fragment is stored
|
|---|
| 65 | std::vector<std::string> typelist;
|
|---|
| [246e13] | 66 | };
|
|---|
| 67 |
|
|---|
| 68 |
|
|---|
| 69 | #endif /* FRAGMENTATION_HPP_ */
|
|---|