1d generation works and gives correct result