Revision 862, 0.5 kB
(checked in by zimamiro, 15 years ago)
|
|
Line | |
---|
1 | function [losses1 losses2]=mc_study(regulator_parameters,system,range,n)
|
---|
2 | losses1=zeros(1,n);
|
---|
3 | losses2=zeros(1,n);
|
---|
4 | [H u]=load_H;
|
---|
5 | for i=1:n
|
---|
6 | apriori(3)=range.P0+randn*range.P0_range;
|
---|
7 | system.b=apriori(3)*randn;
|
---|
8 | apriori(2)=apriori(3)*randn;
|
---|
9 | apriori(1)=range.y0_range*randn;
|
---|
10 | while (system.b==0)
|
---|
11 | system.b=apriori(3)*randn;
|
---|
12 | end
|
---|
13 | while (apriori(2)==0)
|
---|
14 | apriori(2)=apriori(3)*randn;
|
---|
15 | end
|
---|
16 | losses1(i)=ce(regulator_parameters,system,apriori);
|
---|
17 | losses2(i)=rizeni(H,u,system,apriori);
|
---|
18 |
|
---|
19 | end
|
---|
20 | end |
---|