The question:
Start with the inner term. To have a valid number 0 or 1, I used the following expression:
piecewise([A[k]>a*B[l],1],[Otherwise,0])
The rest is straight forward:
sum(sum(A[k]*B[l]*piecewise([A[k]>a*B[l],1],[Otherwise,0]), l=1..L), k=1..K)