Problem with column generation

Good evening everyone,

I am currently trying to implement a mixed-integer programming model with column generation containing a master problem and a pricing problem.
These are my files which seem to be correct and have no errors ocurring when loaded seperately.
Master.dat (200 Bytes)
Master.mod (642 Bytes) (1.4 KB)
Pricing.dat (386 Bytes)
Pricing.mod (2.2 KB)

The run-data is:

# Master problem
model Master.mod;
data Master.dat;
option solver cplex;

# Pricing problem
model Pricing.mod;
data Pricing.dat;

# Initialisierung und Lösen des Master-Problems
solve Master;
display y;

# Holen der Dualvariablen pi[k] aus dem Master-Problem
let {k in BATCHES} pi[k] := Dual[Batchzuteilung[k]];

# Iterative Lösung des Pricing-Problems und Update des Master-Problems
param max_iter integer > 0 default 10; # maximale Anzahl der Iterationen
param tol default 0.01;               # Toleranz für die Lösung
param iter integer default 0;

repeat {
    # Lösen des Pricing-Problems
    solve Pricing;
    display x, t, C, z;

    # Update des Master-Problems basierend auf der Lösung des Pricing-Problems
    let {k in BATCHES, w in SCHEDULES} a[k, w] := if z[k] == 1 then 1 else 0;
    let {w in SCHEDULES} c[w] := reduzierte_Gesamtkosten;

    # Lösen des Master-Problems erneut
    solve Master;
    display y;

    # Holen der Dualvariablen pi[k] aus dem Master-Problem
    let {k in BATCHES} pi[k] := Dual[Batchzuteilung[k]];

    # Abbruchbedingung basierend auf Toleranz und Iterationen
    let iter := iter + 1;
    if iter >= max_iter then {
        print "Maximale Anzahl der Iterationen erreicht.";
    if abs(reduzierte_Gesamtkosten) < tol then {
        print "Lösung innerhalb der Toleranz erreicht.";

# Anzeigen der endgültigen Lösung
display y, z, x, t, C;

However, when trying to load the run-file the following error occurs:, line 11 (offset 185):
	Master is not defined
context:  solve  >>> Master; <<<

Could you give me some pointers on why that is? Could the master and pricing files be wrong after all?
Many thanks in advance!

The “model” and “data” statements only tell AMPL to read the named files, such as Master.mod and Master.dat. Before you can execute “solve Master;”, you will need to also define “Master” as the name of an AMPL “problem”; you can do that by adding a statement like this:

problem Master:
   y, Gesamtkosten, Batchzuteilung, Maschine_Plan;

All of the master problem variables, objectives, and constraints must be listed in this statement. You can put this statement at the end of file Master.mod, or in your run-file after “model Master.mod;”.

Then you will also need to create an AMPL problem named “Pricing”, in the same way.

If you want CPLEX to be used as the solver for all solves, then put “option solver cplex;” at the beginning of the run-file. Also put at the beginning any other “option” statements that should apply to all solves.

To learn more about AMPL’s named problems, see Section 14.4 Alternating between models and Section 14.5 Named problems of the AMPL book.