I communicated with a user recently who wanted to find the area of overlap of one specific contour line on one contour map with a specific contour line on another contour map. In his case the first contour map was temperature and the second was rainfall. He wanted to find the area where temperature was above one value and rainfall was above another value. Whether this was for agriculture or for some other purpose I’m not sure, but it got me thinking that there could be many applications for a use like this. For example, you may have a contour map of density of one endangered species, and another for a second endangered species, and you’re trying to identify high populations of both in order to create a wildlife refuge. Or maybe you have population of people on one contour map and energy use on another, and you want to find areas with low population but high energy usage so you can send conservationists into that area to notify the population of smart practices. The uses are endless!
So that said, below are the steps to determine the area where two specific contour levels on two different maps intersect. In this case, I’ll be finding the area in Colorado where temperature is greater than 12oC and precipitation is less than 50 hundredths of inches, which may indicate an area that is more prone to wildfires. The data used in this article was obtained from NOAA. January 2015 – November 2015 data was averaged and then gridded in order to produce the attached grids.
- Click Map | New | Contour Map.
- In the Open Grid dialog, choose the rainfall_avg.grd file and click Open.
- In the Object Manager, select the Contours- rainfall_avg.grd layer.
- Click on the Levels tab in the Property Manager.
- Change the Level method to Advanced.
- Click the Edit Levels button.
a. Click the Delete button until the top level listed is 50.
b. Click on the next level (55) and click the Delete button until the 50 level is the only level.
c. Make sure the Label column says No (if it says Yes, double click on the Yes in the Label column to turn it to a No).
d. Double click on the line.
e. Change the Color to Blue and click OK.
f. Click OK.
- Click on the Set button on the Coordinate System page in the Property Manager. Setting the coordinate system of the layer will allow us to change the coordinate system of the Map so we can view the area of the overlap in meaningful units.
- Navigate to Predefined | Geographic (lat/lon) | World Geodetic System 1984 and click OK.
- Click Map | Add | Contour Layer.
- In the Open Grid dialog choose the temperature_avg.grd file and click Open.
- In the Object Manager select the Contours- temperature_avg.grd layer.
- Click on the Levels tab in the Property Manager.
- Change the Level method to Advanced.
- Click the Edit Levels button.
a. Click the Delete button until the top level listed is 12.
b. Click on the next level (12.5) and click the Delete button until the 12 level is the only level.
c. Make sure the Label column says No (if it says Yes, double click on the Yes in the Label column to turn it to a No).
d. Double click on the line.
e. Change the Color to Red and click OK.
f. Click OK.
- Click on the Set button on the Coordinate System page in the Property Manager.
- Navigate to Predefined | Geographic (lat/lon) | World Geodetic System 1984 and click OK.
- Click on the Map in the Object Manager.
- Click on the Change button on the Coordinate System page in the Property Manager.
- Navigate to Predefined | Projected Systems | World | Popular Visualisation CRS / Mercator (EPSG 3785) and click OK.
If we were to fill the areas below the rainfall contour and above the temperature contour, it would look like this:

- Uncheck the boxes next to each of the four axes in the Object Manager.
- Click File | Export.
- In the Export dialog, set the Save as type to GSI Golden Software Interchange, give your file a name (like "overlap"), and click Save.
- In the Export Options dialog, make sure the Scaling source is set to Map: Contours-rainfall_avg.grd and then click OK.
- Click Map | Add | Base Layer.
- In the Import dialog, choose the GSI file and click Open.
- Click Yes if you are prompted to expand the map limits to include the new layer.
- In the Object Manager, uncheck the boxes next to the two contour maps to turn them off.
- Right click on the Base-<filename>.gsi layer in the Object Manager and click Edit Group.
- Delete the closed blue polylines that don’t overlap.

- Select one of the blue polylines and click Geoprocessing | Edit Boundaries | Break Polyline.

- Click where this line intersects with a red line.
- Repeat steps 30-31 for the rest of the blue lines, clicking anywhere the line intersects with a red line, until no blue line intersects a red line, but instead the red lines mark where one blue line ends and the next begins.
- Repeat steps 30-32 for each of the red lines, clicking at the same locations you clicked for the blue lines, so now no red line intersects a blue line, but instead where red and blue meet this marks the end of one red line and the start of the next.
- Select the portion of the polyline that is not part of the overlap (using the image from step 19 if needed) and press DELETE.

- Click Draw | Polyline and connect the ends of the two big incomplete polygon. Do the same for the red polyline in the upper right corner and press ESC to exit drawing mode.

- Click one polyline in the big area and rename it ‘1’ in the Object Manager.
- Click the next polyline in the clockwise direction and name it ‘2’, then click and drag it in the Object Manager so it’s just above ‘1’.
- Repeat step 37 for the rest of the polylines in the big area.
- Select all of the polylines that make up the big area and click Geoprocessing | Edit Boundaries | Connect Polylines.
- Repeat step 39 for the smaller area on the left and then the area in the upper right corner.
- Select all of the polylines and click Geoprocessing | Change Boundaries | Polyline to Polygon.
- With all polygons still selected, click Geoprocessing | Edit Boundaries | Combine Islands/Lakes.
- Right click on the Base layer in the Object Manager and click Stop Editing Group.
- You can turn on the axes and contour layers, change the Level method for each contour map back to Simple, and change the line and fill properties of the base layer overlap in the Property Manager, if desired.
- To get the area of this polygon, you can select the polygon and click to the Info tab in the Property Manager to view the perimeter and area in map units.

Although the process takes a little time it’s well worth the result. For practically any field of study, this process can be used to accurately identify where two variables intersect, allowing you to identify your region of interest for overlay with other informative maps in Surfer.

Comments 7
How did u add the legend at the bottom.?
Hi Leo,
Surfer does not support the creation of standard legends for contour maps so the legend at the bottom of this map was created using drawn rectangle and text objects. The colorscale to the right of the map is the type of legend that is supported in Surfer.
Thanks!
Katie
Ok, thanks Katie. Is it possible to overlay more than two maps, maybe three or four? Trying to produce a groundwater potential map.
Hi Leo. Yes, it is possible to overlay more than two maps in Surfer. In fact, to my knowledge there is not a limit on the number of maps that can be overlaid in Surfer.
Thanks!
Katie
Very strange, looks like the website is trying to parse the formula as per html code.
Once last try,:
IF(A>50,1,0)*IF(B the data based on the user defined parameters, rather than manually adjusting contour lines.
If the grid files are different geometries that I expect that you can use intermediate steps to create interpolated grid files with the same geometry in order to apply the above approach.
Leon
Not sure what happened above. (plus clearer explanation).
Correct formula would be:
IF(A>50,1,0)*IF(Bg the two grids together a new grid is created with a value of 1 where the two previous grids are 1, and 0 elsewhere.
Leon
Another, (much) quicker approach could be:
If rainfall is Grid A and Temp is Grid B:
1: Use the following formula in grid math: IF(A>50,1,0)*IF(Brid with a 1 value only where both of these conditions are true, 0 else.
2: Plot the resulting grid as a contour plot using the advanced method above.
This assumes the two grids share the same geometry. Done in Surfer 10.
Leon
Computed in Surfer 10. This requires both the grids to be the same geometry.