<commit_before>#pragma ident "$Id$"

/**
 * @file LinearCombinations.cpp
 * This class defines handy linear combinations of GDS data.
 */

//============================================================================
//
//  This file is part of GPSTk, the GPS Toolkit.
//
//  The GPSTk is free software; you can redistribute it and/or modify
//  it under the terms of the GNU Lesser General Public License as published
//  by the Free Software Foundation; either version 2.1 of the License, or
//  any later version.
//
//  The GPSTk is distributed in the hope that it will be useful,
//  but WITHOUT ANY WARRANTY; without even the implied warranty of
//  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
//  GNU Lesser General Public License for more details.
//
//  You should have received a copy of the GNU Lesser General Public
//  License along with GPSTk; if not, write to the Free Software Foundation,
//  Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
//
//  <NAME> - gAGE ( http://www.gage.es ). 2007, 2008, 2009
//
//============================================================================


#include "LinearCombinations.hpp"


namespace gpstk
{

   LinearCombinations::LinearCombinations()
   {

      double a(+GAMMA_GPS/0.646944444);
      double b(1.0/0.646944444);

         // Definition to compute prefit residual of C1
      c1Prefit.header                     = TypeID::prefitC;
      c1Prefit.body[TypeID::C1]           = +1.0;
      c1Prefit.body[TypeID::rho]          = -1.0;
      c1Prefit.body[TypeID::dtSat]        = +1.0;
      c1Prefit.body[TypeID::rel]          = -1.0;
      c1Prefit.body[TypeID::gravDelay]    = -1.0;
      c1Prefit.body[TypeID::satPCenter]   = -1.0;
      c1Prefit.body[TypeID::tropoSlant]   = -1.0;
      c1Prefit.body[TypeID::ionoL1]       = -1.0;
         // The instrumental delay for C1 is not exactly TGD, but it is close
      c1Prefit.body[TypeID::instC1]       = -1.0;

         // Definition to compute prefit residual of P1
      p1Prefit.header                     = TypeID::prefitC;
      p1Prefit.body[TypeID::P1]           = +1.0;
      p1Prefit.body[TypeID::rho]          = -1.0;
      p1Prefit.body[TypeID::dtSat]        = +1.0;
      p1Prefit.body[TypeID::rel]          = -1.0;
      p1Prefit.body[TypeID::gravDelay]    = -1.0;
      p1Prefit.body[TypeID::satPCenter]   = -1.0;
      p1Prefit.body[TypeID::tropoSlant]   = -1.0;
      p1Prefit.body[TypeID::ionoL1]       = -1.0;
         // Differential code biases (DCBs) for P1-P2
      p1Prefit.body[TypeID::instC1]       = -1.0;

         // Definition to compute PC combination
      pcCombination.header                = TypeID::PC;
      pcCombination.body[TypeID::P1]      = +a;
      pcCombination.body[TypeID::P2]      = -b;

         // Definition to compute PC combination, using C1 instead of P1
      pcCombWithC1.header                 = TypeID::PC;
      pcCombWithC1.body[TypeID::C1]       = +a;
      pcCombWithC1.body[TypeID::P2]       = -b;

         // Definition to compute prefit residual of PC
      pcPrefit.header                     = TypeID::prefitC;
      pcPrefit.body[TypeID::PC]           = +1.0;
      pcPrefit.body[TypeID::rho]          = -1.0;
      pcPrefit.body[TypeID::dtSat]        = +1.0;
      pcPrefit.body[TypeID::rel]          = -1.0;<commit_msg>Added 'l1Prefit' linear combination. Also the multipath corresponding coefficient.<commit_after>#pragma ident "$Id$"

/**
 * @file LinearCombinations.cpp
 * This class defines handy linear combinations of GDS data.
 */

//============================================================================
//
//  This file is part of GPSTk, the GPS Toolkit.
//
//  The GPSTk is free software; you can redistribute it and/or modify
//  it under the terms of the GNU Lesser General Public License as published
//  by the Free Software Foundation; either version 2.1 of the License, or
//  any later version.
//
//  The GPSTk is distributed in the hope that it will be useful,
//  but WITHOUT ANY WARRANTY; without even the implied warranty of
//  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
//  GNU Lesser General Public License for more details.
//
//  You should have received a copy of the GNU Lesser General Public
//  License along with GPSTk; if not, write to the Free Software Foundation,
//  Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
//
//  <NAME> - gAGE ( http://www.gage.es ). 2007, 2008, 2009
//
//============================================================================


#include "LinearCombinations.hpp"


namespace gpstk
{

   LinearCombinations::LinearCombinations()
   {

      double a(+GAMMA_GPS/0.646944444);
      double b(1.0/0.646944444);

         // Definition to compute prefit residual of C1
      c1Prefit.header                     = TypeID::prefitC;
      c1Prefit.body[TypeID::C1]           = +1.0;
      c1Prefit.body[TypeID::rho]          = -1.0;
      c1Prefit.body[TypeID::dtSat]        = +1.0;
      c1Prefit.body[TypeID::rel]          = -1.0;
      c1Prefit.body[TypeID::gravDelay]    = -1.0;
      c1Prefit.body[TypeID::satPCenter]   = -1.0;
      c1Prefit.body[TypeID::tropoSlant]   = -1.0;
      c1Prefit.body[TypeID::ionoL1]       = -1.0;
         // The instrumental delay for C1 is not exactly TGD, but it is close
      c1Prefit.body[TypeID::instC1]       = -1.0;
      c1Prefit.body[TypeID::mpC1]         = -1.0;

         // Definition to compute prefit residual of P1
      p1Prefit.header                     = TypeID::prefitC;
      p1Prefit.body[TypeID::P1]           = +1.0;
      p1Prefit.body[TypeID::rho]          = -1.0;
      p1Prefit.body[TypeID::dtSat]        = +1.0;
      p1Prefit.body[TypeID::rel]          = -1.0;
      p1Prefit.body[TypeID::gravDelay]    = -1.0;
      p1Prefit.body[TypeID::satPCenter]   = -1.0;
      p1Prefit.body[TypeID::tropoSlant]   = -1.0;
      p1Prefit.body[TypeID::ionoL1]       = -1.0;
         // Differential code biases (DCBs) for P1-P2
      p1Prefit.body[TypeID::instC1]       = -1.0;
      p1Prefit.body[TypeID::mpC1]         = -1.0;

         // Definition to compute prefit residual of L1
      l1Prefit.header                     = TypeID::prefitL;
      l1Prefit.body[TypeID::L1]           = +1.0;
      l1Prefit.body[TypeID::rho]          = -1.0;
      l1Prefit.body[TypeID::dtSat]        = +1.0;
      l1Prefit.body[TypeID::rel]          = -1.0;
      l1Prefit.body[TypeID::gravDelay]    = -1.0;
      l1Prefit.body[TypeID::satPCenter]   = -1.0;
      l1Prefit.body[TypeID::tropoSlant]   = -1.0;
      l1Prefit.body[TypeID::ionoL1]       = +1.0;
         // Coefficient for L1 windUp is L1 wavelength/2*PI
      l1Prefit.body[TypeID::windUp]       = -L1_WAVELENGTH/TWO_PI;
      l1Prefit.body[TypeID::mpL1]         = -1.0;

         // Definition to compute PC combination
      pcCombination.header                = TypeID::PC;
      pcCombination.body[TypeID::P1]      = +a;
      pcCombination.body[TypeID::P2]      = -b;

         // Definition to compute PC combination, using C1 instead of P1
      pcCombWithC1.header                 = TypeID::PC;
      pcCombWithC1.body[TypeID::C1]       = +a;
      pcCombWithC1.body[TypeID::P2]       = -b;

         // Definition to compute prefit residual of PC
      pcPrefit.header                     = TypeID::prefitC;
      pcPrefit.body[TypeID::PC]           = +1.0;
      pcPrefit.body[TypeID::rho]          = -1.0;
      pcPrefit.body[TypeID::dtSat]        = +1.0;
      pcPrefit.body[TypeID::rel]          = -1.0;
{'fraction_non_alphanumeric': 0.1600371254309202, 'fraction_numerical': 0.041633518960487934, 'mean_word_length': 2.1666666666666665, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 2, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2747367', 'n_tokens_mistral': 2665, 'n_tokens_neox': 2523, 'n_words': 581}