Dear all,
I am facing problem in formulating syntax for storing (recording) the frequency (how many times the same solution is found) of solution. In other words, in the attached model sensitivity analysis is performed and after each iteration, a new solution is found. What I want is to systematically rank the solution based on their frequency.
Kind regards,
Rofice
Storing solution
Re: Storing solution
Hi
YOu could do as follows:
this gives you
Or:
(1,1) (2,3) = 1
(1,2) (2,4) = 3
...
For the ordering, you probably are better off doing this in excel...
Cheers
Renger
YOu could do as follows:
Code: Select all
alias(i,ai), (j,aj);
parameter frequency(i,j,ai,aj) Frequency of solutions;
frequency(i,j,ai,aj)$(ord(i) = 1) = sum(k$(not sameas(i,ai) and not sameas(j,aj)), report(k,i,j)*report(k,ai,aj)) ;
display frequency;
Code: Select all
index = 1
3 4
1.2 1.000 3.000
2.2 4.000 2.000
(1,1) (2,3) = 1
(1,2) (2,4) = 3
...
For the ordering, you probably are better off doing this in excel...
Cheers
Renger
____________________________________
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
Re: Storing solution
Dear Renger,
Thank you very much for the formulation.
kind regards,
Rofice
Thank you very much for the formulation.
kind regards,
Rofice