analyticconditionalgaussian_additivenoise.cpp
Go to the documentation of this file.
00001 // $Id: analyticconditionalgaussian_additivenoise.cpp 29495 2008-08-13 12:57:49Z tdelaet $
00002 // Copyright (C) 2003 Klaas Gadeyne <first dot last at gmail dot com>
00003 //
00004 // This program is free software; you can redistribute it and/or modify
00005 // it under the terms of the GNU Lesser General Public License as published by
00006 // the Free Software Foundation; either version 2.1 of the License, or
00007 // (at your option) any later version.
00008 //
00009 // This program is distributed in the hope that it will be useful,
00010 // but WITHOUT ANY WARRANTY; without even the implied warranty of
00011 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00012 // GNU Lesser General Public License for more details.
00013 //
00014 // You should have received a copy of the GNU Lesser General Public License
00015 // along with this program; if not, write to the Free Software
00016 // Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
00017 //
00018 
00019 #include "analyticconditionalgaussian_additivenoise.h"
00020 #include <cmath>
00021 #include "../wrappers/rng/rng.h"
00022 
00023 namespace BFL
00024 {
00025 
00026   using namespace MatrixWrapper;
00027 
00028 #define CondGausAddNoise AnalyticConditionalGaussianAdditiveNoise
00029 
00031 
00034   CondGausAddNoise::CondGausAddNoise(const Gaussian& additiveNoise,
00035                                      int num_conditional_arguments)
00036     : AnalyticConditionalGaussian(additiveNoise.DimensionGet(),
00037                           num_conditional_arguments)
00038     , _additiveNoise_Mu   (additiveNoise.ExpectedValueGet())
00039     , _additiveNoise_Sigma(additiveNoise.CovarianceGet())
00040   {}
00041 
00042   CondGausAddNoise::CondGausAddNoise(int dim,
00043                                      int num_conditional_arguments)
00044     : AnalyticConditionalGaussian(dim, num_conditional_arguments)
00045   {
00046     _additiveNoise_Mu.resize(dim);
00047     _additiveNoise_Sigma.resize(dim);
00048   }
00049 
00051   CondGausAddNoise::~CondGausAddNoise()
00052   {}
00053 
00054   SymmetricMatrix
00055   CondGausAddNoise::CovarianceGet() const
00056   {
00057     return AdditiveNoiseSigmaGet();
00058   }
00059 
00060   const ColumnVector&
00061   CondGausAddNoise::AdditiveNoiseMuGet() const
00062   {
00063     return _additiveNoise_Mu;
00064   }
00065 
00066   const SymmetricMatrix&
00067   CondGausAddNoise::AdditiveNoiseSigmaGet() const
00068   {
00069     return _additiveNoise_Sigma;
00070   }
00071 
00072   void
00073   CondGausAddNoise::AdditiveNoiseMuSet(const ColumnVector& mu)
00074   {
00075     _additiveNoise_Mu = mu;
00076   }
00077 
00078   void
00079   CondGausAddNoise::AdditiveNoiseSigmaSet(const SymmetricMatrix& sigma)
00080   {
00081     _additiveNoise_Sigma = sigma;
00082   }
00083 
00084 
00085 
00086 
00087 } // End namespace


bfl
Author(s): Klaas Gadeyne, Wim Meeussen, Tinne Delaet and many others. See web page for a full contributor list. ROS package maintained by Wim Meeussen.
autogenerated on Thu Feb 11 2016 22:31:56