Just a simple algorithm for analog clock in PHP