AArcTern
Product

Product features · Minimal signed angle differences

01

Return the signed shortest difference between two degree angles in the interval from minus 180 inclusive to 180 exclusive.

01

Connection

Base URL, credentials and a reachable server.

02

Selection

A model available through the configured endpoint.

03

Capabilities

Context limits and tool support are determined by the model and server.

Minimal signed angle differences

● ● ●ArcTern●
A concrete starting point · Minimal signed angle differences ×
from math import isfinite

def angle_delta(source, target):
    for value in (source, target):
        if type(value) not in (int, float):
            raise ValueError("angle.number")
        if abs(value) > 1000000000000 or not isfinite(value):
            raise ValueError("angle.range")
    source, target = source % 360, target % 360
    return (target - source + 180) % 360 - 180
✳Return the signed shortest difference between two degree angles in the interval from minus 180 inclusive to 180 exclusive.
✓ ChangesReview before applying ↗
Illustrative workspace
AI coding workspace

Your next change starts here.

Get the Windows app ↗