[Nek5000-users] Read file without using load_fld nor mfi subroutines

nek5000-users at lists.mcs.anl.gov nek5000-users at lists.mcs.anl.gov
Wed May 31 04:44:35 CDT 2017


Thank you for your solution, it works great.

Thank you for your time,

Best wishes,


Arnold




Le 30/05/2017 à 15:54, nek5000-users at lists.mcs.anl.gov a écrit :
> Hi;
> The easies solution would be to copy your velocity and pressure to 
> temporary arrays before reading the file and placing them back later 
> on. e.g.
>
>       real tmp_vel(lx1*ly1*lz1*lelv,ldim), tmp_pr(lx2*ly2*lz2*lelv)
>       common /SCREV/ tmp_vel, tmp_pres
>       integer n_tot
>
>
>       call opcopy(tmp_vel(1,1),tmp_vel(1,2),tmp_vel(1,ndim),vx,vy,vz)
>       n_tot = nx2*ny2*nz2*nelv
>       call copy(tmp_pr,pr)
>
> !     read file and use variables
>
>       call opcopy(vx,vy,vz,tmp_vel(1,1),tmp_vel(1,2),tmp_vel(1,ndim))
>       n_tot = nx2*ny2*nz2*nelv
>       call copy(pr,tmp_pr)
>
>
> Regards
> Adam
>
> On 30/05/17 15:32, nek5000-users at lists.mcs.anl.gov wrote:
>> Hi Neks,
>>
>> I may have a problem when I'm trying to read velocity field (only 
>> velocity field, I don't need pressure.) so I can assign specific 
>> boundary conditions using userbc().
>>
>> My questions are : 1) Is it possible to read velocity fields in nek 
>> that are contained in .f000* files without modifying the pressure 
>> "pr" nor the velocity fields "vx,vy,vz" ?
>>                               2) Is there any subroutine (besides 
>> load_fld or mfi) that would allow me to read .f000* files?
>>
>>
>> When I use the mfi (in ic.f) subroutine, it looks like the pressure 
>> field is modified and hence I'm quickly running into errors like the 
>> following:
>>
>> 100 **ERROR**: Failed in HMHOLTZ: VELX          NaN          NaN 
>> 1.0000E-12.
>>
>> If I use load_fld() I seem to me going back to the initial conditions.
>>
>> Thank you for your help,
>>
>> Arnold
>> _______________________________________________
>> Nek5000-users mailing list
>> Nek5000-users at lists.mcs.anl.gov
>> https://lists.mcs.anl.gov/mailman/listinfo/nek5000-users
>
>
> _______________________________________________
> Nek5000-users mailing list
> Nek5000-users at lists.mcs.anl.gov
> https://lists.mcs.anl.gov/mailman/listinfo/nek5000-users

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/nek5000-users/attachments/20170531/b583457b/attachment.html>


More information about the Nek5000-users mailing list