Download presentation
Presentation is loading. Please wait.
1
GEOS-CHEM adjoint development using TAF
Monika Kopacz, Daniel Jacob, Dylan Jones (UT), Parvadha Suntharalingam, Paul Palmer April 5, 2005
2
What is an adjoint model?
X Y adjoint model Inverse map x y K K* For linear operator K, mapping from space X to space Y. Adjoint operator KT For nonlinear model K represents linearization of the original model
3
Why the need for adjoint model?
constraints on emissions with high resolution can consider nonlinear processes computationally efficient for sensitivity studies
4
Adjoint of GEOS-CHEM 3 approaches to obtaining derivative code: analytic derive adjoint operator analytically and discretize discrete Lagrange function define L = J +lT (K x – yobs) li = li+1 + (Ki+1 xi+1 – yobs,i+1) direct differentiation of the code: Automatic Differentiation Transformation of Algorithm in Fortran (TAF) source to source compiler Recipes for Adjoint Code Construction, Giering and Kaminski, 1998
5
What is TAF? Source to source compiler developed by Ralf Giering and Thomas Kaminski; a commercial, license-based product supplied by Fast Opt® Forward differentiation, Tangent Linear Model: TAF dynamic_loop.f dynamic_loop_tl.f Reverse differentiation, Adjoint Model: TAF dynamic_loop_ad.f dynamic_loop.f TAF dynamic_loop(x, fc) ad_dynamic_loop(x, adx, fc, adfc) where x can represent emissions field fc can represent a scalar ‘cost’ variable then adx stores dfc/dx adfc stores dfc/dfc = 1
6
First step Tangent Linear Model challenges benefits
Semi-automatically derived, stand-alone model Tangent Linear Model challenges benefits ? general TAF-GC interfacing ? resolving flow nonlinearities ? Fortran 90 support ? manual changes verification: comparison with green’s function approach Check linearity of the code Resolve TAF-GC compatibility
7
Next step Adjoint Model challenges benefits
Semi-automatically derived, stand-alone model Adjoint Model challenges benefits ? all TLM Fortran issues ? storage/recomputation for reverse mode ? non-trivial model evaluation ? manual changes ? Interfacing with optimization package verification: comparison with previous CO inversions, (Heald et al. 2003, Palmer et al. 2003) efficient sensitivity studies J inversions for large state vector and large data sets J data assimilation
8
Minimizing the gradient
0 2 1 3 x2 x1 x3 x0 Adjoint Transport GEOS- CHEM Measurement Sampling Estimated Fluxes Modeled Concentrations simulated Measurements “True” Assumed Errors Weighted Residuals Cost function J Flux Update a priori fluxes Adjoint Fluxes = J Minimum of cost function J Courtesy of David Baker
9
Preliminary results Finite Difference Tangent Linear Model 3D field
Scalar perturbation
10
SEMI-AUTOMATIC CAPABILITY TO GENERATE TLM/ADM
End product ADJOINT MODEL TANGENT LINEAR MODEL OPTIMIZATION PACKAGE SEMI-AUTOMATIC CAPABILITY TO GENERATE TLM/ADM
11
Automatic differentiation
Z = X * SIN (Y**2) differential transpose ADY = ADY + ADZ*X *COS(Y**2)*2*Y ADX = ADX + ADZ*SIN(Y**2) ADZ = 0.0 from Recipes for Adjoint Code Construction by R. Giering and T. Kaminski, 1998
12
Analytic adjoint operator for advection
Consider
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.