{"action":"created","issue":{"url":"https://api.github.com/repos/tbeu/Modelica/issues/247","repository_url":"https://api.github.com/repos/tbeu/Modelica","labels_url":"https://api.github.com/repos/tbeu/Modelica/issues/247/labels{/name}","comments_url":"https://api.github.com/repos/tbeu/Modelica/issues/247/comments","events_url":"https://api.github.com/repos/tbeu/Modelica/issues/247/events","html_url":"https://github.com/tbeu/Modelica/issues/247","id":196733415,"number":247,"title":"Inconsistent use of the variable ''vs'' in component DynamicPipe when nParallel > 1","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":504169707,"url":"https://api.github.com/repos/tbeu/Modelica/labels/bug","name":"bug","color":"ee0701","default":true},{"id":504177040,"url":"https://api.github.com/repos/tbeu/Modelica/labels/Fluid","name":"Fluid","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/1","html_url":"https://github.com/tbeu/Modelica/milestone/1","labels_url":"https://api.github.com/repos/tbeu/Modelica/milestones/1/labels","id":2207387,"number":1,"title":"NeedsInput","description":"These are tickets which need more external input in order to decide on further actions/progress.","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":1,"state":"open","created_at":"2016-12-20T13:05:50Z","updated_at":"2016-12-20T17:35:45Z","due_on":null,"closed_at":null},"comments":4,"created_at":"2016-12-20T17:34:14Z","updated_at":"2016-12-20T17:35:55Z","closed_at":"2016-12-20T17:35:45Z","body":"**Reported by anton&#46;sodja&#x40;fe&#x2e;uni-lj&#x2e;si on 27 Nov 2009 13:34 UTC**\nThe variable _vs_ is described as 'mean velocities in flow segments' in the component _Fluid.Pipes.BaseClasses.PartialTwoPortFlow_ and calculated as follows:\n```\nSI.Velocity[n] vs = {0.5*(m_flows[i] + m_flows[i+1])/mediums[i].d/crossAreas[i] for i in 1:n}\n```\nThe parmeter _nParallel_ is not taken into account. That would be right if crossAreas are sum of cross areas of all pipes in parallel.\nHowever, the _vs_ variable if further propagated to _FlowModel_ and _HeatTransfer_, nested submodels of _DynamicPipe_, where it is used to calculate Reynolds number as follows:\n```\n  Res = CharacteristicNumbers.ReynoldsNumber(vs/nParallel, ds, mus, diameters);\n```\n(note the vs/nParallel argument), but (for example):\n```\n if use_Ib_flows then\n    Ib_flows = {rhos[i]*vs[i]*vs[i]*crossAreas[i] - rhos[i+1]*vs[i+1]*vs[i+1]*crossAreas[i+1] for i in 1:n-1};\n```\nParameter 'crossArea' is ostensibly total cross area at the boundary, although from the Properties dialog of the 'DynamicPipe' component it is not exactly clear what it is and also how should parameter _perimeter_ be set. The hydraulic diameter is calculated as follows:\n```\n  extends BaseClasses.PartialTwoPortFlow(\n    /* ... */\n    final crossAreas=fill(crossArea, n),\n    final dimensions=fill(4*crossArea/perimeter, n),\n```\nIf crossArea is the total cross area of all parallel pipes and perimeter is the sum of perimeters of all parallel pipes, why then even have parameter _nParallel_?\n\nTo sum up, a lot of geometric parameters are confusing when _nParallel_ is set to more then 1 and furthermore when varable _vs_ corresponds to mean flow velocity, then Reynolds number is possibliy calculated wrongly (and consequently heat transfer coefficient).\n\n\n\n----\n\nMigrated-From: https://trac.modelica.org/Modelica/ticket/247"},"comment":{"url":"https://api.github.com/repos/tbeu/Modelica/issues/comments/268306549","html_url":"https://github.com/tbeu/Modelica/issues/247#issuecomment-268306549","issue_url":"https://api.github.com/repos/tbeu/Modelica/issues/247","id":268306549,"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-20T17:35:55Z","updated_at":"2016-12-20T17:35:55Z","body":"**Modified by dietmarw on 20 Dec 2012 08:17 UTC**"}}
{"actor":{"display_login":"modelica-trac-importer"}}