Skip to content
Open
Show file tree
Hide file tree
Changes from 67 commits
Commits
Show all changes
76 commits
Select commit Hold shift + click to select a range
7f08ddf
Save changes close to a green suite
mo-rickywong Apr 1, 2026
6c37a63
Updates
mo-rickywong Apr 3, 2026
6926333
Merge branch 'main' into AppsRmGlobalCfg_CoreDriver
mo-rickywong Apr 3, 2026
e42fd48
Merge branch 'main' into AppsRmGlobalCfg_CoreDriver
mo-rickywong Apr 21, 2026
279a2e9
Merge branch 'main' into AppsRmGlobalCfg_CoreDriver
mo-rickywong Apr 23, 2026
00dd755
Tidy and clean
mo-rickywong Apr 24, 2026
f774117
Merge branch 'main' into AppsRmGlobalCfg_CoreDriver
mo-rickywong Apr 24, 2026
fc008f0
Set default tile size
mo-rickywong Apr 29, 2026
21a1cad
force developer change in rose stem back to be same as main
mo-rickywong Apr 29, 2026
74b11a9
Merge branch 'main' into AppsRmGlobalCfg_CoreDriver
mo-rickywong Apr 29, 2026
fd63226
typo
mo-rickywong Apr 29, 2026
a0c9689
Update oversights
mo-rickywong Apr 29, 2026
af12f27
Missing declation
mo-rickywong Apr 30, 2026
35f16a0
Update lfric2lfric macros
mo-rickywong Apr 30, 2026
15d8565
Update lfric2lfric macro
mo-rickywong Apr 30, 2026
f85fcae
Merge branch 'main' into AppsRmGlobalCfg_CoreDriver
mo-rickywong May 1, 2026
129269d
Merge branch 'main' into AppsRmGlobalCfg_CoreDriver
mo-rickywong May 11, 2026
181256b
Merge branch 'main' into AppsRmGlobalCfg_CoreDriver
mo-rickywong May 11, 2026
d04befb
Modify to pass down config_type object due to code owner concerns
mo-rickywong May 28, 2026
2daa065
Merge branch 'main' into AppsRmGlobalCfg_CoreDriver
mo-rickywong Jun 4, 2026
802e3ea
Update doxygen comments
mo-rickywong Jun 5, 2026
033cd12
Merge branch 'main' into AppsRmGlobalCfg_CoreDriver
mo-rickywong Jun 8, 2026
0daee19
Green test suite state
mo-rickywong Jun 18, 2026
c6a3e11
Merge branch 'main' into AppsRmGlobalCfg_CoreDriver
mo-rickywong Jun 18, 2026
1e180a5
Merge branch 'main' into AppsRmGlobalCfg_CoreDriver
mo-rickywong Jun 19, 2026
3ac072a
Merge branch 'main' into AppsRmGlobalCfg_CoreDriver
mo-rickywong Jun 22, 2026
ad0c0e6
update to linear file
mo-rickywong Jun 23, 2026
9cf8c0a
Change requests for Mark Hedley
mo-rickywong Jun 25, 2026
888f398
Change requests from Charlotte Turner
mo-rickywong Jun 25, 2026
345882e
Changes requested by Matthew Hambley
mo-rickywong Jun 25, 2026
e574ca2
Changes requested by Mike Hobson
mo-rickywong Jun 25, 2026
4d7a4fd
Apply suggestions from code review
mo-rickywong Jun 25, 2026
df89d60
Changes requested by Allen T
mo-rickywong Jun 25, 2026
5ee352f
Changes requested by Tom Bendall
mo-rickywong Jun 25, 2026
01875a3
Change requested by Tom Bendall
mo-rickywong Jun 25, 2026
17ec27e
Change requested by tom bendall
mo-rickywong Jun 25, 2026
ff81107
Changes for Tom Bendall
mo-rickywong Jun 25, 2026
542de1f
Additional changes resulting from reviewer updates
mo-rickywong Jun 26, 2026
a7cf4de
Changes request by Iva Kavcic
mo-rickywong Jun 26, 2026
341c86b
Some more changes for SteveM and Pierre
mo-rickywong Jun 26, 2026
38bad42
Update science/gungho/source/algorithm/transport/control/theta_transp…
mo-rickywong Jun 26, 2026
de65c8f
Merge branch 'main' into AppsRmGlobalCfg_CoreDriver
mo-rickywong Jun 26, 2026
ccffe25
Merge branch 'main' into AppsRmGlobalCfg_CoreDriver
mo-rickywong Jun 29, 2026
026df39
Merge branch 'main' into AppsRmGlobalCfg_CoreDriver
mo-rickywong Jun 30, 2026
50ce693
Update the KGOs
mo-rickywong Jun 30, 2026
63c236c
Update comments
mo-rickywong Jun 30, 2026
5300fc6
Move config_mod use statements
mo-rickywong Jun 30, 2026
fba2f64
Remove debug directory
mo-rickywong Jun 30, 2026
d4feb60
Merge branch 'AppsRmGlobalCfg_CoreDriver' into AppsCleanFeigners_1
mo-rickywong Jul 1, 2026
6318391
Merge branch 'main' into AppsCleanFeigners_1
mo-rickywong Jul 1, 2026
ef989f4
Update to merging on main
mo-rickywong Jul 2, 2026
c79f834
Update apps to allow for changes to core
mo-rickywong Jul 22, 2026
c9db323
Merge branch 'main' into AppsCleanFeigners_1
mo-rickywong Jul 22, 2026
a84a56f
Merge branch 'main' into AppsCleanFeigners_1
mo-rickywong Aug 27, 2026
5e757db
Fix arguments in function
mo-rickywong Aug 27, 2026
098f9b0
tidy up doxygens
mo-rickywong Sep 1, 2026
849c9a6
1st set of changes
mo-rickywong Sep 1, 2026
24e7722
Remove pointer statements to get build working
mo-rickywong Sep 1, 2026
e7c99f0
Fix to get build working
mo-rickywong Sep 2, 2026
647a229
Merge branch 'main' into AppsDecoupleGeoTop
mo-rickywong Sep 3, 2026
49aab8d
Merge branch 'main' into AppsCleanFeigners_1
mo-rickywong Sep 3, 2026
aa25e23
update dependencies file
mo-rickywong Sep 3, 2026
1b95f08
Move access of geometry and topology to mesh object where possible
mo-rickywong Sep 7, 2026
44dff0b
Merge branch 'main' into AppsDecoupleGeoTop
mo-rickywong Sep 7, 2026
4ef684e
Merge branch 'AppsDecoupleGeoTop' into AppsCleanFeigners_1
mo-rickywong Sep 7, 2026
0e142e7
Merge branch 'main' into AppsCleanFeigners_1
mo-rickywong Sep 12, 2026
8ed43cc
Merge branch 'main' into AppsCleanFeigners_1
mo-rickywong Sep 17, 2026
a230f50
reviewer requested changes
mo-rickywong Sep 17, 2026
d6986cd
Merge branch 'main' into AppsCleanFeigners_1
mo-rickywong Sep 21, 2026
4e184c9
Merge branch 'main' into AppsCleanFeigners_1
mo-rickywong Oct 5, 2026
bd8dc24
Merge branch 'AppsCleanFeigners_1' of github.com:mo-rickywong/lfric_a…
mo-rickywong Oct 5, 2026
2a3b2ab
Merge branch 'main' into AppsCleanFeigners_1
mo-rickywong Oct 5, 2026
e37e0d9
Merge branch 'main' into AppsCleanFeigners_1
mo-rickywong Oct 23, 2026
2f2a4f8
Merge branch 'main' into AppsCleanFeigners_1
mo-rickywong Oct 23, 2026
88d3a02
Fix failures on moving to head of trunk
mo-rickywong Oct 23, 2026
35cf5e0
Merge branch 'main' into AppsCleanFeigners_1
mo-rickywong Oct 23, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@ module adjt_compute_vorticity_alg_mod
use fs_continuity_mod, only : W1, W2
use function_space_collection_mod, only : function_space_collection

