Project

General

Profile

Calculate the number of degree days and the total sum of solar radiation during these days.

Added by Theodoros Gkousarov about 11 years ago

Hi everybody,

This is very hard and I m not sure whether I can do it by using only CDO.

I have a WRF file containing hourly values of T2 from 2002-2010.
I also have a file containing daily solar radiation from 2002-2010.

I want to calculate the number of days starting from 10th June for each year until 700 degree days has been reached. ( threshold = 10C)
This normaly ranges around 30-45 days in UK. ( will need possibly to calculate daily avg from hourly values)

After I find the amount of days needed to reach the 700 degree days, I need to calculate the amount of solar radiation received in each location, depending on home many days needed. e.x in location A, the number of days is 30 and the sum of solar radiation from 10th june up to the 30th day is 500MJ/m2. In location B, because it was colder, the days are 40, therefore the sum of solar rd is 700MJ/m2.

Is it possible to do it using only CDO? or I will need to use NCL as well?

Every help will be much appreciable.

Thanks,
Theo


Replies (3)

RE: Calculate the number of degree days and the total sum of solar radiation during these days. - Added by Jaison-Thomas Ambadan almost 11 years ago

Hi,

This is very hard

Yes, indeed! ;)

I want to calculate the number of days starting from 10th June for each year until 700 degree days has been reached. ( threshold = 10C)

I'm not sure if I understood your question correctly. Anyway, try the following:

1. extract the period you want and calculate the daily mean

cdo -mergetime -daymean -selmon,7/12 hourly_ifile -daymean -selday,10/30 -selmon,6 hourly_ifile daily_mean_from_10thJune

2. until 700 degree days has been reached. ( threshold = 10C)

I've NO idea what this means but you can use the comparison/mask operators to count the number of days. see here for more info: https://code.zmaw.de/embedded/cdo/1.5.9/cdo.html#x1-1300002.5

For example if you wound like count the number of days > 10 C, for each month

cdo -gt,10 daily_mean_from_10thJune ofile

the output "ofile" is a mask which contains 0s and 1s (1 imples your condition/conditional-statement is true) so if you would like to count the number of days in a month that satisfy the conditon - simply do the monthly sum!

This is just an example.

Is it possible to do it using only CDO?

I'm sure it is possible with CDO (of course not in one step) but you've to play around a little bit.

Cheers,
J

RE: Calculate the number of degree days and the total sum of solar radiation during these days. - Added by Theodoros Gkousarov almost 11 years ago

Thank you very much,

2. until 700 degree days has been reached. ( threshold = 10C)

I mean to accumulate the number of days which exceed 10C until 700degrees have been reached. E.x june 11th had 8 degree days , june 12 has 30.. so 38 so far. after 13 days lets say, you have 700 degree days and its 28th of june, therefore you stop counting. So a value of 13, has been saved for this location.

I want to create a map which shows the spatial destribution of the total amount of days it takes for each individual location to reach 700 degree days.

hope it makes some sense now.

cheers.
Theo

    (1-3/3)