Mercurial > repos > public > sbplib_julia
comparison test/Grids/mapped_grid_test.jl @ 1586:d4a6f9effcdd feature/grids/manifolds
Remove mapped_grid(::Chart) and add equidistant_grid(::Chart)
author | Jonatan Werpers <jonatan@werpers.com> |
---|---|
date | Fri, 26 Apr 2024 22:49:01 +0200 |
parents | f77c5309dd2b |
children | 6d196fb85133 |
comparison
equal
deleted
inserted
replaced
1583:2a9ec1e2abad | 1586:d4a6f9effcdd |
---|---|
181 @test mg isa MappedGrid{SVector{2,Float64}, 2} | 181 @test mg isa MappedGrid{SVector{2,Float64}, 2} |
182 | 182 |
183 lg = equidistant_grid((0,0), (1,1), 10, 11) | 183 lg = equidistant_grid((0,0), (1,1), 10, 11) |
184 @test logicalgrid(mg) == lg | 184 @test logicalgrid(mg) == lg |
185 @test collect(mg) == map(x̄, lg) | 185 @test collect(mg) == map(x̄, lg) |
186 | |
187 | |
188 @testset "mapped_grid(::Chart)" begin | |
189 c = Chart(unitsquare()) do (ξ,η) | |
190 @SVector[2ξ, 3η] | |
191 end | |
192 Grids.jacobian(c::typeof(c), ξ̄) = @SMatrix[2 0; 0 3] | |
193 | |
194 @test mapped_grid(c, 5, 4) isa Grid | |
195 end | |
196 | |
197 end | 186 end |