Skip to main content
FluidEarth Portal Header version 3

FluidEarth Portal

Go Search
  
FluidEarth Portal > FluidEarth Discussions > passed arguments setting issues > passed arguments setting issues.  

FluidEarth Discussions: passed arguments setting issues.

Body

Thank you very much, Gordon. 
You give me very useful advice. I will change my model. If I get new issues, I will ask you.


From: GGlasgow
Posted: 11 June 2010 10:53
Subject: passed arguments setting issues.

sorry, i missed a part of the answer before.
 
to decide how to set 'M' and 'N', you need to remember how the SDK is using these two values; basically, all that happens is it creates a single one-dimensional array of size M.N, which is why i use a one-dimensional echange_item array in my code to handle the data that comes in and out.
 
so if you wish to use this method to pass i tile of 3D data, you need to work out 'M' and 'N' so that their product equals I.J.K.
 
...for example, i like to use
 
M = I.J and N = K (because i am creating K number of tiles, each one with I.J elements, as my last post suggests)
 
but you might prefer
 
M = I and N = J.K
 
or
 
M = 1 and N = I.J.K
 
or
 
M = I.J.K and I = 1
 
so it's really up to you to choose the best approach that suits the way you write your code - as i say, i like to create tiles each one I.J in size, and i have K of them.
 
when i get a little time, i will create a better element set for you:

"FluidEarth.Sdk.ElementSetCubeRegular"

that allows you to specify an I, J and K rather than an N and M.
 
this won't make any difference to your model code at all - all that will happen is you will change your XML files to use this new element set rather than the old Grid version. in both cases, the SDK will create a 1D array which is equal to I.J.K as above.
will try to do this this weekend,
 
gordon
 

From: ZZhang
Posted: 10 June 2010 15:56
Subject: passed arguments setting issues.

Hi, Gordon,
I have several questions about how to set passed arguments in attached pdf file.
The rar file contains the two example model.
Look forward to your reply. Thank you.
Attachments
Content Type: Message
Created at 11/06/2010 11:29  by ZZhang 
Last modified at 11/06/2010 11:29  by ZZhang