Skip to main content
Glama
IBM

Physics MCP Server

by IBM

calculate_spring_mass_period

Calculate the oscillation period of a spring-mass system using mass and spring constant inputs to determine period, frequency, and angular frequency.

Instructions

Calculate period of spring-mass system: T = 2π√(m/k).

Natural oscillation frequency of a mass attached to a spring.
Independent of amplitude (for ideal springs).

Args:
    mass: Mass in kg
    spring_constant: Spring constant k in N/m

Returns:
    Dict containing:
        - period: T in seconds
        - frequency: f in Hz
        - angular_frequency: ω in rad/s

Tips for LLMs:
    - Heavier mass → longer period (slower oscillation)
    - Stiffer spring → shorter period (faster oscillation)
    - ω = 2πf = √(k/m)

Example - Mass on spring:
    result = await calculate_spring_mass_period(
        mass=0.5,  # 500g mass
        spring_constant=20.0  # N/m
    )
    # T ≈ 0.99s, f ≈ 1.01 Hz

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
massYes
spring_constantYes
Behavior4/5

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

With no annotations provided, the description carries full burden and does well by explaining the mathematical model (ideal springs, amplitude independence), providing the return structure (dict with period, frequency, angular_frequency), and including practical tips about physical behavior. It doesn't mention computational limits or error handling, but covers the essential behavioral aspects.

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

Conciseness5/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), each sentence adds value, and it's appropriately sized for the tool's complexity without unnecessary verbosity.

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 2 parameters and no output schema, the description is complete: it explains the physics, documents parameters and return values, provides usage tips, and includes a working example. No significant gaps remain given the tool's straightforward nature.

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?

The schema has 0% description coverage, but the description fully compensates by clearly defining both parameters with units (mass in kg, spring_constant in N/m) and providing an example with concrete values. This adds significant meaning beyond the bare schema.

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 explicitly states the tool's purpose with the formula T = 2π√(m/k) and clarifies it calculates the natural oscillation frequency of a spring-mass system. It distinguishes from siblings like calculate_pendulum_period by specifying the physical system involved.

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

Usage Guidelines4/5

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

The description provides clear context by stating it's for ideal springs and amplitude independence, and the 'Tips for LLMs' section offers practical guidance on how mass and stiffness affect results. However, it doesn't explicitly mention when to use this versus alternatives like calculate_damped_oscillation or calculate_simple_harmonic_motion.

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