<html><head><style type='text/css'>p { margin: 0; }</style></head><body><div style='font-family: Times New Roman; font-size: 12pt; color: #000000'><P>Hi Pradeep,</P>
<P> </P>
<P>I can show you how to do this off-list, there is a way to use the uservp (variable properties) routine in the usr file. Although I am not sure</P>
<P>how this effects using the IFCHAR (if you are). I seem to recall Markus having an issue with PN/PN versus PN/PN-2 when using</P>
<P>variable properties, and the PN/PN-2 routine seemed to correct the issue he was having.</P>
<P> </P>
<P>- Michael</P>
<P><BR>----- Original Message -----<BR>From: nek5000-users@lists.mcs.anl.gov<BR>To: nek5000-users@lists.mcs.anl.gov<BR>Sent: Monday, August 23, 2010 4:13:48 PM GMT -06:00 US/Canada Central<BR>Subject: Re: [Nek5000-users] Temperature gradient at a point<BR><BR>Hi Paul,<BR><BR>Thanks for the detailed reply. The reason I'm not solving it as a conjugate heat transfer problem, is that thermal conductivity is a function of temperature based on some curve fit equations, and I am not sure how to implement that.<BR><BR>Thanks,<BR>Pradeep<BR><BR></P>
<DIV class=gmail_quote>On Mon, Aug 23, 2010 at 4:04 PM, <SPAN dir=ltr><<A href="mailto:nek5000-users@lists.mcs.anl.gov" target=_blank>nek5000-users@lists.mcs.anl.gov</A>></SPAN> wrote:<BR>
<BLOCKQUOTE style="BORDER-LEFT: rgb(204,204,204) 1px solid; MARGIN: 0pt 0pt 0pt 0.8ex; PADDING-LEFT: 1ex" class=gmail_quote><BR>Hi Pradeep,<BR><BR>Why not just solve the conjugate heat transfer problem directly<BR>using fluid + solid elements in nek?<BR><BR>Also, nek supports full Robin boundary conditions if you wish<BR>to do a Newton law of cooling: k*dT/dn . n_hat = h*(T-Tinf), where Tinf is the external temperature and h is the heat transfer coefficient, both of which can be functions of time and space.<BR><BR><BR>Regarding gradm1, you would call it from userchk, and store<BR>the output in arrays in a common block, e.g., as below.<BR><BR>Paul<BR><BR> subroutine userchk<BR> :<BR> common /mygrad/ tx(lx1,ly1,lz1,lelt)<BR> $ , ty(lx1,ly1,lz1,lelt)<BR> $ , tz(lx1,ly1,lz1,lelt)<BR><BR> call gradm1(tx,ty,tz,t)<BR><BR> :<BR> :<BR><BR> subroutine userbc (ix,iy,iz,iside,eg)<BR> include 'SIZE'<BR> include 'TOTAL'<BR> include 'NEKUSE'<BR><BR> common /mygrad/ tx(lx1,ly1,lz1,lelt)<BR> $ , ty(lx1,ly1,lz1,lelt)<BR> $ , tz(lx1,ly1,lz1,lelt)<BR><BR> integer e,eg<BR><BR> e = gllel(eg) ! global element number to processor-local el. #<BR><BR> gtx=tx(ix,iy,iz,e)<BR> gty=ty(ix,iy,iz,e)<BR> gtz=tz(ix,iy,iz,e)
<DIV>
<DIV></DIV>
<DIV class=h5><BR><BR><BR><BR>On Mon, 23 Aug 2010, <A href="mailto:nek5000-users@lists.mcs.anl.gov" target=_blank>nek5000-users@lists.mcs.anl.gov</A> wrote:<BR><BR>
<BLOCKQUOTE style="BORDER-LEFT: rgb(204,204,204) 1px solid; MARGIN: 0pt 0pt 0pt 0.8ex; PADDING-LEFT: 1ex" class=gmail_quote>Hi Paul,<BR><BR>I am basically trying to solve a conjugate heat transfer problem in an<BR>iterative manner, for flow over an infinitely long cylinder (2D).<BR><BR>I need to use the heat transfer at the boundary, to calculate the new<BR>temperature at the boundary for the next time step. The<BR>temperature for the next time step is solved for using this heat flux, by a<BR>function in the usr file using an FEM algorithm for the solid part<BR>(cylinder). The bc type I am using is Temperature - fortran function.<BR><BR>Regards,<BR>Pradeep<BR><BR>On Mon, Aug 23, 2010 at 2:50 PM, <<A href="mailto:nek5000-users@lists.mcs.anl.gov" target=_blank>nek5000-users@lists.mcs.anl.gov</A>> wrote:<BR><BR>
<BLOCKQUOTE style="BORDER-LEFT: rgb(204,204,204) 1px solid; MARGIN: 0pt 0pt 0pt 0.8ex; PADDING-LEFT: 1ex" class=gmail_quote><BR>Pradeep,<BR><BR>if you give me some idea of the nature of your bc, I can<BR>perhaps help --- there are a large number of bc types already<BR>supported inside nek<BR><BR>Paul<BR><BR><BR><BR>On Mon, 23 Aug 2010, <A href="mailto:nek5000-users@lists.mcs.anl.gov" target=_blank>nek5000-users@lists.mcs.anl.gov</A> wrote:<BR><BR> Hi,<BR>
<BLOCKQUOTE style="BORDER-LEFT: rgb(204,204,204) 1px solid; MARGIN: 0pt 0pt 0pt 0.8ex; PADDING-LEFT: 1ex" class=gmail_quote><BR>I wanted to know if there was a way to find the temperature gradient at a<BR>point. I need that information in the userbc function.<BR><BR>I tried using gradm1(), but I am not sure how to get the value at a given<BR>point.<BR><BR>Thanks,<BR>Pradeep<BR><BR> _______________________________________________<BR></BLOCKQUOTE>Nek5000-users mailing list<BR><A href="mailto:Nek5000-users@lists.mcs.anl.gov" target=_blank>Nek5000-users@lists.mcs.anl.gov</A><BR><A href="https://lists.mcs.anl.gov/mailman/listinfo/nek5000-users" target=_blank>https://lists.mcs.anl.gov/mailman/listinfo/nek5000-users</A><BR><BR></BLOCKQUOTE><BR><BR><BR>-- <BR>Pradeep C. Rao<BR>Graduate Research Assistant for FT2L (<A href="http://www1.mengr.tamu.edu/FT2L/" target=_blank>http://www1.mengr.tamu.edu/FT2L/</A>)<BR>Department of Mechanical Engineering<BR>Texas A&M University<BR>College Station, TX 77843-3123<BR><BR>428 Engineering Physics Building<BR>(713) 210-9769<BR><BR></BLOCKQUOTE></DIV></DIV>uuuu<BR>c-----------------------------------------------------------------------<BR>C<BR>C USER SPECIFIED ROUTINES:<BR>C<BR>C - boundary conditions<BR>C - initial conditions<BR>C - variable properties<BR>C - local acceleration for fluid (a)<BR>C - forcing function for passive scalar (q)<BR>C - general purpose routine for checking errors etc.<BR>C<BR>c-----------------------------------------------------------------------<BR> subroutine uservp (ix,iy,iz,eg)<BR> include 'SIZE'<BR> include 'TOTAL'<BR> include 'NEKUSE'<BR><BR> integer e,f,eg<BR>c e = gllel(eg)<BR><BR> udiff =0.<BR> utrans=0.<BR> return<BR> end<BR>c-----------------------------------------------------------------------<BR> subroutine userf (ix,iy,iz,eg)<BR> include 'SIZE'<BR> include 'TOTAL'<BR> include 'NEKUSE'<BR><BR> integer e,f,eg<BR>c e = gllel(eg)<BR><BR><BR>c Note: this is an acceleration term, NOT a force!<BR>c Thus, ffx will subsequently be multiplied by rho(x,t).<BR><BR><BR> ffx = 0.0<BR> ffy = 0.0<BR> ffz = 0.0<BR><BR> return<BR> end<BR>c-----------------------------------------------------------------------<BR> subroutine userq (ix,iy,iz,eg)<BR> include 'SIZE'<BR> include 'TOTAL'<BR> include 'NEKUSE'<BR><BR> integer e,f,eg<BR>c e = gllel(eg)<BR><BR> qvol = 0.0<BR><BR> return<BR> end<BR>c-----------------------------------------------------------------------<BR> subroutine userchk<BR> include 'SIZE'<BR> include 'TOTAL'<BR> return<BR> end<BR>c-----------------------------------------------------------------------<BR> subroutine userbc (ix,iy,iz,iside,ieg)<BR> include 'SIZE'<BR> include 'TOTAL'<BR> include 'NEKUSE'<BR> ux=0.0<BR> uy=0.0<BR> uz=0.0<BR> temp=0.0<BR> return<BR> end<BR>c-----------------------------------------------------------------------<BR> subroutine useric (ix,iy,iz,ieg)<BR> include 'SIZE'<BR> include 'TOTAL'<BR> include 'NEKUSE'<BR> ux=0.0<BR> uy=0.0<BR> uz=0.0<BR> temp=0<BR> return<BR> end<BR>c-----------------------------------------------------------------------<BR> subroutine usrdat<BR> include 'SIZE'<BR> include 'TOTAL'<BR>c<BR> return<BR> end<BR>c-----------------------------------------------------------------------<BR> subroutine usrdat2<BR> include 'SIZE'<BR> include 'TOTAL'<BR><BR> param(66) = 4. ! These give the std nek binary i/o and are<BR> param(67) = 4. ! good default values<BR><BR> return<BR> end<BR>c-----------------------------------------------------------------------<BR> subroutine usrdat3<BR> include 'SIZE'<BR> include 'TOTAL'<BR>c<BR> return<BR> end<BR>c-----------------------------------------------------------------------
<DIV>
<DIV></DIV>
<DIV class=h5><BR>_______________________________________________<BR>Nek5000-users mailing list<BR><A href="mailto:Nek5000-users@lists.mcs.anl.gov" target=_blank>Nek5000-users@lists.mcs.anl.gov</A><BR><A href="https://lists.mcs.anl.gov/mailman/listinfo/nek5000-users" target=_blank>https://lists.mcs.anl.gov/mailman/listinfo/nek5000-users</A><BR></DIV></DIV></BLOCKQUOTE></DIV><BR><BR clear=all><BR>-- <BR>Pradeep C. Rao<BR>Graduate Research Assistant for FT2L (<A href="http://www1.mengr.tamu.edu/FT2L/" target=_blank>http://www1.mengr.tamu.edu/FT2L/</A>)<BR>Department of Mechanical Engineering<BR>Texas A&M University<BR>College Station, TX 77843-3123<BR><BR>428 Engineering Physics Building<BR>(713) 210-9769<BR><BR>_______________________________________________ Nek5000-users mailing list Nek5000-users@lists.mcs.anl.gov https://lists.mcs.anl.gov/mailman/listinfo/nek5000-users </div></body></html>