Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

For example - if I have a raster DEM covering a stream with higher elevations in the west (up river) and lower elevations in the east (down river) is it possible to reverse this trend so that the east will have higher elevations? The idea is to essentially reverse the direction of the river.

share|improve this question
Negating the elevations will reverse the trend, but make the river look like a ridge. If you could disclose more information about the purpose of this exercise, perhaps more effective solutions could be offered. – whuber Jun 13 '11 at 17:12
I am deriving a river thalweg using the Flow Accumulation/Stream Link tools - along with some raster calculations. The idea is to get the in-flow and out-flow points of my river section from the DEM. The problem is, my thalweg only covers about 3/4 of the rivers' reach. I am hoping that by reversing the trend of the raster I can run the same operations covering the "opposite" 3/4's of the river. – Radar Jun 13 '11 at 18:48
up vote 3 down vote accepted

Are you trying to tilt a DEM?

share|improve this answer

We're looking for long answers that provide some explanation and context. Don't just give a one-line answer; explain why your answer is right, ideally with citations. Answers that don't include explanations may be removed.

This is close to what I am looking for, but I think it might be a bit more involved than what I require. I basically want to reverse the trend of a DEM which is sloped (flowing down a river). – Radar Jun 13 '11 at 18:50
@Radar You are lucky that @Dan has identified such a simple solution! – whuber Jun 13 '11 at 20:04
@whuber - funny how it appears to be your solution! If the "sun angle" is increased enough it is possible to simulate a trend reversal of the raster - essentially reversing the flow direction of the river. It's not perfect, but it's suitable for my purposes. Thanks to you and @Dan. – Radar Jun 13 '11 at 20:40
@whuber but what about all that trig? – Kirk Kuykendall Jun 25 '11 at 23:33
@Kirk That's a good question that perhaps has no simple answer. Usually there are at least two approaches to the kinds of calculations we face in GIS: using trig/spherical geometry (on the one hand) or using Cartesian coordinates, complex arithmetic, or quaternions (on the other hand). Once you master both approaches you can usually tell which is better by comparing the two solutions. In my experience, any trig solution that has to divide the calculation into cases (e.g., according to a quadrant or the sign of an angle) is usually not a good approach: that's a red flag. – whuber Jun 27 '11 at 13:28

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.