Generating ideal solution