Skip to content
This repository was archived by the owner on Nov 24, 2018. It is now read-only.

Commit 997f41b

Browse files
committed
native,cgo: update docs for Dgehrd
1 parent 4807f95 commit 997f41b

File tree

2 files changed

+18
-13
lines changed

2 files changed

+18
-13
lines changed

cgo/lapack.go

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -565,15 +565,17 @@ func (impl Implementation) Dgeqrf(m, n int, a []float64, lda int, tau, work []fl
565565
// -1 if n == 0, otherwise Dgehrd will panic.
566566
//
567567
// On return, tau will contain the scalar factors of the elementary reflectors.
568-
// Elements tau[:ilo] and tau[ihi:] of tau will be set to zero. It must have
569-
// length equal to n-1 if n > 1, otherwise Dgehrd will panic.
568+
// Elements tau[:ilo] and tau[ihi:] will be set to zero. tau must have length
569+
// equal to n-1 if n > 0, otherwise Dgehrd will panic.
570570
//
571-
// work must have length at least lwork, otherwise Dgehrd will panic, and lwork
572-
// must be at least max(1,n).
571+
// work must have length at least lwork and lwork must be at least max(1,n),
572+
// otherwise Dgehrd will panic. On return, work[0] contains the optimal value of
573+
// lwork.
573574
//
574-
// The C interface does not support providing temporary storage. To provide
575-
// compatibility with native, lwork == -1 will not run Dgehrd but will instead
576-
// write the minimum work necessary to work[0].
575+
// If lwork == -1, instead of performing Dgehrd, only the optimal value of lwork
576+
// will be stored in work[0].
577+
//
578+
// Dgehrd is an internal routine. It is exported for testing purposes.
577579
func (impl Implementation) Dgehrd(n, ilo, ihi int, a []float64, lda int, tau, work []float64, lwork int) {
578580
checkMatrix(n, n, a, lda)
579581
switch {

native/dgehrd.go

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -54,14 +54,17 @@ import (
5454
// -1 if n == 0, otherwise Dgehrd will panic.
5555
//
5656
// On return, tau will contain the scalar factors of the elementary reflectors.
57-
// Elements tau[:ilo] and tau[ihi:] of tau will be set to zero. It must have
58-
// length equal to n-1 if n > 1, otherwise Dgehrd will panic.
57+
// Elements tau[:ilo] and tau[ihi:] will be set to zero. tau must have length
58+
// equal to n-1 if n > 0, otherwise Dgehrd will panic.
5959
//
60-
// work must have length at least lwork, otherwise Dgehrd will panic, and lwork
61-
// must be at least max(1,n). On return, work[0] contains the optimal value of lwork.
60+
// work must have length at least lwork and lwork must be at least max(1,n),
61+
// otherwise Dgehrd will panic. On return, work[0] contains the optimal value of
62+
// lwork.
6263
//
63-
// If lwork is -1, instead of performing Dgehrd, the function only calculates
64-
// the optimal length of work.
64+
// If lwork == -1, instead of performing Dgehrd, only the optimal value of lwork
65+
// will be stored in work[0].
66+
//
67+
// Dgehrd is an internal routine. It is exported for testing purposes.
6568
func (impl Implementation) Dgehrd(n, ilo, ihi int, a []float64, lda int, tau, work []float64, lwork int) {
6669
checkMatrix(n, n, a, lda)
6770
switch {

0 commit comments

Comments
 (0)