set up a flexible grid