home *** CD-ROM | disk | FTP | other *** search
/ Celestin Apprentice 7 / Apprentice-Release7.iso / Source Code / C ++ / Applications / TimGA 1.2.1 / .h / MyStructs.h < prev    next >
Encoding:
Text File  |  1997-07-16  |  1.4 KB  |  71 lines  |  [TEXT/CWIE]

  1. // ===========================================================================
  2. //    MyStructs.h        ©1995-97 Timo Eloranta                    All rights reserved.
  3. // ===========================================================================
  4.  
  5. #pragma once
  6.  
  7. #include <PP_Types.h>
  8. #include <iterator.h>    // MSL
  9.  
  10. enum    EIterState {
  11.     iter_NoGraph,
  12.     iter_ReadyToGo,
  13.     iter_Running,
  14.     iter_Paused,
  15.     iter_Walking,
  16.     iter_Finished
  17. };
  18.  
  19. struct    SGraphSize {
  20.     Int16    nodes,
  21.             edges;
  22. };
  23.  
  24. struct    SNodePair {
  25.     Int16    nodeNbr1,
  26.             nodeNbr2;
  27. };
  28.  
  29. null_template
  30. struct iterator_trait <const SNodePair*> {
  31.     typedef ptrdiff_t                    distance_type;
  32.     typedef const SNodePair              value_type;
  33.     typedef random_access_iterator_tag   iterator_category;
  34. };
  35.  
  36. struct    STermination {
  37.     Int32    maxGenTotal,
  38.             maxGenNoChange,
  39.             maxTimeTotal,
  40.             maxTimeNoChange;
  41.     Boolean    stopMaxGenTotal,
  42.             stopMaxGenNoChange,
  43.             stopMaxTimeTotal,
  44.             stopMaxTimeNoChange,
  45.             stopNoCrossings;
  46. };
  47.  
  48. struct    SSelection {
  49.     Int16    step,        // A parameter used in linear normalization
  50.             min;        // A parameter used in linear normalization
  51.     Boolean autom,        // Should the selection step be calculated by the program?
  52.             elitism;    // Should the selection process be elitistic?
  53. };
  54.  
  55. struct    SGeneral {
  56.     Int16    sizeGrid,
  57.             sizePop,
  58.             spendTime;
  59. };
  60.  
  61. struct    SEvaluation {
  62.     Boolean crossingsRule;
  63.     Int16    multip1,
  64.             multip2,
  65.             multip3,
  66.             multip4,
  67.             multip5,
  68.             multip6,
  69.             multip7;
  70. };
  71.