Returns angle between vec_a and vec_b in range [-PI, PI].  This
    indicates if vec_a is left of or right of vec_b.

    vec_a is the base vector that the returned angle will be based off of.
    e.g. if vec_b is to the right (clockwise) of vec_a, the angle will be
    negative.  (note line about angle dir below)
    Added to simpler function above with these suggestions:
    http://www.physicsforums.com/showthread.php?t=559966
    Positive angle is counterclockwise as trig functions expect

def angle_v2_rad_dir(vec_a, vec_b):
    """Returns angle between vec_a and vec_b in range [-PI, PI].  This
    indicates if vec_a is left of or right of vec_b.

    vec_a is the base vector that the returned angle will be based off of.
    e.g. if vec_b is to the right (clockwise) of vec_a, the angle will be
    negative.  (note line about angle dir below)
    Added to simpler function above with these suggestions:
    http://www.physicsforums.com/showthread.php?t=559966
    Positive angle is counterclockwise as trig functions expect
    """
    # cos(x) = A * B / |A| * |B|
    rads = math.acos(vec_a.dot(vec_b) / (vec_a.length() * vec_b.length()))
    if vec_a.x * vec_b.y >= vec_a.y * vec_b.x:
        return rads
    else:
        return -rads