Skip to content

Commit

Permalink
some bugfixes for unionizing update, version bump
Browse files Browse the repository at this point in the history
  • Loading branch information
Christian Merdon committed Feb 21, 2022
1 parent 25bb46e commit 78761c2
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 12 deletions.
2 changes: 1 addition & 1 deletion Project.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name = "ExtendableGrids"
uuid = "cfc395e8-590f-11e8-1f13-43a2532b2fa8"
authors = ["Juergen Fuhrmann <[email protected]>, Christian Merdon <[email protected]>"]
version = "0.9.0"
version = "0.9.1"

[deps]
AbstractTrees = "1520ce14-60c1-5f80-bbc7-55ef81b5835c"
Expand Down
2 changes: 1 addition & 1 deletion src/adaptive_meshrefinements.jl
Original file line number Diff line number Diff line change
Expand Up @@ -206,7 +206,7 @@ function RGB_refine(source_grid::ExtendableGrid{T,K}, facemarkers::Array{Bool,1}
else
xgrid[CellRegions] = xCellRegions
end
xgrid[CellGeometries] = VectorOfConstants{ElementGeometries}(Triangle2D,ncells)
xgrid[CellGeometries] = VectorOfConstants{ElementGeometries,Int}(Triangle2D,ncells)


# determine new boundary faces
Expand Down
13 changes: 4 additions & 9 deletions src/derived.jl
Original file line number Diff line number Diff line change
Expand Up @@ -910,22 +910,17 @@ end
function collectVolumes4Geometries(T::Type{<:Real}, xgrid::ExtendableGrid{Tc,Ti}, ItemType) where {Tc,Ti}
# get links to other stuff
xCoordinates = xgrid[Coordinates]
xCoordinateSystem::Type{<:AbstractCoordinateSystem} = xgrid[CoordinateSystem]
xItemNodes::Adjacency{Ti} = xgrid[GridComponent4TypeProperty(ItemType,PROPERTY_NODES) ]
xCoordinateSystem = xgrid[CoordinateSystem]
xItemNodes = xgrid[GridComponent4TypeProperty(ItemType,PROPERTY_NODES) ]
xGeometries = xgrid[GridComponent4TypeProperty(ItemType,PROPERTY_GEOMETRY) ]
EG = xgrid[GridComponent4TypeProperty(ItemType,PROPERTY_UNIQUEGEOMETRY) ]
nitems::Ti = num_sources(xItemNodes)
nitems = num_sources(xItemNodes)

# init Volumes
xVolumes = zeros(T,nitems)

# loop over items and call handlers
itemEG::ElementGeometries = EG[1]
for item = 1 : nitems
if length(EG) > 1
itemEG = xGeometries[item]
end
xVolumes[item] = volume(xCoordinates, xItemNodes, item, itemEG, xCoordinateSystem)::T
xVolumes[item] = volume(xCoordinates, xItemNodes, item, xGeometries[item], xCoordinateSystem)
end

xVolumes
Expand Down
2 changes: 1 addition & 1 deletion src/shape_specs.jl
Original file line number Diff line number Diff line change
Expand Up @@ -403,7 +403,7 @@ local_celledgenodes(::Type{<:Hexahedron3D}) = _local_celledgenodes_Hexahedron3D
### VOLUMES ###
###############

function volume(Coords, Nodes, item ::Type{<:Vertex0D}, ::Type{<:ExtendableGrids.AbstractCoordinateSystem})
function volume(Coords, Nodes, item, ::Type{<:Vertex0D}, ::Type{<:ExtendableGrids.AbstractCoordinateSystem})
return 1
end

Expand Down

2 comments on commit 78761c2

@chmerdon
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@JuliaRegistrator
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Registration pull request created: JuliaRegistries/General/55093

After the above pull request is merged, it is recommended that a tag is created on this repository for the registered package version.

This will be done automatically if the Julia TagBot GitHub Action is installed, or can be done manually through the github interface, or via:

git tag -a v0.9.1 -m "<description of version>" 78761c2d97317f78fef4c6ab6358ddc41da93a5d
git push origin v0.9.1

Please sign in to comment.