Dear Renger,
Could you show me how to test the infeasible to give the same results as you (code, step, etc.) or give me your file with code for check?
Thanks a lot!
Cheers,
Nguyen Xuan.
Help me in CES, CET estimate, please
Re: Help me in CES, CET estimate, please
Hi
If you use conopt you get a warning that your data is badly scaled:
Here it says that a better starting initial point could help. Your starting points are sometimes a factor 10 away from the upper and lower bounds.
You get lots of information if you comment out the first few lines of your code and as the model doesn't seem to converge, you can stop it after iteration 0. The equations listing shows you the size of infeasibilities
If you use conopt you get a warning that your data is badly scaled:
Code: Select all
** Warning ** The variance of the derivatives in the initial
point is large (= 4.5 ). A better initial
point, a better scaling, or better bounds on the
variables will probably help the optimization.
You get lots of information if you comment out the first few lines of your code and as the model doesn't seem to converge, you can stop it after iteration 0. The equations listing shows you the size of infeasibilities
Code: Select all
*option limcol=0, limrow=0;
*$offsymxref offsymlist
*$offlisting
*option solprint = off;
*option reslim = 20000;
option iterlim = 0;
[\code]
Now you can check in the equation listing how your first initialization differs from the bounds and if it makes sense to set upper and lower bounds for certain variables.
I would suggest the following:
[list]
[*] Scale your parameters,
[*] Initialize your variables better.
[*] Run your estimation for just one year for debugging purposes as I suspect that you might find more easily a solution with one time period and debugging your code gets also easier. If you don't find a solution, you might have made some mistakes in your equations/model.
If you want to run your model for one year, I would move the data out of your gams file to an excel sheet and read them with gdxxrw. You can then easily adjust your commands to read one or more years from the excel sheet.
Hope this helps
Cheers
Renger
[/list]
____________________________________
Enjoy modeling even more: Read my blog on modeling at The lazy economist
Enjoy modeling even more: Read my blog on modeling at The lazy economist

 User
 Posts: 7
 Joined: 3 months ago
Re: Help me in CES, CET estimate, please
Dear Renger,
I solved my problems.
Thanks a lot!
Cheers,
Nguyen Xuan.
I solved my problems.
Thanks a lot!
Cheers,
Nguyen Xuan.