Filipe,
Unfortunately, torq_calc returns only a fully-condensed single value (fx, fy, fz; Tx,Ty,Tx) for drag and torque.
Probably best approach:
Spanwise average in z first. (Several examples exist on how to map (vx , vy , vz ) into (ax,ay,az), where, say,
ay is a 3D scalar field that is invariant in the spanwise direction - it should be a one-liner... or maybe 6 lines.
Then, take the gradient of that (in nek5000, call gradm1(axx,axy,axz,ax). The term you want to evaluate
Is axy at y=0. That is: < du/dy > (x,y=0,z). With <a> --> spanwise average.
For that, I suggest to use hpts, with a set of points that are at, say, y=1.e-6 and z=.01 (i.e. not on an element boundary).
Let me know if you need further elaboration.
I suspect it's about 20-30 lines in userchk() to implement this.
Best,
Paul