Both of those error messages mean that <'34944801',SI> is not in the index set for v but you are trying to access v['34944801',SI]. The first error message mentions line 103, which you did not show but should correspond to the MIN statement where v is used. This error arises because the sum is over all <r,c,a> in REMI_CLASS_AOP, which you have not restricted to satisfy your condition on p. To avoid this error, you can explicitly check membership in REMI_CLASS in the MIN statement:
min f = abs(sum {<r,c,a> in REMI_CLASS_AOP: <r,c> in REMI_CLASS} (if char(c,1) = 'M' then 1 else -1)*v[r,c]*p[r,c,a]*X[r,c,a]);
To avoid the second error, you can make a similar change to the CREATE DATA statement:
create data SolData1 from [r c a]={<r,c,a> in REMI_CLASS_AOP: <r,c> in REMI_CLASS} v[r,c] p X;
To restrict v < 100, you can modify the READ DATA statement:
read data sas.VData(where=(v < 100)) into REMI_CLASS=[remi class] v;
The subsequent INTER SETOF does not then need modification.
... View more