Ignore:
Timestamp:
Nov 2, 2009, 12:50:57 PM (16 years ago)
Author:
Frederik Heber <heber@…>
Children:
8bc524
Parents:
245826
Message:

Small changes.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • molecuilder/src/molecule.hpp

    r245826 rdf0520  
    8383  public:
    8484    double cell_size[6];//!< cell size
    85     periodentafel *elemente; //!< periodic table with each element
     85    const periodentafel * const elemente; //!< periodic table with each element
    8686    atom *start;        //!< start of atom list
    8787    atom *end;          //!< end of atom list
     
    9393    int ElementCount;       //!< how many unique elements are therein
    9494    int ElementsInMolecule[MAX_ELEMENTS]; //!< list whether element (sorted by atomic number) is alread present or not
    95     int NoNonHydrogen;  //!< number of non-hydrogen atoms in molecule
    96     int NoNonBonds;     //!< number of non-hydrogen bonds in molecule
    97     int NoCyclicBonds;  //!< number of cyclic bonds in molecule, by DepthFirstSearchAnalysis()
     95    mutable int NoNonHydrogen;  //!< number of non-hydrogen atoms in molecule
     96    mutable int NoNonBonds;     //!< number of non-hydrogen bonds in molecule
     97    mutable int NoCyclicBonds;  //!< number of cyclic bonds in molecule, by DepthFirstSearchAnalysis()
    9898    double BondDistance;  //!< typical bond distance used in CreateAdjacencyList() and furtheron
    9999    bool ActiveFlag;    //!< in a MoleculeListClass used to discern active from inactive molecules
     
    102102    int IndexNr;        //!< index of molecule in a MoleculeListClass
    103103
    104   molecule(periodentafel *teil);
     104  molecule(const periodentafel * const teil);
    105105  virtual ~molecule();
    106106
     
    241241  void CreateAdjacencyListFromDbondFile(ofstream *out, ifstream *output);
    242242  void CreateAdjacencyList(ofstream *out, double bonddistance, bool IsAngstroem, void (BondGraph::*f)(BondedParticle * const , BondedParticle * const , double &, double &, bool), BondGraph *BG = NULL);
    243   int CorrectBondDegree(ofstream *out);
    244   void OutputBondsList(ofstream *out);
    245   void CyclicBondAnalysis();
    246   void OutputGraphInfoPerAtom(ofstream *out);
    247   void OutputGraphInfoPerBond(ofstream *out);
     243  int CorrectBondDegree(ofstream *out) const;
     244  void OutputBondsList(ofstream *out) const;
     245  void CyclicBondAnalysis() const;
     246  void OutputGraphInfoPerAtom(ofstream *out) const;
     247  void OutputGraphInfoPerBond(ofstream *out) const;
    248248
    249249
    250250  // Graph analysis
    251   MoleculeLeafClass * DepthFirstSearchAnalysis(ofstream *out, class StackClass<bond *> *&BackEdgeStack);
    252   void CyclicStructureAnalysis(ofstream *out, class StackClass<bond *> *BackEdgeStack, int *&MinimumRingSize);
    253   bool PickLocalBackEdges(ofstream *out, atom **ListOfLocalAtoms, class StackClass<bond *> *&ReferenceStack, class StackClass<bond *> *&LocalStack);
    254   bond * FindNextUnused(atom *vertex);
    255   void SetNextComponentNumber(atom *vertex, int nr);
    256   void InitComponentNumbers();
    257   void ResetAllBondsToUnused();
     251  MoleculeLeafClass * DepthFirstSearchAnalysis(ofstream *out, class StackClass<bond *> *&BackEdgeStack) const;
     252  void CyclicStructureAnalysis(ofstream *out, class StackClass<bond *> *BackEdgeStack, int *&MinimumRingSize) const;
     253  bool PickLocalBackEdges(ofstream *out, atom **ListOfLocalAtoms, class StackClass<bond *> *&ReferenceStack, class StackClass<bond *> *&LocalStack) const;
     254  bond * FindNextUnused(atom *vertex) const;
     255  void SetNextComponentNumber(atom *vertex, int nr) const;
     256  void ResetAllBondsToUnused() const;
    258257  int CountCyclicBonds(ofstream *out);
    259258  bool CheckForConnectedSubgraph(ofstream *out, KeySet *Fragment);
    260   string GetColor(enum Shading color);
     259  string GetColor(enum Shading color) const;
    261260  bond * CopyBond(atom *left, atom *right, bond *CopyBond);
    262261
     
    351350
    352351  bool AddLeaf(molecule *ptr, MoleculeLeafClass *Previous);
    353   bool FillBondStructureFromReference(ofstream *out, molecule *reference, int &FragmentCounter, atom ***&ListOfLocalAtoms, bool FreeList = false);
     352  bool FillBondStructureFromReference(ofstream *out, const molecule * const reference, int &FragmentCounter, atom ***&ListOfLocalAtoms, bool FreeList = false);
    354353  bool FillRootStackForSubgraphs(ofstream *out, KeyStack *&RootStack, bool *AtomMask, int &FragmentCounter);
    355354  bool AssignKeySetsToFragment(ofstream *out, molecule *reference, Graph *KeySetList, atom ***&ListOfLocalAtoms, Graph **&FragmentList, int &FragmentCounter, bool FreeList = false);
Note: See TracChangeset for help on using the changeset viewer.