MHB How can I get equal columns and rows from a total?

  • Thread starter Thread starter SLSCoder
  • Start date Start date
  • Tags Tags
    Columns
AI Thread Summary
To determine the number of equal columns and rows from a variable total of cells, the calculation involves using the floor function on the square root of the variable x. For example, if x equals 10, the result is 3 columns and 4 rows, with the last row containing only one value. The formula effectively helps in organizing the cells into a grid format. This method ensures that the layout remains balanced while accommodating the total number of cells. Understanding this calculation is essential for efficient data presentation.
SLSCoder
Messages
4
Reaction score
0
I have a number of cells (say 10 cells) but that number is a variable.
I have the value of the variable but it's not a 'hard' number. We'll call the variable x.

I need to calculate how many columns I'll have if the columns and rows will be the same, or the columns will be 1 minus (floor) the number of rows.
If the variable x = 10 then the columns would be 3 and there would be 4 rows, the last row would only have a value in the first column.

How can I calculate for the number of columns I need given the variable x?
 
Mathematics news on Phys.org
Duh - floor(square root of x)
 
Suppose ,instead of the usual x,y coordinate system with an I basis vector along the x -axis and a corresponding j basis vector along the y-axis we instead have a different pair of basis vectors ,call them e and f along their respective axes. I have seen that this is an important subject in maths My question is what physical applications does such a model apply to? I am asking here because I have devoted quite a lot of time in the past to understanding convectors and the dual...
Fermat's Last Theorem has long been one of the most famous mathematical problems, and is now one of the most famous theorems. It simply states that the equation $$ a^n+b^n=c^n $$ has no solutions with positive integers if ##n>2.## It was named after Pierre de Fermat (1607-1665). The problem itself stems from the book Arithmetica by Diophantus of Alexandria. It gained popularity because Fermat noted in his copy "Cubum autem in duos cubos, aut quadratoquadratum in duos quadratoquadratos, et...
Insights auto threads is broken atm, so I'm manually creating these for new Insight articles. In Dirac’s Principles of Quantum Mechanics published in 1930 he introduced a “convenient notation” he referred to as a “delta function” which he treated as a continuum analog to the discrete Kronecker delta. The Kronecker delta is simply the indexed components of the identity operator in matrix algebra Source: https://www.physicsforums.com/insights/what-exactly-is-diracs-delta-function/ by...
Back
Top