{"action":"created","comment":{"url":"https://api.github.com/repos/gonum/lapack/pulls/comments/29897575","id":29897575,"diff_hunk":"@@ -0,0 +1,66 @@\n+package native\n+\n+import (\n+\t\"math\"\n+\n+\t\"github.com/gonum/blas\"\n+\t\"github.com/gonum/blas/blas64\"\n+)\n+\n+// Dpotrf computes the cholesky decomposition of the symmetric positive definite\n+// matrix a. If ul == blas.Upper, then a is stored as an upper-triangular matrix,\n+// and a = U^T U is stored in place into a. If ul == blas.Lower, then a = L L^T\n+// is computed and stored in-place into a. This is the unblocked version of the\n+// algorithm. Dpotrf returns 0 if the decomposition is successful, otherwise","path":"native/dpotf2.go","position":null,"original_position":14,"commit_id":"037870b285013a932093aae45820345874657d4a","original_commit_id":"2f572b02d1d218df040c79b52ed7ad4ecc786794","user":{"login":"btracey","id":3680859,"avatar_url":"https://avatars.githubusercontent.com/u/3680859?v=3","gravatar_id":"","url":"https://api.github.com/users/btracey","html_url":"https://github.com/btracey","followers_url":"https://api.github.com/users/btracey/followers","following_url":"https://api.github.com/users/btracey/following{/other_user}","gists_url":"https://api.github.com/users/btracey/gists{/gist_id}","starred_url":"https://api.github.com/users/btracey/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/btracey/subscriptions","organizations_url":"https://api.github.com/users/btracey/orgs","repos_url":"https://api.github.com/users/btracey/repos","events_url":"https://api.github.com/users/btracey/events{/privacy}","received_events_url":"https://api.github.com/users/btracey/received_events","type":"User","site_admin":false},"body":"\n> On May 7, 2015, at 2:05 PM, Dan Kortschak <notifications@github.com> wrote:\n> \n> In native/dpotf2.go <https://github.com/gonum/lapack/pull/11#discussion_r29895939>:\n> \n> > @@ -0,0 +1,66 @@\n> > +package native\n> > +\n> > +import (\n> > +\t\"math\"\n> > +\n> > +\t\"github.com/gonum/blas\"\n> > +\t\"github.com/gonum/blas/blas64\"\n> > +)\n> > +\n> > +// Dpotrf computes the cholesky decomposition of the symmetric positive definite\n> > +// matrix a. If ul == blas.Upper, then a is stored as an upper-triangular matrix,\n> > +// and a = U^T U is stored in place into a. If ul == blas.Lower, then a = L L^T\n> > +// is computed and stored in-place into a. This is the unblocked version of the\n> > +// algorithm. Dpotrf returns 0 if the decomposition is successful, otherwise\n> Sorry to be difficult on this, but is the indormation we are discarding here likely to be useful to someone? Making it an error allows that to continue to be used if needed.\n\nPersonally, I don’t know for sure, but I don’t really see how. If A is positive definite, then all of the eigenvalues are > 0. A not being positive definite implies one of them is not. However, you can reorder the rows and such of a matrix without changing the eigenvalues (only the order). Thus, it seems to me that the info can’t give you the eigenvalue that’s negative, as there isn’t any real order to the eigenvaules, they just are. Possibly you could “augment” the diagonal of the matrix to make it positive definite, but again, it’s not clear to me why you’d change the first entry that failed. The value on the diagonal is already different from when it started. The integer is also weird in this case, because it’s one-indexed in normal lapack.\n\nI did some quick google searching and couldn’t find an example where the returned integer was used. For example, https://stat.duke.edu/~cr173/Sta523_Fa14/blas_lapack.html <https://stat.duke.edu/~cr173/Sta523_Fa14/blas_lapack.html>, doesn’t even say that that’s the return. ","created_at":"2015-05-07T21:26:32Z","updated_at":"2015-05-07T21:26:32Z","html_url":"https://github.com/gonum/lapack/pull/11#discussion_r29897575","pull_request_url":"https://api.github.com/repos/gonum/lapack/pulls/11","_links":{"self":{"href":"https://api.github.com/repos/gonum/lapack/pulls/comments/29897575"},"html":{"href":"https://github.com/gonum/lapack/pull/11#discussion_r29897575"},"pull_request":{"href":"https://api.github.com/repos/gonum/lapack/pulls/11"}}},"pull_request":{"url":"https://api.github.com/repos/gonum/lapack/pulls/11","id":34790341,"html_url":"https://github.com/gonum/lapack/pull/11","diff_url":"https://github.com/gonum/lapack/pull/11.diff","patch_url":"https://github.com/gonum/lapack/pull/11.patch","issue_url":"https://api.github.com/repos/gonum/lapack/issues/11","number":11,"state":"open","locked":false,"title":"Rearrange Lapack to be like BLAS. Implement cholesky decomposition","user":{"login":"btracey","id":3680859,"avatar_url":"https://avatars.githubusercontent.com/u/3680859?v=3","gravatar_id":"","url":"https://api.github.com/users/btracey","html_url":"https://github.com/btracey","followers_url":"https://api.github.com/users/btracey/followers","following_url":"https://api.github.com/users/btracey/following{/other_user}","gists_url":"https://api.github.com/users/btracey/gists{/gist_id}","starred_url":"https://api.github.com/users/btracey/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/btracey/subscriptions","organizations_url":"https://api.github.com/users/btracey/orgs","repos_url":"https://api.github.com/users/btracey/repos","events_url":"https://api.github.com/users/btracey/events{/privacy}","received_events_url":"https://api.github.com/users/btracey/received_events","type":"User","site_admin":false},"body":"","created_at":"2015-05-06T05:55:34Z","updated_at":"2015-05-07T21:26:32Z","closed_at":null,"merged_at":null,"merge_commit_sha":"acbba49a7cd8a4ec2f3633f18c54281e08113321","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/gonum/lapack/pulls/11/commits","review_comments_url":"https://api.github.com/repos/gonum/lapack/pulls/11/comments","review_comment_url":"https://api.github.com/repos/gonum/lapack/pulls/comments{/number}","comments_url":"https://api.github.com/repos/gonum/lapack/issues/11/comments","statuses_url":"https://api.github.com/repos/gonum/lapack/statuses/037870b285013a932093aae45820345874657d4a","head":{"label":"gonum:adddpotrf","ref":"adddpotrf","sha":"037870b285013a932093aae45820345874657d4a","user":{"login":"gonum","id":3771091,"avatar_url":"https://avatars.githubusercontent.com/u/3771091?v=3","gravatar_id":"","url":"https://api.github.com/users/gonum","html_url":"https://github.com/gonum","followers_url":"https://api.github.com/users/gonum/followers","following_url":"https://api.github.com/users/gonum/following{/other_user}","gists_url":"https://api.github.com/users/gonum/gists{/gist_id}","starred_url":"https://api.github.com/users/gonum/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gonum/subscriptions","organizations_url":"https://api.github.com/users/gonum/orgs","repos_url":"https://api.github.com/users/gonum/repos","events_url":"https://api.github.com/users/gonum/events{/privacy}","received_events_url":"https://api.github.com/users/gonum/received_events","type":"Organization","site_admin":false},"repo":{"id":20473913,"name":"lapack","full_name":"gonum/lapack","owner":{"login":"gonum","id":3771091,"avatar_url":"https://avatars.githubusercontent.com/u/3771091?v=3","gravatar_id":"","url":"https://api.github.com/users/gonum","html_url":"https://github.com/gonum","followers_url":"https://api.github.com/users/gonum/followers","following_url":"https://api.github.com/users/gonum/following{/other_user}","gists_url":"https://api.github.com/users/gonum/gists{/gist_id}","starred_url":"https://api.github.com/users/gonum/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gonum/subscriptions","organizations_url":"https://api.github.com/users/gonum/orgs","repos_url":"https://api.github.com/users/gonum/repos","events_url":"https://api.github.com/users/gonum/events{/privacy}","received_events_url":"https://api.github.com/users/gonum/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/gonum/lapack","description":"A lapack implementation for go","fork":false,"url":"https://api.github.com/repos/gonum/lapack","forks_url":"https://api.github.com/repos/gonum/lapack/forks","keys_url":"https://api.github.com/repos/gonum/lapack/keys{/key_id}","collaborators_url":"https://api.github.com/repos/gonum/lapack/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/gonum/lapack/teams","hooks_url":"https://api.github.com/repos/gonum/lapack/hooks","issue_events_url":"https://api.github.com/repos/gonum/lapack/issues/events{/number}","events_url":"https://api.github.com/repos/gonum/lapack/events","assignees_url":"https://api.github.com/repos/gonum/lapack/assignees{/user}","branches_url":"https://api.github.com/repos/gonum/lapack/branches{/branch}","tags_url":"https://api.github.com/repos/gonum/lapack/tags","blobs_url":"https://api.github.com/repos/gonum/lapack/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/gonum/lapack/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/gonum/lapack/git/refs{/sha}","trees_url":"https://api.github.com/repos/gonum/lapack/git/trees{/sha}","statuses_url":"https://api.github.com/repos/gonum/lapack/statuses/{sha}","languages_url":"https://api.github.com/repos/gonum/lapack/languages","stargazers_url":"https://api.github.com/repos/gonum/lapack/stargazers","contributors_url":"https://api.github.com/repos/gonum/lapack/contributors","subscribers_url":"https://api.github.com/repos/gonum/lapack/subscribers","subscription_url":"https://api.github.com/repos/gonum/lapack/subscription","commits_url":"https://api.github.com/repos/gonum/lapack/commits{/sha}","git_commits_url":"https://api.github.com/repos/gonum/lapack/git/commits{/sha}","comments_url":"https://api.github.com/repos/gonum/lapack/comments{/number}","issue_comment_url":"https://api.github.com/repos/gonum/lapack/issues/comments{/number}","contents_url":"https://api.github.com/repos/gonum/lapack/contents/{+path}","compare_url":"https://api.github.com/repos/gonum/lapack/compare/{base}...{head}","merges_url":"https://api.github.com/repos/gonum/lapack/merges","archive_url":"https://api.github.com/repos/gonum/lapack/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/gonum/lapack/downloads","issues_url":"https://api.github.com/repos/gonum/lapack/issues{/number}","pulls_url":"https://api.github.com/repos/gonum/lapack/pulls{/number}","milestones_url":"https://api.github.com/repos/gonum/lapack/milestones{/number}","notifications_url":"https://api.github.com/repos/gonum/lapack/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/gonum/lapack/labels{/name}","releases_url":"https://api.github.com/repos/gonum/lapack/releases{/id}","created_at":"2014-06-04T07:18:07Z","updated_at":"2015-03-30T13:27:33Z","pushed_at":"2015-05-07T20:10:36Z","git_url":"git://github.com/gonum/lapack.git","ssh_url":"git@github.com:gonum/lapack.git","clone_url":"https://github.com/gonum/lapack.git","svn_url":"https://github.com/gonum/lapack","homepage":null,"size":364,"stargazers_count":13,"watchers_count":13,"language":"C++","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"open_issues_count":2,"forks":1,"open_issues":2,"watchers":13,"default_branch":"master"}},"base":{"label":"gonum:master","ref":"master","sha":"ab032b6bfa0f56265e1e8b51c551ba8971f9b75c","user":{"login":"gonum","id":3771091,"avatar_url":"https://avatars.githubusercontent.com/u/3771091?v=3","gravatar_id":"","url":"https://api.github.com/users/gonum","html_url":"https://github.com/gonum","followers_url":"https://api.github.com/users/gonum/followers","following_url":"https://api.github.com/users/gonum/following{/other_user}","gists_url":"https://api.github.com/users/gonum/gists{/gist_id}","starred_url":"https://api.github.com/users/gonum/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gonum/subscriptions","organizations_url":"https://api.github.com/users/gonum/orgs","repos_url":"https://api.github.com/users/gonum/repos","events_url":"https://api.github.com/users/gonum/events{/privacy}","received_events_url":"https://api.github.com/users/gonum/received_events","type":"Organization","site_admin":false},"repo":{"id":20473913,"name":"lapack","full_name":"gonum/lapack","owner":{"login":"gonum","id":3771091,"avatar_url":"https://avatars.githubusercontent.com/u/3771091?v=3","gravatar_id":"","url":"https://api.github.com/users/gonum","html_url":"https://github.com/gonum","followers_url":"https://api.github.com/users/gonum/followers","following_url":"https://api.github.com/users/gonum/following{/other_user}","gists_url":"https://api.github.com/users/gonum/gists{/gist_id}","starred_url":"https://api.github.com/users/gonum/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gonum/subscriptions","organizations_url":"https://api.github.com/users/gonum/orgs","repos_url":"https://api.github.com/users/gonum/repos","events_url":"https://api.github.com/users/gonum/events{/privacy}","received_events_url":"https://api.github.com/users/gonum/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/gonum/lapack","description":"A lapack implementation for go","fork":false,"url":"https://api.github.com/repos/gonum/lapack","forks_url":"https://api.github.com/repos/gonum/lapack/forks","keys_url":"https://api.github.com/repos/gonum/lapack/keys{/key_id}","collaborators_url":"https://api.github.com/repos/gonum/lapack/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/gonum/lapack/teams","hooks_url":"https://api.github.com/repos/gonum/lapack/hooks","issue_events_url":"https://api.github.com/repos/gonum/lapack/issues/events{/number}","events_url":"https://api.github.com/repos/gonum/lapack/events","assignees_url":"https://api.github.com/repos/gonum/lapack/assignees{/user}","branches_url":"https://api.github.com/repos/gonum/lapack/branches{/branch}","tags_url":"https://api.github.com/repos/gonum/lapack/tags","blobs_url":"https://api.github.com/repos/gonum/lapack/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/gonum/lapack/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/gonum/lapack/git/refs{/sha}","trees_url":"https://api.github.com/repos/gonum/lapack/git/trees{/sha}","statuses_url":"https://api.github.com/repos/gonum/lapack/statuses/{sha}","languages_url":"https://api.github.com/repos/gonum/lapack/languages","stargazers_url":"https://api.github.com/repos/gonum/lapack/stargazers","contributors_url":"https://api.github.com/repos/gonum/lapack/contributors","subscribers_url":"https://api.github.com/repos/gonum/lapack/subscribers","subscription_url":"https://api.github.com/repos/gonum/lapack/subscription","commits_url":"https://api.github.com/repos/gonum/lapack/commits{/sha}","git_commits_url":"https://api.github.com/repos/gonum/lapack/git/commits{/sha}","comments_url":"https://api.github.com/repos/gonum/lapack/comments{/number}","issue_comment_url":"https://api.github.com/repos/gonum/lapack/issues/comments{/number}","contents_url":"https://api.github.com/repos/gonum/lapack/contents/{+path}","compare_url":"https://api.github.com/repos/gonum/lapack/compare/{base}...{head}","merges_url":"https://api.github.com/repos/gonum/lapack/merges","archive_url":"https://api.github.com/repos/gonum/lapack/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/gonum/lapack/downloads","issues_url":"https://api.github.com/repos/gonum/lapack/issues{/number}","pulls_url":"https://api.github.com/repos/gonum/lapack/pulls{/number}","milestones_url":"https://api.github.com/repos/gonum/lapack/milestones{/number}","notifications_url":"https://api.github.com/repos/gonum/lapack/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/gonum/lapack/labels{/name}","releases_url":"https://api.github.com/repos/gonum/lapack/releases{/id}","created_at":"2014-06-04T07:18:07Z","updated_at":"2015-03-30T13:27:33Z","pushed_at":"2015-05-07T20:10:36Z","git_url":"git://github.com/gonum/lapack.git","ssh_url":"git@github.com:gonum/lapack.git","clone_url":"https://github.com/gonum/lapack.git","svn_url":"https://github.com/gonum/lapack","homepage":null,"size":364,"stargazers_count":13,"watchers_count":13,"language":"C++","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1,"mirror_url":null,"open_issues_count":2,"forks":1,"open_issues":2,"watchers":13,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/gonum/lapack/pulls/11"},"html":{"href":"https://github.com/gonum/lapack/pull/11"},"issue":{"href":"https://api.github.com/repos/gonum/lapack/issues/11"},"comments":{"href":"https://api.github.com/repos/gonum/lapack/issues/11/comments"},"review_comments":{"href":"https://api.github.com/repos/gonum/lapack/pulls/11/comments"},"review_comment":{"href":"https://api.github.com/repos/gonum/lapack/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/gonum/lapack/pulls/11/commits"},"statuses":{"href":"https://api.github.com/repos/gonum/lapack/statuses/037870b285013a932093aae45820345874657d4a"}}}}