How many segments on a gridded cuboid?

  • Thread starter Thread starter boyboy400
  • Start date Start date
AI Thread Summary
To determine the total number of segments on the surface of a gridded cuboid, one must calculate the segments on each of the six faces separately, considering the divisions along the X, Y, and Z axes. The formula for the number of segments on a face is derived from the product of the segments along the two axes forming that face. Care must be taken to avoid double-counting the edge segments that are shared between adjacent faces. The discussion emphasizes the need for a systematic approach to ensure accurate counting for algorithm development. A clear formula based on segx, segy, and segz will facilitate this calculation.
boyboy400
Messages
6
Reaction score
0
Hello everyone,
So let's say we have a cuboid.
On the X axis, it's divided to 4 segments (i.e. by 3 lines parallel to z axis) (segx=4).
On the Y axis, it's divided to 3 segments (i.e. by 2 lines parallel to z axis) (segy=3).
On the Z axis, it's divided to 8 segments (i.e. by 7 lines parallel to x or y axes) (segz=8).
Each line between two grid points is called a segment. How many segments are there on the surface of this cube entirely? All the 6 sides are divided as I said (it looks like Rubik's cube!).
The numbers I said were just an example. I need a formula based on segx and segy and segz for the number of segments on this cuboid.
I'm working on an algorithm this is needed for. I appreciate any help.
Thank you so much
 
Physics news on Phys.org
hello boyboy400! :smile:

you'll need to count the segments on each face separately, and then add for all six faces :wink:

(except, don't forget not to count the "edge" segments twice!)
 
Back
Top