import math


def sph_dist(ra1, dec1,ra2, dec2):
    """
    Compute the spherical distance between 2 pairs of coordinates
    using the Haversine formula
    
    Input coordinates are in decimal degrees
    Output: angular distance in decimal degrees
    """
    ra1_rad  = math.radians(ra1)
    dec1_rad = math.radians(dec1)
    ra2_rad  = math.radians(ra2)
    dec2_rad = math.radians(dec2)

    d = math.sin((dec1_rad-dec2_rad)/2)**2;
    d += math.sin((ra1_rad-ra2_rad)/2)**2 * math.cos(dec1_rad)*math.cos(dec2_rad)

    return math.degrees(2*math.asin(math.sqrt(d)))