I think I was able to solve the following problem without algebra but I would love to know if there is an equation for this problem:
Twenty-seven unit cubes are coloured completely blue or completely yellow. All twenty-seven unit cubes are assembled into a larger cube. If half of the surface are of the larger blue cube is blue, what is the maximum number of unit cubes that could have been coloured blue
My logic is to avoid the squares at the corners of each side because 1 cube would take up 3 sides.
A cube is 3 rows of 3 cubes A cube flattened out has 54 sides ( 9 X 6), so blues take up 27 squares 1 cube in the middle you do not see 10 cubes like on the top and the bottom that avoid corner faces 4 center horizontal squares 1 center-edge cube that takes up 2 faces 1 corner cube that takes up 3 squares That is 15 cubes and 27 faces
Could this be done with algebra?
We require half of the $6×3^2=54$, i.e. $27$, of the exposed faces to be blue. Each blue corner cubie (up to $8$) contributes $3$, each such edge cubie (up to $12$) $2$, each such centre cubie (up to $6$) $1$. Thus $$3a+2b+c=27,a\in[0,8],b\in[0,12],c\in[0,6]$$ and we want to maximise/minimise $a+b+c+d$, where $d$ represents the hidden centre cube and is $0$ or $1$. This is a small integer linear program that can be solved by casework, yielding the bounds $10\le a+b+c+d\le17$.