<html><body><div style="font-family: arial, helvetica, sans-serif; font-size: 12pt; color: #000000"><div>Hi,<br></div><div><br data-mce-bogus="1"></div><div>It worked. And now I just have one more question. I store the drag coefficient in each time step <br data-mce-bogus="1"></div><div>lets say<br data-mce-bogus="1"></div><div><br data-mce-bogus="1"></div><div>real dragycoeff(NSTEP)<br data-mce-bogus="1"></div><div>save dragycoeff<br data-mce-bogus="1"></div><div><br data-mce-bogus="1"></div><div>dragycoeff(istep) = dragy(1)<br data-mce-bogus="1"></div><div><br data-mce-bogus="1"></div><div>The reason why I store these values : I would like to use them for adams bashforth scheme. (Since I am working on FSI problem and to solve equation of motion) so i may need the previous for 4 values maximum to compute the displacement and velocity values for the next time step. <br data-mce-bogus="1"></div><div><br data-mce-bogus="1"></div><div>So my question is, If I have a very large time steps (lets say 500000) will it be efficient? I am also thingking another way like dynamic memory allocation. Since I just need the previous 4 values at each time step, I dont have to store all the drag coefficient for all the time steps. So is there any way in NEK5000 to store the just 4 previous values and update these values at every time step. So that i can decalare a varibale of just siwe of 4 (lets say : real dragycoeff(4) ). Or Can I make any function for that?<br data-mce-bogus="1"></div><div><br data-mce-bogus="1"></div><div>Thanks in advance<br data-mce-bogus="1"></div><div><br data-mce-bogus="1"></div><div>SIjo GEORGE<br data-mce-bogus="1"></div><div><br></div><hr id="zwchr" data-marker="__DIVIDER__"><div data-marker="__HEADERS__"><b>De: </b>"nek5000-users" <nek5000-users@lists.mcs.anl.gov><br><b>À: </b>"nek5000-users" <nek5000-users@lists.mcs.anl.gov><br><b>Envoyé: </b>Mercredi 22 Novembre 2017 17:22:30<br><b>Objet: </b>Re: [Nek5000-users] Storing dragy coefficient<br></div><br><div data-marker="__QUOTED_TEXT__"><div style="font-family: arial, helvetica, sans-serif; font-size: 12pt; color: #000000"><div>Thanks Marco I give a try, I am trying to implement FSI with adams bashforth method. RK4 scheme is validated. Now I am doing the stability study (comparing adams and RK4). So thanks and please do keep in touch.<br></div><br><div>Sijo<br></div><hr id="zwchr"><div><b>De: </b>"nek5000-users" <nek5000-users@lists.mcs.anl.gov><br><b>À: </b>"nek5000-users" <nek5000-users@lists.mcs.anl.gov><br><b>Envoyé: </b>Mercredi 22 Novembre 2017 17:18:24<br><b>Objet: </b>Re: [Nek5000-users] Storing dragy coefficient<br></div><br><div>
I think it should do the trick.
<div class=""><br class="">
</div>
<div class="">If you want to use the values in a different subroutine, you must use common block. If the values are used in the same subroutine as they are stored, then save data should be sufficient.</div>
<div class=""><br class="">
</div>
<div class="">Marco</div>
<div class=""><br class="">
</div>
<div class=""><br class="">
<div>
<blockquote class="">
<div class="">On Nov 22, 2017, at 11:10 AM, <a href="mailto:nek5000-users@lists.mcs.anl.gov" class="" target="_blank">
nek5000-users@lists.mcs.anl.gov</a> wrote:</div>
<br class="Apple-interchange-newline">
<div class="">
<div class="">
<div style="font-family: arial, helvetica, sans-serif; font-size: 12pt;" class="">
<div class="">Thank you marco.<br class="">
</div>
<div class=""><br class="">
</div>
<div class="">So you mean if my problem is for 100 time steps and if i declare a variable like below<br class="">
</div>
<div class=""><br class="">
</div>
<div class=""> real dum(100)<br class="">
save dum<br class="">
<br class="">
and if i write </div>
<div class=""><br class="">
</div>
<div class=""> dum(istep)= dragy(1) # I have one object<br class="">
</div>
<div class=""><br class="">
</div>
<div class="">I could store all the dragy coefficient into this array permenently?<br class="">
</div>
<div class=""><br class="">
</div>
<div class="">Because I just want to use the previous values that means (dum(istep-1)) in some other functions.<br class="">
</div>
<div class=""><br class="">
</div>
<div class=""><br class="">
</div>
<div class="">Thanks with regards<br class="">
</div>
<div class=""><br class="">
</div>
<div class=""><br class="">
</div>
<div class="">Sijo GEORGE<br class="">
</div>
<div class=""><br class="">
</div>
<div class=""><br class="">
</div>
<hr id="zwchr" class="">
<div class=""><b class="">De: </b>"nek5000-users" <<a href="mailto:nek5000-users@lists.mcs.anl.gov" class="" target="_blank">nek5000-users@lists.mcs.anl.gov</a>><br class="">
<b class="">À: </b>"nek5000-users" <<a href="mailto:nek5000-users@lists.mcs.anl.gov" class="" target="_blank">nek5000-users@lists.mcs.anl.gov</a>><br class="">
<b class="">Envoyé: </b>Mercredi 22 Novembre 2017 16:58:15<br class="">
<b class="">Objet: </b>Re: [Nek5000-users] Storing dragy coefficient<br class="">
</div>
<div class=""><br class="">
</div>
<div class="">if I correctly understand your problem, you will need to look into common block or save data that are Fortran capabilities.
<div class=""><br class="">
</div>
<div class="">Marco</div>
<div class=""><br class="">
<div class="">
<div class="">
<blockquote class="">
<div class="">On Nov 22, 2017, at 10:49 AM, <a href="mailto:nek5000-users@lists.mcs.anl.gov" class="" target="_blank">
nek5000-users@lists.mcs.anl.gov</a> wrote:</div>
<br class="Apple-interchange-newline">
<div class="">
<div class="">
<div style="font-family: arial, helvetica, sans-serif; font-size: 12pt;" class="">
<div class="">Hi,<br class="">
</div>
<div class=""><br class="">
</div>
<div class="">I was working on storing dragy coefficient on an array. But its not getting permanently stored in the varibale after the next time step. That means I could not access the previous stored value from the array. Is there any way to store and access
dragy of different time steps?<br class="">
</div>
<div class=""><br class="">
</div>
<div class="">Thanks<br class="">
</div>
<div class=""><br class="">
</div>
<div class="">with regards<br class="">
</div>
<div class=""><br class="">
</div>
<div class="">Sijo GEORGE<br class="">
</div>
</div>
</div>
_______________________________________________<br class="">
Nek5000-users mailing list<br class="">
<a href="mailto:Nek5000-users@lists.mcs.anl.gov" class="" target="_blank">Nek5000-users@lists.mcs.anl.gov</a><br class="">
<a href="https://lists.mcs.anl.gov/mailman/listinfo/nek5000-users" class="" target="_blank">https://lists.mcs.anl.gov/mailman/listinfo/nek5000-users</a><br class="">
</div>
</blockquote>
</div>
<br class="">
</div>
</div>
<br class="">
_______________________________________________<br class="">
Nek5000-users mailing list<br class="">
<a href="mailto:Nek5000-users@lists.mcs.anl.gov" class="" target="_blank">Nek5000-users@lists.mcs.anl.gov</a><br class="">
https://lists.mcs.anl.gov/mailman/listinfo/nek5000-users<br class="">
</div>
</div>
</div>
_______________________________________________<br class="">
Nek5000-users mailing list<br class="">
<a href="mailto:Nek5000-users@lists.mcs.anl.gov" class="" target="_blank">Nek5000-users@lists.mcs.anl.gov</a><br class="">
https://lists.mcs.anl.gov/mailman/listinfo/nek5000-users<br class="">
</div>
</blockquote>
</div>
<br class="">
</div>
<br>_______________________________________________<br>Nek5000-users mailing list<br>Nek5000-users@lists.mcs.anl.gov<br>https://lists.mcs.anl.gov/mailman/listinfo/nek5000-users<br></div></div><br>_______________________________________________<br>Nek5000-users mailing list<br>Nek5000-users@lists.mcs.anl.gov<br>https://lists.mcs.anl.gov/mailman/listinfo/nek5000-users<br></div></div></body></html>