Water any news ???

Hello again with a new question,

the pool I am trying to simulate has a bottom that it's depth varies. This
means that i can not use the poolcoords.cal formula as it is and i need to
make some necessary changes. The part of formula i don't understand, but i
think can not work as it is, is the following:

"floor_bin = floor(FloorXres*(Px - FloorOrigX)/FloorWidth) +
floor(FloorYres*(1 - (Py - FloorOrigY)/FloorLength))*FloorXres;"

In this formula 3 more parameters must be added in my opinion: FloorOrigZ,
FloorZres, FloorDepth.

The role of the this formula is to calculate how many points (bins) should
be used for calculating how much energy falls on them,

If someone can explain how the specific formula works [ floor(...) , Px, Py
], or give me directly a new one with the parameters of depth in it, I
whould be grateful.

Thank you in advance for your time

Sotiris Papantoniou
Welsh School of Architecture

Hello Sotiris.

Hello again with a new question,

the pool I am trying to simulate has a bottom that it's depth varies. This
means that i can not use the poolcoords.cal formula as it is and i need to
make some necessary changes.

I don't think you need to change anything in this formula. It returns
the bin number for a point (Px,Py) based on the x and y resolution.
The "depth" of the plane is not taken into account. If you would add
another component you would split the 2-d array into a 3-d array.
I don't think that's what you want to do.

The part of formula i don't understand, but i
think can not work as it is, is the following:

"floor_bin = floor(FloorXres*(Px - FloorOrigX)/FloorWidth) +
floor(FloorYres*(1 - (Py - FloorOrigY)/FloorLength))*FloorXres;"

This formula returns the number of the bin for the particular
"tile" in the Xres (columns) * Yres (rows) grid.

floor_bin = column position + ( row position * columns)

floor() is the math formula to return the next smaller integer number.

It's easy to understand if you replace all the variables with
actual values. Example:

FloorXres = 13
FloorYres = 17
FloorOrigX = 0
FloorOrigY = 0
FloorWidth = 26
FloorLength = 34

Px = 5.67
Py = 12.34

floor_bin = floor( 13 * ( 5.67 - 0 ) / 26 ) + floor( 17 * ( 1 - ( 12.34 - 0
) / 34 ) ) * 13

floor_bin = floor( 13 * rel X position ) + floor ( 17 * ( 1 - rel Y postion)
) * 13

In this formula 3 more parameters must be added in my opinion: FloorOrigZ,
FloorZres, FloorDepth.

Z is not taken into account here.

The role of the this formula is to calculate how many points (bins) should
be used for calculating how much energy falls on them,

Not "how many" bins but "which" bin. The "how many" is set by Xres and Yres.

If someone can explain how the specific formula works [ floor(...) , Px,

Py

], or give me directly a new one with the parameters of depth in it, I
whould be grateful.

I hope you can go on with the explanation above. If your floor slopes down
you might have adjust the area of the floor relative to a horizontal plane.
But that should be all.

Thomas

···

2009/8/13 Σωτήρης Παπαντωνίου <[email protected]>: