chenqinghong
2024-05-07 3ec06a830367465068963156dcc1d8e522571c13
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
Quintiq file version 2.0
#parent: #root
StaticMethod GenerateMetalsBenchmarkRuns (
  LibOpt_BT_BenchmarkTrackingDataset ds
)
{
  TextBody:
  [*
    /*
    For creating an experiment with enlarged Metals benchmarks take the following steps: 
    
    1. Create extendible method CreateTrackingTablesMetals on object LibOpt_BT_BenchmarkTrackingDataset
    2. Extend it in LibMacroPlannerOptimizer and call Optimization::GenerateMetalsBenchmarkRuns( this ); 
    3. Call CreateTrackingTablesMetals from Test of object LibOpt_BT_BenchmarkTrackingDataset
    4. Make a single tracking table in the bt application with description 'start' , and put model settings OTSNoUnplanPriorToRun and OTSGenerateMetalsBenchmark. Customize the strategyname in opt settings
       and set ConvertMinMaxSafetyInDaysToQuantity to false
    5. execute the test method to create all tracking tables. Now these can be used to batch run the various benchmark created below (the current method)
    */
    
    
    start_tt := select( ds, TrackingTable, tt, tt.Description() = 'start' ); 
    
    for ( endproductstoadd := 1; endproductstoadd <= 250; endproductstoadd := endproductstoadd + 25 )
    {
      for ( intermediatetoadd := 1; intermediatetoadd <= 5; intermediatetoadd := intermediatetoadd + 1 )
      {
        for ( periodstoadd := 1; periodstoadd <= 50; periodstoadd := periodstoadd + 10 )  
        {
          addtriplotsize := true; 
          usertriplotsize := 100.0; 
          
          addptolotsize := true; 
          userptolotsize := 1000.0; 
          
          addptominqty := true; 
          userptominqty := 5000.0; 
          
          addinputlotsize := true;  
          userinputlotsize := 1000.0; 
          
          setlotcost := true; 
          
          setinventorymixbalancing := false; 
          
          addcapsmoothing := false;  
          smoothingdelta := 2.0; // 2% smoothing 
          
          addpostponement := false; 
          postponementnrperiods := 6; // parameter used for both horizon and max postponement
          
          name := 
          Optimization::GetBenchmarkName( endproductstoadd, 
                                          intermediatetoadd, 
                                          periodstoadd, 
                                          addtriplotsize, 
                                          usertriplotsize, 
                                          addptolotsize, 
                                          userptolotsize, 
                                          addptominqty, 
                                          userptominqty, 
                                          addinputlotsize, 
                                          userinputlotsize, 
                                          setlotcost, 
                                          setinventorymixbalancing, 
                                          addcapsmoothing, 
                                          smoothingdelta, 
                                          addpostponement, 
                                          postponementnrperiods );
            newtt := start_tt.Copy(); 
            newtt.Description( name ); 
        }
      }
    }
  *]
  InterfaceProperties { Accessibility: 'Module' }
}