<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
<style type="text/css" style="display:none;"><!-- P {margin-top:0;margin-bottom:0;} --></style>
</head>
<body dir="ltr">
<div id="divtagdefaultwrapper" style="font-size:12pt;color:#000000;font-family:Calibri,Helvetica,sans-serif;" dir="ltr">
<p style="margin-top:0;margin-bottom:0"><br>
</p>
<p style="margin-top:0;margin-bottom:0">Usually this is the element number.</p>
<p style="margin-top:0;margin-bottom:0"><br>
</p>
<p style="margin-top:0;margin-bottom:0">For example:</p>
<p style="margin-top:0;margin-bottom:0"><br>
</p>
<p style="margin-top:0;margin-bottom:0"> subroutine userbc(i,j,k,eg)</p>
<p style="margin-top:0;margin-bottom:0"> integer e,eg</p>
<p style="margin-top:0;margin-bottom:0"><br>
</p>
<p style="margin-top:0;margin-bottom:0"> real myux(lxl1,ly1,lz1,lelt)</p>
<p style="margin-top:0;margin-bottom:0"> common /mystuff/ myux</p>
<p style="margin-top:0;margin-bottom:0"><br>
</p>
<p style="margin-top:0;margin-bottom:0"> e = gllel( eg ) ! Convert global element number to element number local to this rank</p>
<p style="margin-top:0;margin-bottom:0"><br>
</p>
<p style="margin-top:0;margin-bottom:0"> ux = myux(i,j,k,e)</p>
<p style="margin-top:0;margin-bottom:0"><br>
</p>
<p style="margin-top:0;margin-bottom:0"> etc.</p>
<p style="margin-top:0;margin-bottom:0"><br>
</p>
<p style="margin-top:0;margin-bottom:0"> return</p>
<p style="margin-top:0;margin-bottom:0"> end</p>
<p style="margin-top:0;margin-bottom:0"><br>
</p>
<p style="margin-top:0;margin-bottom:0">would assign your own ux() ["myux"] array values to the boundary points wherever</p>
<p style="margin-top:0;margin-bottom:0">a Dirichlet condition ("v ") has been assigned.</p>
<p style="margin-top:0;margin-bottom:0"><br>
</p>
<p style="margin-top:0;margin-bottom:0">hth,</p>
<p style="margin-top:0;margin-bottom:0"><br>
</p>
<p style="margin-top:0;margin-bottom:0">Paul</p>
<p style="margin-top:0;margin-bottom:0"><br>
</p>
</div>
<hr style="display:inline-block;width:98%" tabindex="-1">
<div id="divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" style="font-size:11pt" color="#000000"><b>From:</b> Nek5000-users <nek5000-users-bounces@lists.mcs.anl.gov> on behalf of nek5000-users@lists.mcs.anl.gov <nek5000-users@lists.mcs.anl.gov><br>
<b>Sent:</b> Sunday, December 31, 2017 1:18:06 PM<br>
<b>To:</b> nek5000-users@lists.mcs.anl.gov<br>
<b>Subject:</b> Re: [Nek5000-users] Different velocity values in different 'v' inlets</font>
<div> </div>
</div>
<div dir="auto">
<div></div>
<div>What is the variable e in userbc?</div>
<div><br>
On 31 Dec 2017, at 19:35, "<a href="mailto:nek5000-users@lists.mcs.anl.gov">nek5000-users@lists.mcs.anl.gov</a>" <<a href="mailto:nek5000-users@lists.mcs.anl.gov">nek5000-users@lists.mcs.anl.gov</a>> wrote:<br>
<br>
</div>
<blockquote type="cite">
<div>
<div dir="ltr">
<div>
<div>
<div>
<div>
<div>Hi all,<br>
<br>
</div>
I'm trying to simulate a shear-layer which involves two different jets emerging at different velocities. The simulation is 2D for now. The width of the first jet extends from y=0.0 to y=1.0 and the second extends from y=1.0 to y=3.0<br>
<br>
</div>
I generated a mesh using genbox with 'v' BCs for both inlets.<br>
<br>
</div>
In the .usr file I have the following form for usrbc<br>
<br>
subroutine userbc (ix,iy,iz,iside,ieg)<br>
c NOTE ::: This subroutine MAY NOT be called by every process<br>
include 'SIZE'<br>
include 'TOTAL'<br>
include 'NEKUSE'<br>
if (ym1(i,j,k,e).lt.1) then<br>
ux=10.0<br>
elseif (ym1(i,j,k,e).gt.1) then <br>
ux=1.0<br>
endif<br>
ux=1.0<br>
uy=0.0<br>
uz=0.0<br>
temp=0.0<br>
return<br>
end<br>
<br>
</div>
As you can see I try assigning ux = 10.0 and 1.0 to the different zones. However the results show a uniform value of 1.0 across both the inlets.<br>
</div>
<div>What am I missing here?</div>
<div><br>
</div>
<div>Sincerely,<br>
</div>
</div>
<div dir="ltr">-- <br>
</div>
<div class="x_gmail_signature">
<div dir="ltr">
<p dir="ltr"><b><font color="#000033">Amitvikram Dutta</font></b></p>
<p dir="ltr">Graduate Research Assistant</p>
<p dir="ltr">Fluid Mechanics Research Lab</p>
<p>Multi-Physics Interaction Lab</p>
<p dir="ltr">University of Waterloo</p>
</div>
</div>
<pre>_______________________________________________<br>
Nek5000-users mailing list<br>
<a href="mailto:Nek5000-users@lists.mcs.anl.gov">Nek5000-users@lists.mcs.anl.gov</a><br>
<a href="https://lists.mcs.anl.gov/mailman/listinfo/nek5000-users">https://lists.mcs.anl.gov/mailman/listinfo/nek5000-users</a><br>
</pre>
</div>
</blockquote>
</div>
</body>
</html>