Skip to main content
Glama

estimate_rocket_sizing

Calculate rocket sizing estimates for target altitude and payload mass using propellant type and design margin parameters.

Instructions

Estimate rocket sizing requirements for target altitude and payload.

Args: target_altitude_m: Target altitude in meters payload_mass_kg: Payload mass in kg propellant_type: Propellant type ('solid' or 'liquid') design_margin: Design margin factor

Returns: JSON string with sizing estimates

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
target_altitude_mYes
payload_mass_kgYes
propellant_typeNosolid
design_marginNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Implementation Reference

  • Registers the estimate_rocket_sizing tool with the FastMCP server.
    mcp.tool(estimate_rocket_sizing)
  • The MCP tool handler function for 'estimate_rocket_sizing'. It wraps the core logic from integrations, serializes to JSON, and handles import/errors.
    def estimate_rocket_sizing(
        target_altitude_m: float,
        payload_mass_kg: float,
        propellant_type: Literal["solid", "liquid"] = "solid",
        design_margin: float = 1.2,
    ) -> str:
        """Estimate rocket sizing requirements for target altitude and payload.
    
        Args:
            target_altitude_m: Target altitude in meters
            payload_mass_kg: Payload mass in kg
            propellant_type: Propellant type ('solid' or 'liquid')
            design_margin: Design margin factor
    
        Returns:
            JSON string with sizing estimates
        """
        try:
            from ..integrations.rockets import estimate_rocket_sizing as _sizing
    
            result = _sizing(
                target_altitude_m, payload_mass_kg, propellant_type, design_margin
            )
    
            return json.dumps(result, indent=2)
    
        except ImportError:
            return "Rocket sizing not available - install rocketry packages"
        except Exception as e:
            logger.error(f"Rocket sizing error: {str(e)}", exc_info=True)
            return f"Rocket sizing error: {str(e)}"
  • Core helper function implementing the rocket sizing estimation logic using simplified rocket equation, rule-of-thumb ratios for propellants, and geometric estimates.
    def estimate_rocket_sizing(
        target_altitude_m: float, payload_mass_kg: float, propellant_type: str = "solid"
    ) -> dict[str, Any]:
        """
        Estimate rocket sizing for target altitude and payload.
    
        Args:
            target_altitude_m: Target apogee altitude
            payload_mass_kg: Payload mass
            propellant_type: "solid" or "liquid"
    
        Returns:
            Dictionary with sizing estimates
        """
        # Rule-of-thumb ratios for different propellant types
        if propellant_type == "solid":
            isp_s = 250.0  # Specific impulse
            structural_ratio = 0.15  # Structure mass / propellant mass
            thrust_to_weight = 5.0  # Initial T/W ratio
        elif propellant_type == "liquid":
            isp_s = 300.0
            structural_ratio = 0.12
            thrust_to_weight = 4.0
        else:
            isp_s = 250.0
            structural_ratio = 0.15
            thrust_to_weight = 5.0
    
        # Estimate delta-V requirement (simplified)
        # For vertical flight with gravity and drag losses
        # Basic energy approach: need kinetic + potential energy
        potential_energy_per_kg = 9.80665 * target_altitude_m
        # Add gravity losses (roughly 1.5x theoretical for vertical flight)
        # Add drag losses (roughly 10-20% additional)
        delta_v_req = (
            math.sqrt(2 * potential_energy_per_kg) * 1.8
        )  # Factor accounts for losses
    
        # Rocket equation: delta_v = isp * g0 * ln(m_initial / m_final)
        g0 = 9.80665
        mass_ratio = math.exp(delta_v_req / (isp_s * g0))
    
        # Mass breakdown
        # m_initial = payload + structure + propellant
        # m_final = payload + structure
        # mass_ratio = m_initial / m_final = (payload + structure + propellant) / (payload + structure)
    
        # structure = structural_ratio * propellant
        # Let x = propellant mass
        # mass_ratio = (payload + structural_ratio * x + x) / (payload + structural_ratio * x)
        # mass_ratio * (payload + structural_ratio * x) = payload + structural_ratio * x + x
        # mass_ratio * payload + mass_ratio * structural_ratio * x = payload + structural_ratio * x + x
        # mass_ratio * payload - payload = x * (1 + structural_ratio - mass_ratio * structural_ratio)
        # x = (mass_ratio - 1) * payload / (1 + structural_ratio - mass_ratio * structural_ratio)
    
        denominator = 1 + structural_ratio - mass_ratio * structural_ratio
        if denominator <= 0:
            # Impossible mission - need staging
            propellant_mass = float("inf")
        else:
            propellant_mass = (mass_ratio - 1) * payload_mass_kg / denominator
    
        structure_mass = structural_ratio * propellant_mass
        total_mass = payload_mass_kg + structure_mass + propellant_mass
    
        # Thrust requirement
        thrust_n = thrust_to_weight * total_mass * g0
    
        # Rough geometry estimates
        # Assume cylindrical rocket with L/D = 8-12
        density_propellant = 1600.0  # kg/m³ typical solid propellant
        propellant_volume = propellant_mass / density_propellant
    
        # Assume propellant takes 70% of rocket volume
        total_volume = propellant_volume / 0.7
    
        # L/D ratio of 10
        ld_ratio = 10.0
        # V = π * r² * L = π * (D/2)² * L = π * D² * L / 4
        # L = ld_ratio * D
        # V = π * D² * (ld_ratio * D) / 4 = π * ld_ratio * D³ / 4
        # D³ = 4 * V / (π * ld_ratio)
        diameter = (4 * total_volume / (math.pi * ld_ratio)) ** (1 / 3)
        length = ld_ratio * diameter
    
        return {
            "total_mass_kg": total_mass,
            "propellant_mass_kg": propellant_mass,
            "structure_mass_kg": structure_mass,
            "payload_mass_kg": payload_mass_kg,
            "thrust_n": thrust_n,
            "specific_impulse_s": isp_s,
            "mass_ratio": mass_ratio,
            "delta_v_ms": delta_v_req,
            "diameter_m": diameter,
            "length_m": length,
            "thrust_to_weight": thrust_to_weight,
            "feasible": propellant_mass < float("inf"),
        }
