Skip to content

Commit

Permalink
fixed typo
Browse files Browse the repository at this point in the history
  • Loading branch information
giumas committed Apr 15, 2024
1 parent 324614e commit 9b510aa
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion hyo2/ssm2/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
logger.addHandler(logging.NullHandler())

name = "Sound Speed"
__version__ = '2024.0.3'
__version__ = '2024.0.4'
__copyright__ = 'Copyright 2024 University of New Hampshire, Center for Coastal and Ocean Mapping'

pkg_info = PkgInfo(
Expand Down
10 changes: 5 additions & 5 deletions hyo2/ssm2/lib/profile/ray_tracing/ray_tracing.py
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,8 @@ def get_svp_layer_parameters_slow(cls, launch_angle_radians, depths, speeds):
total_time[j + 1] = total_time[j] + log(tan(gamma[j + 1] / 2.0) / tan(gamma[j] / 2.0)) / gradient[j]
total_range[j + 1] = total_range[j] + radius[j] * (cos(gamma[j]) - cos(gamma[j + 1]))

# Note the last radius doen't get computed but that isn't important
# we always want to be in the last layer, so we use the comptutations at the next to last layer
# Note the last radius doesn't get computed but that isn't important
# we always want to be in the last layer, so we use the computations at the next to last layer
# and interpolate to the depth/time which is before the end of the last layer
return gradient, gamma, radius, total_time, total_range

Expand Down Expand Up @@ -77,8 +77,8 @@ def ray_trace(cls, travel_times, depths, speeds, params, b_project=False):
if nr_end_layer < nr_layers or b_project: # SVP deep enough

tau = travel_times[ind] - total_time[nr_end_layer]
# Note the last radius doen't get computed but that isn't important
# we always want to be in the last layer, so we use the comptutations at the next to last layer
# Note the last radius doesn't get computed but that isn't important
# we always want to be in the last layer, so we use the computations at the next to last layer
# and interpolate to the depth/time which is before the end of the last layer
if radius[nr_end_layer] == 0:

Expand Down Expand Up @@ -114,7 +114,7 @@ def ray_trace(cls, travel_times, depths, speeds, params, b_project=False):
-cos(2 * arctan(tan(gamma[nr_end_layer] / 2.0) * exp(gradient[nr_end_layer] * tau))) + cos(
gamma[nr_end_layer])) + total_range[nr_end_layer]

# this would translate to acrosstrack, alongtrack components if we passed in pitch, roll, launchangle
# this would translate to across-track, along-track components if we passed in pitch, roll, launch angle
# result[0]=finalrange*LaunchVector[0]/sqrt(LaunchVector[1]*LaunchVector[1]+LaunchVector[0]*LaunchVector[0])
# result[1]=finalrange*LaunchVector[1]/sqrt(LaunchVector[1]*LaunchVector[1]+LaunchVector[0]*LaunchVector[0])
# result[2]=finaldepth
Expand Down

0 comments on commit 9b510aa

Please sign in to comment.