
Welcome to CivilGEO Knowledge Base
Welcome to CivilGEO Knowledge Base
Welcome to CivilGEO Knowledge Base
Welcome to CivilGEO Knowledge Base
The Grid Calculator command allows the users to perform algebraic computations on raster grids based on existing raster pixel values. The user can perform mathematical operations on each cell in a raster. This can be useful for converting and manipulating raster grids. For example, the user may want to see the difference in water surface elevations in the form of an elevation difference grid by subtracting two elevation grids from each other. Or a user may want to generate a “custom” flood hazard map by multiplying the depth raster grid with another factor.
Note that the raster grids must be loaded into the software before performing any operations on them.
Follow the steps below to use the Grid Calculator command:
The below sections describe how to perform algebraic computations on raster grids and interact with the above dialog box.
The Grid Layers dropdown combo box lists all the loaded raster grids that can be used. To add a raster grid to the Grid Calculator Expression box, click the [Add Layer] button.
This section contains all the available operators.
Click the appropriate button to add an operator to the Grid Calculator Expression box.
The Grid Calculator Expression section is used to define the grid calculator expression.
The user can add a raster grid to the Grid Calculator Expression box and then use the operators from the Available Grid Operators section to either construct calculation expressions or type them into the box.
The Output Grid Limits section allows the user to define the extent of the output raster grid. The user can choose to operate only on a portion of a source raster grid or use the entire extent of the source raster grid.
The Output Grid Specifications section is used to define the specifications for the output raster grid.
Click the […] button next to the Grid file entry to specify the file name and directory location to save the output raster grid file.
By default, the Load grid as map layer checkbox option is checked to load the output raster grid as a layer in the Map Data Layers panel. Click the pencil icon to rename the layer.
The user can select the CRS to be used for the output raster grid from the Grid CRS dropdown combo box. If there is only one CRS in the project, the software automatically selects it.
The user can check the Overwrite existing grid layer checkbox option to automatically overwrite an existing raster layer (if one exists) with the revised raster layer. By default, this option is unchecked.
After the options have been defined, click the [Generate] button. The software will perform calculations on the selected raster grids based on the expression defined in the Grid Calculator Expression box. An output raster grid file will be created at the specified location after the computations are finished. If the Load grid as map layer checkbox was left checked, the newly created raster grid would be added in the Map Data Layers panel.
The below sections describe various scenarios in which the grid calculator can be useful.
To change a raster in meters to a raster in feet, the user can use the conversion factor (3.28084) for meters to feet and create the following expression in the Grid Calculator Expression box:
“USGS DEM Meters” * 3.28084
By clicking the [Generate] button, the software will create a new raster with elevations in feet.
Sometimes the user might want to mask out parts of a raster. For example, consider a raster grid with elevations varying from sea level to mountain peaks. If the user is only interested in the elevation above sea level, the grid calculator can be used to create a mask, which can then be applied to the raster in a single step.
The expression will be as follows:
(“USGS DEM Meters” >= 0) * “USGS DEM Meters”
The first part of the expression in parentheses sets the value of every cell greater than or equal to zero to 1 with all other cell values set to 0. This creates the mask on the fly. The raster (USGS DEM Meters) is then multiplied by the mask values. This sets every cell with an elevation less than zero to zero.
On clicking the [Generate] button, the software will create a new raster with the mask applied.
Depth raster grids are used to depict the depth of the river’s inundation. Grid calculator can be used to create depth raster grids by subtracting the source elevation raster grid from the water surface elevation (WSEL) raster grid. Refer to this article in our knowledge base to learn how to create a water surface elevation raster grid in HEC-RAS.
Once the source elevation and water surface elevation raster grids are available, the user can create the following expression in the Grid Calculator Expression box:
(“WSEL 100yr” – “Elev DEM Feet”)
On clicking the [Generate] button, the software will create a depth raster grid. Depth raster grids can be created for a variety of flood events illustrating the changing flood depths throughout the selected flood extent for each event.
1-800-301-02-955
608-729-5100
(US and Canada)
[email protected]
+1 608-729-5100
CivilGEO India
Graphix Tower, A-13 A
3rd Floor, Sector 62
Noida, Uttar Pradesh 201309
IndiaTel:
1-800-301-02-955 or
+91 022-3831-8601
CivilGEO United States
8383 Greenway Blvd
6th Floor
Middleton, WI 53562
USATel:
608-729-5100 or
800-488-4110
We use cookies to give you the best online experience. By agreeing you accept the use of cookies in accordance with our cookie policy.
When you visit any web site, it may store or retrieve information on your browser, mostly in the form of cookies. Control your personal Cookie Services here.
The ZoomInfo WebSights snippet drops three cookies to track Unique Visits:
1. _pxhd - Related to the Perimeter X security layer (Perimeter X isused to prevent bot attacks).
2. _cfduid - Related to the CloudFlare security layer (CloudFlare is the Network Security protocol that ZoomInfo uses to orchestrate the rate limiting rules).
3. visitorId - This is how WebSights identifies recurring visitors