GG:=AMOUNT/VOL;
M1:=((GG-REF(GG,1))/REF(GG,1))*((GG-REF(GG,1))/REF(GG,1))*10000;
M2:=((REF(GG,1)-GG);
CCB:=SUM(IF(GG>REF(GG,1),(10000*VOL/FINANCE(7))*M1,0),1);
CCS:=SUM(IF(GG<REF(GG,1),(10000*VOL/FINANCE(7))*M2,0),1);
B1:=(CCB+CCS);
B2:=MAX(REF(B1,1),REF(B1,2));
B0:=MAX(B2,REF(B1,3));
B3:=MAX(B0,REF(B1,4));
B4:=MAX(B3,REF(B1,5));
B5:=MAX(B4,REF(B1,6));
B6:=MAX(B5,REF(B1,7));
B7:=MAX(B6,REF(B1,8));
B8:=MAX(B7,REF(B1,9));
B9:=MAX(B8,REF(B1,10));
B10:=MAX(B9,REF(B1,11));
B11:=MAX(B10,REF(B1,12));
B12:=MAX(B11,REF(B1,13));
B13:=MAX(B12,REF(B1,14));
B14:=MAX(B13,REF(B1,15));
B15:=MAX(B14,REF(B1,16));
B16:=MAX(B15,REF(B1,17));
B:=CCB>1.2*B6&&REF(CCB,1)<0.8*REF(B0,1)&&REF(CCB,2)<0.8*REF(B0,2)&&
REF(CCB,3)<0.8*REF(B0,3)&&REF(CCB,4)<0.8*REF(B0,4);
D1:=C>O;
D:=COUNT(D1,6)=5;
B&&D; |