From 28f8501ba297814741eba7a7df41edf5f5e8b0f6 Mon Sep 17 00:00:00 2001 From: Iulian Grindeanu Date: Tue, 22 Oct 2024 20:54:44 -0500 Subject: [PATCH] index for aream --- driver-moab/main/component_mod.F90 | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/driver-moab/main/component_mod.F90 b/driver-moab/main/component_mod.F90 index 5e261e48601c..c7a8f51b99ed 100644 --- a/driver-moab/main/component_mod.F90 +++ b/driver-moab/main/component_mod.F90 @@ -615,7 +615,8 @@ subroutine component_init_aream(infodata, rof_c2_ocn, samegrid_ao, samegrid_al, tagname='aream'//C_NULL_CHAR nloc = mct_avect_lsize(dom_s%data) allocate(data1(nloc)) - data1 = dom_s%data%rAttr(ka,:) + km = mct_aVect_indexRa(dom_s%data, "aream" ) + data1 = dom_s%data%rAttr(km,:) ent_type = 1 ! element dense double tags allocate(gids(nloc)) gids = dom_s%data%iAttr(mct_aVect_indexIA(dom_s%data,"GlobGridNum"),:) @@ -628,6 +629,14 @@ subroutine component_init_aream(infodata, rof_c2_ocn, samegrid_ao, samegrid_al, endif deallocate(gids) deallocate(data1) +#ifdef MOABDEBUG + ierr = iMOAB_WriteMesh(mbrxid, trim('recRofWithAream.h5m'//C_NULL_CHAR), & + trim(';PARALLEL=WRITE_PART'//C_NULL_CHAR)) + if (ierr .ne. 0) then + write(logunit,*) subname,' error in writing rof mesh coupler ' + call shr_sys_abort(subname//' ERROR in writing rof mesh coupler ') + endif +#endif endif endif end if