Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Pierre Fernbach
tsid
Commits
9c9b06bc
Commit
9c9b06bc
authored
Aug 29, 2017
by
andreadelprete
Browse files
[math-utils] Add function to check if matrix/vector contains NaN
parent
bfc74536
Changes
1
Hide whitespace changes
Inline
Side-by-side
include/tsid/math/utils.hpp
View file @
9c9b06bc
...
...
@@ -146,6 +146,12 @@ namespace tsid
return
(
(
x
-
x
).
array
()
==
(
x
-
x
).
array
()).
all
();
}
template
<
typename
Derived
>
inline
bool
is_nan
(
const
Eigen
::
MatrixBase
<
Derived
>&
x
)
{
return
((
x
.
array
()
==
x
.
array
())).
all
();
}
/**
* Write the specified matrix to a binary file with the specified name.
*/
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment