Skip to content

Commit

Permalink
Merge pull request #14 from SciML/patch
Browse files Browse the repository at this point in the history
Patch sys transformation
  • Loading branch information
xtalax authored Jul 19, 2023
2 parents 836e61b + 2e87459 commit 52b3c42
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 3 deletions.
3 changes: 2 additions & 1 deletion Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,8 @@ Symbolics = "5"
julia = "1.6"

[extras]
Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40"
SafeTestsets = "1bc83da4-3b8d-516f-aca4-4fe02f6d838f"

[targets]
test = ["SafeTestsets"]
test = ["SafeTestsets", "Test"]
2 changes: 1 addition & 1 deletion src/interface_defaults.jl
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ check_boundarymap(bmap, v::VariableMap, disc::AbstractDiscretization) = nothing
Boolean function that determines whether a PDESystem should be transformed to
make it compatible with the given discretization.
"""
should_transform(pdesys::PDESystem, disc::AbstractDiscretization) = false
should_transform(pdesys::PDESystem, disc::AbstractDiscretization, boundarymap) = false

"""
transform_pde_system!(v::VariableMap, boundarymap, pdesys::PDESystem, disc::AbstractDiscretization)
Expand Down
2 changes: 1 addition & 1 deletion src/symbolic_discretize.jl
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ function SciMLBase.symbolic_discretize(pdesys::PDESystem, discretization::Abstra
check_boundarymap(boundarymap, v, discretization)

# Transform system so that it is compatible with the discretization
if should_transform(pdesys, discretization)
if should_transform(pdesys, discretization, boundarymap)
pdesys = transform_pde_system!(v, boundarymap, pdesys, discretization)
end

Expand Down

0 comments on commit 52b3c42

Please sign in to comment.