Skip to content

TerrainHelper - terrainReferrencePoint and NullPointerException

Problem to solve

When doing SEAMCAT simulation with using terrain it is observed that same Transmitter (Receiver location) have same Cartesian coordinate (x and y), but different Geographic coordinate (Longitude and Latitude) in different links.

This is illustrated with this comparison of detailed results. Red box shows connected by red arrow show cases with differences in Lon / Lat for the same point in x and y coordinate. Green box show case where it is correct.

This is not correct - same point should have same (x and y ) and same geo coordinate (Longitude and Latitude ) independantly of link which is examined.

image

Further details

When inspecting code in detail source of the problem was detected in TerrainHelper.java method verifyAndAddTerrainData( LinkResult linkResult, PropagationModel propagationModel, Scenario scenario)

In this method for reference point (VLT or VLR) connection is established between Geographic coordinate (Longitude and Latitude) and Cartesian coordinate (x and y) whihc is used for the positioning of other points in the same event.

position = Geographic coordinate of the refere3nce point

terrainReferencePoint = Cartesian coordinate of the reference point

getVictimPositionCorrelation = gives info if referecne point is VLT or VLR

image

Proposal

For terrainReferencePoint = Cartesian coordinate of the reference point get the coordinate of the VLT or VLR. Solution is implemented for Generic system VLT and cellular systems. Solution is to be found for the Generic system - VLR.

Notes

  • Geographic coordinate of the reference point is part of the scenario and does not change over simulation
  • Cartesian coordinate of the VLT is always (0,0)
  • Cartesian coordinate of the VLR is changing per event
  • In Cellular system we may have several VLRs positions in event - reference point is base station of reference cell
Edited by Zeljko Tabakovic
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information