Java tutorial
//package com.java2s; public class Main { private static double getRadiansByHHMMSS(double hours, double minutes, double seconds) { double degreeHours = hours * 15.0; double degreesMin = (minutes / 60.0) * 15.0; double degreesSec = (seconds / 3600.0) * 15.0; double degrees = degreeHours + degreesMin + degreesSec; return Math.toRadians(degrees); } }