{"action":"created","issue":{"url":"https://api.github.com/repos/tbeu/Modelica/issues/1667","repository_url":"https://api.github.com/repos/tbeu/Modelica","labels_url":"https://api.github.com/repos/tbeu/Modelica/issues/1667/labels{/name}","comments_url":"https://api.github.com/repos/tbeu/Modelica/issues/1667/comments","events_url":"https://api.github.com/repos/tbeu/Modelica/issues/1667/events","html_url":"https://github.com/tbeu/Modelica/issues/1667","id":197613959,"number":1667,"title":"Bug in least square calculation in LAPACK (dgelsy)","user":{"login":"modelica-trac-importer","id":22202507,"avatar_url":"https://avatars.githubusercontent.com/u/22202507?v=3","gravatar_id":"","url":"https://api.github.com/users/modelica-trac-importer","html_url":"https://github.com/modelica-trac-importer","followers_url":"https://api.github.com/users/modelica-trac-importer/followers","following_url":"https://api.github.com/users/modelica-trac-importer/following{/other_user}","gists_url":"https://api.github.com/users/modelica-trac-importer/gists{/gist_id}","starred_url":"https://api.github.com/users/modelica-trac-importer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/modelica-trac-importer/subscriptions","organizations_url":"https://api.github.com/users/modelica-trac-importer/orgs","repos_url":"https://api.github.com/users/modelica-trac-importer/repos","events_url":"https://api.github.com/users/modelica-trac-importer/events{/privacy}","received_events_url":"https://api.github.com/users/modelica-trac-importer/received_events","type":"User","site_admin":false},"labels":[{"id":506762997,"url":"https://api.github.com/repos/tbeu/Modelica/labels/bug","name":"bug","color":"ee0701","default":true},{"id":506769526,"url":"https://api.github.com/repos/tbeu/Modelica/labels/L:Math","name":"L:Math","color":"0000aa","default":false}],"state":"closed","locked":false,"assignee":{"login":"beutlich","id":14896695,"avatar_url":"https://avatars.githubusercontent.com/u/14896695?v=3","gravatar_id":"","url":"https://api.github.com/users/beutlich","html_url":"https://github.com/beutlich","followers_url":"https://api.github.com/users/beutlich/followers","following_url":"https://api.github.com/users/beutlich/following{/other_user}","gists_url":"https://api.github.com/users/beutlich/gists{/gist_id}","starred_url":"https://api.github.com/users/beutlich/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/beutlich/subscriptions","organizations_url":"https://api.github.com/users/beutlich/orgs","repos_url":"https://api.github.com/users/beutlich/repos","events_url":"https://api.github.com/users/beutlich/events{/privacy}","received_events_url":"https://api.github.com/users/beutlich/received_events","type":"User","site_admin":false},"assignees":[{"login":"beutlich","id":14896695,"avatar_url":"https://avatars.githubusercontent.com/u/14896695?v=3","gravatar_id":"","url":"https://api.github.com/users/beutlich","html_url":"https://github.com/beutlich","followers_url":"https://api.github.com/users/beutlich/followers","following_url":"https://api.github.com/users/beutlich/following{/other_user}","gists_url":"https://api.github.com/users/beutlich/gists{/gist_id}","starred_url":"https://api.github.com/users/beutlich/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/beutlich/subscriptions","organizations_url":"https://api.github.com/users/beutlich/orgs","repos_url":"https://api.github.com/users/beutlich/repos","events_url":"https://api.github.com/users/beutlich/events{/privacy}","received_events_url":"https://api.github.com/users/beutlich/received_events","type":"User","site_admin":false}],"milestone":{"url":"https://api.github.com/repos/tbeu/Modelica/milestones/59","html_url":"https://github.com/tbeu/Modelica/milestone/59","labels_url":"https://api.github.com/repos/tbeu/Modelica/milestones/59/labels","id":2214862,"number":59,"title":"MSL3.2.2","description":"","creator":{"login":"modelica-trac-importer","id":22202507,"avatar_url":"https://avatars.githubusercontent.com/u/22202507?v=3","gravatar_id":"","url":"https://api.github.com/users/modelica-trac-importer","html_url":"https://github.com/modelica-trac-importer","followers_url":"https://api.github.com/users/modelica-trac-importer/followers","following_url":"https://api.github.com/users/modelica-trac-importer/following{/other_user}","gists_url":"https://api.github.com/users/modelica-trac-importer/gists{/gist_id}","starred_url":"https://api.github.com/users/modelica-trac-importer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/modelica-trac-importer/subscriptions","organizations_url":"https://api.github.com/users/modelica-trac-importer/orgs","repos_url":"https://api.github.com/users/modelica-trac-importer/repos","events_url":"https://api.github.com/users/modelica-trac-importer/events{/privacy}","received_events_url":"https://api.github.com/users/modelica-trac-importer/received_events","type":"User","site_admin":false},"open_issues":0,"closed_issues":68,"state":"closed","created_at":"2016-12-25T13:02:16Z","updated_at":"2016-12-26T19:25:51Z","due_on":"2016-03-11T08:00:00Z","closed_at":"2016-12-25T13:02:16Z"},"comments":5,"created_at":"2016-12-26T19:24:11Z","updated_at":"2016-12-26T19:26:01Z","closed_at":"2016-12-26T19:25:51Z","body":"**Modified by dietmarw on 27 Feb 2015 11:53 UTC**\nIn the two functions _LAPACK.dgelsy_ and _LAPACK.dgelsy_vec_ the integer **lwork** is used to pass the size of the workspace supplied to the FORTRAN subroutine _dgelsy_.\n\nIn the documentation of the FORTRAN routines **lwork** should fulfill the following inequality where MN is min(M,N):\n```\nLWORK >= MAX( MN+3*N+1, 2*MN+NRHS )\n```\n\nThe value of **lwork** is calculated in the modelica code, and also the size if the **work** array, by the following expression:\n```\nmax(min(nrow, ncol) + 3*ncol, 2*min(nrow, ncol) + nrhs)\n```\n(In the function _LAPACK.dgelsy_vec_, **nhrs** is set to 1)\n\nI think there is a '+1' missing in this calculation such as:\n```\nmax(min(nrow, ncol) + 3*ncol + 1, 2*min(nrow, ncol) + nrhs)\n```\n\nAs mentioned before, this problem is also present for the size of the **work** array in both functions.\n\n----\n\n**Reported by johan_ylikiiskila on 26 Feb 2015 09:11 UTC**\nIn the two functions _LAPACK.dgelsy_ and _LAPACK.dgelsy_vec_ the integer **lwork** is used to pass the size of the workspace supplied to the FORTRAN subroutine _dgelsy_.\n\nIn the documentation of the FORTRAN routines **lwork** should fulfill the following inequality where MN is min(M,N):\n```\nLWORK >= MAX( MN+3*N+1, 2*MN+NRHS )\n```\n\nThe value of **lwork** is calculated in the modelica code, and also the size if the **work** array, by the following expression:\n```\nmax(min(nrow, ncol) + 3*ncol, 2*min(nrow, ncol) + nrhs)\n```\n(In the function _LAPACK.dgelsy_vec_, **nhrs** is set to 1)\n\nI think there is a '+1' missing in this calculation such as:\n```\nmax(min(nrow, ncol) + 3*ncol + 1, 2*min(nrow, ncol) + nrhs)\n```\n\nAs mentioned before, this problem is also present for the size of the _'work_ array in both functions.\n\n----\n\nMigrated-From: https://trac.modelica.org/Modelica/ticket/1667"},"comment":{"url":"https://api.github.com/repos/tbeu/Modelica/issues/comments/269236446","html_url":"https://github.com/tbeu/Modelica/issues/1667#issuecomment-269236446","issue_url":"https://api.github.com/repos/tbeu/Modelica/issues/1667","id":269236446,"user":{"login":"modelica-trac-importer","id":22202507,"avatar_url":"https://avatars.githubusercontent.com/u/22202507?v=3","gravatar_id":"","url":"https://api.github.com/users/modelica-trac-importer","html_url":"https://github.com/modelica-trac-importer","followers_url":"https://api.github.com/users/modelica-trac-importer/followers","following_url":"https://api.github.com/users/modelica-trac-importer/following{/other_user}","gists_url":"https://api.github.com/users/modelica-trac-importer/gists{/gist_id}","starred_url":"https://api.github.com/users/modelica-trac-importer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/modelica-trac-importer/subscriptions","organizations_url":"https://api.github.com/users/modelica-trac-importer/orgs","repos_url":"https://api.github.com/users/modelica-trac-importer/repos","events_url":"https://api.github.com/users/modelica-trac-importer/events{/privacy}","received_events_url":"https://api.github.com/users/modelica-trac-importer/received_events","type":"User","site_admin":false},"created_at":"2016-12-26T19:26:01Z","updated_at":"2016-12-26T19:26:01Z","body":"**Modified by beutlich on 23 Oct 2015 09:53 UTC**"}}
{"actor":{"display_login":"modelica-trac-importer"}}