I have a few more questions and suggestions.
Why do you initialize some of the variables to values outside their bounds?
The NLPC solver was retired (no longer documented or maintained) in SAS 9.3. You should instead use the NLP solver:
http://support.sas.com/documentation/cdl/en/ormpug/68156/HTML/default/viewer.htm#ormpug_nlpsolver_toc.htm
It is better to avoid using the absolute value function, which is non-differentiable. Instead, you can rewrite those statements as:
impvar deviation{d in drug, m in month}=(units[D,M]-calc_units[d,m])/calc_units[d,m];
constraint calc_units_dev{d in drug, m in month}: -0.1 <= deviation[d,m] <= 0.1;
For sum-of-squares objectives, it is sometimes better to introduce explicit variables so that you can express the objective as a sum of squares of the new variables, yielding a sparse (diagonal) Hessian:
var error_m_d {M IN MONTH, d in drug};
con error_con {M IN MONTH, d in drug}: error_m_d[m,d] = (units[D,M]-calc_units[d,m])/dailydose[d];
min error = sum{M IN MONTH, d in drug} error_m_d[m,d]**2;
... View more