i1 = [0, 2, 4, 6]
i2 = [0, 1, 3, 7]
i3 = [1, 5, 8, 9]
i4 = [1, 6, 7, 8]
c3[i1, i2, i3, i4] = c1[i1, i2, i3, i4] + c2[i1, i2, i3, i4]
Sum 4D array efficiently according to indices contained in another array