Commit 535f0cb 1 parent 238420e commit 535f0cb Copy full SHA for 535f0cb
File tree 2 files changed +4
-2
lines changed
2 files changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -16,7 +16,8 @@ namespace math {
16
16
* @param v Vector.
17
17
* @return L1 norm of v.
18
18
*/
19
- template <typename Container, require_st_arithmetic<Container>* = nullptr >
19
+ template <typename Container, require_st_arithmetic<Container>* = nullptr ,
20
+ require_container_t <Container>* = nullptr >
20
21
inline auto norm1 (const Container& x) {
21
22
return apply_vector_unary<ref_type_t <Container>>::reduce (
22
23
to_ref (x), [](const auto & v) { return v.template lpNorm <1 >(); });
Original file line number Diff line number Diff line change @@ -16,7 +16,8 @@ namespace math {
16
16
* @param v Vector.
17
17
* @return L2 norm of v.
18
18
*/
19
- template <typename Container, require_st_arithmetic<Container>* = nullptr >
19
+ template <typename Container, require_st_arithmetic<Container>* = nullptr ,
20
+ require_container_t <Container>* = nullptr >
20
21
inline auto norm2 (const Container& x) {
21
22
return apply_vector_unary<ref_type_t <Container>>::reduce (
22
23
to_ref (x), [](const auto & v) { return v.template lpNorm <2 >(); });
You can’t perform that action at this time.
0 commit comments