First working version of rectangular SOM.