Objective as a function of constrains
I am trying to build a CQM where the objective depends on conditions. I have a table of time-dependent entries labeled A, B, and C. (Such that entry1 = (t0, 1(A), 2(B), 2(C)), entry2 = (t1, -3,4,-1), with a large n number of entries) ) I wish to formulate the objective to minimize R, which is found by iterating through the table and checking if A > alpha and B > beta, and if both conditions are met, add C to the rolling sum R. Specifically, I want to tune alpha(an Integer object with a predefined range) and beta to minimize R. Additionally, I hope to generalize the form to expand beyond 2 conditions(where all conditions must be satisfied to add C to R).
for entry in entries:
if (entry.A > x and entry.B > x): #where x = alpha and x = beta
Thanks in advance,