Skip to main content
Glama
IBM

Physics MCP Server

by IBM

calculate_pendulum_period

Calculate the oscillation period of a simple pendulum using length and gravity inputs, with optional amplitude correction for large angles.

Instructions

Calculate pendulum period: T = 2π√(L/g).

Period of a simple pendulum depends only on length and gravity
(for small amplitudes). Includes correction for large amplitudes.

Args:
    length: Pendulum length in meters (pivot to center of mass)
    gravity: Gravitational acceleration in m/s² (default 9.81)
    amplitude_degrees: Amplitude in degrees (optional, for large angle correction)

Returns:
    Dict containing:
        - period: T in seconds
        - frequency: f in Hz
        - angular_frequency: ω in rad/s
        - small_angle_approximation: Whether small angle formula was used

Tips for LLMs:
    - Period independent of mass (Galileo's discovery)
    - Period independent of amplitude (for small angles < 15°)
    - Longer pendulum → longer period
    - Use for: clocks, playground swings, seismometers

Example - Grandfather clock:
    result = await calculate_pendulum_period(
        length=0.994,  # meters (for 2-second period)
        gravity=9.81
    )
    # T = 2.0 seconds

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
lengthYes
gravityNo
amplitude_degreesNo
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries the full burden and does an excellent job explaining behavioral aspects: it clarifies the physics assumptions (small angle approximation vs. large amplitude correction), specifies default values (gravity=9.81), and describes the return structure in detail. It doesn't mention error handling or computational limits, preventing a perfect score.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is well-structured with clear sections (formula, explanation, args, returns, tips, example) and every sentence adds value. It could be slightly more concise in the physics explanations, but the information density is high and the front-loaded formula immediately communicates the core functionality.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a calculation tool with no annotations and no output schema, the description provides exceptional completeness: it includes the governing formula, parameter semantics, detailed return structure, usage examples, physics context, and practical applications. The example with grandfather clock parameters provides concrete implementation guidance.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

With 0% schema description coverage, the description fully compensates by providing detailed semantics for all three parameters: length ('Pendulum length in meters (pivot to center of mass)'), gravity ('Gravitational acceleration in m/s² (default 9.81)'), and amplitude_degrees ('Amplitude in degrees (optional, for large angle correction)'). Each parameter's purpose, units, and optionality are clearly explained.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool's purpose with the specific formula T = 2π√(L/g) and explains it calculates the period of a simple pendulum. It distinguishes from siblings like calculate_spring_mass_period by focusing specifically on pendulum physics rather than other oscillatory systems.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides explicit guidance on when to use this tool ('Use for: clocks, playground swings, seismometers') and includes important context about when the small angle approximation applies versus when amplitude correction is needed. The 'Tips for LLMs' section offers practical decision-making guidance.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/IBM/chuk-mcp-physics'

If you have feedback or need assistance with the MCP directory API, please join our Discord server