3
$\begingroup$

I do not wish to cross post but not sure whether the question belongs here or not - https://codereview.stackexchange.com/questions/185368/numerical-differentiation-on-sphere-with-python. This is a direct example of the question I asked here - Atmospheric science fortran code review ? It appears it is unrelated to meteorology as written for that SE but it is in fact very much related to meteorology when you consider that it is taking the spatial derivative of the wind along a isobaric surface or potential temperature in the zonal direction. Obviously I would reword it for this site.

Responding to Jeopardy Tempest's request

The question could go something like this

Here is an algorithm for taking the spatial derivative for a global rectilinear grid for isobaric zonal and meridional winds

#GRIB Scan order goes eastward and then northward
# Spatial derivatives for interior points

# du(zonal)/dx = u(east) - u(west)  

#dv(meridional)/dy = v(north) - v(south)

  Loop South to North 

       Loop West to East 

            dudx = u(i+1) - u(i-1)/2* dlambda 

            dvdy - v(j+1) - v(j-1) /2* dphi

        End loop

   End loop

# Section for handling poles(north and south)

  Something similar here
| |
$\endgroup$
  • $\begingroup$ Could you perhaps indicate a proposal (or the key points) of how you would word it if you presented it on this site? $\endgroup$ – JeopardyTempest Jan 19 '18 at 7:20
  • $\begingroup$ Unsure, whether it belongs here or not. I would not post it at the pure programming-focussed SE-sites. $\endgroup$ – daniel.heydebreck Feb 12 '18 at 9:09
  • 1
    $\begingroup$ @daniel.neumann - thanks Daniel. I am not asking it anywhere else. If not here nowhere else. $\endgroup$ – gansub Feb 12 '18 at 9:38
2
$\begingroup$

I think the key to your question about that specific example is your sentence,

What I am looking for improvement is the handling of the missing data and perhaps exception handling and obviously code clarity and any other improvements

The question could be answered by a computer programmer and hence could be regarded as being off topic here, but, meteorologists who are experienced in handling the type of data that the algorithm processes may have insights as to how the missing data, etc., should be dealt with to make the results of the algorithm valid for meteorological purposes.

If that was emphasized in the question, then I would regard the question as being on topic here.

| |
$\endgroup$
  • $\begingroup$ I think I was quite clear on what I would be posting here. Look at the algorithm, $\endgroup$ – gansub Jan 26 '18 at 15:46

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .