Page 1 of 1
Modifying a DEM
Posted: 15 Oct 2014 20:40
by brasshat
OK, I sometimes like to dabble in imaginary railroads, those that did not exist, but if they had in the area in which I was modeling them, they would have looked like the model. I found a bit of a DEM map which would be an absolutely wonderful extension of an imaginary module. The problem is that compared with the orientation of my module, and idea, the DEM needs to be modified, by rotating it 130 degrees, or so, and by mirror imaging it.
Is there a reasonable way to modify the DEM in this manner, or is it back to manual methods for this one?
ns
Re: Modifying a DEM
Posted: 15 Oct 2014 21:26
by geophil
DEM rotation is a bit of a challenge and not directly supported. DEM files usually comes with geo referencing included in the file and you can't really modify that. What might be possible - but I have not tested that -, if you are good in math and know how to define and run formulas in a spreadsheet: In TransDEM export the DEM to an xyz text file. Open in the spreadsheet, and apply rotation to the x and y components, using a
rotation matrix or - probably much better - a combination of translation and rotation to retain the anchor point. Write back as xyz and import into TransDEM. It should work but I won't guarantee it.
Same then with mirroring, the
matrix is your friend.
Re: Modifying a DEM
Posted: 16 Oct 2014 06:00
by brasshat
I'd say I was tolerable in Math, but might not go so far as to use the descriptor "good". And I remember having some exposure to matrix arithmetic in Algebra III in grade 11, or so, but I've not done anything with it since. This is not the highest item on my wish list, and I do have some other projects ahead of it. And the area I want to use is represented in 1:24000 scale maps from a century ago or so, and I can perhaps use this to work through tutorial 9 on TIN.
ns