# Tunnel Grid

The tunnel grid in the geology editing window consists of horizontal folded-out perimeters, with 5 meters between them, and 4 vertical lines representing the connection points between the perimeter and the road base (the outer left and right lines), and the abutment points (where the perimeter tangent is at 45 degrees angle to the road surface. We call such a fold-out perimeter a “plan line”. The plan line can be thought of as a measuring tape being extended along the periphery of the actual perimeter from one connection point to the other. The abutment points are ticked off on the measuring tape along with the road normal intersection, and the measuring tape is then stretched out and placed flat on a sheet of paper.

The road normal intersection point is then considered to be the origin of the measuring tape. All points to the left of this point are negative; all points to the right are positive. These values are considered to be the X coordinate of the tunnel grid. The chainage number is considered to be the Y coordinate.

A point halfway between the abutment points is ticked off, and we call this the midpoint of the plan line.

Note: The midpoint and the road normal intersection point may be at the same position, but not necessarily so. The midpoint does not play an important role in creating the tunnel grid. The left figure shows the tunnel grid as it is drawn on the screen. In the right figure, the blue line shows what a longitudinal line through the road's normal intersection points would have looked like. The green lines show the plan lines at “points of special interest”. Note how the longitudinal lines break at these plan lines, even though the plan lines themselves are not drawn.

## Geological locations

While the perimeter and road base are defined by humans, the geological locations are literally “set in stone”. To the tunnel designer, the road model is also a given, so that the only variables that the tunnel designer can change are the tunnel parameters.

When a specific geological location is entered onto the tunnel grid, then it is positioned in terms of one or more sets of X and Y coordinates. Note that if the tunnel designer later changes the perimeter, then the X coordinate may become invalid, because the location as measured along the tunnel perimeter from the road normal intersection point may change. What does not change, is the angle measured between a vertical line upwards from the road centerline, and a line from the road centerline to the geological location (called Alpha in the illustration above).

When the geological location's X coordinate is entered (in the context of the perimeter in effect at the time), the program will automatically calculate Alpha, and store it together with the X coordinate in the geometry file.

If the perimeter (or the road model) changes at a later date, it becomes necessary to recalculate the X coordinates for all geological locations from the Alpha value (this is requested by the user through a tool button in the GUI). When this happens, there is a possibility that geological locations close to the connection points may fall outside of the newly defined perimeter. In such cases, the angle will be flagged as invalid (as described under the next subheading), and the X coordinate set exactly at the connection point.

In old tunnel geometry files stemming from before the angle feature was implemented in NP Tunnel, there will not be any angles for the geological locations. When such files are opened, NP Tunnel will note that this is the case, and ask the user if it is desirable that the angles be calculated.

## The angle status in the tunnel geometry file

Due to the circumstances described above, a geological location angle in the geometry file will have a status that can take on one out of three possible values:

In the geometry file, a point entry will look like this:

<GeoPoint>

<ChainageNumber>1095.55</ChainageNumber>

<Angle>0.174562</Angle>

<X>1.21277</X>

<AngleStatus>2</AngleStatus>

<OuterEdge>0</OuterEdge>

</GeoPoint>

Note: The AngleStatus element, which, in this case, defines the angle as valid.

Next topic: Tunnel Design