Skip to main content
Glama
eng-toolkit

eng-toolkit

by Lin830326

Fluids Surge

fluids_surge

Calculate water-hammer surge pressures and transient pipe flow with Joukowsky/Michaud estimates or method-of-characteristics simulation, and export reach/location results to CSV.

Instructions

Thin-wall elastic wave speed, Joukowsky surge, Michaud slow-closure estimate and reservoir-pipe-valve MOC CSV. Linear valve-area closure, friction neglected; Courant=1. D/e>=20; <=200 reaches, 20000 steps and 2 million reach-steps. No cavitation/column-separation model.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "fluids_surge"
  }
}

Input Schema

NameRequiredDescriptionDefault
lengthNoReservoir-to-valve pipe length, e.g. '1000 m'; required for estimates and simulation.
densityNoFluid mass density, e.g. '1000 kg/m^3'; all modes; default is a nominal water input, not a property correlation.1000 kg/m^3
reachesNoEqual pipe reaches for MOC, 2..200; default 40; ignored for estimate-only calls.
diameterNoPipe inside diameter, e.g. '0.5 m'; required in all modes.
durationNoMOC simulation duration, e.g. '5 s'; '' returns estimates only; actual final time rounds up by less than one step.
anchoringNoexpansion_joints (c1=1), restrained (1-nu^2), or upstream_anchor (1-nu/2).restrained
locationsNoMOC output positions, e.g. '0 m;500 m'; <=20 records, nearest grid point reported; '' selects 0,L/2,L.
time_stepNoMOC time step, e.g. '0.01 s'; '' uses dx/a; supplied value must satisfy Courant=1 within 1e-8.
bulk_modulusNoFluid bulk modulus, e.g. '2.2 GPa'; required for elastic wave speed.
closure_timeNoTime for linear valve-area closure, e.g. '1 s'; required; '0 s' means instantaneous closure.
poisson_ratioNoPipe-wall Poisson ratio nu, e.g. 0.3; all anchoring cases, 0..0.49.
reservoir_headNoReservoir head above valve outlet, e.g. '100 m'; required for MOC, '' for estimates only; horizontal pipe.
wall_thicknessNoElastic pipe wall thickness, e.g. '10 mm'; required, thickness/diameter<=0.05.
youngs_modulusNoPipe-wall Young's modulus, e.g. '200 GPa'; required for elastic compliance.
initial_velocityNoForward velocity before complete valve closure, e.g. '1 m/s'; required and positive.
dynamic_viscosityNoFluid dynamic viscosity, e.g. '1 mPa*s'; all modes; '' requires kinematic_viscosity instead.1 mPa*s
kinematic_viscosityNoFluid kinematic viscosity, e.g. '1 cSt'; '' omits; supply only when dynamic_viscosity is ''.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.0.1

TDQS

A3.6/5.0
Behavior4/5

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

With no annotations, the description carries the full burden and discloses important model assumptions: linear valve-area closure, neglected friction, Courant=1, D/e>=20, reach/step limits, and no cavitation or column-separation model. It does not describe CSV columns, estimate return values in detail, or error behavior, so it stops short of full behavioral disclosure.

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 dense and front-loaded: it states the computations first, then assumptions and numerical limits. Every clause carries useful information, and there is no filler or repetition.

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 complex 17-parameter simulation tool with no output schema and no annotations, the description supplies key assumptions, numerical constraints, and the main output categories. It still omits mode-selection guidance and detailed return-format information, but it is largely complete for an agent to understand the tool's scope.

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

Parameters3/5

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

Schema description coverage is 100%, and the schema already documents each of the 17 parameters with examples and constraints. The description adds model-level context such as Courant=1 and D/e>=20, but it does not add parameter-specific syntax or interaction details beyond what the schema provides, so the baseline of 3 is appropriate.

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 names specific computations: thin-wall elastic wave speed, Joukowsky surge, Michaud slow-closure estimate, and reservoir-pipe-valve MOC CSV. That is much clearer than a generic fluids tool, but it does not explicitly differentiate this from siblings such as fluids_compressible or fluids_pipe_network.

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 gives no explicit when-to-use or when-not-to-use guidance, and it names no alternatives. The presence of estimate and simulation outputs is implied, but the agent is not told how to choose between modes or when this tool is preferred over related fluids tools.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Deploy Server

Other Tools