@@ -93,6 +93,7 @@ pub mod eig;
9393pub mod eigh;
9494pub mod eigh_generalized;
9595pub mod least_squares;
96+ pub mod opnorm;
9697pub mod qr;
9798pub mod rcond;
9899pub mod solve;
@@ -101,7 +102,6 @@ pub mod svd;
101102pub mod svddc;
102103
103104mod alloc;
104- mod opnorm;
105105mod triangular;
106106mod tridiagonal;
107107
@@ -121,7 +121,7 @@ pub type Pivot = Vec<i32>;
121121
122122#[ cfg_attr( doc, katexit:: katexit) ]
123123/// Trait for primitive types which implements LAPACK subroutines
124- pub trait Lapack : OperatorNorm_ + Triangular_ + Tridiagonal_ {
124+ pub trait Lapack : Triangular_ + Tridiagonal_ {
125125 /// Compute right eigenvalue and eigenvectors for a general matrix
126126 fn eig (
127127 calc_v : bool ,
@@ -261,6 +261,9 @@ pub trait Lapack: OperatorNorm_ + Triangular_ + Tridiagonal_ {
261261 ///
262262 /// `anorm` should be the 1-norm of the matrix `a`.
263263 fn rcond ( l : MatrixLayout , a : & [ Self ] , anorm : Self :: Real ) -> Result < Self :: Real > ;
264+
265+ /// Compute operator norm of a matrix
266+ fn opnorm ( t : NormType , l : MatrixLayout , a : & [ Self ] ) -> Self :: Real ;
264267}
265268
266269macro_rules! impl_lapack {
@@ -428,6 +431,12 @@ macro_rules! impl_lapack {
428431 let mut work = RcondWork :: <$s>:: new( l) ;
429432 work. calc( a, anorm)
430433 }
434+
435+ fn opnorm( t: NormType , l: MatrixLayout , a: & [ Self ] ) -> Self :: Real {
436+ use opnorm:: * ;
437+ let mut work = OperatorNormWork :: <$s>:: new( t, l) ;
438+ work. calc( a)
439+ }
431440 }
432441 } ;
433442}
0 commit comments