Ignore:
Timestamp:
Nov 10, 2009, 8:59:00 PM (16 years ago)
Author:
Frederik Heber <heber@…>
Children:
418117a
Parents:
2fbbc96
Message:

Attempt to fix tesselation for case 1_2-dimethylbenzene.

  • The issue is still the strongly degenerated end of the molecule, that is very flat.
  • new function: Tesselation::HasOtherBaselineBetterCandidate() - checks whether for the two other baselines of a proposed triangle there isn't an even better candidate
  • Tesselation::FindNextSuitableTriangle() uses the above function.
  • FindNonConvexBorder() - instead of jumping to end() if a new line was attempted, we jump to the beginning but only if new line was created succesfully.
  • DoSingleStepOutput reactived for this debugging.
  • Where the newly installed tesselations did only fail for this molecule, now they fail for all and some segfault. Only this runs through cleanly.

Signed-off-by: Frederik Heber <heber@…>

File:
1 edited

Legend:

Unmodified
Added
Removed
  • molecuilder/src/tesselationhelpers.cpp

    r2fbbc96 r09d3b8  
    461461  for (int i=0;i<3;i++)
    462462    for (int j=i+1; j<3; j++) {
    463       if (nodes[i]->lines.find(nodes[j]->node->nr) != nodes[i]->lines.end()) {  // there already is a line
     463      if (nodes[i] == NULL) {
     464        Log() << Verbose(1) << "Node nr. " << i << " is not yet present." << endl;
     465        result = true;
     466      } else if (nodes[i]->lines.find(nodes[j]->node->nr) != nodes[i]->lines.end()) {  // there already is a line
    464467        LineMap::const_iterator FindLine;
    465468        pair<LineMap::const_iterator,LineMap::const_iterator> FindPair;
Note: See TracChangeset for help on using the changeset viewer.