SAP Message UPF154 - Incorrect index &1 with function &2

Diagnosis
You transferred the wrong index to function &V1&. The index starts with1 and ends with the number of the variable values.

System Response
Executing the planning function is terminated.

Procedure
Change the formula.