private void setCoeff ( ) { c [ 0 ] [ 0 ] = 0.0 ; cd [ 0 ] [ 0 ] = 0.0 ; epoch = Double . parseDouble ( input [ 0 ] . trim ( ) . split ( "[\\s]+" ) [ 0 ] ) ; defaultDate = epoch + 2.5 ; String [ ] tokens ; //loop to get data from internal values for ( int i = 1 ; i < input . length ; i ++ ) { tokens = input [ i ] . trim ( ) . split ( "[\\s]+" ) ; int n = Integer . parseInt ( tokens [ 0 ] ) ; int m = Integer . parseInt ( tokens [ 1 ] ) ; double gnm = Double . parseDouble ( tokens [ 2 ] ) ; double hnm = Double . parseDouble ( tokens [ 3 ] ) ; double dgnm = Double . parseDouble ( tokens [ 4 ] ) ; double dhnm = Double . parseDouble ( tokens [ 5 ] ) ; if ( m <= n ) { c [ m ] [ n ] = gnm ; cd [ m ] [ n ] = dgnm ; if ( m != 0 ) { c [ n ] [ m - 1 ] = hnm ; cd [ n ] [ m - 1 ] = dhnm ; } } } }
This method sets the input data to the internal fit coefficents . If there is an exception reading the input file WMM . COF these values are used .