﻿id	summary	reporter	owner	description	type	status	priority	milestone	component	version	resolution	keywords	cc
229	Bug in ropp_pp_internal_navbit	Ian Culverwell	Ian Culverwell	"Kjartan Kinch (DMI) has identified a bug in the open loop processing routine ropp_pp/preprocess/ropp_pp_openloop.f90.  This contains the subroutine ropp_pp_internal_navbit which calculates

    TGM(:) = MODULO(time(:), GPSFL)[[BR]]

    TGI(:) = INT(time(:)/GPSFL)

Unfortunately, this doesn't quite work:

 time =   -2.50000000000000       -1.50000000000000      -0.500000000000000
  0.500000000000000        1.50000000000000        2.50000000000000

 MODULO(time, gpsfl) =   0.500000000000000       0.500000000000000
  0.500000000000000       0.500000000000000       0.500000000000000
  0.500000000000000

 INT(time/gpsfl) =           -2          -1           0           0           1        2

Note the double zero in INT. 

Problem solved by using FLOOR instead:
 
 FLOOR(time/gpsfl) =           -3          -2          -1           0           1           2
TGM+TGI then reconstructs the original time variable correctly. 

This fixes some of Kjartan's difficulties in rationalising OCC and ROPP. It has been put right in ROPP5.0.
"	defect	closed	normal	5.0	ropp_pp	4.1	fixed	open loop navigation bits	
