Pages

Monday, December 8, 2014

Including Channel Bathymetry into your Terrain.

Written by Christopher Goodell, P.E., D.WRE  |  WEST Consultants
Copyright © The RAS Solution 2014.  All rights reserved.

Let’s say you have a digital terrain model of the area you want to model with 2D HEC-RAS.  ONLY 2D RAS.  In other words, you want to lay out a grid, but do not want to have do to any 1D computations-all 2D.  The problem is the area you want to model includes one or more rivers and streams that have no bathymetric (under water topography) data represented in the digital terrain model.  This is a common problem as many sources of terrain data are collected today using LiDAR (Light Detection And Ranging).  As great as LiDAR is for collecting surface data, conventional forms of LiDAR do not penetrate water. 

To adequately model 2D in RAS,
you need a terrain of your entire modeled area-including the stream channels.  HEC has come up with an easy way to weave in a channel terrain with your LiDAR terrain, IF you already have cross sections of the channel.

Open an HEC-RAS project in Version 5.0 (beta or newer) that has your cross sections represented in a geometry file.  The figure below shows an existing model of the White River in Muncie, Indiana USA.  This is from one of the standard 2D HEC-RAS data sets that come with HEC-RAS 5.0 beta.
image
We wish to lay a grid over this entire area to model it as 2D only.  A major problem here is that the terrain below the water surface of the White River is not included in the Terrain that we have obtained.  Notice that there is no relief represented within the stream, and in fact the bridges that cross over the White River are included in the original terrain.  Bridges should not be included in the terrain-they can be added as model components in the geometry window, if it is desired to include them in your model. 
image
HEC has provided a way to easily incorporate our cross section data into the terrain for a single comprehensive terrain model that includes bathymetry (and no bridges in the terrain!):
1.  In RAS Mapper, first make sure a geographic projection is selected (Tools…Set Projection for Project…).  Then select to view the geometry that has the cross sections you want to include in the terrain.  Then check the features River, Bank Line, XS (XS stands for cross section), and XS Interpolation Surface.  It should look like this:
image
Here you can see, that just by having cross sections in a geometry file, RAS has already created a conceptual interpolated surface from those cross sections.  Each pair of cross sections is linearly interpolated.  This is very similar to the cross section interpolation routines in the tools menu item of the geometry window.  Only here, instead of adding interpolated cross sections, we’re developing a continuous surface that can be made into a terrain.  RAS does all of this for you, all you have to do is enter cross sections into your geometry, and check the box that says XS Interpolation Surface. 
2.    From the data file tree on the left,  right-click on the name of the geometry file you’re working in and select Export Layer…Create terrain GeoTiff from XS’s (channel only).  We select channel only, under the presumption that the LiDAR data has better resolution than the cross section data, so where the two sources overlap (i.e. in the overbanks), we’ll stick with the LiDAR data.   If channel only is selected, RAS will create the new terrain between the established Bank Lines (polylines that spatially connect the cross section bank stations). 
image
Once you select to create the terrain from XS’s, RAS will ask you to name the new terrain (a GeoTiff) and where to store it.  It will also ask you to enter in a raster cell size.  This is the grid cell size that RAS will set this new terrain to.  It should be representative of the resolution of the station-elevation data that make up your cross section.  You can view the new terrain by selecting Tool…New Terrain. 
image
3.  Once you’ve added the new channel, a new terrain can be created that combines both the original LiDAR-based terrain with the new channel terrain.  Select  Tools…New Terrain.  This time you’ll add both two files: the original terrain and the new channel terrain.
image
Make sure that the channel terrain (in this example…White River.tif) has the highest priority by moving it to the top of the list using the arrow button on the left.  This will ensure that where ever the two terrains overlap, the channel terrain will be used in creating the new single comprehensive terrain. After clicking the Create button, a new terrain is created that combines both the channel bathymetric data (interpolated by cross sections) and the original LiDAR-based terrain. 
image
Now you’re ready to lay down a mesh and run your 2D model.   More information on working with terrains in HEC-RAS 5.0 can be found in the document “Combined 1D and 2D Modeling with HEC-RAS”.  Check the link on the side bar to download the latest version of HEC-RAS. 

