steadfastasart/geoscience-skills/discretize
Claude Code and agent skill by steadfastasart/geoscience-skills
- community
Checking that the SKILL.md file is still in the repository.
Create finite-volume meshes and discrete differential operators with discretize. Use for TensorMesh or TreeMesh geometry, cell/face/edge ordering, divergence, interpolation and meshes supporting SimPEG; use a physics solver for inversion itself.
Install
npx vskill@latest install steadfastasart/geoscience-skills/discretizeSKILL.md
discretize
Construct the mesh and location-aware operators before attaching physical data. The library does not determine the CRS or the physical units of its coordinates.
Choose geometry and data locations
Use TensorMesh for separable rectangular grids; choose TreeMesh when local refinement substantially reduces cost. Finalize a tree before using its operators. Pad model boundaries and refine sources, receivers and property contrasts as required by the forward problem, then test domain and resolution sensitivity.
Record axis meanings, origin, units, cell widths and active-cell mask. In a 2D vertical section the second coordinate can mean elevation, but this is a project convention. A vector of length n_cells is not a face or edge vector.
Divergence with an independent answer
The synthetic velocity field is u = (2x, -3y) per second. Its divergence is -1 s⁻¹, including on this nonuniform mesh. Boundary fluxes are represented at their actual face locations; no zero boundary condition is imposed implicitly.
The rectangular area is 36 m², so the area-integrated divergence and outward boundary flux are both -36 m²/s. In 2D, cell_volumes are cell areas.
Handoffs and checks
- Inspect
cell_centers,faces_x,faces_yand the operator shape. Keep cell,
face, node and edge quantities distinct when interpolating or plotting.
- Cell ordering has the first coordinate varying fastest; reshape cell vectors
with Fortran order when required. Test a spatially varying field, not a uniform array that could hide an ordering error.
- Verify constants/linear fields, conservation and convergence against an
independent analytic case before using a mesh in an inverse problem.
- Preserve inactive/air masks and do not turn NaNs into zero conductivity.
See the operator tutorials and API for the chosen mesh.
Security
- Security scanPassed, 100 of 100Pattern checks on the skill's files.
- Model reviewNot runA model review is scheduled for the next rescan.
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingdiscretize/SKILL.md
Popularity
- 7-day trend score
- 0
Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/steadfastasart/geoscience-skills/discretize)