gtsam
basis
Basis.cpp
Go to the documentation of this file.
1
/* ----------------------------------------------------------------------------
2
3
* GTSAM Copyright 2010, Georgia Tech Research Corporation,
4
* Atlanta, Georgia 30332-0415
5
* All Rights Reserved
6
* Authors: Frank Dellaert, et al. (see THANKS for the full author list)
7
8
* See LICENSE for the license information
9
10
* -------------------------------------------------------------------------- */
11
19
#include <
gtsam/basis/Basis.h
>
20
21
namespace
gtsam
{
22
23
Matrix
kroneckerProductIdentity
(
size_t
M
,
const
Weights
&
w
) {
24
Matrix
result
(
M
,
w
.cols() *
M
);
25
result
.setZero();
26
27
for
(
int
i
= 0;
i
<
w
.cols();
i
++) {
28
result
.block(0,
i
*
M
,
M
,
M
).diagonal().array() =
w
(
i
);
29
}
30
return
result
;
31
}
32
33
}
// namespace gtsam
w
RowVector3d w
Definition:
Matrix_resize_int.cpp:3
gtsam::Matrix
Eigen::MatrixXd Matrix
Definition:
base/Matrix.h:39
result
Values result
Definition:
OdometryOptimize.cpp:8
gtsam::kroneckerProductIdentity
Matrix kroneckerProductIdentity(size_t M, const Weights &w)
Function for computing the kronecker product of the 1*N Weight vector w with the MxM identity matrix ...
Definition:
Basis.cpp:23
Basis.h
Compute an interpolating basis.
gtsam
traits
Definition:
SFMdata.h:40
Eigen::Matrix< double, 1, -1 >
i
int i
Definition:
BiCGSTAB_step_by_step.cpp:9
M
Matrix< RealScalar, Dynamic, Dynamic > M
Definition:
bench_gemm.cpp:51
gtsam
Author(s):
autogenerated on Sat Nov 16 2024 04:01:53