Changed implementation to create a grid of numbers rather than single arrays that are then combined after creation.