VAR1:=AMOUNT/vol/100;
VAR2:=(3*HIGH+LOW+OPEN+2*CLOSE)/7;
VAR3:=SUM(AMOUNT,13)/VAR1/100;
VAR4:=DMA(VAR2,VOL/VAR3);
VAR5:=(CLOSE-VAR4)/VAR4*100;
VAR6:=(INDEXC-LLV(INDEXL,9))/(HHV(INDEXH,9)-LLV(INDEXL,9))*100;
VAR7:=SMA(VAR6,3,1);
VAR8:=SMA(VAR7,3,1);
XG2:crOSS(VAR7,VAR8) AND VAR7<45 AND COUNT(VAR5<=-15,5)>=1 ;