geoschem / geos-chem

GEOS-Chem "Science Codebase" repository. Contains GEOS-Chem science routines, run directory generation scripts, and interface code. This repository is used as a submodule within the GCClassic and GCHP wrappers, as well as in other modeling contexts (external ESMs).
http://geos-chem.org
Other
164 stars 154 forks source link

[BUG/ISSUE] KPP build warning #1496

Closed ktravis213 closed 1 year ago

ktravis213 commented 1 year ago

What institution are you from?

NASA LaRC

Description of the problem

When I rebuild fullchem.eqn in 13.4.0 I get the following errors:

 Warning: 39 continuation lines for JTUV(283) = ...
 Warning: 37 continuation lines for XX(283) = ...

See log file below for the KPP build.

Description of troubleshooting performed

I tried some different versions of KPP with no success. I want to make sure I am not inadvertently excluding some chemistry in my build.

GEOS-Chem version

13.4.0

Description of modifications

I have not modified any of the chemistry except for this bug fix https://github.com/geoschem/geos-chem/pull/1447

I also grabbed the pressure fixer fix.

Log files

This is KPP-2.3.1_gc.

KPP is parsing the equation file.
KPP is computing Jacobian sparsity structure.
KPP is starting the code generation.
KPP is initializing the code generation.
KPP is generating the monitor data:
    - gckpp_Monitor
KPP is generating the utility data:
    - gckpp_Util
KPP is generating the global declarations:
    - gckpp_Main
KPP is generating the ODE function:
    - gckpp_Function
KPP is generating the ODE Jacobian:
    - gckpp_Jacobian
    - gckpp_JacobianSP
 Warning: 39 continuation lines for JTUV(283) = ...
KPP is generating the linear algebra routines:
    - gckpp_LinearAlgebra
 Warning: 37 continuation lines for XX(283) = ...
KPP is generating the utility functions:
    - gckpp_Util
KPP is generating the rate laws:
    - gckpp_Rates
KPP is generating the parameters:
    - gckpp_Parameters
KPP is generating the global data:
    - gckpp_Global
KPP is generating the driver from none.f90:
    - gckpp_Main
KPP is starting the code post-processing.

KPP has succesfully created the model "gckpp".

Reactivity consists of 189 reactions
Written to gckpp_Util.F90

Software versions

KPP from here: https://zenodo.org/record/4552707#.Y21Twi-B1oN

yantosca commented 1 year ago

Thanks for writing @ktravis213. Those are harmless warnings that are generated by the KPP C-language code:

code_f90.c:153:       printf("\n Warning: double-check continuation lines for:\n   %s = %s\n",ls,rs);
code_f90.c:180:     printf("\n Warning: %d continuation lines for %s = ...",number_of_lines,ls);

Back when KPP was first being developed (about 20 years ago), the most recent Fortran standard was F90. This allowed only 39 continuation lines. More recent Fortran standards like F2003 and F2008 allow for many more continuation lines (I think up to 255).

I'll raise this as an issue on the KPP GitHub page, so that we can fix the warning in a future version.

BTW, we just released KPP 3.0.0! Chemistry mechanisms will be built with KPP 3.0.0 version starting in GEOS-Chem 14.1.0.

Also tagging @Jourdan-He and @SaptSinha

yantosca commented 1 year ago

For your reference, I've posted an issue on the KPP GitHub: https://github.com/KineticPreProcessor/KPP/issues/65

ktravis213 commented 1 year ago

Ok great! So I don't need to worry about it?

yantosca commented 1 year ago

Hi @ktravis213! Yes, that's right, no need to worry about it. In fact, in the KPP 3.0.0 release, I'm told that we have already increased the max # of lines parameter from 39 to 250 -- so you won't get this error unless your equation has 250+ lines.

We can close this out now. Thanks again!