63 comments:

  1. Nice post, thanks for doing these. I've also found this as a nice/quick tool for merging terrain with cross-sections to improve RasMapper mapping results even for 1D simulations. In other words just improves the visualization of the inundation area around the river sections after modeling but very handy and requires less tweaking for production mapping.

    ReplyDelete
    Replies
    1. Excellent point! Thanks for mentioning that.

      Delete
    2. This tool is just what I was looking for. I've got a model built to investigate habitat conditions for low and medium flow conditions, so correct bathymetry in the TIN is really important when exporting steady flow simulations to GIS. One question though, the model is built in version 4.1. Can I import that into 5.0 to use the new RasMapper features? Or, is a CAD program the better way to go?
      Thanks!

      Delete
    3. HI Daniel. As long as your model in 4.1 is georeferenced and you have a digital terrain model in the same projection, it should be no problem. No need to import to 5.0. Just open up your model in 5.0 and it should work. You may have to do some work with your terrain,but it should be fairly easy.

      Delete
  2. Chris,
    Great post... The terrain generated by Rasmapper is equally good to create interpolated cross-sections between surveyed data (HECGeoRAS Input Data processing using DEM)for most projects where rivers have relatively linear slope with varying overbank topography.

    ReplyDelete
  3. Sure does make adding a proposed channel to the surface easier. Can also be used to make edits to the surface reflecting proposed fill such as new roads...though there are probably better tools if you are well versed in GIS.

    ReplyDelete
  4. Somehow the Terrain writes an error during simulations after I have merged the cross section one with the Dem. The error says that the merged Terrain does not cover the whole extent of the 2 D area which is within the area of the original Dem.

    ReplyDelete
  5. After I have merged two Terrains, one from the original Dem and the other from the cross sections, I get an error message when I run the Simulation again. It now says the Terrain does not cover the whole area of my Simulation. Before the original Dem did cover it though. What went wrong?

    ReplyDelete
    Replies
    1. That's interesting. Not sure what would cause that, and I've never seen that before. I would double and triple check that your 2D area is still within the new terrain perimeter and then send a bug report to HEC.

      Delete
  6. I intend to model a Solimões River reach (upstream Manaus city), using Hec-Ras 2D, and I'd like to include channel bathymetry into terrain. I actually don't know how to deal with the "islands" that divide river flow, when creating river centerline and river banks.
    Any suggestions?

    ReplyDelete
    Replies
    1. For your river centerline, just pick the side of the island that carries the most flow. Bank stations can be centered around that thread, or both threads, it's up to you.

      Delete
  7. Chris, I'm going to check the geological risk Marano's river but not fail to cross section
    automatically since i can't get your first image. After defining the river, how do i get the cross-sections (green line in your immage)? Thank

    ReplyDelete
    Replies
    1. Cross sections are currently brought in using HEC-GeoRAS, or something similar. You can enter the cross sections manually into the geometry window, but they will not be georerferenced.

      Delete
  8. Hi Chris,

    I followed your tutorial till the second step, but I am getting two blank spaces in my channel terrain. In those blank reaches it seems channel bathymetry has not been interpolated. Do you know why this is happening? Many thanks!

    ReplyDelete
    Replies
    1. Not sure. Do you have a break in your stream centerline?

      Delete
    2. I do not have breaks in the stream centerline.

      Delete
    3. I do not have breaks in the stream centerline.

      Delete
    4. Strange. Not sure what would cause that.

      Delete
  9. Hey Chris,
    I just found out that the extent of the tif file that HEC RAS created with my interpolated bathymetry is smaller than the extent of my river stretch. So the river stretches that are not included in the extent of the tif file created by HEC RAS were left blank. It seems that HEC RAS used the cross sections to stablish the extent (the box) of the bathymetry tif file. So, the question is: how can I include river stretches between cross sections which are not included in the cross sections box. It would be great if I could send you an image with my problem. Many thanks!

    ReplyDelete
    Replies
    1. As long as everything is properly entered into the cross section editor, RAS should include all cross sections in the cross section interpolated surface. I would go through my cross section editor and double check that you aren't missing some require input data.

      Delete
  10. Hi Chris,
    Sorry for this third post. I made a link with a picture of my problem (I have opened the tif file created by HEC RAS in Arc Map to see its extent).
    http://psr.me/ilncmz
    You can see in blue the box that HEC RAS used to interpolate the channel bathymetry. You can also see the river stretches that were not interpolated, because they are not included in the extent considered by HEC RAS. Is there a way I can solve this without creating dummy cross sections in those stretches? Many thanks!

    ReplyDelete
    Replies
    1. That's strange. You are saying that RAS created the blue box? Typically, the cross section interpolated surface should follow the cross section endpoints-it won't be a "box" like is shown in your figure. Could it be that box is your other terrain? Could it be your projection file is limiting the workspace?

      Delete
    2. Hi Chris,

      I solved the problem by interpolating the cross sections. Your other post helped me: http://hecrasmodel.blogspot.com.br/2014/08/exploring-hec-ras-xs-interpolation.html

      In fact, my first try was just to extend the sections in order to include all river curves in the box I mentioned before. I would have to do it anyway because I am modelling floodplains and the cross sections were too short to include higher floods.

      However, this brought me another problem: plain areas outside the channel in curves like this one: http://psr.me/ilncmz

      So, to completely solve all problems, I had to make a balance between extending the cross sections and interpolating them in the curves.

      Thanks!

      Delete
    3. Good to hear Taina. Not sure I understand what the image is showing me though.

      Delete
    4. Check this RAS Mapper image: http://psr.me/ilncmz

      I used the option Create Terrain GeoTiff from XS´s (channel only). However, HEC RAS created those completely plain areas outside of the channel (in blue because they are flooded like a pool), where in fact, I have contour lines.

      I am not sure how HEC RAS does it, but is has to do with the length of the cross sections (with short cross section this problem does not happen, but I need large cross sections, as I mentioned before).

      To solve this problem, I had to interpolate the cross section in the curve.

      Delete
  11. Hi Chris,
    Indeed, the interpolated surface follows the cross section endpoints.
    The blue box is the extent of the terrain that RAS has created, in other words, the area available for processing.
    Since there are portions of the river channel outside of the extent, RAS does not process it. The solution I found for this problem is simply extend the sixth cross section (from bottom to top of the figure) so that the new box (the new extent) would be big enough to include all my river channel. You can see the result in the picture I put in the following link: http://psr.me/ffo8dd Many thanks!

    ReplyDelete
  12. Hi Chris,

    There is one problem I can not solve: when I include the channel bathymetry into my terrain using your tutorial with RAS Mapper, every upstream cross section of each reach, plus the downstream cross section of my downstream reach (in other words, cross sections in the extremes), have their terrain looking like zigzag, like this one: http://psr.me/mldc7c

    In fact, if I do not include the channel bathymetry using RAS Mapper, I am still able to run my 1D steady flow and see the results, without that line of current terrain. Here it is the same cross section: http://psr.me/634mx5

    In my understading, including the channel bathymetry into the terrain is only used to visualize results in RAS Mapper right? I mean, HEC RAS will interpolate the channel bathymetry and run the steady flow even if we do not include the channel bathymetry with RAS Mapper.

    But in case I do want to visualize results in RAS Mapper, do you know I can I solve the problem with the zigzag current terrain?

    Many thanks!

    ReplyDelete
    Replies
    1. The zigzag terrain you see in the plot is the ground elevation in the Terrain that is associated with the geometry file. It is not used in the computations. It's only there for your reference.

      Delete
  13. Is there a way to impose/import the bank lines that are used with the RAS Mapper tool "Create Terrain GeoTiff from XS (channel only)?

    In many cases, the RAS generated bank lines between the surveyed sections are not representative of the true bank lines. In my case, the RAS bank line is located too far inland on a sharp bend. As a result, the channel thalweg in the interpolated terrain overlaps with a flood protection dike located at the top of bank.

    I noticed that the bank line info is stored in the geometry hdf file. I modified the vertices of the bank line in the .g01.hdf file using HDFView, but my changes to the bank line were not implemented when I re-opened RAS Mapper. Any suggestions?

    ReplyDelete
    Replies
    1. Your bank lines are created based on the location of your bank stations. So you can easily go into your cross sections and edit those as you see fit. If you are not seeing changes to geometry after editing your hdf file, try removing your hdf file from RAS Mapper, close RAS Mapper, then reopen it. Don't save your geometry file in between because that will rewrite your hdf file. I think that will work, but not 100% sure.

      Delete
  14. Hi Chris,

    Thanks for the quick response. I'm mostly concerned with adjusting the RAS bank lines where I have no cross sections, so editing the locations of the bank stations won't help.

    I liked your suggestion with the hdf file but RAS Mapper seems to regenerate the bank lines (and overwrite my changes) when I reopen the file in RAS Mapper. The hdf file's Date modified timestamp in Windows explorer shows that RAS Mapper is modifying the data in the file every time RAS Mapper opens (version 5.0.1 and version 5.0.3).

    If you think of something else, I'd be happy to hear it. Otherwise, I hope that HEC will be implementing the option to adjust the RAS generate bank lines in the next release of RAS Mapper.

    ReplyDelete
    Replies
    1. My bad, I didn't read your question close enough. Now I see you're talking about in between cross sections. Let me think about this. I'll ask around to see if there are any brilliant ideas short of cutting a bunch of new intermediate cross sections.

      Delete
    2. You might try exporting the entire cross section as a geotiff, then in GIS, use your bank lines to clip out what you don't want. Just a thought...

      Delete
    3. Or perhaps adding more definition to your stream centerline (more points to better follow the axis of the stream may help RAS make a better attempt at drawing your bank stations in between cross sections. Not sure if this will work, but easy to do and worth a try.
      Let me know if any of these work...

      Delete
  15. Hi, I just had this issue. More definition on centreline does help position interpolated sections better, but to make further adjustments, I bought the bank lines I wanted into RASMapper, so then they also appeared in geometry. Then, I manually moved the end points (delete/filter out any other GIS XY pts in table view first) of the interpolated sections in geometry so bank stations lay on the lines and result of interpolated surface in RASMapper was then much better. Just don't make more interpolated sections than you need to define bank lines at this point. Once you've moved them, you can always turn them into real sections by deleting the * from the name and add other interpolates between these if you like, which should then line up better anyway.

    ReplyDelete
  16. Is there a way to update and change the bank lines in the HEC-RAS RAS Mapper for HEC-RAS 5.0? I am trying to find out how to update the channel in my terrain model but I am have not luck in trying to expand my bank lines. Thanks!

    ReplyDelete
    Replies
    1. Not in RAS Mapper. But you can adjust the bank stations individually in the cross section editor, or graphical cross section editor.

      Delete
  17. Hi Chris,
    Is there a way to generate the "XS Interpolation Surface" from the HECRAS environment? Or we need to provide it in advance in order to generate the terrian?

    ReplyDelete
    Replies
    1. This is done for you in RAS Mapper. It is one of the layers that RAS creates in the geometry group.

      Delete
    2. Thanks, Chris.
      I just found the menu on the left-hand-side of the RAS Mapper could be collapsed, and I need to clip on the ellipsis icon to expand it. Now I can see the XS Interpolation surface by checking the selection box next to the layer name.

      Delete
  18. Hi - thanks for this post. I've also been referring to the 2D modelling manual and would like to clarify the following parameters when creating a new terrain:

    1. What does 'create stitches' do when inputting more than one terrain file?
    2. What does the Rounding/precision refer to?

    Thanks!

    ReplyDelete
    Replies
    1. 1. It's a way for RAS Mapper to better blend the multiple elevation datasets together. I don't know the exact details of how it works.
      Try it both ways and look at the differences to see which you prefer.
      2. This is how RAS Mapper rounds off the elevation values for each cell. Typically the default works well. However, in very shallow terrain, you may get a stair-stepped look in profile view, in which case you would want to use a more precise value.

      Delete
    2. Thanks Chris.

      So Precision = 1/100 would round to 2 decimal places? i.e. 0.01

      I am building a linked 1D-2D model and am wondering whether it would be beneficial to generate a combined channel/overbank terrain model. If I have surveyed cross sections which will model in-bank flow in 1D, is there any benefit from creating a 2D channel terrain model from the cross sections?

      Delete
    3. Correct. Yes, there are benefits. There are also drawbacks. A single 2D model is cleaner and less prone to errors/instabilities that you can commonly get at connections like lateral structures. Also, with only 2D, you don't have to worry about where to put ineffective flow areas (2D figures that out for you). But the downside to all 2D is if you have a very long reach, it could make computation time too long. Also, you won't have access to the familiar output plots like the profile plot and cross section plot (although you can do something very similar to that with profile lines in RAS Mapper). Also, you'll need to be very careful about identifying areas of leaking from the main channel to the overbanks, if you have any high ground features like levees along your river. But those are usually easy to spot.

      Good luck!

      Delete
  19. Hi Chris,

    I am following most of your blogs. I am trying to include bathymetry in terrain. I am using HEC-RAS 5.0.3. While exporting XS interpolation surface into Geotiff file, I don't have option Create Terrain GeoTiff from XS´s (channel only) under Export layer. Instead it has other options to convert into shapefile. What might be the issues with this?

    ReplyDelete
    Replies
    1. You have to right-click on the geometry file in the RAS Mapper layer manager. There you should see the option to export XS interpolation surface to a GeoTiff file.

      Delete
  20. I have a fairly simple question, but I am struggling to determine the answer. I imported my XS's from a CSV file, and when I made the XS interpolated surface from them, the bank lines crossed. Is this an easy fix that I am missing?

    ReplyDelete
    Replies
    1. Sounds like one or more. Ross sections are oriented in the wrong direction. Cross sections should be oriented from left to right When looking in the downstream direction. You can view the cross section dir cation arrows in the RAS schematic. Just need to swap the cut line coordinates of the affected cross sections that fix this.

      Delete
  21. In 1D and 2D linked model, if 1D cross-sections bank are slightly higher from linked 2D surface than at what point water will start spilling over to 2D? Is it as soon as the water level in 1D rises to the level of 2D surface?

    ReplyDelete
    Replies
    1. In a 1D2D inline connection, where the 1D reach flows into a 2D area, the following transfer of information occurs at each time step. Flow in the boundary cross section is passed to all of the boundary cells and distributed based on a conveyance weighting in the cells. The water surface elevation is taken at each of the boundary cells and averaged (again based on a conveyance weighting) and that average water surface elevation is assigned to the boundary cross section. RAS does not know about "spilling" of flow over high ground in the cross section. That's why it is very important that your bounding cross section and your bounding cells share the same underlying terrain.

      Delete
  22. Hi. If i want to change the terrain of my river and only have the terrain in RAS-mapper, is there a way to change/draw cross sections in HEC-RAS? Or do i have to use Hec-georas? In this example you already have river, bank and cross sections, but can this be made from a DEM (.tiff) in RAS-mapper without using Hec-georas.

    I want to avoid using Hec-georas because i do not want to convert my DEM to TIN

    In this example i se that you have geometry

    ReplyDelete
    Replies
    1. In HEC-RAS Version 5.0.4, you can do all of this in RAS Mapper.

      Delete
  23. Chris,
    This is really helpful. I have a LARGE river model (>400 miles) that I only want to generate the channel terrain of a small portion for (10 miles at a time). I see no options in the Export Layer dialogue that would allow me to select one of the reaches in the model. Short of deleting out the cross sections and creating a new project file, is there a way to generate a terrain for a subset of the cross sections?

    ReplyDelete
  24. Background: We have surveyed cross sections multiple thousand feet apart on a stream.

    Problem: We need more dense XS's in order to create stable unsteady model.

    Potential Solution: Use the method in this post, modified slightly.
    1) use GeoRAS's "update XS Elevations" tool to create XS with surveyed bathymetry data at locations where the survey was taken, and lidar along the rest of the XS.
    2)Export those XS to RAS. Use "Interpolate XS" tool in RAS to get channel data interpolated between XS. This step is where I think the process may break down.
    3) Use the "XS Interpolation Surface" from RASmapper to get a Terrain using the interpolated sections (herein lies the rub: not sure RASmapper will create a surface that follows the stream line using Interpolated sections).
    4) Export the Terrain in the channel only, per the method on this post.
    5) Merge the channel Terrain with the original LiDAR surface and use that new Terrain in GeoRAS to cut intermediate XS with accurate LiDAR and interpolated channel data.

    It seems like I may be making this more complicated than it has to be. I appreciate your thoughts.

    -Alan

    ReplyDelete
  25. Hey

    I managed to implement bathymetrie in my terrain. But for one part my interpolation surface looks like two triangles between two crosssection instead of a rectangel (color: from white to black). Is there a posibility to change that shape. If I merge the terrains it looks very bad. It interpolates the terain only very near to the crosssections.
    I have that problem only for this particular part (I model a concrete wall around a river reach. in front of a culvert)
    Could you help me?
    Thank you!
    -Geo

    ReplyDelete
  26. Anyone have any idea if or when the GeoRAS "update XS Elevations" function will be available in RAS Mapper pre-processing tools? I have been using a hybrid GeoRAS & Mapper approach for developing models as shown above.

    ReplyDelete
  27. I merged channel bathymetry into the DEM. When I checked the station-elevation for some cross-sections, there is a shift between merged terrain and surveyed cross-section graph. However, when I checked the cross-section in geometry data, they are matched. Does anyone know how to solve this issue?

    ReplyDelete
  28. Hi Chris,

    I use method in this post many times and it work excelent for create DTM of channel. Hovever today I have problem with some stretches, where interpolation failed. I attach URL with image https://ibb.co/cvwsG02 Direction of Cross Sections and River is correct. I tried re-compute staion and Reach lengts, delete Edge lines and Bank lines, but the problem persists. Do you know how can I fix it?

    Thank´s

    Jaroslav

    ReplyDelete
    Replies
    1. I can't tell from the image alone. Just make sure to check the following:
      1. Cross sections drawn from left to right (looks like you did this).
      2. Reach line is drawn from upstream to downstream and every cross section is intersected by the reach centerline (looks like you did this).
      3. Make sure the reach centerline is always between the bank stations.
      4. Make sure the reach lengths for each cross section are correct.

      Outside of that, not sure what could cause this issue.

      Delete
  29. Hey Chris,
    I've encountered a problem while going through this process. When exporting the "Channel only" interpolated surface, the created surface includes areas beyond the channel. Moreover, these areas are not reflecting the real overbank topography, but rather some weird topography. Here is a link to a picture of the said surface: https://ibb.co/ZJ65kh2. I turned on the bank lines so you can see where the surface diverts from them.
    Do you have any thoughts on how to resolve this issue?

    ReplyDelete
  30. Hi Chris,
    I am using HEC-RAS 5.0.6. I have followed tutorials on creating 1D geometry in RAS Mapper, editing in the Geometry Editor, and then using it to modify your terrain back in RAS Mapper. Is there a way to import georeferenced cross section data into RAS Mapper as 1D geometry to modify your terrain, similar to above, without having to assign river stationing with GeoRAS? (Just XYZ data) Or, could it be assigned a dummy value for river station that would separate each cross section, but not dictate the length of river between the sections? I hope this makes sense, I can clarify if needed. Thanks!

    ReplyDelete
    Replies
    1. Hi Kathleen- Yeah, there's no need to have any kind of spatiality associated with your river stationing. Can be "dummy" values. Just make sure they are numerically in the correct order. Outside of that, the numbers don't matter, they're just ID's. Especially if you are only using the cross sections to make a terrain.

      Delete
  31. Hi Chris
    I am using HEC RAS 5.0.7, initially i had run the 1D model by creating XS's in Rasmapper.After that again i changed the XS's location but reach lengths and river stations are not getting updated. please help me in this regard.
    Thank you

    ReplyDelete

Note: Only a member of this blog may post a comment.