Did you try 400-array1[i]?

This may need scaling though if array1[i] ever exceeds 400 (so if array[i] can reach 800, then you'll need to divide by 2 to fit the graph to the screen).

What is the range of numbers stored in image256 (ie what are the min and max)?