Create a Grid in Grasshopper

Hello everybody,

I’m trying to create a simple axis grid. It should consist of X-directed and Y-directed axis lines and you should be able to set the number of axes and the distances between them by number-sliders.
My first thought was:

  1. lines on the X and Y axis
  2. points on these lines to determine distances and number of axes (e.g. length 10 m, number of points 5 --> points every 2 m)
  3. axis grid lines: Starting points are the points on the axes (X direction, if point on Y axis and vice versa)

It seems quite complicated to me and I can imagine that there is an easier way. Does anyone know?

Best regards, Heiko

Maybe you can try the “Rectangular Grid” component?

Here’s one way to create a set of grid-lines with full control over where they start, how far apart they are, how many there are, and the extent of each line in the perpendicular direction: grid_lines.gh (12.7 KB)

There are loads of other ways to achieve something similar. You can start with one of the grid components. Or begin with a line and use the Array component. Or begin with a line and use Move with various vectors. Or begin with a planar surface and extract isocurves. Or begin with two lines that you divide into an equal number of points and then connect.

Here’s an approach which starts with a rectangle and divides two opposite edges into number of points which are then connected: divide rectangle.gh (11.2 KB)