mirror of
https://github.com/gnss-sdr/gnss-sdr
synced 2025-01-05 15:00:33 +00:00
Enhance const correctness, minor cosmetics
This commit is contained in:
parent
ff90cf1a7e
commit
0c26a95af4
@ -84,7 +84,7 @@ void Gps_L1_Ca_Kf_Tracking_cc::forecast(int noutput_items,
|
|||||||
{
|
{
|
||||||
if (noutput_items != 0)
|
if (noutput_items != 0)
|
||||||
{
|
{
|
||||||
ninput_items_required[0] = static_cast<int>(d_vector_length) * 2; //set the required available samples in each call
|
ninput_items_required[0] = static_cast<int>(d_vector_length) * 2; // set the required available samples in each call
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -122,7 +122,7 @@ Gps_L1_Ca_Kf_Tracking_cc::Gps_L1_Ca_Kf_Tracking_cc(
|
|||||||
// Initialize tracking ==========================================
|
// Initialize tracking ==========================================
|
||||||
d_code_loop_filter.set_DLL_BW(dll_bw_hz);
|
d_code_loop_filter.set_DLL_BW(dll_bw_hz);
|
||||||
|
|
||||||
//--- DLL variables --------------------------------------------------------
|
// --- DLL variables --------------------------------------------------------
|
||||||
d_early_late_spc_chips = early_late_space_chips; // Define early-late offset (in chips)
|
d_early_late_spc_chips = early_late_space_chips; // Define early-late offset (in chips)
|
||||||
|
|
||||||
// Initialization of local code replica
|
// Initialization of local code replica
|
||||||
@ -144,7 +144,7 @@ Gps_L1_Ca_Kf_Tracking_cc::Gps_L1_Ca_Kf_Tracking_cc(
|
|||||||
|
|
||||||
multicorrelator_cpu.init(2 * d_current_prn_length_samples, d_n_correlator_taps);
|
multicorrelator_cpu.init(2 * d_current_prn_length_samples, d_n_correlator_taps);
|
||||||
|
|
||||||
//--- Perform initializations ------------------------------
|
// --- Perform initializations ------------------------------
|
||||||
// define initial code frequency basis of NCO
|
// define initial code frequency basis of NCO
|
||||||
d_code_freq_chips = GPS_L1_CA_CODE_RATE_HZ;
|
d_code_freq_chips = GPS_L1_CA_CODE_RATE_HZ;
|
||||||
// define residual code phase (in chips)
|
// define residual code phase (in chips)
|
||||||
@ -156,7 +156,6 @@ Gps_L1_Ca_Kf_Tracking_cc::Gps_L1_Ca_Kf_Tracking_cc(
|
|||||||
|
|
||||||
// sample synchronization
|
// sample synchronization
|
||||||
d_sample_counter = 0;
|
d_sample_counter = 0;
|
||||||
//d_sample_counter_seconds = 0;
|
|
||||||
d_acq_sample_stamp = 0;
|
d_acq_sample_stamp = 0;
|
||||||
|
|
||||||
d_enable_tracking = false;
|
d_enable_tracking = false;
|
||||||
@ -197,7 +196,7 @@ Gps_L1_Ca_Kf_Tracking_cc::Gps_L1_Ca_Kf_Tracking_cc(
|
|||||||
double sigma2_phase_detector_cycles2;
|
double sigma2_phase_detector_cycles2;
|
||||||
sigma2_phase_detector_cycles2 = (1.0 / (2.0 * CN_lin * GPS_L1_CA_CODE_PERIOD)) * (1.0 + 1.0 / (2.0 * CN_lin * GPS_L1_CA_CODE_PERIOD));
|
sigma2_phase_detector_cycles2 = (1.0 / (2.0 * CN_lin * GPS_L1_CA_CODE_PERIOD)) * (1.0 + 1.0 / (2.0 * CN_lin * GPS_L1_CA_CODE_PERIOD));
|
||||||
|
|
||||||
//covariances (static)
|
// covariances (static)
|
||||||
double sigma2_carrier_phase = GPS_TWO_PI / 4;
|
double sigma2_carrier_phase = GPS_TWO_PI / 4;
|
||||||
double sigma2_doppler = 450;
|
double sigma2_doppler = 450;
|
||||||
double sigma2_doppler_rate = pow(4.0 * GPS_TWO_PI, 2) / 12.0;
|
double sigma2_doppler_rate = pow(4.0 * GPS_TWO_PI, 2) / 12.0;
|
||||||
|
@ -38,7 +38,7 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "bayesian_estimation.h"
|
#include "bayesian_estimation.h"
|
||||||
#include <armadillo>
|
|
||||||
|
|
||||||
Bayesian_estimator::Bayesian_estimator()
|
Bayesian_estimator::Bayesian_estimator()
|
||||||
{
|
{
|
||||||
@ -176,12 +176,12 @@ void Bayesian_estimator::update_sequential(const arma::vec& data, const arma::ve
|
|||||||
Psi_prior = Psi_posterior;
|
Psi_prior = Psi_posterior;
|
||||||
}
|
}
|
||||||
|
|
||||||
arma::mat Bayesian_estimator::get_mu_est()
|
arma::mat Bayesian_estimator::get_mu_est() const
|
||||||
{
|
{
|
||||||
return mu_est;
|
return mu_est;
|
||||||
}
|
}
|
||||||
|
|
||||||
arma::mat Bayesian_estimator::get_Psi_est()
|
arma::mat Bayesian_estimator::get_Psi_est() const
|
||||||
{
|
{
|
||||||
return Psi_est;
|
return Psi_est;
|
||||||
}
|
}
|
||||||
|
@ -69,8 +69,8 @@ public:
|
|||||||
void update_sequential(const arma::vec& data);
|
void update_sequential(const arma::vec& data);
|
||||||
void update_sequential(const arma::vec& data, const arma::vec& mu_prior_0, int kappa_prior_0, int nu_prior_0, const arma::mat& Psi_prior_0);
|
void update_sequential(const arma::vec& data, const arma::vec& mu_prior_0, int kappa_prior_0, int nu_prior_0, const arma::mat& Psi_prior_0);
|
||||||
|
|
||||||
arma::mat get_mu_est();
|
arma::mat get_mu_est() const;
|
||||||
arma::mat get_Psi_est();
|
arma::mat get_Psi_est() const;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
arma::vec mu_est;
|
arma::vec mu_est;
|
||||||
|
Loading…
Reference in New Issue
Block a user