analog-garage / dimple

Dimple: Java and Matlab libraries for probabilistic inference
Apache License 2.0
80 stars 17 forks source link

Problems with propagating Gaussian covariance matrices #2

Open iron76 opened 10 years ago

iron76 commented 10 years ago

Dear dimple developers, I am experiencing a problem when using the Gaussian solver with Multivariate variables. In particular the following code:

fg = FactorGraph(); fg.Solver = 'Gaussian'; N = 3; x1 = RealJoint(N); x2 = RealJoint(N); q12 = RealJoint(N); x1_meas = 1; x1.FixedValue = ones(N,1)._x1_meas; q12_meas = 3; q12.FixedValue = ones(N,1)._q12_meas; fg.addFactor(@add, q12, x1, x2);
fg.solve();

does not return a zero covariance matrix for the variable x2.Belief which is instead expected since q12 = x1 + x2 with q12 and x1 given. I get instead a covariance matrix eye(3)*1e-7 which is then propagated causing huge numerical errors. Anyone know how this can be solved? Francesco

analog-cbarber commented 10 years ago

Internally this is https://bugzilla.cdcdesign.analog.com/show_bug.cgi?id=53