floating point with WPP and Qcloud or Qice

Questions relating to the use of the WRF Post Processor V3

floating point with WPP and Qcloud or Qice

Postby DVD » Fri Jul 11, 2008 10:24 am

I’m using WRF-ARW v3 and WPP v3. For our database we need regular lat-lon grib files, that’s why I use the WPP. For our cloud fraction algorithm we need the Qcloud and Qice. But when I set

(CLD WTR ON MDL SFCS ) SCAL=( 3.0)
L=(00000 00000 00000 00000 00000 00000 00000 00000 00000 00000 00000 00000 00000 00000)
(CLD ICE ON MDL SFCS ) SCAL=( 3.0)
L=(00000 00000 00000 00000 00000 00000 00000 00000 00000 00000 00000 00000 00000 00000)

To:

(CLD WTR ON MDL SFCS ) SCAL=( 3.0)
L=(11111 11111 11111 11111 11111 00000 00000 00000 00000 00000 00000 00000 00000 00000)
(CLD ICE ON MDL SFCS ) SCAL=( 3.0)
L=(11111 11111 11111 11111 11111 00000 00000 00000 00000 00000 00000 00000 00000 00000)

It gives a floating point acceptation.

In GRIBBIT.f it calls the function W3FI72, this is the one to give the error.
The error occurs when the variable “GRIDO” is to short. Because for each level it should be dx * dy, but in the case of the floating point acception it is about 12 to short.
I really don’t have a clue why this is, because the same output give nice output with ARWpost->GrADS.

Do anybody know what is going on and where to look for the solution?

Thanks in advanced!

Daniël
DVD
 
Posts: 18
Joined: Tue Jun 17, 2008 5:36 am

Re: floating point with WPP and Qcloud or Qice

Postby ivan » Thu Mar 05, 2009 10:43 am

I am not sure, whether this is relevant, but I got a lot of floating point underflow errors when running WRFPost. Finally I asolved the problem by adding -fpe3 flag to FFLAGS in makefile and recompiling the WPP.
I use ifort compiler and fpe3 in my compiler disable all floating point exceptions.
ivan
 
Posts: 13
Joined: Sat Dec 20, 2008 7:02 am

Re: floating point with WPP and Qcloud or Qice

Postby DVD » Wed Apr 08, 2009 5:25 am

Hi,

I couldn't find the similar kind of flag for pgf, so I've tried to solve the error by preventing the floating point exception to occur at all.

After an extensive search I found that extreme small numbers give and floating point exception in the functions "GET_BITS" (range=inf, so amount of bits=inf) and W3FI72.

After the line "CALL COLLECT(GRID,GRIDO)" I added the following code:
Code: Select all
      DO I=1,IM
        DO J=1,JM
          if ( abs(GRIDO(I,J)) .lt. 1.E-30 ) then
            GRIDO(I,J)=0.
          end if
        enddo
      ENDDO

This way all small numbers are set to zero, I'm not interested in Qcloud being 1.E-38 kg/kg anyway!

Hope this will help other people too.

cheers,

Daniël
DVD
 
Posts: 18
Joined: Tue Jun 17, 2008 5:36 am


Return to WRF Post Processor V3

Who is online

Users browsing this forum: No registered users and 1 guest