Skip to content

Commit

Permalink
Change cut_off value to meters
Browse files Browse the repository at this point in the history
  • Loading branch information
ezhilsabareesh8 committed Nov 5, 2024
1 parent 61f9e7f commit 5ff9cfe
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ Options
usage: topogtools min_dy --input <input_file> --output <output_file> --hgrid <grid> --cutoff <cutoff_value>
```

Convert ocean cells into land if their y size is smaller than <cutoff_value> kilometres.
Convert ocean cells into land if their y size is smaller than <cutoff_value> metres.

# Building and Installation

Expand Down
4 changes: 2 additions & 2 deletions src/topography.f90
Original file line number Diff line number Diff line change
Expand Up @@ -493,10 +493,10 @@ subroutine topography_min_dy(this, hgrid, cutoff)

! Calculate T cell size based on dy
! For each point, the T cell size is a sum of dy(2*i-1, 2*j) and dy(2*i, 2*j)
! Apply cutoff to depth based on the provided T-cell cutoff value in kilometers
! Apply cutoff to depth based on the provided T-cell cutoff value in meters
do i = 1, ny_len / 2
do j = 1, (nxp_len - 1) / 2
if (dy(2 * i - 1, 2 * j) + dy(2 * i, 2 * j) < cutoff*1000.0_real64) then !Input cutoff in Kilometers covert it to meters
if (dy(2 * i - 1, 2 * j) + dy(2 * i, 2 * j) < cutoff) then !Input cutoff in meters
this%depth(i, j) = MISSING_VALUE ! Set values below cutoff to zero or another value as needed
end if
end do
Expand Down

0 comments on commit 5ff9cfe

Please sign in to comment.