http://projecteuler.net/index.php?section=problems&id=173

回答者が多いだけあって簡単。

lamina :: Integer -> Integer
lamina n = (sum.map (div n)) [4,8..4*m] - div (m*(m+1)) 2
where m = floor.sqrt.fromInteger.div n $ 4
p173 = lamina $ 10^6