Behavior2/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 mentions the tool 'estimates' requirements, implying a read-only calculation, but doesn't specify if it's deterministic, approximate, or has limitations like accuracy bounds. It also lacks details on rate limits, error handling, or computational requirements, which are critical for a sizing tool.

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 appropriately sized and front-loaded, with the core purpose stated first, followed by a structured breakdown of arguments and returns. Every sentence adds value, and there's no redundant information. A slight deduction for not being maximally concise (e.g., 'Args' and 'Returns' sections could be more integrated).

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

Completeness3/5

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

Given the tool's moderate complexity (4 parameters, no annotations, but with an output schema), the description is somewhat complete. It covers parameter semantics adequately and notes the return format ('JSON string with sizing estimates'), leveraging the output schema. However, it lacks behavioral context like estimation methods or error margins, leaving gaps for an AI agent to infer usage.

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

Parameters4/5

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

The description adds significant meaning beyond the input schema, which has 0% description coverage. It explains each parameter's purpose (e.g., 'target altitude in meters', 'payload mass in kg'), clarifies the propellant_type enum values, and notes the design_margin factor. This compensates well for the schema's lack of descriptions, though it doesn't detail units or constraints beyond basics.

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

Purpose4/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: 'Estimate rocket sizing requirements for target altitude and payload.' It specifies the verb ('estimate') and resource ('rocket sizing requirements'), making the function unambiguous. However, it doesn't differentiate from sibling tools like 'rocket_3dof_trajectory' or 'optimize_thrust_profile', which prevents a perfect score.

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

Usage Guidelines2/5

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

The description provides no guidance on when to use this tool versus alternatives. It doesn't mention sibling tools like 'rocket_3dof_trajectory' for trajectory analysis or 'optimize_thrust_profile' for optimization, nor does it specify prerequisites or exclusions. This leaves the agent with minimal context for tool selection.

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/cheesejaguar/aerospace-mcp'

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