Skip to main content
Glama

together_expression

Combine rational expressions into a single fraction over a common denominator, simplifying sums of fractions.

Instructions

    Combine rational expressions over a common denominator.

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

    Combines separate fractions into a single fraction.

    Use cases:
    - Combine clearance terms
    - Total bioavailability
    - Multiple dosing routes
    - Fraction addition

    Args:
        expression: Sum of rational expressions
        deep: Apply to subexpressions (default: False)

    Returns:
        Combined expression with LaTeX

    Examples:
        # Simple addition
        together_expression("1/x + 1/y")
        → {"result": "(x + y)/(x*y)", ...}

        # Multiple clearances
        together_expression("CL_renal/V + CL_hepatic/V")
        → {"result": "(CL_renal + CL_hepatic)/V", ...}

        # Complex fractions
        together_expression("1/(x-1) + 1/(x+1)")
        → {"result": "2*x/(x**2 - 1)", ...}

        # PK: Total clearance
        together_expression("Q/V1 + CL/V1")
        → {"result": "(Q + CL)/V1", ...}
    

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
deepNo
expressionYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Behavior4/5

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

No annotations are provided, and the description carries the full burden. It discloses the return format ('Combined expression with LaTeX'), the effect of the deep parameter ('Apply to subexpressions'), and shows multiple input/output examples. It lacks explicit discussion of failure modes (e.g., non-rational input), but for a pure rewriting operation this is largely acceptable.

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

Conciseness3/5

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

The description is well-organized with sections (summary, use cases, args, returns, examples), but it includes promotional text about 'PHASE 1 - NOT IN SYMPY-MCP OR NSFORGE v0.2.3!' and version comparisons that are irrelevant to tool usage. This extra noise detracts from an otherwise efficient layout.

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

Completeness4/5

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

For a tool with two simple parameters and an output schema (not shown but indicated), the description provides thorough guidance: purpose, use cases, parameter semantics, return description, and four illustrative examples. It lacks only edge-case behavior (e.g., handling of already-combined expressions), but that is a minor gap given its simplicity.

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 provides only bare titles and no descriptions, but the description compensates fully: 'expression: Sum of rational expressions' and 'deep: Apply to subexpressions (default: False)' give precise meanings. The examples also map concrete argument values to expected outputs, making parameter usage unambiguous.

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 'Combine rational expressions over a common denominator,' using a specific verb and resource. It also provides distinct examples (e.g., '1/x + 1/y' → '(x + y)/(x*y)') that differentiate it from similar simplification tools like cancel or apart.

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?

A dedicated 'Use cases' section lists concrete scenarios (combine clearance terms, total bioavailability, multiple dosing routes, fraction addition), giving clear context on when to use the tool. It does not explicitly mention when not to use it or alternative tools, but the examples and phrasing sufficiently imply usage.

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