[Rcpp-commits] r3519 - in pkg/RcppSMC: inst/include src
noreply at r-forge.r-project.org
noreply at r-forge.r-project.org
Sun Mar 18 03:17:29 CET 2012
Author: edd
Date: 2012-03-18 03:17:27 +0100 (Sun, 18 Mar 2012)
New Revision: 3519
Modified:
pkg/RcppSMC/inst/include/blockpfgaussianopt.h
pkg/RcppSMC/inst/include/pffuncs.h
pkg/RcppSMC/inst/include/pfnonlinbs.h
pkg/RcppSMC/inst/include/rngR.h
pkg/RcppSMC/src/blockpfgaussianopt.cpp
pkg/RcppSMC/src/history.cpp
pkg/RcppSMC/src/pf.cpp
pkg/RcppSMC/src/pfnonlinbs.cpp
pkg/RcppSMC/src/smc-exception.cpp
Log:
more copyright header standardization
Modified: pkg/RcppSMC/inst/include/blockpfgaussianopt.h
===================================================================
--- pkg/RcppSMC/inst/include/blockpfgaussianopt.h 2012-03-17 16:31:04 UTC (rev 3518)
+++ pkg/RcppSMC/inst/include/blockpfgaussianopt.h 2012-03-18 02:17:27 UTC (rev 3519)
@@ -1,3 +1,24 @@
+// -*- mode: C++; c-indent-level: 4; c-basic-offset: 4; indent-tabs-mode: nil; -*-
+//
+// blockpfgaussianopt.h: Rcpp integration of SMC library -- Block PF Gaussian
+//
+// Copyright (C) 2012 Dirk Eddelbuettel and Adam Johansen
+//
+// This file is part of RcppSMC.
+//
+// RcppSMC is free software: you can redistribute it and/or modify it
+// under the terms of the GNU General Public License as published by
+// the Free Software Foundation, either version 2 of the License, or
+// (at your option) any later version.
+//
+// RcppSMC 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 General Public License for more details.
+//
+// You should have received a copy of the GNU General Public License
+// along with RcppSMC. If not, see <http://www.gnu.org/licenses/>.
+
#include "smctc.h"
#include <vector>
@@ -8,7 +29,7 @@
void fMoveBSPFG(long lTime, smc::particle<vector<double> > & pFrom, smc::rng *pRng);
namespace BSPFG {
-extern Rcpp::NumericVector y;
+ extern Rcpp::NumericVector y;
}
using BSPFG::y;
Modified: pkg/RcppSMC/inst/include/pffuncs.h
===================================================================
--- pkg/RcppSMC/inst/include/pffuncs.h 2012-03-17 16:31:04 UTC (rev 3518)
+++ pkg/RcppSMC/inst/include/pffuncs.h 2012-03-18 02:17:27 UTC (rev 3519)
@@ -1,30 +1,48 @@
+// -*- mode: C++; c-indent-level: 4; c-basic-offset: 4; indent-tabs-mode: nil; -*-
+//
+// pffuncs.h: Rcpp wrapper for SMC library -- first example of Johansen (2009)
+//
+// Copyright (C) 2008 Adam Johansen
+// Copyright (C) 2012 Dirk Eddelbuettel and Adam Johansen
+//
+// This file is part of RcppSMC.
+//
+// RcppSMC is free software: you can redistribute it and/or modify it
+// under the terms of the GNU General Public License as published by
+// the Free Software Foundation, either version 2 of the License, or
+// (at your option) any later version.
+//
+// RcppSMC 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 General Public License for more details.
+//
+// You should have received a copy of the GNU General Public License
+// along with RcppSMC. If not, see <http://www.gnu.org/licenses/>.
+
#include "smctc.h"
-class cv_state
+class cv_state
{
public:
- double x_pos, y_pos;
- double x_vel, y_vel;
+ double x_pos, y_pos;
+ double x_vel, y_vel;
};
class cv_obs
{
public:
- double x_pos, y_pos;
+ double x_pos, y_pos;
};
double logLikelihood(long lTime, const cv_state & X);
smc::particle<cv_state> fInitialise(smc::rng *pRng);
-long fSelect(long lTime, const smc::particle<cv_state> & p,
- smc::rng *pRng);
-void fMove(long lTime, smc::particle<cv_state> & pFrom,
- smc::rng *pRng);
+long fSelect(long lTime, const smc::particle<cv_state> & p, smc::rng *pRng);
+void fMove(long lTime, smc::particle<cv_state> & pFrom, smc::rng *pRng);
extern double nu_x;
extern double nu_y;
extern double Delta;
-//extern cv_obs * y;
-//extern Rcpp::NumericMatrix y;
extern std::vector<cv_obs> y;
Modified: pkg/RcppSMC/inst/include/pfnonlinbs.h
===================================================================
--- pkg/RcppSMC/inst/include/pfnonlinbs.h 2012-03-17 16:31:04 UTC (rev 3518)
+++ pkg/RcppSMC/inst/include/pfnonlinbs.h 2012-03-18 02:17:27 UTC (rev 3519)
@@ -1,16 +1,16 @@
+// -*- mode: C++; c-indent-level: 4; c-basic-offset: 4; indent-tabs-mode: nil; -*-
//
-// pf1dnonlinbs.h
+// pfnonlinbs.h: Rcpp integration of SMC library -- PF Nonlinear Bootstrp
//
-// The declarations and externals for an implementation of the bootstrap
-// particle filter of "Novel approaches to nonlinear non-Gaussian
-// Bayesian state estimation", Gordon Salmond and Smith,
-// IEE PROCEEDINGS-F 140(2):107-113, 1993
+// The declarations and externals for an implementation of the bootstrap
+// particle filter of "Novel approaches to nonlinear non-Gaussian
+// Bayesian state estimation", Gordon Salmond and Smith,
+// IEE PROCEEDINGS-F 140(2):107-113, 1993
//
-// Copyright Adam Johansen, 2012
+// Copyright (C) 2012 Dirk Eddelbuettel and Adam Johansen
//
-// This file is part of RcppSMC.
+// This file is part of RcppSMC.
//
-//
// RcppSMC is free software: you can redistribute it and/or modify it
// under the terms of the GNU General Public License as published by
// the Free Software Foundation, either version 2 of the License, or
@@ -22,27 +22,17 @@
// GNU General Public License for more details.
//
// You should have received a copy of the GNU General Public License
-// along with RInside. If not, see <http://www.gnu.org/licenses/>.
-// from examples/pf/pfexample.cc; pffuncs.cc and pffuncs.hh also used
+// along with RcppSMC. If not, see <http://www.gnu.org/licenses/>.
-// RcppSMC builds on top of, and wraps, SMCTC which is
-//
-// Copyright Adam Johansen, 2008-2012.
-//
-// and released under GPL-3, see the copyright headers in inst/include/
-
-
#include "smctc.h"
namespace nonlinbs {
- double logLikelihood(long lTime, const double & X);
+ double logLikelihood(long lTime, const double & X);
- smc::particle<double> fInitialise(smc::rng *pRng);
- long fSelect(long lTime, const smc::particle<double> & p,
- smc::rng *pRng);
- void fMove(long lTime, smc::particle<double> & pFrom,
- smc::rng *pRng);
+ smc::particle<double> fInitialise(smc::rng *pRng);
+ long fSelect(long lTime, const smc::particle<double> & p, smc::rng *pRng);
+ void fMove(long lTime, smc::particle<double> & pFrom, smc::rng *pRng);
- double integrand_mean_x(const double&, void*);
- double integrand_var_x(const double&, void*);
+ double integrand_mean_x(const double&, void*);
+ double integrand_var_x(const double&, void*);
}
Modified: pkg/RcppSMC/inst/include/rngR.h
===================================================================
--- pkg/RcppSMC/inst/include/rngR.h 2012-03-17 16:31:04 UTC (rev 3518)
+++ pkg/RcppSMC/inst/include/rngR.h 2012-03-18 02:17:27 UTC (rev 3519)
@@ -18,7 +18,6 @@
//
// You should have received a copy of the GNU General Public License
// along with RInside. If not, see <http://www.gnu.org/licenses/>.
-// from examples/pf/pfexample.cc; pffuncs.cc and pffuncs.hh also used
// RcppSMC builds on top of, and wraps, SMCTC which is
//
Modified: pkg/RcppSMC/src/blockpfgaussianopt.cpp
===================================================================
--- pkg/RcppSMC/src/blockpfgaussianopt.cpp 2012-03-17 16:31:04 UTC (rev 3518)
+++ pkg/RcppSMC/src/blockpfgaussianopt.cpp 2012-03-18 02:17:27 UTC (rev 3519)
@@ -19,7 +19,6 @@
//
// You should have received a copy of the GNU General Public License
// along with RcppSMC. If not, see <http://www.gnu.org/licenses/>.
-// from examples/pf/pfexample.cc; pffuncs.cc and pffuncs.hh also used
#include "smctc.h"
#include "blockpfgaussianopt.h"
Modified: pkg/RcppSMC/src/history.cpp
===================================================================
--- pkg/RcppSMC/src/history.cpp 2012-03-17 16:31:04 UTC (rev 3518)
+++ pkg/RcppSMC/src/history.cpp 2012-03-18 02:17:27 UTC (rev 3519)
@@ -19,7 +19,6 @@
//
// You should have received a copy of the GNU General Public License
// along with RcppSMC. If not, see <http://www.gnu.org/licenses/>.
-// from examples/pf/pfexample.cc; pffuncs.cc and pffuncs.hh also used
#include "smctc.h"
Modified: pkg/RcppSMC/src/pf.cpp
===================================================================
--- pkg/RcppSMC/src/pf.cpp 2012-03-17 16:31:04 UTC (rev 3518)
+++ pkg/RcppSMC/src/pf.cpp 2012-03-18 02:17:27 UTC (rev 3519)
@@ -19,7 +19,6 @@
//
// You should have received a copy of the GNU General Public License
// along with RcppSMC. If not, see <http://www.gnu.org/licenses/>.
-// from examples/pf/pfexample.cc; pffuncs.cc and pffuncs.hh also used
#include <Rcpp.h>
Modified: pkg/RcppSMC/src/pfnonlinbs.cpp
===================================================================
--- pkg/RcppSMC/src/pfnonlinbs.cpp 2012-03-17 16:31:04 UTC (rev 3518)
+++ pkg/RcppSMC/src/pfnonlinbs.cpp 2012-03-18 02:17:27 UTC (rev 3519)
@@ -24,7 +24,6 @@
//
// You should have received a copy of the GNU General Public License
// along with RcppSMC. If not, see <http://www.gnu.org/licenses/>.
-// from examples/pf/pfexample.cc; pffuncs.cc and pffuncs.hh also used
#include "smctc.h"
#include "pfnonlinbs.h"
Modified: pkg/RcppSMC/src/smc-exception.cpp
===================================================================
--- pkg/RcppSMC/src/smc-exception.cpp 2012-03-17 16:31:04 UTC (rev 3518)
+++ pkg/RcppSMC/src/smc-exception.cpp 2012-03-18 02:17:27 UTC (rev 3519)
@@ -19,7 +19,6 @@
//
// You should have received a copy of the GNU General Public License
// along with RcppSMC. If not, see <http://www.gnu.org/licenses/>.
-// from examples/pf/pfexample.cc; pffuncs.cc and pffuncs.hh also used
#include "smc-exception.h"
More information about the Rcpp-commits
mailing list