smart indent, and change push_back to add

release/4.3a0
Frank Dellaert 2013-05-21 21:22:55 +00:00
parent 8e26da7396
commit 75803f0229
1 changed files with 85 additions and 84 deletions

View File

@ -19,6 +19,7 @@
% - The robot moves forward at 2m/s % - The robot moves forward at 2m/s
% - We have measurements between each pose from multiple odometry sensors % - We have measurements between each pose from multiple odometry sensors
clear all;
clear all; clear all;
import gtsam.*; import gtsam.*;
@ -92,7 +93,7 @@ for time = deltaT : deltaT : 10.0
loopFactor = BetweenFactorPose2(loopKey1, loopKey2, loopMeasurement, loopNoise); loopFactor = BetweenFactorPose2(loopKey1, loopKey2, loopMeasurement, loopNoise);
% The state at 5.0s should have been transferred to the concurrent smoother at this point. Add the loop closure. % The state at 5.0s should have been transferred to the concurrent smoother at this point. Add the loop closure.
smootherFactors = NonlinearFactorGraph; smootherFactors = NonlinearFactorGraph;
smootherFactors.push_back(loopFactor); smootherFactors.add(loopFactor);
concurrentSmoother.update(smootherFactors, Values()); concurrentSmoother.update(smootherFactors, Values());
end end
@ -124,7 +125,7 @@ for time = deltaT : deltaT : 10.0
axis equal axis equal
axis tight axis tight
view(2) view(2)
pause pause(0.01)
end end