background information on acquisition and analysis of … compass... · 2004-12-13 · background...

10
Background Information on Acquisition and Analysis of Bathometric Data (The technical details for those that like this type of stuff) Raw depth data is collected using a Lowrance X15 GPS/Sonar unit configured with WAAS or DGPS capabilities. The data density of the survey will depend on the final map resolution required. Ideally survey points should be concentrated in areas where the depth is changing rapidly. Data acquired by the X15 unit is stored onto 256 Mb storage cards using the Log Sonar Chart Data feature. A 256 Mb storage card is capable of storing >20 hours of data at acquisition rates of > 1 hertz. The raw data is transferred from the storage card to a Windows PC using a card reader. Each sonar file is opened with the Lowrance Sonar Viewer application. The raw data is exported into a standard ASCII text file using the Output Chart Information feature of the Sonar Viewer Application. The text files for an entire lake are imported into MS Excel and sorted to remove data without depth or position data. For large lakes, with greater than 64,000 depth measurements, multiple files are used. The boat position data reported by the Lowrance Sonar Viewer application uses a non- standard coordinate system (Mercator Meter). An MS Excel macro is used to convert the position data to decimal degree or Universal Transverse Mercator coordinate systems that are compatible to most mapping programs (Macro attached). Figure 1 shows the results of a typical bathometric survey. The survey data is augmented with lake boundary data downloaded from the Maine Office of GIS. The depth of a lake boundary is zero and these points should be added to the bathymetry data file before calculating a grid. Figure 1. Data coverage for East Pond, Smithfield,

Upload: others

Post on 15-Apr-2020

