Repository navigation
Add supported_conditions hook for discretizers to declare BC support - #147
Merged
xtalax merged 2 commits intoOct 28, 2026
Merged
Conversation
The SciMLBase PDE interface asks each discretizer to document its supported geometries and Dirichlet, Neumann, Robin, periodic and interface conditions. supported_conditions(disc) returns a SupportedConditions record so that this lives in one machine-readable place; the default declares nothing (unknown). It is documentation and introspection only and is not called by the pipeline. Agent-Harness: Claude Code 2.1.310 Agent-Model: claude-opus-5-5 Agent-Session: e5d08c60-db9f-4954-946c-272b70ca9edb Agent-Review: unreviewed Co-authored-by: Claude Code <[email protected]>
This was referenced Oct 26, 2026
Merged
Integration only: resolved src/PDEBase.jl by taking the union of the @public/include/export additions of both sides. Agent-Harness: Claude Code 2.1.312 Agent-Model: claude-sonnet-5-5 Agent-Session: a20a681b-e8cc-4c82-a40d-a5b8349014e2 Agent-Review: unreviewed Co-authored-by: Claude Code <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Motivation
The SciMLBase PDE interface asks each discretizer package to document which geometries and boundary-condition classes it supports: Dirichlet, Neumann, Robin, periodic, interface and others. PDEBase is the shared layer under FiniteElementMethod, MethodOfLines and NeuralPDE, so it is the natural home for one machine-readable place where each discretizer declares that support.
What is added
PDEBase.SupportedConditions, an immutable record with a keyword constructor:geometries: a tuple of symbols such as:interval,:boxor:mesh, or of domain types;dirichlet,neumann,robin,periodic,interfaceandtime_dependent: eachtrue,false, ornothingfor not declared;notes: free text.isempty(sc)is true when nothing is declared.show(io, MIME"text/markdown"(), sc)renders the record as a Markdown table for discretizer docs.PDEBase.supported_conditions(disc::AbstractDiscretization)is a developer hook. Its default returnsSupportedConditions(), which means unknown, not "supports nothing". A discretizer declares its support like this:Both names are
@publicin the developer-API list and documented in a new "Supported Conditions" section of the Developer Extension API page.The hook is for documentation and introspection only. PDEBase never calls it during discretization, so existing behaviour is unchanged.
Tests
The new
test/supported_conditions.jlcovers:isempty;geometriesto a tuple;test/public_api.jlchecks that both names are defined, documented and public. Core and QA pass locally.Notes for review
These field names become public API once released, so they deserve the closest look, particularly
time_dependent, and whetherinterfaceshould be split, for example into conservation and continuity interfaces.🤖 Posted by an AI agent · harness: Claude Code 2.1.310 · model: claude-opus-5-5
Review: unreviewed
Session: e5d08c60-db9f-4954-946c-272b70ca9edb