KPP 3.5.0 release#155
Merged
Merged
Conversation
site-lisp/kpp.el - Linted this file with Claude AI and resolved several issues that were preventing proper font-lock rendering on newer versions of emacs. CHANGELOG.md - Updated accordingly Signed-off-by: Bob Yantosca <yantosca@seas.harvard.edu>
docs/source/tech_info/08_bnf_description_of_kpp_lang.rst - Added the #GRAPH command to the commands section .gitignore - Tell Git to ignore .DS_Store Signed-off-by: Bob Yantosca <yantosca@seas.harvard.edu>
src/Makefile.defs - Use "CC ?= gcc" (instead of "CC := gcc") so that Make will first use the value of the $CC environment variable from the shell instead of setting it to "gcc". This matters because the default gcc on MacOSX points to Clang rather than to GNU Compiler Collection. CHANGELOG.md - Updated accordingly Signed-off-by: Bob Yantosca <yantosca@seas.harvard.edu>
docs/source/getting-started/01_installation.rst - Updated the MacOSX-specific instructions to use a path-agnostic algorithm in .bashrc to search for the GCC compiler. - Minor formatting updates CHANGELOG.md - Updated accordingly Signed-off-by: Bob Yantosca <yantosca@seas.harvard.edu>
util/Makefile_c - Now use "CC ?= gcc" which will use the value of the CC env var if it has already been defined in the shell - Added "list" target to print compiler version info util/Makefile_f90 util/Makefile_upper_F90 - Now use "FC_GFORTRAN ?= gfortran", which will use the value of the FC env var if it has been already defined in the shell - Added "list" target to print compiler version info CHANGELOG.md - Updated accordingly Signed-off-by: Bob Yantosca <yantosca@seas.harvard.edu>
src/Makefile.defs - Added an architecture-agnostic block that calls "brew --prefix flex" (if Homebrew is present) instead of hardwiring the FLEX_LIB_DIR path. - Define _BREW_PREFIX to store the value of "brew --prefix". This allows us the FLEX and BISON paths in an architecture-indepenedent way. - Updated comments CHANGELOG.md - Updated accordingly Signed-off-by: Bob Yantosca <yantosca@seas.harvard.edu>
.ci-pipelines/ci-common-defs.sh
- Replace "gcc --version" with "${CC} --version", which will use the
C compiler defined in the shell. (Using "gcc" may point to clang").
- Replace "gfortran --version" with "${FC}" version, for the same reason
CHANGELOG.md
- Updated accordingly
Signed-off-by: Bob Yantosca <yantosca@seas.harvard.edu>
src/gen.c - In function GenerateUpdateRconst, set the UPDATE_RCONST value to zero so that it will not generate a "maybe-unassigned-variable" compiler warning with GCC 15+. CHANGELOG.md - Updated accordingly Signed-off-by: Bob Yantosca <yantosca@seas.harvard.edu>
This merge brings PR #153 (Fixes for building KPP on MacOSX, by @yantosca and @HartwigHarder) into the KPP 3.4.1 development stream. PR #153 addresses several issues that prevented building KPP on MacOSX systems. We have now confirmed that KPP builds properly on MacOSX, for both ARM and x86_64 chipsets. Signed-off-by: Bob Yantosca <yantosca@seas.harvard.edu>
code_f90.c
- In function F90_Decl:
- Modified the ELM case block to write a F90 scalar argument with the
OPTIONAL attribute when ATTR_F90_OPT is specified
- Updated comments (cosmetic changes)
- Added F90_FunctionBeginNoArgDecl, which is similar to F90_FunctionBegin
except that it doesn't automatically write the F90 function args
immediately below the subroutine header.
- In routine Use_F90:
- Point FunctionBeginNoArgDecl to F90_FunctionBeginNoArgDecl
src/code.c
- Added function prototype for FunctionBeginNoArgDecl
src/code.h
- Added macro DefElmO, which writes an OPTIONAL F90 scalar variable
- Added an extern function prototype for FunctionBeginNoArgDecl
src/code_c.c
src/code_f77.c
src/code_matlab.c
- Point FunctionBeginNoArgDecl to NULL in order to avoid
uninitialized-variable compiler warnings
CHANGELOG.md
- Updated accordingly
Signed-off-by: Bob Yantosca <yantosca@seas.harvard.edu>
src/gen.c
- In routine InitGen:
- Added variables NON_PASV_SPC_CT and NON_PASV_SPC_IND, which will
be used to write F90 variables (NonPassiveSpc_Count and
NonPassiveSpc_indices) to keep track of non-passive species
- Updated comments for clarity + other cosmetic changes
- In routine GenerateUpdateRconst
- Now use FunctionBeginNoArgsDecl to write the subroutine interface
for UPDATE_RCONST with YIN as optional input argument
- Updated comments
- In routine GenerateGlobalHeader
- Write NonPassiveSpc_Count and NonPassiveSpc_Indices to ROOT_Global
(for F90 only)
- Now write the autoreduction variables following the non-THREADPRIVATE
variables
- Updated comments, cosmetic changes
- In routine GenerateInitialize
- Use FunctionBeginNoArgsDecl to write the ROOT_Initialize subroutine
header with PassiveSpc_ATOL_Threshold optional variable
- Write the PassiveSpc_ATOL_Threshold variable declaration
following all F90 USE statements
- For F90 only, add inlined code that initializes the variables
NonPassiveSpc_Count and NonPassiveSpc_Indices by testing which
species have ATOL < PassiveSpc_ATOL_Threshold
- Updated comments for clarity
int/rosenbrock.f90
int/rosenbrock_adj.f90
int/rosenbrock_autoreduce.f90
int/rosenbrock_tlm.f90
- Rewrote the ros_ErrorNorm function to use NonPassiveSpc_Count and
NonPassiveSpc_Indices so that passive species won't influence
the Rosenbrock error norm
- Use separate loops for vector tolerance and scalar tolerance,
to faciltate vectorization
Signed-off-by: Bob Yantosca <yantosca@seas.harvard.edu>
int/runge_kutta.c - Set Hacc and ErrOldl to zero, which avoids compiler warnings for uninitialized variables CHANGELOG.md - Updated accordingly Signed-off-by: Bob Yantosca <yantosca@seas.harvard.edu>
src/gen.c
- At top of file:
- Removed NON_PASV_SPC_CT and NON_PASV_SPC_IND integer variables
- In function GenerateUpdateRconst:
- Set YIN and Y to zero when F90 if useLang != F90_LANG
- Free YIN and Y when F90 at function's end if useLang != F90_LANG
(this fixes a segfault)
- In function GenerateGlobalHeader
- Declare NON_PASV_SPC_CT and NON_PASV_SPC_IND as local variables
- Free NON_PASV_SPC_CT and NON_PASV_SPC_IND if useLang != F90_LANG
CHANGELOG.md
- Updated accordingly
Signed-off-by: Bob Yantosca <yantosca@seas.harvard.edu>
.github/workflows/run-ci-tests - Added GCC 14 and GCC 15 to the build matrix CHANGELOG.md - Updated accordingly Signed-off-by: Bob Yantosca <yantosca@seas.harvard.edu>
.github/workflows/run-ci-tests.yml - Added code to manually install the GCC 15 compiler, since it does not come pre-installed with Ubuntu 24.04. Signed-off-by: Bob Yantosca <yantosca@seas.harvard.edu>
src/gen.c
- In routine GenerateInitialize:
- Moved the initialization of NonPassiveSpc_Count and
NonPassiveSpc_Indices after the F90_INIT section.
This will prevent clobbering of inlined ATOL values.
Signed-off-by: Bob Yantosca <yantosca@seas.harvard.edu>
.ci-pipelines/ci-common-defs.sh
- Added F90_ros_passivespc to the list of tests
ci-tests/F90_ros_passivespc.kpp
- Added this KPP definition file for the F90_ros_passivespc C-I test.
This is the "small strato" mechanism plus 3 passive species.
docs/source/getting-started/00_revision_history.rst
- Added to the list of recent updates under "Unreleased"
docs/source/tech_info/06_info_for_kpp_developers.rst
- Converted KPP source code files table into a list-table
- Added F90_ros_passivespc to the C-I tests table
- Added a 5th column ("What this tests") with links to the C-I tests
table
docs/source/tech_info/07_numerical_methods.rst
- Renamed "rk_method_comparison" anchor to "rk-methods-3stage"
- Added "rk-methods-radau5", "rk_methods-sdirk", "rk-methods-sdirk4",
"rk-methods-seulex" anchors
src/gen.c
- Updated syntax in comment
CHANGELOG.md
- Updated accordingly
Signed-off-by: Bob Yantosca <yantosca@seas.harvard.edu>
.github/workflows/run-ci-tests.yml - Added GCC 16 to the GCC versions matrix for the Run C-I tests action docs/source/index.rst - Converted HTML in header to ReST CHANGELOG.md - Updated accordingly Signed-off-by: Bob Yantosca <yantosca@seas.harvard.edu>
docs/source/using_kpp/04_input_for_kpp.rst - Added "Filtering out passive species with an absolute tolerance threshold" section - Shortened some ~~~ underlines docs/source/using_kpp/05_output_from_kpp.rst - Added a note under ROOT_Initialize pointing the user to the "Filtering out passive species with an absolute tolerance threshold" section - Converted tables to list-tables Signed-off-by: Bob Yantosca <yantosca@seas.harvard.edu>
.github/workflows/run-ci-tests.yml - Remove unneeded stuff from packages.microsoft.com from the GitHub Actions runner. This will make sure that a failure in checking out these packages does not take down the entire job. CHANGELOG.md - Updated accordingly Signed-off-by: Bob Yantosca <yantosca@seas.harvard.edu>
int/rosenbrock.f90 int/rosenbrock_adj.f90 int/rosenbrock_autoreduce.f90 int/rosenbrock_tlm.f90 - Now use consistent formatting in the comment headers for ICNTRL and RCNTRL Signed-off-by: Bob Yantosca <yantosca@seas.harvard.edu>
This merge brings PR #154 (Create variables to track non-passive species, so that they can be excluded from the Rosenbrock error norm (in int/rosenbrock*.f90 integrators only), by @yantosca) into the KPP 3.5.0 development stream. PR #154 adds two new module-level variables have been added to the ROOT_Global module (for F90 only). These are: - NonPassiveSpc_Count: The number of non-passive species - NonPassiveSpc_Indices: The KPP species indices for non-passive species These optional variables (which are stored in ROOT_Global) are constructed when the Initialize routine is called. If Initialize is called with the PassiveSpc_ATOL_Threshold optional argument, then all species that have an absolute tolerance (ATOL) greater than or equal to PassiveSpc_ATOL_Threshold will be denoted as passive species. In this case, NonPassiveSpc_Count will be equal to NVAR - the number of passive species and NonPassiveSpc_Indices will contain the index list of only the non-passive species. If Initialize is called without any optional arguments, then NonPassiveSpc_Count will be equal to NVAR and NonPassiveSpc_Indices will contain the index list of all variable species. We have also updated the algorithm in the Ros_ErrorNorm function (in each of the int/rosenbrock*.f90 files) to compute the error norm on the basis of non-passive species. We have also optimized the function to facilitate vectorization and to remove unnecessary ELSE blocks, which can be a bottleneck: Other modifications bundled into this PR: - Added C-I test F90_ros_passivespc, which adds 3 passive species to the small_strato mechanism. - Added new driver program drv/general_passivespc.f90, which executes CALL INITIALIZE( PassiveSpc_ATOL_Threshold = 1.0d25 ). - Added KPP internal function F90_FunctionBeginNoArgsDecl (in src/code_f90.c) - Added macro DefElmO in src/code.h, - Added GNU 14, 15, 16 compilers to the "Run C-I tests" GitHub action. - Set Hacc = ZERO; and ErrOld = ZERO; in int/runge_kutta.c to avoid generating compiler warnings during C-I tests - Updated ICNTRL and RCNTRL comment headers in the int/rosenbrock*.f90 integrator files. - Updated ReadtheDocs documentation accordingly. Signed-off-by: Bob Yantosca <yantosca@seas.harvard.edu>
Split up 04_input_for_kpp.rst and 05_output_from_kpp into several files and placed into separate toctrees. Also renamed the files in the getting_started folder to remove preceding numbers in the filenames. Signed-off-by: Bob Yantosca <yantosca@seas.harvard.edu>
docs/source/tech_info/06_info_for_kpp_developers.rst has been split up so that each Heading 2 section is now its own file: 1. docs/source/tech_info/kpp_dir_structure.rst 2. docs/source/tech_info/kpp_env_vars.rst 3. docs/source/tech_info/kpp_internal_modules.rst 4. docs/source/tech_info/adding_new_commands.rst 5. docs/source/tech_info/about_ci_tests.rst Signed-off-by: Bob Yantosca <yantosca@seas.harvard.edu>
Renamed: docs/source/tech_info/08_bnf_description_of_kpp_lang.rst to: docs/source/tech_info/bnf_description_of_kpp_lang.rst Signed-off-by: Bob Yantosca <yantosca@seas.harvard.edu>
We have split docs/source/tech_info/07_numerical_methods.rst into several smaller files in the docs/source/num_methods folder: 1. docs/source/num_methods/rosenbrock_methods.rst 2. docs/source/num_methods/runge_kutta_methods.rst 3. docs/source/num_methods/backward_diff.rst 4. docs/source/num_methods/forward_diff.rst 5. docs/source/num_methods/controlling_the_integrator.rst 6. docs/source/num_methods/output_from_integrators.rst Signed-off-by: Bob Yantosca <yantosca@seas.harvard.edu>
Renamed: docs/source/citations/19_kpp_references.rst to: docs/source/citations/kpp_references.rst Signed-off-by: Bob Yantosca <yantosca@seas.harvard.edu>
Renamed: docs/source/citations/09_acknowledgments.rst To: docs/source/citations/acknowledgments.rst Signed-off-by: Bob Yantosca <yantosca@seas.harvard.edu>
Moved: docs/source/using_kpp/output_from_integrators.rst To: docs/source/num_methods/output_from_integrators.rst Moved: docs/source/using_kpp/code_c.rst To: docs/source/output/code_c.rst Moved: docs/source/using_kpp/code_f90.rst To: docs/source/output/code_f90.rst Moved: docs/source/using_kpp/code_matlab.rst To: docs/source/output/code_matlab.rst Moved: docs/source/using_kpp/makefile.rst To: docs/source/output/makefile.rst Also added info about Makefile targets Moved: docs/source/using_kpp/log_file.rst To: docs/source/output/log_file.rst Signed-off-by: Bob Yantosca <yantosca@seas.harvard.edu>
Moved: docs/source/using_kpp/controlling_the_integrator.rst To: docs/source/num_methods/controlling_the_integrator.rst Moved: docs/source/using_kpp/auxiliary_files.rst To: docs/source/input/auxiliary_files.rst Moved: docs/source/using_kpp/filter-passive-spc.rst To: docs/source/input/filter-passive-spc.rst Moved: docs/source/using_kpp/inlined_code.rst To: docs/source/input/inlined_code.rst Moved: docs/source/using_kpp/input_overview.rst To: docs/source/input/input_overview.rst Moved: docs/source/using_kpp/kpp_commands.rst To: docs/source/input/kpp_commands.rst Moved: docs/source/using_kpp/kpp_sections.rst To: docs/source/input/kpp_sections.rst Signed-off-by: Bob Yantosca <yantosca@seas.harvard.edu>
docs/source/getting_started/revision_history - Added sentence about splitting up large files and reorganizing folders docs/source/index.rst - Updated toctrees to point to new files docs/source/tech_info/bnf_description_of_kpp_lang.rst - Commmited this updated file (should have been done a few commits ago) Signed-off-by: Bob Yantosca <yantosca@seas.harvard.edu>
This merge brings updates from the KPP 3.5.0 development stream into the release/3.5.0 branch, in anticipation of the KPP 3.5.0 release. Signed-off-by: Bob Yantosca <yantosca@seas.harvard.edu>
This merge brings documentation updates for KPP 3.5.0 into the 'release/X.Y.Z branch', in anticipation of the KPP 3.5.0 release. Signed-off-by: Bob Yantosca <yantosca@seas.harvard.edu>
Updated version numbers to 3.5.0 in: - CHANGELOG.md - docs/source/conf.py - src/gdata.h Updated Python to 3.13 in .readthedocs.yaml Updated Python package versions to be consistent with the requirements.txt and read_the_docs_environment.yml in docs/source/reference/editing_these.docs.yml Fixed formatting issues in docs/source/output/makefile.rst Signed-off-by: Bob Yantosca <yantosca@seas.harvard.edu>
.gitattributes - Normalizes line endings for text source files and marks flex/bison generated files as generated CLAUDE.md - Provides guidance to Claude Code CODE_OF_CONDUCT.md - Boilerplate text describing our code of conduct (many GitHub repos expect this) SECURITY.md - Boilerplate text as to how to report security vulnerabilities (Many GitHub repos expect this) Signed-off-by: Bob Yantosca <yantosca@seas.harvard.edu>
RolfSander
approved these changes
Jul 14, 2026
RolfSander
left a comment
Contributor
There was a problem hiding this comment.
Looks good. Yes, let's release 3.5.0!
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
We propose to release KPP version 3.5.0 (in order to start being able to take advantage of the fix to exclude passive species from the Rosenbrock error norm computation).
Pull requests included
Documentation updates
We have added boilerplate files (
.gitattributes,CODE_OF_CONDUCT.md,SECURITY.md) that GitHub expects.We have added
CLAUDE.md, which directs Claude Code AI on how it should interface with this repo.We have split up some of the longer ReadTheDocs
*.rstfiles into smaller files, which will make it easier for users to navigate the site. The left nav bar now shows:Screenshots:

