Skip to main content
Glama

laplace_transform_expression

Convert time-domain functions to s-domain using Laplace transform for ODE solving, stability analysis, and transfer functions. Returns F(s) with convergence conditions.

Instructions

    Laplace transform: f(t) → F(s).

    ═══════════════════════════════════════════════════════════════════════
    🆕 PHASE 2 - NOT IN SYMPY-MCP OR NSFORGE v0.2.3!
    ═══════════════════════════════════════════════════════════════════════

    Transforms time-domain functions to s-domain (Laplace domain).

    CRITICAL FOR:
    - ODE solving (time → algebraic in s-domain)
    - Stability analysis (poles in s-plane)
    - Transfer functions (system response)
    - Compartment model analysis

    Args:
        expression: Time-domain expression f(t)
        time_var: Time variable (default: "t")
        freq_var: Frequency variable (default: "s")

    Returns:
        Laplace transform F(s) with convergence conditions

    Examples:
        # Exponential decay
        laplace_transform_expression("exp(-k*t)", "t", "s")
        → {"result": "1/(s + k)", "convergence": "Re(s) > -Re(k)"}

        # Compartment elimination
        laplace_transform_expression("C0*exp(-k*t)", "t", "s")
        → {"result": "C0/(s + k)", ...}

        # Step function response
        laplace_transform_expression("Heaviside(t)", "t", "s")
        → {"result": "1/s", "convergence": "Re(s) > 0"}

        # Dosing with absorption
        laplace_transform_expression("D*ka*exp(-ka*t)", "t", "s")
        → {"result": "D*ka/(s + ka)", ...}

        # PK: Convert ODE to algebra
        # dC/dt + k*C = 0 → s*C(s) - C(0) + k*C(s) = 0
    

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
freq_varNos
time_varNot
expressionYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Behavior4/5

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

With no annotations, the description carries the transparency burden. It describes the output format ('result' and 'convergence') and gives multiple examples illustrating behavior. However, it does not explicitly state that the operation is non-mutating or discuss error handling for invalid expressions, leaving some minor gaps.

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 headings (Args, Returns, Examples) and front-loaded with the core definition. It is somewhat lengthy due to the 'PHASE 2' banner and multiple PK-specific examples, but the additional content is relevant and organized.

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?

The description is comprehensive: it states the mathematical purpose, critical applications, parameter semantics, return format, and several examples. Although an output schema exists, the description supplements it with convergence-condition details and domain-specific context (PK/compartment modeling), making it fully usable.

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 description includes an 'Args' section that explains expression, time_var, and freq_var, including their roles and defaults. Since schema description coverage is 0%, this fully compensates and adds meaning beyond the input 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 opens with 'Laplace transform: f(t) → F(s)' and explicitly states 'Transforms time-domain functions to s-domain (Laplace domain).' This clearly specifies the operation and distinguishes it from inverse or Fourier transforms also present in the sibling tools.

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 lists critical use cases: ODE solving, stability analysis, transfer functions, and compartment model analysis. This provides clear context for when to use the tool, though it does not explicitly mention when not to use it or point to alternatives like inverse_laplace_transform_expression.

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/u9401066/nsforge-mcp'

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