use config_mod, only: config_type

implicit none

public
Expand All @@ -31,15 +33,16 @@ module adjt_compute_vorticity_alg_mod
!> Determined by testing the equality of inner products <Mx, Mx> and <AMx, x>,
!> where M is the tangent linear and A is the adjoint.
!> @param[in] mesh The model mesh
subroutine adjt_compute_vorticity_alg( mesh )
subroutine adjt_compute_vorticity_alg(config, mesh)

use compute_vorticity_alg_mod, only : compute_vorticity_alg
use adj_compute_vorticity_alg_mod, only : adj_compute_vorticity_alg

implicit none

! Arguments
type(mesh_type), pointer, intent(in) :: mesh
type(config_type), intent(in) :: config
type(mesh_type), intent(in) :: mesh

! Arguments for tl and adj calls
type(field_type) :: xi
Expand Down Expand Up @@ -101,7 +104,7 @@ module adjt_compute_vorticity_alg_mod
setval_x( u_input, u ) )

! Tangent linear
call compute_vorticity_alg( xi, u, weak_form_u )
call compute_vorticity_alg(config, xi, u, weak_form_u)

! < Mx, Mx >
call invoke( x_innerproduct_x( xi_inner_prod, xi ), &
Expand Down Expand Up @@ -130,7 +133,7 @@ module adjt_compute_vorticity_alg_mod
u_u_input_inner_prod = 0.0_r_def

! Adjoint
call adj_compute_vorticity_alg( xi, u, weak_form_u )
call adj_compute_vorticity_alg(config, xi, u, weak_form_u)

! < AMx, x >
call invoke( x_innerproduct_y( xi_xi_input_inner_prod, &
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
!> @brief Module containing adjoint test for atl_derive_exner_from_eos_alg
module atlt_derive_exner_from_eos_alg_mod

use config_mod, only : config_type
use field_mod, only : field_type
use function_space_mod, only : function_space_type
use constants_mod, only : r_def, i_def
Expand Down Expand Up @@ -33,16 +34,18 @@ module atlt_derive_exner_from_eos_alg_mod
!> @details Passes if adjoint is transpose of tangent linear.
!> Determined by testing the equality of inner products <Mx, Mx> and <AMx, x>,
!> where M is the tangent linear and A is the adjoint.
!> @param[in] config Application configuration object
!> @param[in] mesh The model mesh
subroutine atlt_derive_exner_from_eos_alg( mesh )
subroutine atlt_derive_exner_from_eos_alg(config, mesh)

use tl_derive_exner_from_eos_alg_mod, only : tl_derive_exner_from_eos
use atl_derive_exner_from_eos_alg_mod, only : atl_derive_exner_from_eos

implicit none

! Arguments
type(mesh_type), pointer, intent(in) :: mesh
type(config_type), intent(in) :: config
type(mesh_type), intent(in) :: mesh

! Arguments for tl and atl calls
! Form of state and rhs is [u,theta,rho,exner]
Expand Down Expand Up @@ -111,7 +114,7 @@ module atlt_derive_exner_from_eos_alg_mod
setval_random( ls_moist_dyn ) )

! Tangent linear
call tl_derive_exner_from_eos( state, moist_dyn, ls_state, ls_moist_dyn )
call tl_derive_exner_from_eos( config, state, moist_dyn, ls_state, ls_moist_dyn )

! < Mx, Mx >
call invoke( x_innerproduct_x( state_inner_prod(igh_t), state(igh_t) ), &
Expand Down Expand Up @@ -151,7 +154,7 @@ module atlt_derive_exner_from_eos_alg_mod
moist_dyn_moist_dyn_input_inner_prod = 0.0_r_def

! Adjoint
call atl_derive_exner_from_eos( state, moist_dyn, ls_state, ls_moist_dyn )
call atl_derive_exner_from_eos( config, state, moist_dyn, ls_state, ls_moist_dyn )

! < AMx, x >
call invoke( x_innerproduct_y( state_state_input_inner_prod(igh_t), &
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
!> @brief Module containing adjoint test for atl_rhs_alg
module atlt_rhs_alg_mod

use config_mod, only : config_type
use sci_assign_field_random_range_alg_mod, &
only : assign_field_random_range
use field_mod, only : field_type
Expand Down Expand Up @@ -41,18 +42,20 @@ module atlt_rhs_alg_mod
!> @details Passes if adjoint is transpose of tangent linear.
!> Determined by testing the equality of inner products <Mx, Mx> and <AMx, x>,
!> where M is the tangent linear and A is the adjoint.
!> @param[in] config Application configuration object
!> @param[in] mesh The model mesh
!> @param[in] model_clock The model clock
subroutine atlt_rhs_alg( mesh, model_clock )
subroutine atlt_rhs_alg( config, mesh, model_clock )

use tl_rhs_alg_mod, only : tl_rhs_alg
use atl_rhs_alg_mod, only : atl_rhs_alg
use tl_rhs_alg_mod, only: tl_rhs_alg
use atl_rhs_alg_mod, only: atl_rhs_alg

implicit none

! Arguments
type(mesh_type), pointer, intent(in) :: mesh
type(model_clock_type), intent(in) :: model_clock
type(config_type), intent(in) :: config
type(mesh_type), intent(in) :: mesh
type(model_clock_type), intent(in) :: model_clock

! Arguments for tl and atl calls
! Form of state and rhs is [u,theta,rho,exner]
Expand Down Expand Up @@ -206,8 +209,8 @@ module atlt_rhs_alg_mod


! Tangent linear
call tl_rhs_alg( rhs, alpha_dt, base_state, state, moist_dyn, &
ls_state, ls_moist_dyn, compute_eos, &
call tl_rhs_alg( config, rhs, alpha_dt, base_state, state, moist_dyn, &
ls_state, ls_moist_dyn, compute_eos, &
dlayer_rhs, model_clock )

! < Mx, Mx >
Expand Down Expand Up @@ -310,8 +313,8 @@ module atlt_rhs_alg_mod
rhs_rhs_input_inner_prod(:) = 0.0_r_def

! Adjoint
call atl_rhs_alg( rhs, alpha_dt, base_state, state, moist_dyn, &
ls_state, ls_moist_dyn, compute_eos, &
call atl_rhs_alg( config, rhs, alpha_dt, base_state, state, moist_dyn, &
ls_state, ls_moist_dyn, compute_eos, &
dlayer_rhs, model_clock )

! < AMx, x >
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,9 @@
!> @brief Module containing adjoint test for adj_w3h_adv_upd_lookup_lookup_kernel
module adjt_w3h_adv_upd_lookup_alg_mod


use adj_trans_lookup_cache_mod, only : adj_trans_lookup_cache_type
use config_mod, only : config_type
use integer_field_mod, only : integer_field_type
use r_tran_field_mod, only : r_tran_field_type
use fs_continuity_mod, only : W3, W2
Expand Down Expand Up @@ -36,17 +38,19 @@ module adjt_w3h_adv_upd_lookup_alg_mod
!> @details Passes if adjoint is transpose of tangent linear.
!> Determined by testing the equality of inner products <Mx, Mx> and <AMx, x>,
!> where M is the tangent linear and A is the adjoint.
!> @param[in] config Application configuration object
!> @param[in] mesh The model mesh
!> @param[in] adj_lookup_table_cache The lookup table cache
subroutine adjt_w3h_adv_upd_lookup_alg( mesh, adj_lookup_table_cache )
subroutine adjt_w3h_adv_upd_lookup_alg( config, mesh, adj_lookup_table_cache )

use w3h_advective_update_kernel_mod, only : w3h_advective_update_kernel_type
use invoke_adj_w3h_adv_upd_lookup_mod, only : invoke_adj_w3h_adv_upd_lookup_kernel_type

implicit none

! Arguments
type(mesh_type), pointer, intent(in) :: mesh
type(config_type), intent(in) :: config
type(mesh_type), intent(in) :: mesh
type(adj_trans_lookup_cache_type), intent(in) :: adj_lookup_table_cache

! Internal arguments for kernels
Expand Down Expand Up @@ -84,8 +88,9 @@ module adjt_w3h_adv_upd_lookup_alg_mod
real(kind=r_tran) :: machine_tol
real(kind=r_tran) :: relative_diff

nullify(m3_inv, lookup_w3h_adv_upd, lookup_w3h_adv_upd_field, set_count_w3h_adv_upd_field, &
vector_space_w3_md_ptr, vector_space_w3_ptr, vector_space_w2_ptr)
nullify(m3_inv, lookup_w3h_adv_upd, lookup_w3h_adv_upd_field, &
set_count_w3h_adv_upd_field, vector_space_w3_md_ptr, &
vector_space_w3_ptr, vector_space_w2_ptr)

vector_space_w3_md_ptr => function_space_collection%get_fs( &
mesh, element_order_h, element_order_v, W3, ndata, ndata_first=.false. &
Expand All @@ -101,7 +106,7 @@ module adjt_w3h_adv_upd_lookup_alg_mod
call wind%initialise( vector_space=vector_space_w2_ptr, name='wind' )
call advective_increment_input%initialise( vector_space=vector_space_w3_ptr, name='advective_increment_input' )
call tracer_input%initialise( vector_space=vector_space_w3_md_ptr, name='tracer_input' )
m3_inv => get_inverse_mass_matrix_fe( W3, mesh%get_id() )
m3_inv => get_inverse_mass_matrix_fe( config, mesh, W3 )
advective_increment_inner_prod = 0.0_r_def
tracer_inner_prod = 0.0_r_def

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ contains

call vector_mx%set_scalar(0.0_r_def)
call vector_amx%set_scalar(0.0_r_def)
call mixed_op%apply( vector_x, vector_mx )
call mixed_op%apply( config, vector_x, vector_mx )

! --------------------------------------------------------------------------
! Compute <Mx,Mx>
Expand Down Expand Up @@ -186,7 +186,7 @@ contains

adj_mixed_op = adj_mixed_operator_type()

call adj_mixed_op%apply( vector_mx, vector_amx )
call adj_mixed_op%apply( config, vector_mx, vector_amx )

! --------------------------------------------------------------------------
! Compute <AMx,x>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -163,11 +163,11 @@ contains
call compute_si_operators( modeldb%config, ls_theta, ls_rho, ls_exner, &
model_clock, ls_moist_dyn )

call create_pressure_preconditioner( rhs, pressure_operator, pressure_preconditioner )
call create_pressure_preconditioner( modeldb%config, rhs, pressure_operator, pressure_preconditioner )
call create_pressure_solver( pressure_operator, pressure_preconditioner, pressure_solver )
call create_mixed_preconditioner( rhs, pressure_solver, mixed_preconditioner )

call create_adj_pressure_preconditioner( rhs, adj_lookup_table_cache, &
call create_adj_pressure_preconditioner( modeldb%config, rhs, adj_lookup_table_cache, &
adj_pressure_operator, adj_pressure_preconditioner )
call create_adj_pressure_solver( adj_pressure_operator, adj_pressure_preconditioner, adj_pressure_solver )
call create_adj_mixed_preconditioner( rhs, adj_pressure_solver, adj_mixed_preconditioner )
Expand All @@ -183,7 +183,7 @@ contains
! Apply the preconditioner (i.e., forward code)
! --------------------------------------------------------------------------

call mixed_preconditioner%apply( vector_x, vector_mx )
call mixed_preconditioner%apply( modeldb%config, vector_x, vector_mx )

! --------------------------------------------------------------------------
! Compute <Mx,Mx>
Expand Down Expand Up @@ -219,7 +219,7 @@ contains
! Adjoint code
! --------------------------------------------------------------------------

call adj_mixed_preconditioner%apply( vector_mx, vector_amx )
call adj_mixed_preconditioner%apply( modeldb%config, vector_mx, vector_amx )

! --------------------------------------------------------------------------
! Compute <AMx,x>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -152,8 +152,8 @@ contains
! Input fields are r_def fields so preliminary work uses field_types

! Normalise theta & u residual
t_normalisation => get_normalisation( Wtheta, rhs(igh_p)%get_mesh_id() )
u_normalisation => get_normalisation( W2, rhs(igh_p)%get_mesh_id() )
t_normalisation => get_normalisation( modeldb%config, rhs(igh_p)%get_mesh(), Wtheta )
u_normalisation => get_normalisation( modeldb%config, rhs(igh_p)%get_mesh(), W2 )
call invoke(inc_X_times_Y( rhs(igh_u), u_normalisation ))

if (eliminate_variables == eliminate_variables_analytic) then
Expand Down Expand Up @@ -192,12 +192,12 @@ contains
call compute_si_operators( modeldb%config, ls_theta, ls_rho, ls_exner, &
model_clock, ls_moist_dyn )

call create_pressure_preconditioner( rhs, pressure_operator, pressure_preconditioner )
call create_pressure_preconditioner( modeldb%config, rhs, pressure_operator, pressure_preconditioner )
call create_pressure_solver( pressure_operator, pressure_preconditioner, pressure_solver )
call create_mixed_preconditioner( rhs, pressure_solver, mixed_preconditioner )
call create_mixed_solver( mixed_preconditioner, mixed_operator, mixed_solver )

call create_adj_pressure_preconditioner( rhs, adj_lookup_table_cache, &
call create_adj_pressure_preconditioner( modeldb%config, rhs, adj_lookup_table_cache, &
adj_pressure_operator, adj_pressure_preconditioner )
call create_adj_pressure_solver( adj_pressure_operator, adj_pressure_preconditioner, adj_pressure_solver )
call create_adj_mixed_preconditioner( rhs, adj_pressure_solver, adj_mixed_preconditioner )
Expand All @@ -214,7 +214,7 @@ contains
! Apply the mixed_solver (i.e., forward code)
! --------------------------------------------------------------------------

call mixed_solver%apply( vector_mx, vector_x )
call mixed_solver%apply( modeldb%config, vector_mx, vector_x )

! --------------------------------------------------------------------------
! Compute <Mx,Mx>
Expand Down Expand Up @@ -251,7 +251,7 @@ contains
! Adjoint code
! --------------------------------------------------------------------------

call adj_mixed_solver%apply( vector_amx, vector_mx )
call adj_mixed_solver%apply( modeldb%config, vector_amx, vector_mx )

! --------------------------------------------------------------------------
! Compute <AMx,x>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -152,9 +152,9 @@ contains
call compute_si_operators( modeldb%config, ls_theta, ls_rho, ls_exner, &
model_clock, ls_moist_dyn )

call create_pressure_preconditioner( rhs, pressure_operator, pressure_preconditioner )
call create_pressure_preconditioner( modeldb%config, rhs, pressure_operator, pressure_preconditioner )

call create_adj_pressure_preconditioner( rhs, &
call create_adj_pressure_preconditioner( modeldb%config, rhs, &
adj_lookup_table_cache, &
adj_pressure_operator, &
adj_pressure_preconditioner )
Expand All @@ -175,7 +175,7 @@ contains
! Apply the preconditioner (i.e., forward code)
! --------------------------------------------------------------------------

call pressure_preconditioner%apply( vector_x, vector_mx )
call pressure_preconditioner%apply( modeldb%config, vector_x, vector_mx )

! --------------------------------------------------------------------------
! Compute <Mx,Mx>
Expand All @@ -199,7 +199,7 @@ contains
! Adjoint code
! --------------------------------------------------------------------------

call adj_pressure_preconditioner%apply( vector_mx, vector_amx )
call adj_pressure_preconditioner%apply(modeldb%config, vector_mx, vector_amx )

! --------------------------------------------------------------------------
! Compute <AMx,x>
Expand Down
Loading
Loading