1

I have a generic digital surface model (DSM) and I want to simulate illumination in different parts of the country on the same day, all using the same DSM. (i.e., how does illumination differ in Seattle and San Antonio on March 4?) I am using the ArcMap v10.4 hillshade function, but there are other implementations of hillshade functions in various software packages.

The ArcMap hillshade function requires the solar elevation and azimuth as inputs. These can be calculated for a given location and date/time using NOAA's solar position calculator.

I want to know if the spatial location of the DSM affects the output of the hillshade function, or if the elevation and azimuth are the only variables that affect the output.

To test this, I created three separate rasters as inputs: my original projected DSM, the DSM with the projection removed, and the DSM projected but shifted an arbitrary number of X and Y units. In R:

require(raster)

#Input one
DSM <- raster("DSM.tif")

#Input two
DSM_nocrs <- raster("DSM.tif")
crs(DSM_nocrs) <- NULL

#Input three
DSM_shifted <- shift(DSM, x = 100000, y = 100000)

I inputted these three rasters into the ArcMap hillshade function using the same solar elevation and azimuth. I saved the outputs to my working directory. I then compared the raw values of each output in R.

DSM_hillshade <- raster("DSM_hillshade.tif")
DSM_nocrs_hillshade <- raster("DSM_nocrs_hillshade.tif")
DMS_shift_hillshade <- raster("DMS_shift_hillshade.tif")

all.equal(values(DSM_hillshade), values(DSM_nocrs_hillshade))
[1] TRUE

all.equal(values(DSM_hillshade), values(DSM_shift_hillshade))
[1] TRUE

As you can see, R indicates that the values of the three hillshade rasters are the same even though one wasn't projected and one had a different spatial location. This suggests that the spatial location of the DEM/DSM has no impact on the output of the hillshade function. Perhaps then, for my analysis, I do not need to change the spatial location of my generic DSM and only need to change the solar elevation and azimuth.

My question: Does this seem like a fair interpretation? Is there any reason to believe that the spatial location of a projected DEM/DSM has an impact of the output of a hillshade function?

0

1 Answer 1

1

Yes that's a fair interpretation, and no I don't believe location has any bearing on the hillside function.

The default settings give the best appearance rather than taking position into account unless you give extra parameters for it to work with.

According to How Hillshade works

The default azimuth is 315 degrees (NW)
The default [altitude] is 45 degrees

This will illuminate your hillshade as if the sun is to the northwest (where in the US the sun would be towards the south).

From Why the default value of the azimuth in the hillshade is 315?

It has to do with how the human eye perceives shadows and depths and putting the light source from the North/NorthWest has the effect to put shadows at the base of hills/ridges/mountains and thus, they are not depressions, but appear as extrusions.

If your goal is to iterate and change the sun's position to simulate real effects of shadows for a modeling exercise, then the default value should be changed to simulate the sun's position in the sky.

If it's to make a "pretty shaded relief map" keeping it at the default generally produces the best looking Hillshade output.

As such using the defaults will put the sun in the same position and angle on any hillshade you produce.

Using your own values would put the sun into a different position. Using those same values for two different locations will put the sun at the same angle and position for each hillshade. To model the sun at the same time for the different locations would require you to get and set the different azimuths and altitudes relative to each location.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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