What's the difference between online and offline running?

General scientific issues regarding ROMS

Moderators: arango, robertson

Post Reply
Message
Author
goodboy

What's the difference between online and offline running?

#1 Unread post by goodboy »

I ask this question because of the biological modules. When I read the biological module code in ROMS, there is usually some notes like this in the end. It then updates all of the biological values behind these notes.
!-----------------------------------------------------------------------
! Update global tracer variables: Add increment due to BGC processes
! to tracer array in time index "nnew". Index "nnew" is solution after
! advection and mixing and has transport units (m Tunits) hence the
! increment is multiplied by Hz. Notice that we need to subtract
! original values "Bio_old" at the top of the routine to just account
! for the concentractions affected by BGC processes. This also takes
! into account any constraints (non-negative concentrations, carbon
! concentration range) specified before entering BGC kernel. If "Bio"
! were unchanged by BGC processes, the increment would be exactly
! zero. Notice that final tracer values, t(:,:,:,nnew,:) are not
! bounded >=0 so that we can preserve total inventory of nutrients
! when advection causes tracer concentration to go negative.
I'm curious about how it figures out the biological advection and mixing. I read the codes in main3d.F and step3d_t.F. I found that in the main3d.F or main3d_offline.F, it calls biology first, and then calls step3d_t after calling biology. Is this meaning it actually adds increment due to BGC processes first, and then doing the physical advection and diffusion process of biological tracers? I can't understand why is in this order. Or is it doesn't matter who is first?

In step3d_t.F file, there is usually these codes. Is this meaning that there isn't any physical advection and diffusion process in my biological modules if I don't define OFFLINE_BIOLOGY? However, when I define OFFLINE_BIOLOGY, it chooses the main3d_offline.F instead of main3d.F.

Code: Select all

!  Horizontal tracer advection.  It is possible to have a different
!  advection schme for each tracer.
!
#ifdef OFFLINE_BIOLOGY
      T_LOOP1 : DO ibt=1,NBT
        itrc=idbio(ibt)
#else
      T_LOOP1 : DO itrc=1,NT(ng)
#endif
I read the globaldefs.h, there is some information about these:

Code: Select all

/*
** OFFLINE
*/

#if defined OFFLINE_FLOATS || defined OFFLINE_BIOLOGY
# define OFFLINE
#endif
Therefore, I want to ask this question: what's the difference between online and offline running? Is it meaning that there are only biological processes and nothing of physical advection and diffusion of biological tracers during the online running?

User avatar
kate
Posts: 4091
Joined: Wed Jul 02, 2003 5:29 pm
Location: CFOS/UAF, USA

Re: What's the difference between online and offline running?

#2 Unread post by kate »

As I posted elsewhere, I've given up on offline biology. The point of it was that you run the physics once, saving daily outputs. Then you read those fields in as "climalotogy" for running the biology. The dream is that you can maybe take a longer timestep when you only have the biology going on and perhaps save some computer time.

In online mode, I don't think it matters which order you update all the various processes.

goodboy

Re: What's the difference between online and offline running?

#3 Unread post by goodboy »

Ok, thank you very much. Now I can know the difference between them.

Post Reply