[mpas-developers] Test Case 6 Error

Michael Duda duda at ucar.edu
Thu Mar 18 14:25:13 MDT 2010


Hi, Doug.

Wow -- thanks very much for finding this! When I had originally
implemented TC6, the initial conditions looked a little off, and
the results were incorrect, and after looking through the code and
paper about 10 times or so, I couldn't find the problem. It turns
out that the minus sign in the -2 power had been completely lost
in the scan of the article that I had been working from, with only
some extra white space between 'cos' and '2 theta' in equation
147.

Please commit this fix whenever you're ready!

Michael


On Thu, Mar 18, 2010 at 02:58:34PM -0400, Doug Jacobsen wrote:
> Hello All,
> 
> I have been working on the variable resolution results for TC2, TC5, and TC6
> with Todd. We ran into an issue with the TC6 results, and after digging
> through the code I found an error in the initialization for TC6. On lines
> 510 and 511 of module_test_cases.F the function AA(theta) is defined as
> 
> AA = 0.5 * w * (2.0 * omega + w) * cos(theta)**2.0 + &
>       0.25 * K**2.0 * cos(theta)**(2.0*R) * ((R+1.0)*cos(theta)**2.0 +
> 2.0*R**2.0 - R - 2.0 - 2.0*(R*cos(theta))**2.0)
> 
> In the Williamson paper, he defines this as:
> 
> AA = 0.5 * w * (2.0 * omega + w) * cos(theta)**2.0 + &
>       0.25 * K**2.0 * cos(theta)**(2.0*R) * ((R+1.0)*cos(theta)**2.0 +
> 2.0*R**2.0 - R - 2.0 - 2.0*R**2*cos(theta))**-2.0
> 
> The main (or only) difference that I found was in the currently implemented
> case, cos(theta) (the last term) is squared, but it really need to be raised
> to the -2 power.
> 
> Doug

> _______________________________________________
> mpas-developers mailing list
> mpas-developers at mailman.ucar.edu
> http://mailman.ucar.edu/mailman/listinfo/mpas-developers



More information about the mpas-developers mailing list