This manuscript presents an added inverse modeling system capability for CHIMERE based on PYVAR, which has been successfully used with LMDz for GHG flux estimation. The manuscript describes its model development and show some very promising results for CO and NOx. This version of the manuscript has improved relative to original submission, addressing several of previous reviewers comments. I commend the authors for this revision. However, while this is relevant to the scope of GMD, I have several concerns with regards to the clarity and presentation of its description and substantive presentation of results, especially on quantifying some uncertainties or describing its fidelity. I suggest minor revisions to address the following concerns before publication:
1) Description of the system could be improved by:
a) clear differentiation of new developments in PYVAR for reactive species. In its current form, it appears to be just an implementation of PYVAR to CHIMERE. If so, detailed testing strategies is warranted to show the fidelity of i) CHIMERE adjoint/TLM, ii) PYVAR global minimization especially for the current application to reactive species. How are these tested and quantified?
b) clear differentiation between PYVAR and 4D-Var. How is PYVAR different than other 4DVar approaches? What are its advantages and disadvantages? What are its strengths and limitations? Please add some context.
c) Clear description of Figure 3. In its current form, it shows a list or table of variables and parameters. It would be clearer if details on this Figure are discussed. What do these variables represent? Are there utilities in PYVAR system that are used? If so, it may be better to name and describe those utilities.
d) clear mathematical expressions and their representation (including consistent use of nomenclature). In particular, how does the time component of the cost function (i.e., 4DVAr versus PYVAR) treated in PYVAR? Can the “add”, “mult”, and “scale” be incorporated in the cost function notation? Where are these correction estimated and applied in the algorithm?
2) Presentation of results could be improved by:
a) Some diagnostics to check optimality of the inversion algorithm. For example, i) posterior error covariances – if calculated especially error reduction estimates, ii) RMSEs. This reviewer understands that comparison with independent measurements is beyond the scope of this paper. But at least provide some indication of its optimality. Results on scaling factors and increments can only be interpreted if compared to independent datasets and other approaches. However, one can show for example that the minimization reached its minimum or show the breakdown of the cost function to show that the observations are able to constrain some elements of the control vector. In its current form, this is shown qualitatively in Figure 5 to 8. At least quantify these by statistics other than mean biases. These are very promising results and should be highlighted more.
b) Spell and grammar checks, as well as clearer formats of tables.
1) Abstract: Please add some numbers for your results (especially error reduction)
2) Line 16: “in addition to greenhouse gases”. I understand that PYVAR has been used for GHG before, but I don’t think it’s used here. Good for the intro but perhaps not in the abstract. Focus on what exactly is new here.
3) Introduction: While discussion on emissions and inversions can be interesting, some of these are general statements which may not be exactly what this paper is specifically addressing and demonstrating. Focus on what issues/problems exactly the study addresses. For example, is this study addressing high resolution emission estimations (at 0.5 degrees?) or O3 or GHG? I understand that some of these statements motivate future work but perhaps make it more concise and focus more on what exactly does this paper at its current form address in terms of scientific problems? Why are other approaches not sufficient? What are the limitations of these approaches?
4) Line 102. Check spacing
5) Line 121. “in input of the CTM”. Please clarify
6) Line 124: “during the inversion process (surface fluxes …)” Perhaps make this two separate sentences?
7) Line 121-134: parameters versus variables? Are they the same?
8) Line 130: “observation errors”. Why not call it model-data mismatch?
9) Line 132: “given their prior estimates, the observations, the CTM and the associated uncertainties”. First, it may be better if “the” article is omitted on the succeeding segments of the sentence. Second, “given the CTM” may not be accurate way to describe this minimization.
10) Line 133: “in the following”. Please clarify or omit.
11) Line 135: What is xb? There is no mention of time in this section. Be consistent in notations (italic versus non-italic, bold vs not bold) for all expressions not just Eq. 1. What are the dimensions of these vectors and matrices?
12) Line 137: “state vector x”. Is this the same as control vector? What do you mean by state? Is a parameter a state?
13) Line 139: “includes the CTM”. Please clarify.
14) Line 157: I suggest to may Eq 2 as a separate line. Should B be bold?
15) Line 142: “errors are assumed to be centered and to have Gaussian distribution”. What do you mean by centered? Unbiased? Is it necessary to assume Gaussianity? If so, then why not just solve the analytical solution? Because H is non-linear?
16) Line 159: “optimal solution”. What does optimality mean here?
17) Line 163: Careful on spacing between words
18) Line 172: I suggest to make the modified equation 2 as a separate line. How is this linearization implemented? i.e., where is this linearization point relative to the iteration interval? Does making shorter intervals improve minimization and representation of non-linearity?
19) Line 173: what do you mean by “norms”.
20) Line 175: how do you address local minimum?
21) Line 177-184: If there’s an estimate of posterior uncertainty in this system, is this used in the study? Please state which approach is used.
22) Figure 1. Are B and R fixed? Caption has bold fonts.
23) Line 199: “without chemistry a first time”. Please clarify.
24) Section 3.2 How do you diagnose if these adjoints are calculated accurately? Are there tests conducted for this purpose?
25) Line 207-216. Please check spacing between words.
26) Line 214: “lead with”. Please clarify.
27) Line 217-222. While important, I suggest to have them numbered but part of the paragraph rather than bulleted. And please elaborate each one.
28) Line 221: “when no species requires them”. Please clarify. Do you mean for GHG for all – chem, dep? Or for a particular species that do not have either of these processes?
29) Line 224: “currently operational”. Please clarify. Does this mean it is used in operational mode to forecast and predict? Also, is there a particular version of PYVAR and CHIMERE and PYVAR-CHIMERE used in this study?
30) Table 1 is very informative. Please format accordingly, especially separating the header as it becomes confusing to read. Not sure if the “example of the definition..” row should be there. Can it be in the title?
31) Section 3.3. Discussion of correction types is very informative as well. Is it possible to show how these are related to Eq. 1 to 3? Isnt it that the control vector consists of elements –corresponding to each grid point and species? If so, how is “scale” implemented to maps or masks for regions?.
32) Line 254: “which is similar to the control vector of budgets…” Please elaborate.
33) Line 256: “adding the obtained values to the …” please rephrase.
34) Line 259: “standard deviation coefficient”. Please clarify. Is it really a coefficient? And since this is an error covariance matrix, should the diagonal elements be error variance not error standard deviation?
35) Line 260-262: Very important statement. But please elaborate or rephrase. What is standard deviation of the uncertainty?
36) Line 266: “variances”. Are these error variances?
37) Line 270: “ error correlation between fluxes of CO and NOx, are not coded yet”. Please elaborate on its potential effect on your estimation?
38) Line 296: How about calling this “Observation Operators”?
39) Line 298: Please note spacing between words.
40) Section 3.4. I think this is very relevant. Please elaborate Figure 3. In its current form, it is not clear what this Figure represents and how we can use it to interpret results. I think coding of these operators is a vital step in the assimilation and should be given more emphasis. Are these utilities also available? How good are the adjoints of these operators? Are there tests to diagnose their accuracy?
41) Please check bold fonts in line 311 to 312
42) Line 314-318: Please highlight in your notations if these are scalars or vectors. And please add corresponding dimensions. What is the difference between small (c_m(o)) and big C_m(o. What is x_a?
43) Line 328-334: This is also informative. Is there a reference for parallelization approach in PYVAR and CHIMERE? How does it scale with more CPUs? 4 hours seem to be a long time, isn’t it? Please elaborate and compare with other systems.
44) Line 336-343. Bold? Check spacing between words.
45) Line 391-392. Why are they not different?
46) Figure 5 caption. “differences are in %” is in contrast to the units in the figure.
47) Figure 6 and 7. Is it possible to show difference plots? And more statistics (RMSEs, correlation, bias? Error reduction? Are these really surface concentrations? They are column measurements, right? What about initial conditions? Has this change as well since these are part of the control vector? Superscript on units?
48) Section 4.2. Should this be presented prior to section 4.1.3 since some of the plots are for the posterior estimates?
49) Section 4.2.1. Can this be summarized in a table and discuss a little bit in the text as to the rational of the choice of these parameters? Am I to assume that NOx emissions are estimated only for 1 day, and all days are the same? For CO, what do you mean by 7-day? Average? How are emissions incorporated in CHIMERE in terms of time? Is there a distribution? i.e., diurnal and weekly cycle?
50) Section 4.2.2. Please check spacing of words and bold fonts.
51) Section 4.2.3. Is it possible to break down the components of J? How about emission error reduction? How do you ensure that these increments are “resolved by the observations”. It would be great to see error reduction plots, if posterior error covariances are calculated. How about initial conditions? Did this change as well?
52) Line 508-516. What is the implication of this to overall cost and computing and optimality of minimization including error correlation of CO and NOX (and spatial correlation against superobbing) as well as increase in dimension of control vector? This also entails using this system at higher spatiotemporal resolution, right? It would be great to have a section on limitations before future implicatio