Geometrical-optics approach to measure the optical density of bacterial cultures using a LED-based photometer