[FLASH-USERS] Using scratch variables
vgop at lle.rochester.edu
vgop at lle.rochester.edu
Mon Mar 25 19:29:49 EDT 2019
Thank you! That seems like it’s fixed the problem.
From: Ji, Suoqing <suoqing at caltech.edu>
Sent: Monday, March 25, 2019 5:31 PM
To: vgop at lle.rochester.edu
Cc: flash-users at flash.uchicago.edu
Subject: Re: [FLASH-USERS] Using scratch variables
Hi Varchas,
I suspect you might get the wrong pointer for the scratch variables (not the way of getting solnData). You could get the correct pointer for the scratch variables by calling
call Grid_getBlkPtr(blockId, scrtData, SCRATCH_CTR)
Best regards,
—
Suoqing Ji
Sherman Fairchild Fellow
TAPIR & Walter Burke Institute for Theoretical Physics
California Institue of Technology
<http://www.tapir.caltech.edu/~suoqing> http://www.tapir.caltech.edu/~suoqing
On Mar 25, 2019, at 2:11 PM, vgop at lle.rochester.edu <mailto:vgop at lle.rochester.edu> wrote:
Dear community,
Has anyone had experience with using scratch variables in FLASH? I’d like to have a scratch variable to keep track of some index values between time steps to speed up a table lookup. My first try was to use
SCRATCHCENTERVAR RIDX
In my Config file, and then try to read from/write to the scratch variable by referencing
blkPointer(RIDX_SCRATCH_VAR,I,j,k)
However, it seems like in Flash.par, RIDX_SCRATCH_CENTER_VAR has the same value as DENS_VAR, which leads to a rather unfortunate series of errors whenever I write to it and instead end up overwriting DENS_VAR. Does anyone have advice with how I should actually go about reading/writing the scratch vars?
Thanks,
Varchas Gopalaswamy
PhD Candidate, Laboratory for Laser Energetics,
Department of Mechanical Engineering
University of Rochester
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://flash.rochester.edu/pipermail/flash-users/attachments/20190325/7bb81221/attachment-0001.htm>
More information about the flash-users
mailing list