AA:=((CLOSE*V-REF(COST(90),1)*V)/20+250)*1.2/5,COLORMAGENTA;
BB:=((REF(COST(90),1)*V-CLOSE*V)/20+250)*1.2/5,COLORCYAN;
CC:=((CLOSE*V-REF(COST(10),1)*V)/20+250)*1.2/5,COLORRED;
DD:=((REF(COST(10),1)*V-CLOSE*V)/20+250)*1.2/5,COLORBLUE;
主升浪:=CC>0 AND AA>0 AND BB<0 AND DD<0;
VAR1:=(CC>0 AND crOSS(AA,BB) OR CROSS(AA,0)) ;
VAR2:=(VAR1 AND COUNT(VAR1,10)=1) OR (主升浪 AND COUNT(主升浪,60)=1);
XG:VAR2 AND COUNT(VAR2,20)=1;