Yet again, im programming a software to align pictures on a 2D plane, kinda like they are in windows exploror. I need to find a relationship betwen these.(adsbygoogle = window.adsbygoogle || []).push({});

I C R

_______

1 1 1

2 1 2

3 1 3

4 1 4

5 1 5

6 1 1

7 2 2

8 2 3

9 2 4

10 2 5

11 3 1

I would be my for loop counter, C would be the colum of picture I, and R would be what row it belongs to.

I already know that

C = Ceil(i / 5);

And I have come close to finding the value of R, so far I have

R = i - (Floor(i/(5 + C))*5);

But I know the latter equation is wrong, I just cant seem to figure it out out.

Thanks in advanve

**Physics Forums - The Fusion of Science and Community**

Dismiss Notice

Join Physics Forums Today!

The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

# Another relationship of variables

Loading...

Similar Threads - Another relationship variables | Date |
---|---|

B Transforming a circle onto another plane | Apr 24, 2017 |

I Another negative one equals one proof | Mar 30, 2017 |

I Deriving expression as a function of another variable | Sep 5, 2016 |

B Heard of Another Kind of "Rational" (Fraction) Addition? | Mar 22, 2016 |

**Physics Forums - The Fusion of Science and Community**