[MITgcm-devel] problem with maskInC and obcs-balancing in adjoint

Martin Losch Martin.Losch at awi.de
Mon Mar 14 09:28:40 EDT 2011


Hi Jean-Michel, Patrick,

I have the impression that something goes wrong with the balancing code in the adjoint.:
The field maskInC has 1 on the open boundary, whereas they should have zeros (as set in obcs_init_fixed). The reason is that there is a ifdef ALLOW_AUTODIFF_TAMC block in initialise_varia, where ini_depth and ini_masks_etc are called, where maskInC is reset to its original value (1 on the boundary). I need to force TAF to call obcs_init_fixed again within this block. What is the preferred option?
1. show obcs_init_fixed to TAF (edit obcs_ad_diff.list)
2. use directives:
CADJ SUBROUTINE OBCS_INIT_FIXED INPUT  = 1
CADJ SUBROUTINE OBCS_INIT_FIXED OUTPUT =
CADJ SUBROUTINE OBCS_INIT_FIXED REQUIRED
(edit obcs_ad.flow)
3. As an alternative, one could re-introduce the "obcs-masks" that you have just removed a few versions ago.

1 and 2 work, haven't tried 3 (because I do not like that option).

Martin



More information about the MITgcm-devel mailing list