Scheduled Downtime
On Friday 21 April 2023 @ 5pm MT, this website will be down for maintenance and expected to return online the morning of 24 April 2023 at the latest

How to post-process precipitation from MPAS model

This post was from a previous version of the WRF&MPAS-A Support Forum. New replies have been disabled and if you have follow up questions related to this post, then please start a new thread from the forum home page.


New member
I writing to find out how to post process precipitation from the MPAS model as well as the suggested best practices for configuring the MPAS model to simulate rainfall correctly.

I have ran a 30 year variable resolution simulation with MPAS and I am about to analyse precipitation. When I plot a single day of rainfall over my area of interest it looks patchy (see rain.gif) and not as smooth as WRF and observation data. Therefore, I am wondering if I configured the model correctly or not.

Particularly, I enabled the option config_bucket_update = '01:00:00' in the model physics, I noticed that the accumulated precipitation does not build up continuously (that is cumulative sum from first day of simulation to last day of simulation). Therefore, it is not clear to me if I need to de-accumulate the rainfall or not. This is because the rainfall time series does not look like an accumulation from the first hour of simulation to the last hour.

I configured the model to write diag files at 6 hourly interval as below:


I post-process the rainfall from the diag file using convert_mpas tool to get a single file ( by running the following command:

convert_mpas diag*.nc

I want to calculate daily rainfall (mm/day) from the 6 hourly output and it is not clear to me if I need to take the average of the 6 hourly output using a tool like cdo after combining the 6 hourly output into a single file. That is, is it OK to do something like below?

cdo daymean


1- Do I need to de-accumulate MPAS rainc and rainnc fields if I set the option config_bucket_update = '01:00:00' in my namelist (attached)?
2- Is there any example or documentation you can refer me to as I have been unable to get this information from the user's guide and presentations?
3- How can I process rainfall from MPAS simulation so that it is comparable with observations and WRF simulations?
4- How can one configure the MPAS model to simulate rainfall well over complex terrain? Do you have any comments about my attached namelist?
5- I see from ncdump of one of the diag*.nc files that the unit of rainc is "mm", is this mm per day ? (see diag_file_meta.txt)

Thanks while looking forward to hearing from you.


  • diag_file_meta.txt
    17.8 KB · Views: 68
  • rain.gif
    171.8 KB · Views: 3,089
  • namelist.atmosphere.txt
    1.8 KB · Views: 80
Firstly, thanks very much for your detailed post.

Unfortunately, we haven't provided much information about the precipitation and radiation bucket option in the User's Guide. Essentially, though, setting config_bucket_update to a time interval that is not "none" activates the bucket option, which behaves as follows:

  • In each timestep, the model checks whether the bucket alarm is ringing; this alarm rings at the interval (in simulation time) specified by the config_bucket_update namelist option.
  • If the bucket alarm is ringing, any grid cells whose accumulated values for precipitation or radiative flux exceed the bucket sizes, which default to 100 mm for precipitation and 1e9 J for radiation, will have one bucket size subtracted from their accumulated values and a corresponding bucket counter incremented.

With the bucket option activated, then, you'll need to make use of the i_rainc and i_rainnc fields to obtain the correct accumulated precipitation. For each grid cell, you can multiply the precipitation bucket size by i_rainc and add the result to rainc, and similarly for i_rainnc and rainnc.

With this in mind:

  1. If you would like the precipitation accumulation over any specific period, you will need to de-accumulate the precipitation fields. After making use of the bucket counts to obtain the total accumulation at two time periods during the model simulation, you can find the accumulation between those periods by subtraction.
  2. We really should add at least the above information to the User's Guide. I think a new section in Chapter 8 might be appropriate.
  3. Making use of the bucket counts (and knowing the bucket size) should give you correct accumulated precipitation since the beginning of the model simulation.
  4. MPAS-Atmosphere does have a much more limited set of parameterization schemes compared to, e.g., the WRF model. Other than testing with other schemes, I don't know that there is much else in the namelist.atmosphere file that would help with the simulation of precipitation over complex terrain.
  5. The units of "mm" for rainc and rainnc give the total accumulated amount of precipitation since the start of the model simulation. As mentioned in (1), you can get the accumulation in any given period by subtracting the running accumulation at t_1 from the running accumulation at t_2.

If you have any related questions, please don't hesitate to follow-up in this thread!
Thank you very much for the clear explanation. I will implement the suggestions and if I have any questions I will get back to you. This is awesome! :D
Hi Michael,
Thanks once more for the clear explanation.

Using the description which you provided about what happens when the setting config_bucket_update is enabled, I was able to get a good spatial representation of total accumulated rainfall (see attached) by using the formula below:


NB: By applying the above formula, the patchy rainfall (figure which I submitted in earlier post) becomes smooth as I will expect(see attached figure tot_accum_rain.gif ).



  • tot_accum_rain.gif
    64.9 KB · Views: 3,073
Thanks very much for following up, and I'm glad to hear you have been able to compute what looks like a reasonable total precipitation field!