Converts angle measurements from degrees to radians using the formula radians = degrees × π/180. Access via MCP in Cursor, Claude Code, or other AI tools, or call GET /v1/math/deg-to-rad directly. For example, 180° becomes π (≈3.14159). Returns precise floating-point results for trigonometric calculations.
curl "https://tinyfn.io/v1/math/deg-to-rad" \
-H "X-API-Key: YOUR_API_KEY"
const response = await fetch('https://tinyfn.io/v1/math/deg-to-rad', {
headers: { 'X-API-Key': 'YOUR_API_KEY' }
});
const data = await response.json();
console.log(data);
import requests
response = requests.get('https://tinyfn.io/v1/math/deg-to-rad',
headers={'X-API-Key': 'YOUR_API_KEY'})
data = response.json()
print(data)
Connect your AI agent (Claude, Cursor, Windsurf, etc.) to TinyFn's math tools:
{
"mcpServers": {
"tinyfn-math": {
"url": "https://tinyfn.io/mcp/math",
"headers": {
"X-API-Key": "YOUR_API_KEY"
}
}
}
}
Use the MCP tool in supported editors like Cursor or Windsurf, or make a GET request to /v1/math/deg-to-rad with your degree value. The conversion uses the standard formula: radians = degrees × π/180.
Degrees divide a circle into 360 parts, while radians use the circle's radius as the unit. One full rotation is 360° or 2π radians, making π radians equal to 180°.
Yes, negative degree values are converted correctly. For example, -90° becomes -π/2 radians (≈-1.5708).
Most programming languages and mathematical functions expect radians for trigonometric operations (sin, cos, tan). Using radians eliminates conversion overhead in computational workflows.
Returns standard floating-point precision using the exact π value. Common conversions: 90° = π/2, 180° = π, 270° = 3π/2, 360° = 2π.