Skip to main content
Glama
IBM

Physics MCP Server

by IBM

create_simulation

Initialize a new rigid-body physics simulation with configurable gravity, timestep, and dimensions using the Rapier engine.

Instructions

Create a new physics simulation using Rapier engine.

Initializes a new rigid-body physics world with configurable gravity and
timestep. Returns a simulation ID used for all subsequent operations.

Args:
    gravity_x: X component of gravity vector (m/s²). Default 0.0
    gravity_y: Y component of gravity vector (m/s²). Default -9.81 (Earth down)
    gravity_z: Z component of gravity vector (m/s²). Default 0.0
    dimensions: 2 or 3 for 2D/3D simulation. Default 3.
    dt: Simulation timestep in seconds. Default 0.016 (60 FPS).
        Smaller = more accurate but slower, larger = faster but less stable
    integrator: Integration method. Options: "euler", "verlet", "rk4". Default "verlet".

Returns:
    SimulationCreateResponse containing:
        - sim_id: Unique simulation identifier (use for all other sim calls)
        - config: Echo of the configuration used

Tips for LLMs:
    - Keep simulation IDs in memory for the conversation session
    - Default gravity is Earth standard (9.81 m/s² down = -Y direction)
    - dt=0.016 ≈ 60 FPS, dt=0.008 ≈ 120 FPS (higher accuracy)
    - "verlet" integrator is good default (stable, energy-conserving)
    - Remember to destroy_simulation when done to free resources

Requires:
    - Rapier provider must be configured (see config.py)
    - Rapier service must be running (see RAPIER_SERVICE.md)

Example:
    # Create simulation with Earth gravity
    sim = await create_simulation(
        gravity_y=-9.81,
        dt=0.016
    )
    # Use sim.sim_id for add_body, step_simulation, etc.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
gravity_xNo
gravity_yNo
gravity_zNo
dimensionsNo
dtNo
integratorNoverlet
Behavior5/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It effectively explains that the tool creates a new simulation, returns a simulation ID for subsequent operations, and includes important behavioral details such as resource management ('destroy_simulation when done to free resources'), performance implications ('Smaller = more accurate but slower'), and default settings. This covers critical aspects like creation, output usage, and cleanup.

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 distinct sections (purpose, args, returns, tips, requires, example) and front-loaded key information. However, it is somewhat lengthy due to detailed parameter explanations and tips, which are necessary but could be slightly condensed. Every sentence earns its place by adding value, but it borders on being verbose.

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 tool with 6 parameters, no annotations, and no output schema, the description is highly complete. It covers purpose, parameters, return values, usage tips, prerequisites, and an example, providing all necessary context for an AI agent to understand and use the tool effectively. The inclusion of behavioral details and practical guidance fills gaps left by the lack of structured data.

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?

Given 0% schema description coverage and 6 parameters, the description compensates fully by detailing each parameter in the 'Args' section with clear semantics, default values, units (e.g., 'm/s²'), and practical advice (e.g., 'dt=0.016 ≈ 60 FPS'). It adds meaning beyond the bare schema, explaining the purpose and effects of each parameter, which is essential for proper tool invocation.

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 specific action ('Create a new physics simulation') and resource ('using Rapier engine'), distinguishing it from siblings like 'destroy_simulation' or 'step_simulation'. It explicitly mentions initialization of a rigid-body physics world with configurable parameters, making the purpose unambiguous and distinct.

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 for when to use this tool (to start a new simulation) and includes prerequisites ('Requires: Rapier provider must be configured...'), but does not explicitly state when not to use it or compare it to alternatives among siblings. The 'Tips for LLMs' section offers practical guidance, though it lacks direct sibling tool comparisons.

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