Opened 12 years ago

Last modified 11 years ago

#548 closed bug

IMPORTANT: Corrected a bug in GST propagator (periodic applications) — at Initial Version

Reported by: arango Owned by: arango
Priority: major Milestone: Adjoint Based Algorithms
Component: Adjoint Version: 3.6
Keywords: Cc:

Description

Corrected a nasty bug in the Generalized Stability Theory (GST) adjoint-based propagators for periodic applications. We have been hunting on and off for this bug for the last six months. It was very frustrating because we didn't have a clue. We systematically searched for the bug and finally found it in the last thing that we checked. It was in the packing and unpacking routines of the state vector that communicates with the ARPACK library, wpoints.F. We just ignored that IstrU and IstrV is 1 in periodic applications and not 2 for the tiles adjacent to the boundary.

Rats... it is not the first time that we introduce bugs with that nasty logic in periodic boundary conditions.

A new test case is added CHANNEL for a uniform periodic channel. We are adding this one to the test suite. It is a very simple test for the Optimal Perturvation eigenfunction. It also illustrate how to use the error function package in the ROMS/Utility/erf.F module. This module has very convenient mathematical functions that are not part of the standard Fortran:

 ERF        Error function, ERF(x)
 ERFC       Complementary error function, ERFC(x)
 ERFCC      Complementary error function, ERFCC(x), cheaper Chebyshev fitting approximation
 GAMMP      Incomplete gamma function, P(a,x)
 GAMMQ      Incomplete gamma function complement, Q(a,x)=1-P(a,x)

These functions can be used to code a variety of analytical solutions.

Many thanks to Andy Moore for his help searching for this bug and coming up with an analytical test case. Also thank you to Kevin Smith for running the test cases.

I also corrected a typo in read_phypar.F. Many thanks to John Luick for bringing this to my attention.

Change History (0)

Note: See TracTickets for help on using tickets.