0 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Background Information on Acquisition and Analysis of … Compass... · 2004-12-13 · Background Information on Acquisition and Analysis of Bathometric Data (The technical details

Background Information on Acquisition and Analysis of Bathometric Data (The technical details for those that like this type of stuff)

Raw depth data is collected using a Lowrance X15 GPS/Sonar unitconfigured with WAAS or DGPS capabilities. The data density of the survey willdepend on the final map resolution required. Ideally survey points should beconcentrated in areas where the depth is changing rapidly. Data acquired by theX15 unit is stored onto 256 Mb storage cards using the Log Sonar Chart Datafeature. A 256 Mb storage card is capable of storing >20 hours of data atacquisition rates of > 1 hertz. The raw data is transferred from the storage cardto a Windows PC using a card reader. Each sonar file is opened with theLowrance Sonar Viewer application. The raw data is exported into a standardASCII text file using the Output Chart Information feature of the Sonar ViewerApplication. The text files for an entire lake are imported into MS Excel andsorted to remove data without depth or position data. For large lakes, withgreater than 64,000 depth measurements, multiple files are used. The boatposition data reported by the Lowrance Sonar Viewer application uses a non-standard coordinate system (Mercator Meter). An MS Excel macro is used toconvert the position data to decimal degree or Universal Transverse Mercatorcoordinate systems that are compatible to most mapping programs (Macroattached). Figure 1 shows the results of a typical bathometric survey. Thesurvey data is augmented with lake boundary data downloaded from the MaineOffice of GIS. The depth of a lake boundary is zero and these points should beadded to the bathymetry data file before calculating a grid.

Figure 1. Data coverage for East Pond, Smithfield,Maine.

Page 2: Background Information on Acquisition and Analysis of … Compass... · 2004-12-13 · Background Information on Acquisition and Analysis of Bathometric Data (The technical details

Waterville Analytical October 2004 page 2 of 10

Most mapping programs require regularly spaced data for data display.Raw bathymetery data was gridded into a regular data array using GoldenSoftware’s Surfer program. The final grid spacing for the map is determined bythe original data density and the expected use of the map. Gridded data filesmay be displayed as surfaces, contour maps, or exported to other programs suchas ESRI ARC Map, ESRI shape files, Delorme XMap, or XYZ ASCII grid files.Examples of map products are provided in the appendix at the end of thisdocument.

Page 3: Background Information on Acquisition and Analysis of … Compass... · 2004-12-13 · Background Information on Acquisition and Analysis of Bathometric Data (The technical details

Waterville Analytical October 2004 page 3 of 10

Advanced MappingThe challenge in obtaining high resolution depth maps is to sample the

lake strategically. Ideally, data density should be proportional to the rate ofchange of the lake bottom depth with distance. A flat lake bottom requires fewdata measurements to accurately map the depth. In contrast, abrupt changes inlake depth require lots of data density in order to capture the complexity of thelake bottom. To facilitate high resolution lake mapping, we have written aLabView-based software product that interfaces to Lowrance GPS/Sonar products.The software allows the user to import preliminary maps into a display windowand then plot boat position on the map. Using this tool, additional data collectionmay be concentrated in areas of rapid depth change. The software alsointerfaces to YSI Inc. water quality sensors for in situ measurement of waterquality parameters such as oxygen and temperature.

Figure 2. Advanced Bathymetry Software used to optimize depth surveys.

Lake map used forhigh resolution surveys

Page 4: Background Information on Acquisition and Analysis of … Compass... · 2004-12-13 · Background Information on Acquisition and Analysis of Bathometric Data (The technical details

Waterville Analytical October 2004 page 4 of 10

Excel Functions for Coordinate Conversion from Metric Mercator to UTM. Thesefunctions may be distributed free of charge to other Lowrance customers andshould not be resold. The user will need to be familiar with the MS EXCELmacro/function structure and syntax, and VBAproject modules.

'*************************************************************'Whitney King, Mao Zheng, Department of Chemistry, Colby College'Waterville, Maine 04901, 2004. [email protected], www.colby.edu.'These functions may be distributed to other interested parties at no charge'with proper acknowledgement and should not be resold.'Functions for the conversion of LL to UTM were obtained from the'Ordinace Survey office of Great Britain (www.gps.gov.uk) Full documentation on'the conversions may be obtained from their web site.'*************************************************************

Private Function ZoneChooser(Longitude)'Choose the UTM zone number according to user input decimal Longitude'East is positive directionDim PreZNum As DoublePreZNum = (180 + Longitude) / 6 + 1ZoneChooser = Int(PreZNum)End Function

Function WGS84LL2East(PHI As Double, LAM As Double)'Project Latitude and longitude to Transverse Mercator eastings.'Input: - _ Latitude (PHI) and Longitude (LAM) in decimal degrees; _ ellipsoid axis dimensions (a & b) in meters; _ eastings of false origin (e0) in meters; _ central meridian scale factor (f0); _ latitude (PHI0) and longitude (LAM0) of false origin in decimal degrees.'North and East are positive direction

'constants specific to WGS84Dim a, b, e0, f0, PHI0 As Doublea = 6378137b = 6356752.3141e0 = 500000f0 = 0.9996PHI0 = 0

'Calculate LAM0 of the UTM zone which the user input Longitude is inDim PreZNum As DoubleDim ZNum As IntegerDim LAM0 As DoublePreZNum = (180 + LAM) / 6 + 1ZNum = Int(PreZNum)LAM0 = -(183 - 6 * ZNum)

'Convert angle measures to radians PI = 3.14159265358979 RadPHI = PHI * (PI / 180) RadLAM = LAM * (PI / 180) RadPHI0 = PHI0 * (PI / 180)

Page 5: Background Information on Acquisition and Analysis of … Compass... · 2004-12-13 · Background Information on Acquisition and Analysis of Bathometric Data (The technical details

Waterville Analytical October 2004 page 5 of 10

RadLAM0 = LAM0 * (PI / 180)

af0 = a * f0 bf0 = b * f0 e2 = ((af0 ^ 2) - (bf0 ^ 2)) / (af0 ^ 2) n = (af0 - bf0) / (af0 + bf0) nu = af0 / (Sqr(1 - (e2 * ((Sin(RadPHI)) ^ 2)))) rho = (nu * (1 - e2)) / (1 - (e2 * (Sin(RadPHI)) ^ 2)) eta2 = (nu / rho) - 1 p = RadLAM - RadLAM0

IV = nu * (Cos(RadPHI)) V = (nu / 6) * ((Cos(RadPHI)) ^ 3) * ((nu / rho) - ((Tan(RadPHI) ^ 2))) VI = (nu / 120) * ((Cos(RadPHI)) ^ 5) * (5 - (18 * ((Tan(RadPHI)) ^ 2)) + ((Tan(RadPHI)) ^ 4) + (14 *eta2) - (58 * ((Tan(RadPHI)) ^ 2) * eta2))

WGS84LL2East = e0 + (p * IV) + ((p ^ 3) * V) + ((p ^ 5) * VI)

End Function

Function WGS84LL2North(PHI As Double, LAM As Double)'Project Latitude and longitude to Transverse Mercator northings'Input: - _ Latitude (PHI) and Longitude (LAM) in decimal degrees; _ ellipsoid axis dimensions (a & b) in meters; _ eastings (e0) and northings (n0) of false origin in meters; _ central meridian scale factor (f0); _ latitude (PHI0) and longitude (LAM0) of false origin in decimal degrees.

'REQUIRES THE "Marc1" FUNCTION

'constants specific to WGS84Dim a, b, e0, f0, n0, PHI0 As Doublea = 6378137b = 6356752.3141e0 = 500000f0 = 0.9996PHI0 = 0n0 = 0

'Calculate LAM0 of the UTM zone which the user input Longitude is inDim PreZNum As DoubleDim ZNum As IntegerDim LAM0 As DoublePreZNum = (180 + LAM) / 6 + 1ZNum = Int(PreZNum)LAM0 = -(183 - 6 * ZNum)

'Convert angle measures to radians PI = 3.14159265358979 RadPHI = PHI * (PI / 180) RadLAM = LAM * (PI / 180) RadPHI0 = PHI0 * (PI / 180) RadLAM0 = LAM0 * (PI / 180)

af0 = a * f0

Page 6: Background Information on Acquisition and Analysis of … Compass... · 2004-12-13 · Background Information on Acquisition and Analysis of Bathometric Data (The technical details

Waterville Analytical October 2004 page 6 of 10

bf0 = b * f0 e2 = ((af0 ^ 2) - (bf0 ^ 2)) / (af0 ^ 2) n = (af0 - bf0) / (af0 + bf0) nu = af0 / (Sqr(1 - (e2 * ((Sin(RadPHI)) ^ 2)))) rho = (nu * (1 - e2)) / (1 - (e2 * (Sin(RadPHI)) ^ 2)) eta2 = (nu / rho) - 1 p = RadLAM - RadLAM0 M = Marc1(bf0, n, RadPHI0, RadPHI)

I = M + n0 II = (nu / 2) * (Sin(RadPHI)) * (Cos(RadPHI)) III = ((nu / 24) * (Sin(RadPHI)) * ((Cos(RadPHI)) ^ 3)) * (5 - ((Tan(RadPHI)) ^ 2) + (9 * eta2)) IIIA = ((nu / 720) * (Sin(RadPHI)) * ((Cos(RadPHI)) ^ 5)) * (61 - (58 * ((Tan(RadPHI)) ^ 2)) +((Tan(RadPHI)) ^ 4))

WGS84LL2North = I + ((p ^ 2) * II) + ((p ^ 4) * III) + ((p ^ 6) * IIIA)

End Function

Private Function Marc1(bf0, n, PHI0, PHI)'Compute meridional arc.'Input: - _ ellipsoid semi major axis multiplied by central meridian scale factor (bf0) in meters; _ n (computed from a, b and f0); _ lat of false origin (PHI0) and initial or final latitude of point (PHI) IN RADIANS.

'THIS FUNCTION IS CALLED BY THE - _ "Lat_Long_to_North" and "InitialLat" FUNCTIONS'THIS FUNCTION IS ALSO USED ON IT'S OWN IN THE "Projection and TransformationCalculations.xls" SPREADSHEET

Marc1 = bf0 * (((1 + n + ((5 / 4) * (n ^ 2)) + ((5 / 4) * (n ^ 3))) * (PHI - PHI0)) _ - (((3 * n) + (3 * (n ^ 2)) + ((21 / 8) * (n ^ 3))) * (Sin(PHI - PHI0)) * (Cos(PHI + PHI0))) _ + ((((15 / 8) * (n ^ 2)) + ((15 / 8) * (n ^ 3))) * (Sin(2 * (PHI - PHI0))) * (Cos(2 * (PHI + PHI0)))) _ - (((35 / 24) * (n ^ 3)) * (Sin(3 * (PHI - PHI0))) * (Cos(3 * (PHI + PHI0)))))

End Function

Function WGS84UTM2Lat(East As Double, North As Double, ZoneNum As Integer)'Un-project Transverse Mercator eastings and northings back to latitude.'Input: - _ eastings (East) and northings (North) in meters; _ ellipsoid axis dimensions (a & b) in meters; _ eastings (e0) and northings (n0) of false origin in meters; _ central meridian scale factor (f0) and _ latitude (PHI0) and longitude (LAM0) of false origin in decimal degrees.

'REQUIRES THE "Marc1" AND "InitialLat1" FUNCTIONS

'Datum specific constanta = 6378137b = 6356752.3141e0 = 500000f0 = 0.9996PHI0 = 0n0 = 0

Page 7: Background Information on Acquisition and Analysis of … Compass... · 2004-12-13 · Background Information on Acquisition and Analysis of Bathometric Data (The technical details

Waterville Analytical October 2004 page 7 of 10

'Convert angle measures to radians PI = 3.14159265358979 RadPHI0 = PHI0 * (PI / 180) LAM0 = 6 * ZoneNum - 183 RadLAM0 = LAM0 * (PI / 180)

'Compute af0, bf0, e squared (e2), n and Et af0 = a * f0 bf0 = b * f0 e2 = ((af0 ^ 2) - (bf0 ^ 2)) / (af0 ^ 2) n = (af0 - bf0) / (af0 + bf0) Et = East - e0

'Compute initial value for latitude (PHI) in radians PHId = InitialLat1(North, n0, af0, RadPHI0, n, bf0)

'Compute nu, rho and eta2 using value for PHId nu = af0 / (Sqr(1 - (e2 * ((Sin(PHId)) ^ 2)))) rho = (nu * (1 - e2)) / (1 - (e2 * (Sin(PHId)) ^ 2)) eta2 = (nu / rho) - 1

'Compute Latitude VII = (Tan(PHId)) / (2 * rho * nu) VIII = ((Tan(PHId)) / (24 * rho * (nu ^ 3))) * (5 + (3 * ((Tan(PHId)) ^ 2)) + eta2 - (9 * eta2 *((Tan(PHId)) ^ 2))) IX = ((Tan(PHId)) / (720 * rho * (nu ^ 5))) * (61 + (90 * ((Tan(PHId)) ^ 2)) + (45 * ((Tan(PHId)) ^ 4)))

WGS84UTM2Lat = (180 / PI) * (PHId - ((Et ^ 2) * VII) + ((Et ^ 4) * VIII) - ((Et ^ 6) * IX))

End Function

Function WGS84UTM2Long(East As Double, North As Double, ZoneNum As Integer)'Un-project Transverse Mercator eastings and northings back to longitude.'Input: - _ eastings (East) and northings (North) in meters; _ ellipsoid axis dimensions (a & b) in meters; _ eastings (e0) and northings (n0) of false origin in meters; _ central meridian scale factor (f0) and _ latitude (PHI0) and longitude (LAM0) of false origin in decimal degrees.

'REQUIRES THE "Marc1" AND "InitialLat" FUNCTIONS'Datum specific constantsa = 6378137b = 6356752.3141e0 = 500000f0 = 0.9996PHI0 = 0n0 = 0

'Convert angle measures to radians PI = 3.14159265358979 RadPHI0 = PHI0 * (PI / 180) LAM0 = 6 * ZoneNum - 183 RadLAM0 = LAM0 * (PI / 180)

Page 8: Background Information on Acquisition and Analysis of … Compass... · 2004-12-13 · Background Information on Acquisition and Analysis of Bathometric Data (The technical details

Waterville Analytical October 2004 page 8 of 10

'Compute af0, bf0, e squared (e2), n and Et af0 = a * f0 bf0 = b * f0 e2 = ((af0 ^ 2) - (bf0 ^ 2)) / (af0 ^ 2) n = (af0 - bf0) / (af0 + bf0) Et = East - e0

'Compute initial value for latitude (PHI) in radians PHId = InitialLat1(North, n0, af0, RadPHI0, n, bf0)

'Compute nu, rho and eta2 using value for PHId nu = af0 / (Sqr(1 - (e2 * ((Sin(PHId)) ^ 2)))) rho = (nu * (1 - e2)) / (1 - (e2 * (Sin(PHId)) ^ 2)) eta2 = (nu / rho) - 1

'Compute Longitude X = ((Cos(PHId)) ^ -1) / nu XI = (((Cos(PHId)) ^ -1) / (6 * (nu ^ 3))) * ((nu / rho) + (2 * ((Tan(PHId)) ^ 2))) XII = (((Cos(PHId)) ^ -1) / (120 * (nu ^ 5))) * (5 + (28 * ((Tan(PHId)) ^ 2)) + (24 * ((Tan(PHId)) ^ 4))) XIIA = (((Cos(PHId)) ^ -1) / (5040 * (nu ^ 7))) * (61 + (662 * ((Tan(PHId)) ^ 2)) + (1320 *((Tan(PHId)) ^ 4)) + (720 * ((Tan(PHId)) ^ 6)))

WGS84UTM2Long = (180 / PI) * (RadLAM0 + (Et * X) - ((Et ^ 3) * XI) + ((Et ^ 5) * XII) - ((Et ^ 7) *XIIA))

End Function

Private Function InitialLat1(North, n0, afo, PHI0, n, bfo)'Compute initial value for Latitude (PHI) IN RADIANS.'Input: - _ northing of point (North) and northing of false origin (n0) in meters; _ semi major axis multiplied by central meridian scale factor (af0) in meters; _ latitude of false origin (PHI0) IN RADIANS; _ n (computed from a, b and f0) and _ ellipsoid semi major axis multiplied by central meridian scale factor (bf0) in meters.

'REQUIRES THE "Marc1" FUNCTION'THIS FUNCTION IS CALLED BY THE "E_N_to_Lat", "E_N_to_Long" and "E_N_to_C" FUNCTIONS'THIS FUNCTION IS ALSO USED ON IT'S OWN IN THE "Projection and TransformationCalculations.xls" SPREADSHEET

'First PHI value (PHI1) PHI1 = ((North - n0) / afo) + PHI0

'Calculate M M = Marc1(bfo, n, PHI0, PHI1)

'Calculate new PHI value (PHI2) PHI2 = ((North - n0 - M) / afo) + PHI1

'Iterate to get final value for InitialLat Do While Abs(North - n0 - M) > 0.00001 PHI2 = ((North - n0 - M) / afo) + PHI1 M = Marc1(bfo, n, PHI0, PHI2)

Page 9: Background Information on Acquisition and Analysis of … Compass... · 2004-12-13 · Background Information on Acquisition and Analysis of Bathometric Data (The technical details

Waterville Analytical October 2004 page 9 of 10

PHI1 = PHI2 Loop

InitialLat1 = PHI2

End Function

Function GeoToMerX(Lon As Double)'Geographic in Degrees to Merctor'Input deg Lon, output meters(or whatever unit) of Mercator X coordinate''algrithm from Patty B at lowrance. WGS84 onlyDim RadToDeg As Double, DegToRad As Double, b As Double, PI As Double, HALF_PI As DoubleRadToDeg = 57.2957795132DegToRad = 0.0174532925199b = 6356752.3142PI = 3.141592654HALF_PI = 1.570796327GeoToMerX = Lon * DegToRad * bEnd Function

Function GeoToMerY(Lat As Double)'Geographic in Degrees to Merctor'Input deg Lat, output meters(or whatever unit) of Mercator Y coordinate''algrithm from Patty B at lowrance. WGS84 onlyDim RadToDeg As Double, DegToRad As Double, b As Double, PI As Double, HALF_PI As DoubleRadToDeg = 57.2957795132DegToRad = 0.0174532925199b = 6356752.3142PI = 3.141592654HALF_PI = 1.570796327GeoToMerY = b * (Log(Tan((Lat * DegToRad + HALF_PI) * 0.5)))End Function

Function MerToGeoLong(xpos As Double)'Merctor to Geographic in Degrees'Input x position in meters (or whatever the standard unit), Output GeoLat in deg'algrithm from Patty B at lowrance. WGS84 onlyDim RadToDeg As Double, DegToRad As Double, b As Double, PI As Double, HALF_PI As DoubleRadToDeg = 57.2957795132DegToRad = 0.0174532925199b = 6356752.3142PI = 3.141592654HALF_PI = 1.570796327MerToGeoLong = xpos * RadToDeg / bEnd Function

Function MerToGeoLat(ypos As Double)'Merctor to Geographic in Degrees'Input y position in meters (or whatever the standard unit), Output GeoLong in deg''algrithm from Patty B at lowrance. WGS84 onlyDim RadToDeg As Double, DegToRad As Double, b As Double, PI As Double, HALF_PI As DoubleRadToDeg = 57.2957795132DegToRad = 0.0174532925199b = 6356752.3142PI = 3.141592654HALF_PI = 1.570796327

Page 10: Background Information on Acquisition and Analysis of … Compass... · 2004-12-13 · Background Information on Acquisition and Analysis of Bathometric Data (The technical details

Waterville Analytical October 2004 page 10 of 10

MerToGeoLat = RadToDeg * (2 * Atn(Exp(ypos / b)) - HALF_PI)End Function

Function UTMZone(LAM As Double)'Calculate the UTM zone from input Longitude.'Input x position in decimal deg.Dim PreZNum As DoubleDim ZNum As IntegerDim LAM0 As DoublePreZNum = (180 + LAM) / 6 + 1ZNum = Int(PreZNum)UTMZone = ZNumEnd Function