Skip to content

Error and use of SQRT in NN search in cable_parameters #643

@Whyborn

Description

@Whyborn

There's no need to take the SQRT of the distances computed in cable_parameters.F90 here and here when finding the nearest neighbour from the gridinfo file (is there a reason we do this search twice?). I can't think of any instance where this would be necessary, assuming we set an appropriately high starting value.

On further inspection, the implementation appears to be flat wrong around the antimeridian? A point at 179.5 degrees would be computed to be 359 degrees away from a point at -179.5 degrees. Unlikely to be a big problem given this is mostly over ocean, but should still be fixed.

Metadata

Metadata

Assignees

Labels

code clean-upe.g., removal of dead codeinvalidThis doesn't seem right

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions