Git Product home page Git Product logo

Comments (6)

adcroft avatar adcroft commented on June 11, 2024

@MJHarrison-GFDL and I were discussing this earlier today.

  • We think we need a self-contained (more kernelized) function that takes inputs of the lateral grid, vertical grid and a filename and returns a scalar field using the same algorithm used to T/S.
  • We can test the new routine by making sure it gives the same answers when used for T/S.
  • Some options need to be passed to the remapping routines (e.g. order of accuracy, extrapolation choices) but few enough that I think we can pass them as arguments and avoid using types.
  • The routine MOM_temp_salt_initialize_from_Z() is currently close to 1k lines and has several "contained" subroutines. Should this function be in a self-contained module?

from mom6.

MJHarrison-GFDL avatar MJHarrison-GFDL commented on June 11, 2024

...working on finalizing a new interface for generic tracers.

current version based on discussions with @nikizadehgfdl and Jasmin John:

MOM_initialize_tracer_from_z(h,tr,G,PF,src_file,src_var,unit_conversion,recnum, homogenize,useALE,remappingScheme,src_gridspec)

italics==optional

Defaults are based on USE_REGRIDDING and REMAPPING_SCHEME parameters.

from mom6.

nikizadehgfdl avatar nikizadehgfdl commented on June 11, 2024

@MJHarrison-GFDL , do you mean to create a new routine to generalize MOM_temp_salt_initialize_from_Z() to step through all the known tracers (COBALT tracers, ...) and initialize the ones that are requested to be initialized by the generic_tracer package?
So the call sequence in MOM_initialize.F90 would be something like:

    if (from_Z_file) then
!     Initialize thickness and T/S from z-coordinate data in a file.
      if (.NOT.use_temperature) call MOM_error(FATAL,"MOM_initialize : "//&
         "use_temperature must be true if INIT_LAYERS_FROM_Z_FILE is true")

      call MOM_temp_salt_initialize_from_Z(h, tv, G, PF, dirs)

>     call  MOM_initialize_tracer_from_z(h,tr,G, ...)   !Loops through tracers in tr and asks generics which should be initialized and mimic the above temp_salt call for them 

      call pass_var(h, G%Domain)
    else

from mom6.

nikizadehgfdl avatar nikizadehgfdl commented on June 11, 2024

MOM6 does not know about the generic tracers until after the call to tracer_flow_control_init() in MOM.F90
So a call like MOM_initialize_tracer_from_z above must appear after the call to tracer_flow_control_init() in MOM.F90
and cannot happen along with T&S.

So why not replace the existing function call to tracer_Z_init() in initialize_MOM_generic_tracer() with MOM_initialize_tracer_from_z() ?

from mom6.

adcroft avatar adcroft commented on June 11, 2024

Status on this issue?

from mom6.

Hallberg-NOAA avatar Hallberg-NOAA commented on June 11, 2024

This capability has existed via calls to MOM_initialize_tracer_form_Z for 5 years now (since September 1, 2015). This issue can be closed. If there are specific issues that remain, please open a new issue ticket describing them.

from mom6.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.