Scheduled Downtime
On Tuesday 24 October 2023 @ 5pm MT the forums will be in read only mode in preparation for the downtime. On Wednesday 25 October 2023 @ 5am MT, this website will be down for maintenance and expected to return online later in the morning.
Normal Operations
The forums are back online with normal operations. If you notice any issues or errors related to the forums, please reach out to help@ucar.edu

CLM: from lat/lon to gridcell index

I am new to CLM and I have a question about the gridcell index which I appreciate your response. I am currently dealing with data assimilation into CLM. I need to do a kind of local averaging (including the values of a surface data for let’s say the surrounding 25 grid cells) of each grid cell. However, I don’t know how to identify the gridcell index of surrounding pixels (in both vertical and horizontal directions). I know about the grc%latdeg(g) that converts the gridcell index to lat/lon, I am wondering whether there is also a reverse function that gives the gridcell index of lat/lon by which I can idendify the adjacents cells from their lats/lons. Or, is there any other way to get the gridcell index of surrounding pixcels?

 

Best Regards

Farshid
 
Top