NOAA-EMC / bufr-query

Apache License 2.0
1 stars 2 forks source link

SensorScanAngleVariable Bug #26

Open rmclaren opened 8 hours ago

rmclaren commented 8 hours ago

In SensorScanAngleVariable:

if (sensor == "iasi")
{
   float tmp;
   tmp = -stepAdj;
   // Calculate sensor scan angle
   for (size_t idx = 0; idx < fovnObj->size(); idx++)
   {
      if (scanpos[idx] % 2 == 1)
      {
         tmp = stepAdj;
      }
      scanang[idx] = start + static_cast<float>((fovn[idx]-1)/4) * step + tmp;
   }
}

tmp starts being negative of stepAdj but is mutated to be equal to stepAdj with the first odd numbered scanpos. It stays that way for the rest of the for loop execution.

rmclaren commented 8 hours ago

@emilyhcliu Is the intention for the stepAdj to be negative for even numbered scan positions?

rmclaren commented 6 hours ago

@JasonWelsh-NOAA Could you take aa look :)