Hi everyone!
I've got stuck figuring out how to get printf work with my results.
When I use printf I get the following error:
Reading model section from city2.mod...
city2.mod:77: only numeric, symbolic, or logical expression allowed
Context: ...ansfer , <= 20 ; printf { i in PLANTSC } '...' , p_c [ i ] ;
Model processing error
Where p_c is defined as:
var p_c{i in PLANTSC} >=0;
and
set PLANTSC := VP21 VP22 VP23...
but when I look in my result file without the printf statement i get
No. Column name Activity Lower bound Upper bound
------ ------------ ------------- ------------- -------------
1 p_c[VP21] 26.667 0
2 p_c[VP22] 26.667 0
3 p_c[VP23] 26.667 0
4 p_c[VP24] 26.667 0
5 p_c[VP25] 26.667 0
6 p_c[VP26] 26.667 0
7 p_c[VP91] 24 0
8 p_c[VP92] 24 0
>From my point of view I should use
printf{i in PLANTSC} "res= %f", p_c[i]
to print the results, but get the silly error.
Best Regards
Mattias Berglund
_______________________________________________
Help-glpk mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/help-glpk