From 21fec30a56ed11259129e0d6e7fa10f4b5767a4c Mon Sep 17 00:00:00 2001 From: Fredrik Ekre Date: Tue, 29 Oct 2024 15:42:34 +0100 Subject: [PATCH] Manual changes after Runic formatting --- docs/src/literate-gallery/helmholtz.jl | 3 +- docs/src/literate-gallery/landau.jl | 16 +- .../quasi_incompressible_hyperelasticity.jl | 4 +- .../literate-gallery/topology_optimization.jl | 24 +- docs/src/literate-howto/threaded_assembly.jl | 1 + .../computational_homogenization.jl | 36 +- .../src/literate-tutorials/hyperelasticity.jl | 3 +- .../incompressible_elasticity.jl | 3 +- .../literate-tutorials/linear_elasticity.jl | 4 +- docs/src/literate-tutorials/linear_shell.jl | 3 +- docs/src/literate-tutorials/plasticity.jl | 27 +- docs/src/literate-tutorials/porous_media.jl | 3 +- .../literate-tutorials/reactive_surface.jl | 9 +- docs/src/literate-tutorials/stokes-flow.jl | 16 +- docs/src/topics/SimpleCellValues_literate.jl | 21 +- src/Dofs/ConstraintHandler.jl | 17 +- src/Dofs/DofHandler.jl | 13 +- src/Export/VTK.jl | 9 +- src/FEValues/CellValues.jl | 6 +- src/FEValues/FacetValues.jl | 8 +- src/FEValues/FunctionValues.jl | 7 +- src/FEValues/GeometryMapping.jl | 6 +- src/FEValues/InterfaceValues.jl | 10 +- src/FEValues/PointValues.jl | 3 +- src/FEValues/common_values.jl | 26 +- src/Grid/grid.jl | 30 +- src/Grid/grid_generators.jl | 109 +- src/Grid/topology.jl | 6 +- src/L2_projection.jl | 5 +- src/PointEvalHandler.jl | 3 +- src/Quadrature/gaussquad_prism_table.jl | 249 +-- src/Quadrature/gaussquad_pyramid_table.jl | 175 +- src/Quadrature/gaussquad_tet_table.jl | 159 +- src/Quadrature/gaussquad_tri_table.jl | 1639 ++++++++--------- src/Quadrature/quadrature.jl | 6 +- src/assembler.jl | 29 +- src/deprecations.jl | 17 +- src/interpolations.jl | 15 +- src/iterators.jl | 6 +- src/utils.jl | 3 +- 40 files changed, 1360 insertions(+), 1369 deletions(-) diff --git a/docs/src/literate-gallery/helmholtz.jl b/docs/src/literate-gallery/helmholtz.jl index 56837750a0..9d9070411d 100644 --- a/docs/src/literate-gallery/helmholtz.jl +++ b/docs/src/literate-gallery/helmholtz.jl @@ -90,8 +90,7 @@ update!(dbcs, 0.0) K = allocate_matrix(dh); function doassemble( - cellvalues::CellValues, facetvalues::FacetValues, - K::SparseMatrixCSC, dh::DofHandler + cellvalues::CellValues, facetvalues::FacetValues, K::SparseMatrixCSC, dh::DofHandler ) b = 1.0 f = zeros(ndofs(dh)) diff --git a/docs/src/literate-gallery/landau.jl b/docs/src/literate-gallery/landau.jl index d976e96332..30268ab65c 100644 --- a/docs/src/literate-gallery/landau.jl +++ b/docs/src/literate-gallery/landau.jl @@ -32,10 +32,7 @@ using Base.Threads # ### 4th order Landau free energy function Fl(P::Vec{3, T}, α::Vec{3}) where {T} P2 = Vec{3, T}((P[1]^2, P[2]^2, P[3]^2)) - return ( - α[1] * sum(P2) + - α[2] * (P[1]^4 + P[2]^4 + P[3]^4) - ) + + return (α[1] * sum(P2) + α[2] * (P[1]^4 + P[2]^4 + P[3]^4)) + α[3] * ((P2[1] * P2[2] + P2[2] * P2[3]) + P2[1] * P2[3]) end # ### Ginzburg free energy @@ -116,9 +113,10 @@ end # utility to quickly save a model function save_landau(path, model, dofs = model.dofs) - return VTKGridFile(path, model.dofhandler) do vtk + VTKGridFile(path, model.dofhandler) do vtk write_solution(vtk, model.dofhandler, dofs) end + return end # ## Assembly @@ -161,19 +159,21 @@ end # The gradient calculation for each dof function ∇F!(∇f::Vector{T}, dofvector::Vector{T}, model::LandauModel{T}) where {T} fill!(∇f, zero(T)) - return @assemble! begin + @assemble! begin ForwardDiff.gradient!(cache.element_gradient, cache.element_potential, eldofs, cache.gradconf) @inbounds assemble!(∇f, cache.element_indices, cache.element_gradient) end + return end # The Hessian calculation for the whole grid function ∇²F!(∇²f::SparseMatrixCSC, dofvector::Vector{T}, model::LandauModel{T}) where {T} assemblers = [start_assemble(∇²f) for t in 1:nthreads()] - return @assemble! begin + @assemble! begin ForwardDiff.hessian!(cache.element_hessian, cache.element_potential, eldofs, cache.hessconf) @inbounds assemble!(assemblers[threadid()], cache.element_indices, cache.element_hessian) end + return end # We can also calculate all things in one go! @@ -204,7 +204,7 @@ function minimize!(model; kwargs...) end function h!(storage, x) return ∇²F!(storage, x, model) - #apply!(storage, model.boundaryconds) + # apply!(storage, model.boundaryconds) end f(x) = F(x, model) diff --git a/docs/src/literate-gallery/quasi_incompressible_hyperelasticity.jl b/docs/src/literate-gallery/quasi_incompressible_hyperelasticity.jl index 0365282b09..2f19d4ada9 100644 --- a/docs/src/literate-gallery/quasi_incompressible_hyperelasticity.jl +++ b/docs/src/literate-gallery/quasi_incompressible_hyperelasticity.jl @@ -262,8 +262,8 @@ function assemble_global!( ## Loop over all cells in the grid for cell in CellIterator(dh) global_dofs = celldofs(cell) - global_dofsu = global_dofs[1:nu] # first nu dofs are displacement - global_dofsp = global_dofs[(nu + 1):end] # last np dofs are pressure + global_dofsu = global_dofs[1:nu] # first nu dofs are displacement + global_dofsp = global_dofs[(nu + 1):end] # last np dofs are pressure @assert size(global_dofs, 1) == nu + np # sanity check ue = w[global_dofsu] # displacement dofs for the current cell pe = w[global_dofsp] # pressure dofs for the current cell diff --git a/docs/src/literate-gallery/topology_optimization.jl b/docs/src/literate-gallery/topology_optimization.jl index e8c7f6e13c..37e99e00d7 100644 --- a/docs/src/literate-gallery/topology_optimization.jl +++ b/docs/src/literate-gallery/topology_optimization.jl @@ -204,7 +204,7 @@ function cache_neighborhood(dh, topology) i = cellid(element) for j in 1:_nfacets nbg_cellid = getneighborhood(topology, dh.grid, FacetIndex(i, j)) - if (!isempty(nbg_cellid)) + if !isempty(nbg_cellid) nbg[j] = first(nbg_cellid)[1] # assuming only one facet neighbor per cell else # boundary facet nbg[j] = first(getneighborhood(topology, dh.grid, FacetIndex(i, opp[j])))[1] @@ -246,7 +246,7 @@ function compute_χn1(χn, Δχ, ρ, ηs, χ_min) λ_upper = maximum(Δχ) + ηs λ_trial = 0.0 - while (abs(ρ - ρ_trial) > 1.0e-7) + while abs(ρ - ρ_trial) > 1.0e-7 for i in 1:n_el Δχt = 1 / ηs * (Δχ[i] - λ_trial) χ_trial[i] = max(χ_min, min(1.0, χn[i] + Δχt)) @@ -257,9 +257,9 @@ function compute_χn1(χn, Δχ, ρ, ηs, χ_min) ρ_trial += χ_trial[i] / n_el end - if (ρ_trial > ρ) + if ρ_trial > ρ λ_lower = λ_trial - elseif (ρ_trial < ρ) + elseif ρ_trial < ρ λ_upper = λ_trial end λ_trial = 1 / 2 * (λ_upper + λ_lower) @@ -304,7 +304,7 @@ function update_density(dh, states, mp, ρ, neighboorhoods, Δh) χn1 = compute_χn1(χn, Δχ, ρ, mp.η, mp.χ_min) - if (j < n_j) + if j < n_j χn[:] = χn1[:] end end @@ -364,7 +364,7 @@ function elmt!(Ke, re, element, cellvalues, facetvalues, grid, mp, ue, state) symmetrize_lower!(Ke) - return @inbounds for facet in 1:nfacets(getcells(grid, cellid(element))) + @inbounds for facet in 1:nfacets(getcells(grid, cellid(element))) if (cellid(element), facet) ∈ getfacetset(grid, "traction") reinit!(facetvalues, element, facet) t = Vec((0.0, -1.0)) # force pointing downwards @@ -377,7 +377,7 @@ function elmt!(Ke, re, element, cellvalues, facetvalues, grid, mp, ue, state) end end end - + return end function symmetrize_lower!(K) @@ -479,13 +479,13 @@ function topopt(ra, ρ, n, filename; output = :false) ## calculate compliance compliance = 1 / 2 * u' * K * u - if (it == 1) + if it == 1 compliance_0 = compliance end ## check convergence criterium (twice!) - if (abs(compliance - compliance_n) / compliance < tol) - if (conv) + if abs(compliance - compliance_n) / compliance < tol + if conv println("Converged at iteration number: ", it) break else @@ -505,7 +505,7 @@ function topopt(ra, ρ, n, filename; output = :false) compliance_n = compliance ## output during calculation - if (output) + if output i = @sprintf("%3.3i", it) filename_it = string(filename, "_", i) @@ -516,7 +516,7 @@ function topopt(ra, ρ, n, filename; output = :false) end ## export converged results - if (!output) + if !output VTKGridFile(filename, grid) do vtk write_cell_data(vtk, χ, "density") end diff --git a/docs/src/literate-howto/threaded_assembly.jl b/docs/src/literate-howto/threaded_assembly.jl index 48d778f137..3b8f908c26 100644 --- a/docs/src/literate-howto/threaded_assembly.jl +++ b/docs/src/literate-howto/threaded_assembly.jl @@ -72,6 +72,7 @@ function create_example_2d_grid() Ferrite.write_cell_colors(vtk, grid, colors_workstream, "workstream-coloring") Ferrite.write_cell_colors(vtk, grid, colors_greedy, "greedy-coloring") end + return end create_example_2d_grid() diff --git a/docs/src/literate-tutorials/computational_homogenization.jl b/docs/src/literate-tutorials/computational_homogenization.jl index 748e8dbb47..6fb04d3b54 100644 --- a/docs/src/literate-tutorials/computational_homogenization.jl +++ b/docs/src/literate-tutorials/computational_homogenization.jl @@ -458,29 +458,25 @@ end # So we have now already computed all the components, and just need to gather the data in # a fourth order tensor: -E_dirichlet = SymmetricTensor{4, 2}( - (i, j, k, l) -> begin - if k == l == 1 - σ̄.dirichlet[1][i, j] # ∂σ∂ε_**11 - elseif k == l == 2 - σ̄.dirichlet[2][i, j] # ∂σ∂ε_**22 - else - σ̄.dirichlet[3][i, j] # ∂σ∂ε_**12 and ∂σ∂ε_**21 - end +E_dirichlet = SymmetricTensor{4, 2}() do i, j, k, l + if k == l == 1 + σ̄.dirichlet[1][i, j] # ∂σ∂ε_**11 + elseif k == l == 2 + σ̄.dirichlet[2][i, j] # ∂σ∂ε_**22 + else + σ̄.dirichlet[3][i, j] # ∂σ∂ε_**12 and ∂σ∂ε_**21 end -) +end -E_periodic = SymmetricTensor{4, 2}( - (i, j, k, l) -> begin - if k == l == 1 - σ̄.periodic[1][i, j] - elseif k == l == 2 - σ̄.periodic[2][i, j] - else - σ̄.periodic[3][i, j] - end +E_periodic = SymmetricTensor{4, 2}() do i, j, k, l + if k == l == 1 + σ̄.periodic[1][i, j] + elseif k == l == 2 + σ̄.periodic[2][i, j] + else + σ̄.periodic[3][i, j] end -); +end # We can check that the result are what we expect, namely that the stiffness with Dirichlet # boundary conditions is higher than when using periodic boundary conditions, and that diff --git a/docs/src/literate-tutorials/hyperelasticity.jl b/docs/src/literate-tutorials/hyperelasticity.jl index 6bad61a93c..b113f0b71a 100644 --- a/docs/src/literate-tutorials/hyperelasticity.jl +++ b/docs/src/literate-tutorials/hyperelasticity.jl @@ -298,12 +298,13 @@ function assemble_global!(K, g, dh, cv, fv, mp, u, ΓN) assembler = start_assemble(K, g) ## Loop over all cells in the grid - return @timeit "assemble" for cell in CellIterator(dh) + @timeit "assemble" for cell in CellIterator(dh) global_dofs = celldofs(cell) ue = u[global_dofs] # element dofs @timeit "element assemble" assemble_element!(ke, ge, cell, cv, fv, mp, ue, ΓN) assemble!(assembler, global_dofs, ke, ge) end + return end; # Finally, we define a main function which sets up everything and then performs Newton diff --git a/docs/src/literate-tutorials/incompressible_elasticity.jl b/docs/src/literate-tutorials/incompressible_elasticity.jl index 1b29797911..eda174b964 100644 --- a/docs/src/literate-tutorials/incompressible_elasticity.jl +++ b/docs/src/literate-tutorials/incompressible_elasticity.jl @@ -274,7 +274,8 @@ function solve(ν, interpolation_u, interpolation_p) σvM = map(x -> √(3 / 2 * dev(x) ⊡ dev(x)), σ) # von Mise effective stress ## Export the solution and the stress - filename = "cook_" * (interpolation_u == Lagrange{RefTriangle, 1}()^2 ? "linear" : "quadratic") * + filename = "cook_" * + (interpolation_u == Lagrange{RefTriangle, 1}()^2 ? "linear" : "quadratic") * "_linear" VTKGridFile(filename, grid) do vtk diff --git a/docs/src/literate-tutorials/linear_elasticity.jl b/docs/src/literate-tutorials/linear_elasticity.jl index 21f20b4cf6..9a4bce8e39 100644 --- a/docs/src/literate-tutorials/linear_elasticity.jl +++ b/docs/src/literate-tutorials/linear_elasticity.jl @@ -358,8 +358,8 @@ colors = [ #hide "1" => 1, "5" => 1, # purple #hide "2" => 2, "3" => 2, # red #hide "4" => 3, # blue #hide - "6" => 4, # green #hide -] #hide + "6" => 4, # green #hide +] #hide for (key, color) in colors #hide for i in getcellset(grid, key) #hide color_data[i] = color #hide diff --git a/docs/src/literate-tutorials/linear_shell.jl b/docs/src/literate-tutorials/linear_shell.jl index fa79b387bd..446b4c8232 100644 --- a/docs/src/literate-tutorials/linear_shell.jl +++ b/docs/src/literate-tutorials/linear_shell.jl @@ -154,7 +154,8 @@ function fiber_coordsys(Ps::Vector{Vec{3, Float64}}) a = abs.(P) j = 1 if a[1] > a[3] - a[3] = a[1]; j = 2 + a[3] = a[1] + j = 2 end if a[2] > a[3] j = 3 diff --git a/docs/src/literate-tutorials/plasticity.jl b/docs/src/literate-tutorials/plasticity.jl index 1db9851516..b1e4cbf60d 100644 --- a/docs/src/literate-tutorials/plasticity.jl +++ b/docs/src/literate-tutorials/plasticity.jl @@ -100,7 +100,7 @@ function compute_stress_tangent(ϵ::SymmetricTensor{2, 3}, material::J2Plasticit σᵗ = material.Dᵉ ⊡ (ϵ - state.ϵᵖ) # trial-stress sᵗ = dev(σᵗ) # deviatoric part of trial-stress J₂ = 0.5 * sᵗ ⊡ sᵗ # second invariant of sᵗ - σᵗₑ = sqrt(3.0 * J₂) # effective trial-stress (von Mises stress) + σᵗₑ = sqrt(3.0 * J₂) # effective trial-stress (von Mises stress) σʸ = material.σ₀ + H * state.k # Previous yield limit φᵗ = σᵗₑ - σʸ # Trial-value of the yield surface @@ -109,7 +109,7 @@ function compute_stress_tangent(ϵ::SymmetricTensor{2, 3}, material::J2Plasticit return σᵗ, material.Dᵉ, MaterialState(state.ϵᵖ, σᵗ, state.k) else # plastic loading h = H + 3G - μ = φᵗ / h # plastic multiplier + μ = φᵗ / h # plastic multiplier c1 = 1 - 3G * μ / σᵗₑ s = c1 * sᵗ # updated deviatoric stress @@ -129,8 +129,8 @@ function compute_stress_tangent(ϵ::SymmetricTensor{2, 3}, material::J2Plasticit ## Return new state Δϵᵖ = 3 / 2 * μ / σₑ * s # plastic strain - ϵᵖ = state.ϵᵖ + Δϵᵖ # plastic strain - k = state.k + μ # hardening variable + ϵᵖ = state.ϵᵖ + Δϵᵖ # plastic strain + k = state.k + μ # hardening variable return σ, D, MaterialState(ϵᵖ, σ, k) end end @@ -200,10 +200,7 @@ end #md # Due to symmetry, we only compute the lower half of the tangent #md # and then symmetrize it. #md # -function assemble_cell!( - Ke, re, cell, cellvalues, material, - ue, state, state_old - ) +function assemble_cell!(Ke, re, cell, cellvalues, material, ue, state, state_old) n_basefuncs = getnbasefunctions(cellvalues) reinit!(cellvalues, cell) @@ -222,7 +219,8 @@ function assemble_cell!( end end end - return symmetrize_lower!(Ke) + symmetrize_lower!(Ke) + return end # Helper function to symmetrize the material tangent @@ -257,10 +255,10 @@ end # Define a function which solves the FE-problem. function solve() ## Define material parameters - E = 200.0e9 # [Pa] + E = 200.0e9 # [Pa] H = E / 20 # [Pa] - ν = 0.3 # [-] - σ₀ = 200.0e6 # [Pa] + ν = 0.3 # [-] + σ₀ = 200.0e6 # [Pa] material = J2Plasticity(E, ν, σ₀, H) L = 10.0 # beam length [m] @@ -285,10 +283,10 @@ function solve() ## Pre-allocate solution vectors, etc. n_dofs = ndofs(dh) # total number of dofs - u = zeros(n_dofs) # solution vector + u = zeros(n_dofs) # solution vector Δu = zeros(n_dofs) # displacement correction r = zeros(n_dofs) # residual - K = allocate_matrix(dh) # tangent stiffness matrix + K = allocate_matrix(dh) # tangent stiffness matrix ## Create material states. One array for each cell, where each element is an array of material- ## states - one for each integration point @@ -310,7 +308,6 @@ function solve() while true newton_itr += 1 - if newton_itr > 8 error("Reached maximum Newton iterations, aborting") break diff --git a/docs/src/literate-tutorials/porous_media.jl b/docs/src/literate-tutorials/porous_media.jl index 1c51e70401..71c0837d62 100644 --- a/docs/src/literate-tutorials/porous_media.jl +++ b/docs/src/literate-tutorials/porous_media.jl @@ -359,7 +359,8 @@ function solve(dh, ch, domains; Δt = 0.025, t_total = 1.0) pvd[t] = vtk end end - return vtk_save(pvd) + vtk_save(pvd) + return end; # Finally we call the functions to actually run the code diff --git a/docs/src/literate-tutorials/reactive_surface.jl b/docs/src/literate-tutorials/reactive_surface.jl index eb0c96fd82..723c50a756 100644 --- a/docs/src/literate-tutorials/reactive_surface.jl +++ b/docs/src/literate-tutorials/reactive_surface.jl @@ -202,7 +202,8 @@ function setup_initial_conditions!(u₀::Vector, cellvalues::CellValues, dh::Dof end end - return u₀ .+= 0.01 * rand(ndofs(dh)) + u₀ .+= 0.01 * rand(ndofs(dh)) + return end; # ### Mesh generation @@ -227,7 +228,7 @@ function create_embedded_sphere(refinements) nodes = tonodes() elements, _ = toelements(2) gmsh.finalize() - return grid = Grid(elements, nodes) + return Grid(elements, nodes) end # ### Simulation routines @@ -312,8 +313,8 @@ function gray_scott_on_sphere(material::GrayScottMaterial, Δt::Real, T::Real, r ## Finally we totate the solution to initialize the next timestep. uₜ₋₁ .= uₜ end - - return vtk_save(pvd) + vtk_save(pvd) + return end ## This parametrization gives the spot pattern shown in the gif above. diff --git a/docs/src/literate-tutorials/stokes-flow.jl b/docs/src/literate-tutorials/stokes-flow.jl index a19a873981..b88baa3a4a 100644 --- a/docs/src/literate-tutorials/stokes-flow.jl +++ b/docs/src/literate-tutorials/stokes-flow.jl @@ -444,7 +444,7 @@ function check_mean_constraint(dh, fvp, u) #src range_p = dof_range(dh, :p) #src cc = CellCache(dh) #src ## Loop over all the boundaries and compute the integrated pressure #src - ∫pdΓ, Γ = 0.0, 0.0 #src + ∫pdΓ, Γ = 0.0, 0.0 #src for (ci, fi) in set #src reinit!(cc, ci) #src reinit!(fvp, cc, fi) #src @@ -452,10 +452,11 @@ function check_mean_constraint(dh, fvp, u) #src for qp in 1:getnquadpoints(fvp) #src dΓ = getdetJdV(fvp, qp) #src ∫pdΓ += function_value(fvp, qp, ue, range_p) * dΓ #src - Γ += dΓ #src + Γ += dΓ #src end #src end #src - return @test ∫pdΓ / Γ ≈ 0.0 atol = 1.0e-16 #src + @test ∫pdΓ / Γ ≈ 0.0 atol = 1.0e-16 #src + return #src end #src function check_L2(dh, cvu, cvp, u) #src @@ -473,11 +474,12 @@ function check_L2(dh, cvu, cvp, u) #src ph = function_value(cvp, qp, ue, range_p) #src ∫uudΩ += (uh ⋅ uh) * dΩ #src ∫ppdΩ += (ph * ph) * dΩ #src - Ω += dΩ #src + Ω += dΩ #src end #src end #src - @test √(∫uudΩ) / Ω ≈ 0.0007255988117907926 atol = 1.0e-7 #src - return @test √(∫ppdΩ) / Ω ≈ 0.02169683180923709 atol = 1.0e-5 #src + @test √(∫uudΩ) / Ω ≈ 0.0007255988117907926 atol = 1.0e-7 #src + @test √(∫ppdΩ) / Ω ≈ 0.02169683180923709 atol = 1.0e-5 #src + return #src end #src function main() @@ -486,7 +488,7 @@ function main() grid = setup_grid(h) ## Interpolations ipu = Lagrange{RefTriangle, 2}()^2 # quadratic - ipp = Lagrange{RefTriangle, 1}() # linear + ipp = Lagrange{RefTriangle, 1}() # linear ## Dofs dh = setup_dofs(grid, ipu, ipp) ## FE values diff --git a/docs/src/topics/SimpleCellValues_literate.jl b/docs/src/topics/SimpleCellValues_literate.jl index 763ce43e70..1395e6aadf 100644 --- a/docs/src/topics/SimpleCellValues_literate.jl +++ b/docs/src/topics/SimpleCellValues_literate.jl @@ -7,17 +7,24 @@ using Ferrite, Test # * The cell shape has the same dimension as the physical space (excludes so-called embedded cells). struct SimpleCellValues{T, dim} <: Ferrite.AbstractCellValues - N::Matrix{T} # Precalculated shape values, N[i, q_point] where i is the + ## Precalculated shape values, N[i, q_point] where i is the ## shape function number and q_point the integration point - dNdξ::Matrix{Vec{dim, T}} # Precalculated shape gradients in the reference domain, dNdξ[i, q_point] - dNdx::Matrix{Vec{dim, T}} # Cache for shape gradients in the physical domain, dNdx[i, q_point] - M::Matrix{T} # Precalculated geometric shape values, M[j, q_point] where j is the + N::Matrix{T} + ## Precalculated shape gradients in the reference domain, dNdξ[i, q_point] + dNdξ::Matrix{Vec{dim, T}} + ## Cache for shape gradients in the physical domain, dNdx[i, q_point] + dNdx::Matrix{Vec{dim, T}} + ## Precalculated geometric shape values, M[j, q_point] where j is the ## geometric shape function number - dMdξ::Matrix{Vec{dim, T}} # Precalculated geometric shape gradients, dMdξ[j, q_point] - weights::Vector{T} # Given quadrature weights in the reference domain, weights[q_point] - detJdV::Vector{T} # Cache for quadrature weights in the physical domain, detJdV[q_point], i.e. + M::Matrix{T} + ## Precalculated geometric shape gradients, dMdξ[j, q_point] + dMdξ::Matrix{Vec{dim, T}} + ## Given quadrature weights in the reference domain, weights[q_point] + weights::Vector{T} + ## Cache for quadrature weights in the physical domain, detJdV[q_point], i.e. ## det(J)*weight[q_point], where J is the jacobian of the geometric mapping ## at the quadrature point, q_point. + detJdV::Vector{T} end; # Next, we create a constructor with the same input as `CellValues` diff --git a/src/Dofs/ConstraintHandler.jl b/src/Dofs/ConstraintHandler.jl index 03acf2090f..d3d16212f2 100644 --- a/src/Dofs/ConstraintHandler.jl +++ b/src/Dofs/ConstraintHandler.jl @@ -155,7 +155,7 @@ function apply_rhs!(data::RHSData, f::AbstractVector, ch::ConstraintHandler, app end end end - return @inbounds for (i, pdof) in pairs(ch.prescribed_dofs) + @inbounds for (i, pdof) in pairs(ch.prescribed_dofs) dofcoef = ch.dofcoefficients[i] b = ch.inhomogeneities[i] if dofcoef !== nothing # if affine constraint @@ -166,11 +166,12 @@ function apply_rhs!(data::RHSData, f::AbstractVector, ch::ConstraintHandler, app bz = applyzero ? zero(eltype(f)) : b f[pdof] = bz * m end + return end function Base.show(io::IO, ::MIME"text/plain", ch::ConstraintHandler) println(io, "ConstraintHandler:") - return if !isclosed(ch) + if !isclosed(ch) print(io, " Not closed!") else print(io, " BCs:") @@ -178,6 +179,7 @@ function Base.show(io::IO, ::MIME"text/plain", ch::ConstraintHandler) print(io, "\n ", "Field: ", dbc.field_name, ", ", "Components: ", dbc.components) end end + return end isclosed(ch::ConstraintHandler) = ch.closed @@ -269,7 +271,8 @@ function add!(ch::ConstraintHandler, ac::AffineConstraint) # TODO: Would be nice to pass nothing if ac.entries is empty, but then we lose the fact # that this constraint is an AffineConstraint which is currently needed in update! # in order to not update inhomogeneities for affine constraints - return add_prescribed_dof!(ch, ac.constrained_dof, ac.b, #=isempty(ac.entries) ? nothing : =# ac.entries) + add_prescribed_dof!(ch, ac.constrained_dof, ac.b, #=isempty(ac.entries) ? nothing : =# ac.entries) + return ch end """ @@ -653,7 +656,7 @@ function apply!(KK::Union{SparseMatrixCSC, Symmetric}, f::AbstractVector, ch::Co zero_out_rows!(K, ch.dofmapping) # Add meandiag to constraint dofs - return @inbounds for i in 1:length(ch.inhomogeneities) + @inbounds for i in 1:length(ch.inhomogeneities) d = ch.prescribed_dofs[i] K[d, d] = m if length(f) != 0 @@ -661,6 +664,7 @@ function apply!(KK::Union{SparseMatrixCSC, Symmetric}, f::AbstractVector, ch::Co f[d] = vz * m end end + return end # Fetch dof coefficients for a dof prescribed by an affine constraint. Return nothing if the @@ -739,6 +743,8 @@ function _add_or_grow(cnt::Int, I::Vector{Int}, J::Vector{Int}, dofi::Int, dofj: end I[cnt] = dofi return J[cnt] = dofj + J[cnt] = dofj + return end """ @@ -794,11 +800,12 @@ end function zero_out_rows!(K, dofmapping) rowval = K.rowval nzval = K.nzval - return @inbounds for i in eachindex(rowval, nzval) + @inbounds for i in eachindex(rowval, nzval) if haskey(dofmapping, rowval[i]) nzval[i] = 0 end end + return end function meandiag(K::AbstractMatrix) diff --git a/src/Dofs/DofHandler.jl b/src/Dofs/DofHandler.jl index 5e926277c1..a89ffef1cb 100644 --- a/src/Dofs/DofHandler.jl +++ b/src/Dofs/DofHandler.jl @@ -78,7 +78,8 @@ end function Base.show(io::IO, mime::MIME"text/plain", sdh::SubDofHandler) println(io, typeof(sdh)) println(io, " Cell type: ", getcelltype(sdh)) - return _print_field_information(io, mime, sdh) + _print_field_information(io, mime, sdh) + return end function _print_field_information(io::IO, mime::MIME"text/plain", sdh::SubDofHandler) @@ -86,11 +87,12 @@ function _print_field_information(io::IO, mime::MIME"text/plain", sdh::SubDofHan for (i, fieldname) in pairs(sdh.field_names) println(io, " ", repr(mime, fieldname), ", ", repr(mime, sdh.field_interpolations[i])) end - return if !isclosed(sdh.dh) + if !isclosed(sdh.dh) print(io, " Not closed!") else println(io, " Dofs per cell: ", ndofs_per_cell(sdh)) end + return end mutable struct DofHandler{dim, G <: AbstractGrid{dim}} <: AbstractDofHandler @@ -151,11 +153,12 @@ function Base.show(io::IO, mime::MIME"text/plain", dh::DofHandler) println(io, " ", repr(fieldname), ", ", field_type) end end - return if !isclosed(dh) + if !isclosed(dh) print(io, " Not closed!") else print(io, " Total dofs: ", ndofs(dh)) end + return end isclosed(dh::AbstractDofHandler) = dh.closed @@ -659,7 +662,7 @@ if the edge is flipped. """ function sortedge(edge::Tuple{Int, Int}) a, b = edge - return a < b ? (return (edge, PathOrientationInfo(true))) : (return ((b, a), PathOrientationInfo(false))) + return a < b ? (edge, PathOrientationInfo(true)) : ((b, a), PathOrientationInfo(false)) end """ @@ -670,7 +673,7 @@ Here the unique representation is the sorted node index tuple. """ function sortedge_fast(edge::Tuple{Int, Int}) a, b = edge - return a < b ? (return edge) : (return (b, a)) + return a < b ? edge : (b, a) end """ diff --git a/src/Export/VTK.jl b/src/Export/VTK.jl index debf7c283e..840817fd4b 100644 --- a/src/Export/VTK.jl +++ b/src/Export/VTK.jl @@ -54,7 +54,8 @@ end function Base.show(io::IO, ::MIME"text/plain", vtk::VTKGridFile) open_str = isopen(vtk.vtk) ? "open" : "closed" filename = vtk.vtk.path - return print(io, "VTKGridFile for the $open_str file \"$(filename)\".") + print(io, "VTKGridFile for the $open_str file \"$(filename)\".") + return end function WriteVTK.collection_add_timestep(pvd::WriteVTK.CollectionFile, datfile::VTKGridFile, time::Real) @@ -129,10 +130,12 @@ function create_vtk_grid(filename::AbstractString, grid::Grid{dim, C, T}; kwargs end function toparaview!(v, x::Vec{D}) where {D} - return v[1:D] .= x + v[1:D] .= x + return v end function toparaview!(v, x::SecondOrderTensor) - return tovoigt!(v, x) + tovoigt!(v, x) + return v end function _vtk_write_node_data( diff --git a/src/FEValues/CellValues.jl b/src/FEValues/CellValues.jl index cbea37fb90..9f7583c1ab 100644 --- a/src/FEValues/CellValues.jl +++ b/src/FEValues/CellValues.jl @@ -96,7 +96,8 @@ getnquadpoints(cv::CellValues) = getnquadpoints(cv.qr) @inline function _update_detJdV!(detJvec::AbstractVector, q_point::Int, w, mapping) detJ = calculate_detJ(getjacobian(mapping)) detJ > 0.0 || throw_detJ_not_pos(detJ) - return @inbounds detJvec[q_point] = detJ * w + @inbounds detJvec[q_point] = detJ * w + return end @inline _update_detJdV!(::Nothing, q_point, w, mapping) = nothing @@ -136,5 +137,6 @@ function Base.show(io::IO, d::MIME"text/plain", cv::CellValues) print(io, getnquadpoints(cv), " quadrature points") print(io, "\n Function interpolation: "); show(io, d, ip_fun) print(io, "\nGeometric interpolation: ") - return sdim === nothing ? show(io, d, ip_geo) : show(io, d, ip_geo^sdim) + sdim === nothing ? show(io, d, ip_geo) : show(io, d, ip_geo^sdim) + return end diff --git a/src/FEValues/FacetValues.jl b/src/FEValues/FacetValues.jl index 5c28a6c158..43c9860cc3 100644 --- a/src/FEValues/FacetValues.jl +++ b/src/FEValues/FacetValues.jl @@ -116,7 +116,8 @@ function set_current_facet!(fv::FacetValues, face_nr::Int) # Checking face_nr before setting current_facet allows us to use @inbounds # when indexing by getcurrentfacet(fv) in other places! checkbounds(Bool, 1:nfacets(fv), face_nr) || throw(ArgumentError("Face index out of range.")) - return fv.current_facet = face_nr + fv.current_facet = face_nr + return end @inline function reinit!(fv::FacetValues, x::AbstractVector, face_nr::Int) @@ -138,7 +139,7 @@ function reinit!(fv::FacetValues, cell::Union{AbstractCell, Nothing}, x::Abstrac throw(ArgumentError("The cell::AbstractCell input is required to reinit! non-identity function mappings")) end - return @inbounds for (q_point, w) in pairs(getweights(fv.fqr, face_nr)) + @inbounds for (q_point, w) in pairs(getweights(fv.fqr, face_nr)) mapping = calculate_mapping(geo_mapping, q_point, x) J = getjacobian(mapping) # See the `Ferrite.embedding_det` docstring for more background @@ -149,6 +150,7 @@ function reinit!(fv::FacetValues, cell::Union{AbstractCell, Nothing}, x::Abstrac @inbounds fv.normals[q_point] = weight_norm / norm(weight_norm) apply_mapping!(fun_values, q_point, mapping, cell) end + return end function Base.show(io::IO, d::MIME"text/plain", fv::FacetValues) @@ -168,6 +170,8 @@ function Base.show(io::IO, d::MIME"text/plain", fv::FacetValues) print(io, " Function interpolation: "); show(io, d, function_interpolation(fv)) print(io, "\nGeometric interpolation: ") return sdim === nothing ? show(io, d, ip_geo) : show(io, d, ip_geo^sdim) + sdim === nothing ? show(io, d, ip_geo) : show(io, d, ip_geo^sdim) + return end """ diff --git a/src/FEValues/FunctionValues.jl b/src/FEValues/FunctionValues.jl index 224d7612c3..006b365789 100644 --- a/src/FEValues/FunctionValues.jl +++ b/src/FEValues/FunctionValues.jl @@ -5,14 +5,14 @@ # vdim = vector dimension (dimension of the field) # ################################################################# -# Scalar, sdim == rdim sdim rdim +# Scalar, sdim == rdim sdim rdim typeof_N(::Type{T}, ::ScalarInterpolation, ::VectorizedInterpolation{dim, <:AbstractRefShape{dim}}) where {T, dim} = T typeof_dNdx(::Type{T}, ::ScalarInterpolation, ::VectorizedInterpolation{dim, <:AbstractRefShape{dim}}) where {T, dim} = Vec{dim, T} typeof_dNdξ(::Type{T}, ::ScalarInterpolation, ::VectorizedInterpolation{dim, <:AbstractRefShape{dim}}) where {T, dim} = Vec{dim, T} typeof_d2Ndx2(::Type{T}, ::ScalarInterpolation, ::VectorizedInterpolation{dim, <:AbstractRefShape{dim}}) where {T, dim} = Tensor{2, dim, T} typeof_d2Ndξ2(::Type{T}, ::ScalarInterpolation, ::VectorizedInterpolation{dim, <:AbstractRefShape{dim}}) where {T, dim} = Tensor{2, dim, T} -# Vector, vdim == sdim == rdim vdim sdim rdim +# Vector, vdim == sdim == rdim vdim sdim rdim typeof_N(::Type{T}, ::VectorInterpolation{dim}, ::VectorizedInterpolation{dim, <:AbstractRefShape{dim}}) where {T, dim} = Vec{dim, T} typeof_dNdx(::Type{T}, ::VectorInterpolation{dim}, ::VectorizedInterpolation{dim, <:AbstractRefShape{dim}}) where {T, dim} = Tensor{2, dim, T} typeof_dNdξ(::Type{T}, ::VectorInterpolation{dim}, ::VectorizedInterpolation{dim, <:AbstractRefShape{dim}}) where {T, dim} = Tensor{2, dim, T} @@ -132,7 +132,8 @@ sdim_from_gradtype(::Type{<:SMatrix{<:Any, sdim}}) where {sdim} = sdim # For performance, these must be fully inferable for the compiler. # args: valname (:CellValues or :FacetValues), shape_gradient_type, eltype(x) function check_reinit_sdim_consistency(valname, gradtype::Type, ::Type{<:Vec{sdim}}) where {sdim} - return check_reinit_sdim_consistency(valname, Val(sdim_from_gradtype(gradtype)), Val(sdim)) + check_reinit_sdim_consistency(valname, Val(sdim_from_gradtype(gradtype)), Val(sdim)) + return end check_reinit_sdim_consistency(_, ::Nothing, ::Type{<:Vec}) = nothing # gradient not stored, cannot check check_reinit_sdim_consistency(_, ::Val{sdim}, ::Val{sdim}) where {sdim} = nothing diff --git a/src/FEValues/GeometryMapping.jl b/src/FEValues/GeometryMapping.jl index 0fcc05fce2..85aed2d45a 100644 --- a/src/FEValues/GeometryMapping.jl +++ b/src/FEValues/GeometryMapping.jl @@ -34,8 +34,7 @@ struct GeometryMapping{DiffOrder, IP, M_t, dMdξ_t, d2Mdξ2_t} ip::IP # ::Interpolation Geometric interpolation M::M_t # ::AbstractMatrix{<:Number} Values of geometric shape functions dMdξ::dMdξ_t # ::AbstractMatrix{<:Vec} Gradients of geometric shape functions in ref-domain - d2Mdξ2::d2Mdξ2_t # ::AbstractMatrix{<:Tensor{2}} Hessians of geometric shape functions in ref-domain - # ::Nothing (dMdξ or d2Mdξ2 if not required) + d2Mdξ2::d2Mdξ2_t # ::Union{AbstractMatrix{<:Tensor{2}}, Nothing} Hessians of geometric shape functions in ref-domain function GeometryMapping( ip::IP, M::M_t, ::Nothing, ::Nothing ) where {IP <: ScalarInterpolation, M_t <: AbstractMatrix{<:Number}} @@ -48,8 +47,7 @@ struct GeometryMapping{DiffOrder, IP, M_t, dMdξ_t, d2Mdξ2_t} end function GeometryMapping( ip::IP, M::M_t, dMdξ::dMdξ_t, d2Mdξ2::d2Mdξ2_t - ) where - { + ) where { IP <: ScalarInterpolation, M_t <: AbstractMatrix{<:Number}, dMdξ_t <: AbstractMatrix{<:Vec}, d2Mdξ2_t <: AbstractMatrix{<:Tensor{2}}, } diff --git a/src/FEValues/InterfaceValues.jl b/src/FEValues/InterfaceValues.jl index 4375a17507..8866811aa4 100644 --- a/src/FEValues/InterfaceValues.jl +++ b/src/FEValues/InterfaceValues.jl @@ -317,10 +317,7 @@ multiply by minus the outward facing normal to the first element's side of the i """ function function_gradient_jump end -for (func,) in ( - (:function_value,), - (:function_gradient,), - ) +for func in (:function_value, :function_gradient) @eval begin function $(func)( iv::InterfaceValues, q_point::Int, u::AbstractVector; @@ -430,7 +427,7 @@ function InterfaceOrientationInfo(cell_a::AbstractCell{RefShapeA}, cell_b::Abstr end function InterfaceOrientationInfo(_::AbstractCell{RefShapeA}, _::AbstractCell{RefShapeB}, _::Int, _::Int) where {RefShapeA <: AbstractRefShape{1}, RefShapeB <: AbstractRefShape{1}} - return (error("1D elements don't use transformations for interfaces.")) + error("1D elements don't use transformations for interfaces.") end """ @@ -581,5 +578,6 @@ function Base.show(io::IO, m::MIME"text/plain", iv::InterfaceValues) show(io, m, iv.here) println(io) print(io, "{There} ") - return show(io, m, iv.there) + show(io, m, iv.there) + return end diff --git a/src/FEValues/PointValues.jl b/src/FEValues/PointValues.jl index ed9c1e7930..84645697d8 100644 --- a/src/FEValues/PointValues.jl +++ b/src/FEValues/PointValues.jl @@ -77,5 +77,6 @@ end function Base.show(io::IO, d::MIME"text/plain", cv::PointValues) println(io, "PointValues containing a") - return show(io, d, cv.cv) + show(io, d, cv.cv) + return end diff --git a/src/FEValues/common_values.jl b/src/FEValues/common_values.jl index dba3aed88f..a2cd905bbe 100644 --- a/src/FEValues/common_values.jl +++ b/src/FEValues/common_values.jl @@ -10,23 +10,17 @@ function checkquadpoint(fe_v::AbstractValues, qp::Int) end @noinline function throw_incompatible_dof_length(length_ue, n_base_funcs) - throw( - ArgumentError( - "the number of base functions ($(n_base_funcs)) does not match the length " * - "of the vector ($(length_ue)). Perhaps you passed the global vector, " * - "or forgot to pass a dof_range?" - ) - ) + msg = "the number of base functions ($(n_base_funcs)) does not match the length " * + "of the vector ($(length_ue)). Perhaps you passed the global vector, " * + "or forgot to pass a dof_range?" + throw(ArgumentError(msg)) end @noinline function throw_incompatible_coord_length(length_x, n_base_funcs) - throw( - ArgumentError( - "the number of (geometric) base functions ($(n_base_funcs)) does not match " * - "the number of coordinates in the vector ($(length_x)). Perhaps you forgot to " * - "use an appropriate geometric interpolation when creating FE values? See " * - "https://github.com/Ferrite-FEM/Ferrite.jl/issues/265 for more details." - ) - ) + msg = "the number of (geometric) base functions ($(n_base_funcs)) does not match " * + "the number of coordinates in the vector ($(length_x)). Perhaps you forgot to " * + "use an appropriate geometric interpolation when creating FE values? See " * + "https://github.com/Ferrite-FEM/Ferrite.jl/issues/265 for more details." + throw(ArgumentError(msg)) end """ @@ -139,7 +133,7 @@ function shape_curl(cv::AbstractValues, q_point::Int, base_func::Int) return curl_from_gradient(shape_gradient(cv, q_point, base_func)) end curl_from_gradient(∇v::SecondOrderTensor{3}) = Vec{3}((∇v[3, 2] - ∇v[2, 3], ∇v[1, 3] - ∇v[3, 1], ∇v[2, 1] - ∇v[1, 2])) -curl_from_gradient(∇v::SecondOrderTensor{2}) = Vec{1}((∇v[2, 1] - ∇v[1, 2],)) # Alternatively define as Vec{3}((0,0,v)) +curl_from_gradient(∇v::SecondOrderTensor{2}) = Vec{1}((∇v[2, 1] - ∇v[1, 2],)) # Alternatively define as Vec{3}((0, 0, v)) """ function_value(fe_v::AbstractValues, q_point::Int, u::AbstractVector, [dof_range]) diff --git a/src/Grid/grid.jl b/src/Grid/grid.jl index 501d5714a6..3d27431bd1 100644 --- a/src/Grid/grid.jl +++ b/src/Grid/grid.jl @@ -218,14 +218,14 @@ reference_vertices(::Type{RefHexahedron}) = (1, 2, 3, 4, 5, 6, 7, 8) function reference_edges(::Type{RefHexahedron}) return ( (1, 2), (2, 3), (3, 4), (4, 1), (5, 6), (6, 7), # e1 ... e6 - (7, 8), (8, 5), (1, 5), (2, 6), (3, 7), (4, 8), - ) # e7 ... e12 + (7, 8), (8, 5), (1, 5), (2, 6), (3, 7), (4, 8), # e7 ... e12 + ) end function reference_faces(::Type{RefHexahedron}) return ( (1, 4, 3, 2), (1, 2, 6, 5), (2, 3, 7, 6), # f1, f2, f3 - (3, 4, 8, 7), (1, 5, 8, 4), (5, 6, 7, 8), - ) # f4, f5, f6 + (3, 4, 8, 7), (1, 5, 8, 4), (5, 6, 7, 8), # f4, f5, f6 + ) end # RefPrism (refdim = 3) @@ -233,14 +233,14 @@ reference_vertices(::Type{RefPrism}) = (1, 2, 3, 4, 5, 6) function reference_edges(::Type{RefPrism}) return ( (2, 1), (1, 3), (1, 4), (3, 2), (2, 5), # e1, e2, e3, e4, e5 - (3, 6), (4, 5), (4, 6), (6, 5), - ) # e6, e7, e8, e9 + (3, 6), (4, 5), (4, 6), (6, 5), # e6, e7, e8, e9 + ) end function reference_faces(::Type{RefPrism}) return ( (1, 3, 2), (1, 2, 5, 4), (3, 1, 4, 6), # f1, f2, f3 - (2, 3, 6, 5), (4, 5, 6), - ) # f4, f5 + (2, 3, 6, 5), (4, 5, 6), # f4, f5 + ) end # RefPyramid (refdim = 3) @@ -248,14 +248,14 @@ reference_vertices(::Type{RefPyramid}) = (1, 2, 3, 4, 5) function reference_edges(::Type{RefPyramid}) return ( (1, 2), (1, 3), (1, 5), (2, 4), # e1 ... e4 - (2, 5), (4, 3), (3, 5), (4, 5), - ) # e5 ... e8 + (2, 5), (4, 3), (3, 5), (4, 5), # e5 ... e8 + ) end function reference_faces(::Type{RefPyramid}) return ( (1, 3, 4, 2), (1, 2, 5), (1, 5, 3), # f1, f2, f3 - (2, 4, 5), (3, 5, 4), - ) # f4, f5 + (2, 4, 5), (3, 5, 4), # f4, f5 + ) end ###################################################### @@ -606,7 +606,8 @@ get_node_coordinate(grid, n) = get_node_coordinate(getnodes(grid, n)) function cellnodes!(global_nodes::Vector{Int}, grid::AbstractGrid, i::Int) cell = getcells(grid, i) - return _cellnodes!(global_nodes, cell) + _cellnodes!(global_nodes, cell) + return global_nodes end function _cellnodes!(global_nodes::Vector{Int}, cell::AbstractCell) @assert length(global_nodes) == nnodes(cell) @@ -624,7 +625,8 @@ function Base.show(io::IO, ::MIME"text/plain", grid::Grid) typestrs = sort!(repr.(OrderedSet(typeof(x) for x in grid.cells))) end join(io, typestrs, '/') - return print(io, " cells and $(getnnodes(grid)) nodes") + print(io, " cells and $(getnnodes(grid)) nodes") + return end """ diff --git a/src/Grid/grid_generators.jl b/src/Grid/grid_generators.jl index 5dde0a48f9..1b47c7ef50 100644 --- a/src/Grid/grid_generators.jl +++ b/src/Grid/grid_generators.jl @@ -28,12 +28,10 @@ function generate_grid(::Type{Line}, nel::NTuple{1, Int}, left::Vec{1, T} = Vec{ # Cell faces - boundary = Vector( - [ - FacetIndex(1, 1), - FacetIndex(nel_x, 2), - ] - ) + boundary = [ + FacetIndex(1, 1), + FacetIndex(nel_x, 2), + ] # Cell face sets facetsets = Dict( @@ -162,15 +160,14 @@ function generate_grid(::Type{QuadraticQuadrilateral}, nel::NTuple{2, Int}, LL:: node_array = reshape(collect(1:n_nodes), (n_nodes_x, n_nodes_y)) cells = QuadraticQuadrilateral[] for j in 1:nel_y, i in 1:nel_x - push!( - cells, QuadraticQuadrilateral( - ( - node_array[2 * i - 1, 2 * j - 1], node_array[2 * i + 1, 2 * j - 1], node_array[2 * i + 1, 2 * j + 1], node_array[2 * i - 1, 2 * j + 1], - node_array[2 * i, 2 * j - 1], node_array[2 * i + 1, 2 * j], node_array[2 * i, 2 * j + 1], node_array[2 * i - 1, 2 * j], - node_array[2 * i, 2 * j], - ) + cell = QuadraticQuadrilateral( + ( + node_array[2 * i - 1, 2 * j - 1], node_array[2 * i + 1, 2 * j - 1], node_array[2 * i + 1, 2 * j + 1], node_array[2 * i - 1, 2 * j + 1], + node_array[2 * i, 2 * j - 1], node_array[2 * i + 1, 2 * j], node_array[2 * i, 2 * j + 1], node_array[2 * i - 1, 2 * j], + node_array[2 * i, 2 * j], ) ) + push!(cells, cell) end # Cell faces @@ -213,14 +210,13 @@ function generate_grid(::Type{Hexahedron}, nel::NTuple{3, Int}, left::Vec{3, T} node_array = reshape(collect(1:n_nodes), (n_nodes_x, n_nodes_y, n_nodes_z)) cells = Hexahedron[] for k in 1:nel_z, j in 1:nel_y, i in 1:nel_x - push!( - cells, Hexahedron( - ( - node_array[i, j, k], node_array[i + 1, j, k], node_array[i + 1, j + 1, k], node_array[i, j + 1, k], - node_array[i, j, k + 1], node_array[i + 1, j, k + 1], node_array[i + 1, j + 1, k + 1], node_array[i, j + 1, k + 1], - ) + cell = Hexahedron( + ( + node_array[i, j, k], node_array[i + 1, j, k], node_array[i + 1, j + 1, k], node_array[i, j + 1, k], + node_array[i, j, k + 1], node_array[i + 1, j, k + 1], node_array[i + 1, j + 1, k + 1], node_array[i, j + 1, k + 1], ) ) + push!(cells, cell) end # Cell faces @@ -267,22 +263,22 @@ function generate_grid(::Type{Wedge}, nel::NTuple{3, Int}, left::Vec{3, T} = Vec node_array = reshape(collect(1:n_nodes), (n_nodes_x, n_nodes_y, n_nodes_z)) cells = Wedge[] for k in 1:nel_z, j in 1:nel_y, i in 1:nel_x - push!( - cells, Wedge( - ( - node_array[i, j, k], node_array[i + 1, j, k], node_array[i, j + 1, k], - node_array[i, j, k + 1], node_array[i + 1, j, k + 1], node_array[i, j + 1, k + 1], - ) + # ◺ + wedge1 = Wedge( + ( + node_array[i, j, k], node_array[i + 1, j, k], node_array[i, j + 1, k], + node_array[i, j, k + 1], node_array[i + 1, j, k + 1], node_array[i, j + 1, k + 1], ) - ) # ◺ - push!( - cells, Wedge( - ( - node_array[i + 1, j, k], node_array[i + 1, j + 1, k], node_array[i, j + 1, k], - node_array[i + 1, j, k + 1], node_array[i + 1, j + 1, k + 1], node_array[i, j + 1, k + 1], - ) + ) + push!(cells, wedge1) + # ◹ + wedge2 = Wedge( + ( + node_array[i + 1, j, k], node_array[i + 1, j + 1, k], node_array[i, j + 1, k], + node_array[i + 1, j, k + 1], node_array[i + 1, j + 1, k + 1], node_array[i, j + 1, k + 1], ) - ) # ◹ + ) + push!(cells, wedge2) end # Order the cells as c_nxyz[2, x, y, z] such that we can look up boundary cells @@ -395,17 +391,16 @@ function generate_grid(::Type{SerendipityQuadraticHexahedron}, nel::NTuple{3, In # Generate cells cells = SerendipityQuadraticHexahedron[] for k in 1:2:2nel_z, j in 1:2:2nel_y, i in 1:2:2nel_x - push!( - cells, SerendipityQuadraticHexahedron( - ( - node_array[i, j, k], node_array[i + 2, j, k], node_array[i + 2, j + 2, k], node_array[i, j + 2, k], # vertices bot - node_array[i, j, k + 2], node_array[i + 2, j, k + 2], node_array[i + 2, j + 2, k + 2], node_array[i, j + 2, k + 2], # vertices top - node_array[i + 1, j, k], node_array[i + 2, j + 1, k], node_array[i + 1, j + 2, k], node_array[i, j + 1, k], # edges horizontal bottom - node_array[i + 1, j, k + 2], node_array[i + 2, j + 1, k + 2], node_array[i + 1, j + 2, k + 2], node_array[i, j + 1, k + 2], # edges horizontal top - node_array[i, j, k + 1], node_array[i + 2, j, k + 1], node_array[i + 2, j + 2, k + 1], node_array[i, j + 2, k + 1], - ) - ) # edges vertical + cell = SerendipityQuadraticHexahedron( + ( + node_array[i, j, k], node_array[i + 2, j, k], node_array[i + 2, j + 2, k], node_array[i, j + 2, k], # vertices bot + node_array[i, j, k + 2], node_array[i + 2, j, k + 2], node_array[i + 2, j + 2, k + 2], node_array[i, j + 2, k + 2], # vertices top + node_array[i + 1, j, k], node_array[i + 2, j + 1, k], node_array[i + 1, j + 2, k], node_array[i, j + 1, k], # edges horizontal bottom + node_array[i + 1, j, k + 2], node_array[i + 2, j + 1, k + 2], node_array[i + 1, j + 2, k + 2], node_array[i, j + 1, k + 2], # edges horizontal top + node_array[i, j, k + 1], node_array[i + 2, j, k + 1], node_array[i + 2, j + 2, k + 1], node_array[i, j + 2, k + 1], # edges vertical + ) ) + push!(cells, cell) end # Cell faces @@ -486,22 +481,22 @@ function generate_grid(::Type{QuadraticTriangle}, nel::NTuple{2, Int}, LL::Vec{2 node_array = reshape(collect(1:n_nodes), (n_nodes_x, n_nodes_y)) cells = QuadraticTriangle[] for j in 1:nel_y, i in 1:nel_x - push!( - cells, QuadraticTriangle( - ( - node_array[2 * i - 1, 2 * j - 1], node_array[2 * i + 1, 2 * j - 1], node_array[2 * i - 1, 2 * j + 1], - node_array[2 * i, 2 * j - 1], node_array[2 * i, 2 * j], node_array[2 * i - 1, 2 * j], - ) + # ◺ + triangle1 = QuadraticTriangle( + ( + node_array[2 * i - 1, 2 * j - 1], node_array[2 * i + 1, 2 * j - 1], node_array[2 * i - 1, 2 * j + 1], + node_array[2 * i, 2 * j - 1], node_array[2 * i, 2 * j], node_array[2 * i - 1, 2 * j], ) - ) # ◺ - push!( - cells, QuadraticTriangle( - ( - node_array[2 * i + 1, 2 * j - 1], node_array[2 * i + 1, 2 * j + 1], node_array[2 * i - 1, 2 * j + 1], - node_array[2 * i + 1, 2 * j], node_array[2 * i, 2 * j + 1], node_array[2 * i, 2 * j], - ) + ) + push!(cells, triangle1) + # ◹ + triangle2 = QuadraticTriangle( + ( + node_array[2 * i + 1, 2 * j - 1], node_array[2 * i + 1, 2 * j + 1], node_array[2 * i - 1, 2 * j + 1], + node_array[2 * i + 1, 2 * j], node_array[2 * i, 2 * j + 1], node_array[2 * i, 2 * j], ) - ) # ◹ + ) + push!(cells, triangle2) end # Cell faces diff --git a/src/Grid/topology.jl b/src/Grid/topology.jl index de95dbb368..e70023e2ab 100644 --- a/src/Grid/topology.jl +++ b/src/Grid/topology.jl @@ -79,11 +79,9 @@ function ExclusiveTopology(grid::AbstractGrid{sdim}) where {sdim} num_shared_vertices = _num_shared_vertices(cell, neighbor_cell) if num_shared_vertices == 1 _add_single_vertex_neighbor!(vertex_vertex_neighbor_buf, cell, cell_id, neighbor_cell, neighbor_cell_id) - # Shared edge - elseif num_shared_vertices == 2 + elseif num_shared_vertices == 2 # Shared edge _add_single_edge_neighbor!(edge_edge_neighbor_buf, cell, cell_id, neighbor_cell, neighbor_cell_id) - # Shared face - elseif num_shared_vertices >= 3 + elseif num_shared_vertices >= 3 # Shared face _add_single_face_neighbor!(face_face_neighbor_buf, cell, cell_id, neighbor_cell, neighbor_cell_id) else error("Found connected elements without shared vertex... Mesh broken?") diff --git a/src/L2_projection.jl b/src/L2_projection.jl index 61255c3434..2083a2bce7 100644 --- a/src/L2_projection.jl +++ b/src/L2_projection.jl @@ -253,8 +253,9 @@ function project(p::L2Projector, vars::AbstractMatrix, args...) return project(p, collect(eachcol(vars)), args...) end -function _project(proj::L2Projector, vars::Union{AbstractVector{TC}, AbstractDict{Int, TC}}, qrs_rhs::Vector{<:QuadratureRule}) where - {TC <: AbstractVector{T}} where {T <: Union{Number, AbstractTensor}} +function _project(proj::L2Projector, vars::Union{AbstractVector{TC}, AbstractDict{Int, TC}}, qrs_rhs::Vector{<:QuadratureRule}) where { + T <: Union{Number, AbstractTensor}, TC <: AbstractVector{T}, + } # Sanity checks for user input isclosed(proj) || error("The L2Projector is not closed") diff --git a/src/PointEvalHandler.jl b/src/PointEvalHandler.jl index 968fcdffa3..496cbc4e88 100644 --- a/src/PointEvalHandler.jl +++ b/src/PointEvalHandler.jl @@ -39,11 +39,12 @@ function Base.show(io::IO, ::MIME"text/plain", ph::PointEvalHandler) println(io, typeof(ph)) println(io, " number of points: ", length(ph.local_coords)) n_missing = sum(x -> x === nothing, ph.cells) - return if n_missing == 0 + if n_missing == 0 print(io, " Found corresponding cell for all points.") else print(io, " Could not find corresponding cell for ", n_missing, " points.") end + return end # Internals: diff --git a/src/Quadrature/gaussquad_prism_table.jl b/src/Quadrature/gaussquad_prism_table.jl index 741a0afec6..6479cdcf77 100644 --- a/src/Quadrature/gaussquad_prism_table.jl +++ b/src/Quadrature/gaussquad_prism_table.jl @@ -1,3 +1,4 @@ +# runic: off # Symmetric quadrature rules takes from # Witherden, Freddie D., and Peter E. Vincent. "On the identification of # symmetric quadrature rules for finite element methods." Computers & @@ -5,13 +6,13 @@ # Note that the original rule is defined on [-1,1]^3 while our reference prism is defined on [0,1]^3, hence we transform in the end. function _get_gauss_prismdata_polyquad(n::Int) if n == 1 - return reshape([1 / 3 1 / 3 1 / 2 1 / 2], (1, 4)) + return reshape([1/3 1/3 1/2 1/2], (1,4)) elseif n == 2 xw = [ -0.33333333333333333333333333333333333333 -0.33333333333333333333333333333333333333 -0.99999999999999985119303811076522004183 0.66666666666666686507594918564641756458 -0.33333333333333333333333333333333333333 -0.33333333333333333333333333333333333333 0.99999999999999985119303811076522004183 0.66666666666666686507594918564641756458 -0.74158162379719638007464124598498266439 0.48316324759439276014928249196996532878 0 0.88888888888888875661603387623572162361 - 0.48316324759439276014928249196996532878 -0.74158162379719638007464124598498266439 0 0.88888888888888875661603387623572162361 + 0.48316324759439276014928249196996532878 -0.74158162379719638007464124598498266439 0 0.88888888888888875661603387623572162361 -0.74158162379719638007464124598498266439 -0.74158162379719638007464124598498266439 0 0.88888888888888875661603387623572162361 ] elseif n == 3 @@ -19,9 +20,9 @@ function _get_gauss_prismdata_polyquad(n::Int) -0.33333333333333333333333333333333333333 -0.33333333333333333333333333333333333333 -0.86066920446477793249332885107223920359 0.89998695257960196814387903509173005101 -0.33333333333333333333333333333333333333 -0.33333333333333333333333333333333333333 0.86066920446477793249332885107223920359 0.89998695257960196814387903509173005101 -0.52223312808684327863699399822724711768 0.52222829574978345631488370728601281383 0 0.366671015806799343952040321636089983 - 0.52222829574978345631488370728601281383 -0.52223312808684327863699399822724711768 0 0.366671015806799343952040321636089983 + 0.52222829574978345631488370728601281383 -0.52223312808684327863699399822724711768 0 0.366671015806799343952040321636089983 -0.99999516766294017767788970905876569615 0.52222829574978345631488370728601281383 0 0.366671015806799343952040321636089983 - 0.52222829574978345631488370728601281383 -0.99999516766294017767788970905876569615 0 0.366671015806799343952040321636089983 + 0.52222829574978345631488370728601281383 -0.99999516766294017767788970905876569615 0 0.366671015806799343952040321636089983 -0.99999516766294017767788970905876569615 -0.52223312808684327863699399822724711768 0 0.366671015806799343952040321636089983 -0.52223312808684327863699399822724711768 -0.99999516766294017767788970905876569615 0 0.366671015806799343952040321636089983 ] @@ -29,34 +30,34 @@ function _get_gauss_prismdata_polyquad(n::Int) xw = [ -0.33333333333333333333333333333333333333 -0.33333333333333333333333333333333333333 -0.86686197400903479841583223937151297546 0.43164789926214201915560571539043719684 -0.33333333333333333333333333333333333333 -0.33333333333333333333333333333333333333 0.86686197400903479841583223937151297546 0.43164789926214201915560571539043719684 - -0.062688380276009575455822705856210492672 -0.87462323944798084908835458828757901466 0 0.54565845042191057226153838655080393041 + -0.062688380276009575455822705856210492672 -0.87462323944798084908835458828757901466 0 0.54565845042191057226153838655080393041 -0.87462323944798084908835458828757901466 -0.062688380276009575455822705856210492672 0 0.54565845042191057226153838655080393041 - -0.062688380276009575455822705856210492672 -0.062688380276009575455822705856210492672 0 0.54565845042191057226153838655080393041 + -0.062688380276009575455822705856210492672 -0.062688380276009575455822705856210492672 0 0.54565845042191057226153838655080393041 -0.79851918840217872745314255427215462609 0.59703837680435745490628510854430925218 -0.67563982368225971739661759355428029031 0.24995480836833070748402890159445230251 - 0.59703837680435745490628510854430925218 -0.79851918840217872745314255427215462609 -0.67563982368225971739661759355428029031 0.24995480836833070748402890159445230251 + 0.59703837680435745490628510854430925218 -0.79851918840217872745314255427215462609 -0.67563982368225971739661759355428029031 0.24995480836833070748402890159445230251 -0.79851918840217872745314255427215462609 -0.79851918840217872745314255427215462609 -0.67563982368225971739661759355428029031 0.24995480836833070748402890159445230251 -0.79851918840217872745314255427215462609 0.59703837680435745490628510854430925218 0.67563982368225971739661759355428029031 0.24995480836833070748402890159445230251 - 0.59703837680435745490628510854430925218 -0.79851918840217872745314255427215462609 0.67563982368225971739661759355428029031 0.24995480836833070748402890159445230251 + 0.59703837680435745490628510854430925218 -0.79851918840217872745314255427215462609 0.67563982368225971739661759355428029031 0.24995480836833070748402890159445230251 -0.79851918840217872745314255427215462609 -0.79851918840217872745314255427215462609 0.67563982368225971739661759355428029031 0.24995480836833070748402890159445230251 ] elseif n == 5 xw = [ -0.33333333333333333333333333333333333333 -0.33333333333333333333333333333333333333 0 0.71145555593148684996197343022099556338 -0.025400070899508667767082370124706051859 -0.94919985820098266446583525975058789628 0 0.22471006722826685202639587426081419504 - -0.94919985820098266446583525975058789628 -0.025400070899508667767082370124706051859 0 0.22471006722826685202639587426081419504 + -0.94919985820098266446583525975058789628 -0.025400070899508667767082370124706051859 0 0.22471006722826685202639587426081419504 -0.025400070899508667767082370124706051859 -0.025400070899508667767082370124706051859 0 0.22471006722826685202639587426081419504 - -0.10880379065925599247444934872713650457 -0.78239241868148801505110130254572699087 -0.8710029348654440527292590830738210619 0.18566142131615813987257487985503458339 - -0.78239241868148801505110130254572699087 -0.10880379065925599247444934872713650457 -0.8710029348654440527292590830738210619 0.18566142131615813987257487985503458339 - -0.10880379065925599247444934872713650457 -0.10880379065925599247444934872713650457 -0.8710029348654440527292590830738210619 0.18566142131615813987257487985503458339 - -0.10880379065925599247444934872713650457 -0.78239241868148801505110130254572699087 0.8710029348654440527292590830738210619 0.18566142131615813987257487985503458339 - -0.78239241868148801505110130254572699087 -0.10880379065925599247444934872713650457 0.8710029348654440527292590830738210619 0.18566142131615813987257487985503458339 - -0.10880379065925599247444934872713650457 -0.10880379065925599247444934872713650457 0.8710029348654440527292590830738210619 0.18566142131615813987257487985503458339 - -0.79828210803458293816870337538129563058 0.59656421606916587633740675076259126116 -0.57042698070515927206196786842334325646 0.25007428574779395912056494464439239186 - 0.59656421606916587633740675076259126116 -0.79828210803458293816870337538129563058 -0.57042698070515927206196786842334325646 0.25007428574779395912056494464439239186 - -0.79828210803458293816870337538129563058 -0.79828210803458293816870337538129563058 -0.57042698070515927206196786842334325646 0.25007428574779395912056494464439239186 - -0.79828210803458293816870337538129563058 0.59656421606916587633740675076259126116 0.57042698070515927206196786842334325646 0.25007428574779395912056494464439239186 - 0.59656421606916587633740675076259126116 -0.79828210803458293816870337538129563058 0.57042698070515927206196786842334325646 0.25007428574779395912056494464439239186 - -0.79828210803458293816870337538129563058 -0.79828210803458293816870337538129563058 0.57042698070515927206196786842334325646 0.25007428574779395912056494464439239186 + -0.10880379065925599247444934872713650457 -0.78239241868148801505110130254572699087 -0.8710029348654440527292590830738210619 0.18566142131615813987257487985503458339 + -0.78239241868148801505110130254572699087 -0.10880379065925599247444934872713650457 -0.8710029348654440527292590830738210619 0.18566142131615813987257487985503458339 + -0.10880379065925599247444934872713650457 -0.10880379065925599247444934872713650457 -0.8710029348654440527292590830738210619 0.18566142131615813987257487985503458339 + -0.10880379065925599247444934872713650457 -0.78239241868148801505110130254572699087 0.8710029348654440527292590830738210619 0.18566142131615813987257487985503458339 + -0.78239241868148801505110130254572699087 -0.10880379065925599247444934872713650457 0.8710029348654440527292590830738210619 0.18566142131615813987257487985503458339 + -0.10880379065925599247444934872713650457 -0.10880379065925599247444934872713650457 0.8710029348654440527292590830738210619 0.18566142131615813987257487985503458339 + -0.79828210803458293816870337538129563058 0.59656421606916587633740675076259126116 -0.57042698070515927206196786842334325646 0.25007428574779395912056494464439239186 + 0.59656421606916587633740675076259126116 -0.79828210803458293816870337538129563058 -0.57042698070515927206196786842334325646 0.25007428574779395912056494464439239186 + -0.79828210803458293816870337538129563058 -0.79828210803458293816870337538129563058 -0.57042698070515927206196786842334325646 0.25007428574779395912056494464439239186 + -0.79828210803458293816870337538129563058 0.59656421606916587633740675076259126116 0.57042698070515927206196786842334325646 0.25007428574779395912056494464439239186 + 0.59656421606916587633740675076259126116 -0.79828210803458293816870337538129563058 0.57042698070515927206196786842334325646 0.25007428574779395912056494464439239186 + -0.79828210803458293816870337538129563058 -0.79828210803458293816870337538129563058 0.57042698070515927206196786842334325646 0.25007428574779395912056494464439239186 ] elseif n == 6 xw = [ @@ -65,27 +66,27 @@ function _get_gauss_prismdata_polyquad(n::Int) -0.33333333333333333333333333333333333333 -0.33333333333333333333333333333333333333 -0.99083630081924474869286718300205167763 0.13839610937412451172575590081432159364 -0.33333333333333333333333333333333333333 -0.33333333333333333333333333333333333333 0.99083630081924474869286718300205167763 0.13839610937412451172575590081432159364 -0.66959346994381506531292392577889361708 0.33918693988763013062584785155778723416 0 0.31182801481333532900066338577135735737 - 0.33918693988763013062584785155778723416 -0.66959346994381506531292392577889361708 0 0.31182801481333532900066338577135735737 + 0.33918693988763013062584785155778723416 -0.66959346994381506531292392577889361708 0 0.31182801481333532900066338577135735737 -0.66959346994381506531292392577889361708 -0.66959346994381506531292392577889361708 0 0.31182801481333532900066338577135735737 -0.95905346077548616195214584157965381704 0.91810692155097232390429168315930763408 0 0.050146535238696554002545078611329875622 - 0.91810692155097232390429168315930763408 -0.95905346077548616195214584157965381704 0 0.050146535238696554002545078611329875622 + 0.91810692155097232390429168315930763408 -0.95905346077548616195214584157965381704 0 0.050146535238696554002545078611329875622 -0.95905346077548616195214584157965381704 -0.95905346077548616195214584157965381704 0 0.050146535238696554002545078611329875622 - -0.067776668819680981202280000599855057023 -0.86444666236063803759543999880028988595 -0.48167413488438751267079566597126764678 0.19605056020608216687021916179149498019 + -0.067776668819680981202280000599855057023 -0.86444666236063803759543999880028988595 -0.48167413488438751267079566597126764678 0.19605056020608216687021916179149498019 -0.86444666236063803759543999880028988595 -0.067776668819680981202280000599855057023 -0.48167413488438751267079566597126764678 0.19605056020608216687021916179149498019 - -0.067776668819680981202280000599855057023 -0.067776668819680981202280000599855057023 -0.48167413488438751267079566597126764678 0.19605056020608216687021916179149498019 - -0.067776668819680981202280000599855057023 -0.86444666236063803759543999880028988595 0.48167413488438751267079566597126764678 0.19605056020608216687021916179149498019 + -0.067776668819680981202280000599855057023 -0.067776668819680981202280000599855057023 -0.48167413488438751267079566597126764678 0.19605056020608216687021916179149498019 + -0.067776668819680981202280000599855057023 -0.86444666236063803759543999880028988595 0.48167413488438751267079566597126764678 0.19605056020608216687021916179149498019 -0.86444666236063803759543999880028988595 -0.067776668819680981202280000599855057023 0.48167413488438751267079566597126764678 0.19605056020608216687021916179149498019 - -0.067776668819680981202280000599855057023 -0.067776668819680981202280000599855057023 0.48167413488438751267079566597126764678 0.19605056020608216687021916179149498019 + -0.067776668819680981202280000599855057023 -0.067776668819680981202280000599855057023 0.48167413488438751267079566597126764678 0.19605056020608216687021916179149498019 -0.59485220654953844609181984939099585377 0.52549348166744454603903998678937679713 -0.80928579325583275231645432806703865787 0.084632875139559356776397936558477141722 - 0.52549348166744454603903998678937679713 -0.59485220654953844609181984939099585377 -0.80928579325583275231645432806703865787 0.084632875139559356776397936558477141722 + 0.52549348166744454603903998678937679713 -0.59485220654953844609181984939099585377 -0.80928579325583275231645432806703865787 0.084632875139559356776397936558477141722 -0.93064127511790609994722013739838094335 0.52549348166744454603903998678937679713 -0.80928579325583275231645432806703865787 0.084632875139559356776397936558477141722 - 0.52549348166744454603903998678937679713 -0.93064127511790609994722013739838094335 -0.80928579325583275231645432806703865787 0.084632875139559356776397936558477141722 + 0.52549348166744454603903998678937679713 -0.93064127511790609994722013739838094335 -0.80928579325583275231645432806703865787 0.084632875139559356776397936558477141722 -0.93064127511790609994722013739838094335 -0.59485220654953844609181984939099585377 -0.80928579325583275231645432806703865787 0.084632875139559356776397936558477141722 -0.59485220654953844609181984939099585377 -0.93064127511790609994722013739838094335 -0.80928579325583275231645432806703865787 0.084632875139559356776397936558477141722 -0.59485220654953844609181984939099585377 0.52549348166744454603903998678937679713 0.80928579325583275231645432806703865787 0.084632875139559356776397936558477141722 - 0.52549348166744454603903998678937679713 -0.59485220654953844609181984939099585377 0.80928579325583275231645432806703865787 0.084632875139559356776397936558477141722 + 0.52549348166744454603903998678937679713 -0.59485220654953844609181984939099585377 0.80928579325583275231645432806703865787 0.084632875139559356776397936558477141722 -0.93064127511790609994722013739838094335 0.52549348166744454603903998678937679713 0.80928579325583275231645432806703865787 0.084632875139559356776397936558477141722 - 0.52549348166744454603903998678937679713 -0.93064127511790609994722013739838094335 0.80928579325583275231645432806703865787 0.084632875139559356776397936558477141722 + 0.52549348166744454603903998678937679713 -0.93064127511790609994722013739838094335 0.80928579325583275231645432806703865787 0.084632875139559356776397936558477141722 -0.93064127511790609994722013739838094335 -0.59485220654953844609181984939099585377 0.80928579325583275231645432806703865787 0.084632875139559356776397936558477141722 -0.59485220654953844609181984939099585377 -0.93064127511790609994722013739838094335 0.80928579325583275231645432806703865787 0.084632875139559356776397936558477141722 ] @@ -94,24 +95,24 @@ function _get_gauss_prismdata_polyquad(n::Int) -0.33333333333333333333333333333333333333 -0.33333333333333333333333333333333333333 -0.98022806959089160171504882914128008603 0.11378272445075715563392222208600913026 -0.33333333333333333333333333333333333333 -0.33333333333333333333333333333333333333 0.98022806959089160171504882914128008603 0.11378272445075715563392222208600913026 -0.98332480906795705560590831565479581293 0.96664961813591411121181663130959162585 0 0.024472968692380158977782543188506640362 - 0.96664961813591411121181663130959162585 -0.98332480906795705560590831565479581293 0 0.024472968692380158977782543188506640362 + 0.96664961813591411121181663130959162585 -0.98332480906795705560590831565479581293 0 0.024472968692380158977782543188506640362 -0.98332480906795705560590831565479581293 -0.98332480906795705560590831565479581293 0 0.024472968692380158977782543188506640362 - -0.036956049341726798726440754485546402356 -0.92608790131654640254711849102890719529 -0.84138735420652599295096060100359489758 0.086203456344905850875965416526967283444 + -0.036956049341726798726440754485546402356 -0.92608790131654640254711849102890719529 -0.84138735420652599295096060100359489758 0.086203456344905850875965416526967283444 -0.92608790131654640254711849102890719529 -0.036956049341726798726440754485546402356 -0.84138735420652599295096060100359489758 0.086203456344905850875965416526967283444 - -0.036956049341726798726440754485546402356 -0.036956049341726798726440754485546402356 -0.84138735420652599295096060100359489758 0.086203456344905850875965416526967283444 - -0.036956049341726798726440754485546402356 -0.92608790131654640254711849102890719529 0.84138735420652599295096060100359489758 0.086203456344905850875965416526967283444 + -0.036956049341726798726440754485546402356 -0.036956049341726798726440754485546402356 -0.84138735420652599295096060100359489758 0.086203456344905850875965416526967283444 + -0.036956049341726798726440754485546402356 -0.92608790131654640254711849102890719529 0.84138735420652599295096060100359489758 0.086203456344905850875965416526967283444 -0.92608790131654640254711849102890719529 -0.036956049341726798726440754485546402356 0.84138735420652599295096060100359489758 0.086203456344905850875965416526967283444 - -0.036956049341726798726440754485546402356 -0.036956049341726798726440754485546402356 0.84138735420652599295096060100359489758 0.086203456344905850875965416526967283444 + -0.036956049341726798726440754485546402356 -0.036956049341726798726440754485546402356 0.84138735420652599295096060100359489758 0.086203456344905850875965416526967283444 -0.80903350325702126768802840491559333013 0.61806700651404253537605680983118666027 -0.79584909058698306626909009833843112408 0.11671409960839383433248991439345238969 - 0.61806700651404253537605680983118666027 -0.80903350325702126768802840491559333013 -0.79584909058698306626909009833843112408 0.11671409960839383433248991439345238969 + 0.61806700651404253537605680983118666027 -0.80903350325702126768802840491559333013 -0.79584909058698306626909009833843112408 0.11671409960839383433248991439345238969 -0.80903350325702126768802840491559333013 -0.80903350325702126768802840491559333013 -0.79584909058698306626909009833843112408 0.11671409960839383433248991439345238969 -0.80903350325702126768802840491559333013 0.61806700651404253537605680983118666027 0.79584909058698306626909009833843112408 0.11671409960839383433248991439345238969 - 0.61806700651404253537605680983118666027 -0.80903350325702126768802840491559333013 0.79584909058698306626909009833843112408 0.11671409960839383433248991439345238969 + 0.61806700651404253537605680983118666027 -0.80903350325702126768802840491559333013 0.79584909058698306626909009833843112408 0.11671409960839383433248991439345238969 -0.80903350325702126768802840491559333013 -0.80903350325702126768802840491559333013 0.79584909058698306626909009833843112408 0.11671409960839383433248991439345238969 -0.97570173680324342035479366133901540544 0.48599336414579127066992364784746385989 0 0.10205942534059700976786329599159184945 - 0.48599336414579127066992364784746385989 -0.97570173680324342035479366133901540544 0 0.10205942534059700976786329599159184945 + 0.48599336414579127066992364784746385989 -0.97570173680324342035479366133901540544 0 0.10205942534059700976786329599159184945 -0.51029162734254785031512998650844845445 0.48599336414579127066992364784746385989 0 0.10205942534059700976786329599159184945 - 0.48599336414579127066992364784746385989 -0.51029162734254785031512998650844845445 0 0.10205942534059700976786329599159184945 + 0.48599336414579127066992364784746385989 -0.51029162734254785031512998650844845445 0 0.10205942534059700976786329599159184945 -0.51029162734254785031512998650844845445 -0.97570173680324342035479366133901540544 0 0.10205942534059700976786329599159184945 -0.97570173680324342035479366133901540544 -0.51029162734254785031512998650844845445 0 0.10205942534059700976786329599159184945 -0.38968756713554786569859973469754143293 -0.69403080315040476305982696739689230156 -0.4039345605321099116998238341362959742 0.15576281310483042016174134706586605691 @@ -134,56 +135,56 @@ function _get_gauss_prismdata_polyquad(n::Int) -0.33333333333333333333333333333333333333 -0.33333333333333333333333333333333333333 -0.68182544157086581170215168002374039522 0.20435770844872619128158195584935122282 -0.33333333333333333333333333333333333333 -0.33333333333333333333333333333333333333 0.68182544157086581170215168002374039522 0.20435770844872619128158195584935122282 -0.89317529812618572284389086719897089711 0.78635059625237144568778173439794179421 0 0.072608995136598867700988758862181257017 - 0.78635059625237144568778173439794179421 -0.89317529812618572284389086719897089711 0 0.072608995136598867700988758862181257017 + 0.78635059625237144568778173439794179421 -0.89317529812618572284389086719897089711 0 0.072608995136598867700988758862181257017 -0.89317529812618572284389086719897089711 -0.89317529812618572284389086719897089711 0 0.072608995136598867700988758862181257017 - -0.079822074372578761440178266060788079463 -0.84035585125484247711964346787842384107 0 0.2107989796260286741645220068699562506 + -0.079822074372578761440178266060788079463 -0.84035585125484247711964346787842384107 0 0.2107989796260286741645220068699562506 -0.84035585125484247711964346787842384107 -0.079822074372578761440178266060788079463 0 0.2107989796260286741645220068699562506 - -0.079822074372578761440178266060788079463 -0.079822074372578761440178266060788079463 0 0.2107989796260286741645220068699562506 - -0.082861862418097326120000870246452008956 -0.83427627516380534775999825950709598209 -0.87619591000025424474025327234232345955 0.084346037174345969123924723988899397111 + -0.079822074372578761440178266060788079463 -0.079822074372578761440178266060788079463 0 0.2107989796260286741645220068699562506 + -0.082861862418097326120000870246452008956 -0.83427627516380534775999825950709598209 -0.87619591000025424474025327234232345955 0.084346037174345969123924723988899397111 -0.83427627516380534775999825950709598209 -0.082861862418097326120000870246452008956 -0.87619591000025424474025327234232345955 0.084346037174345969123924723988899397111 - -0.082861862418097326120000870246452008956 -0.082861862418097326120000870246452008956 -0.87619591000025424474025327234232345955 0.084346037174345969123924723988899397111 - -0.082861862418097326120000870246452008956 -0.83427627516380534775999825950709598209 0.87619591000025424474025327234232345955 0.084346037174345969123924723988899397111 + -0.082861862418097326120000870246452008956 -0.082861862418097326120000870246452008956 -0.87619591000025424474025327234232345955 0.084346037174345969123924723988899397111 + -0.082861862418097326120000870246452008956 -0.83427627516380534775999825950709598209 0.87619591000025424474025327234232345955 0.084346037174345969123924723988899397111 -0.83427627516380534775999825950709598209 -0.082861862418097326120000870246452008956 0.87619591000025424474025327234232345955 0.084346037174345969123924723988899397111 - -0.082861862418097326120000870246452008956 -0.082861862418097326120000870246452008956 0.87619591000025424474025327234232345955 0.084346037174345969123924723988899397111 + -0.082861862418097326120000870246452008956 -0.082861862418097326120000870246452008956 0.87619591000025424474025327234232345955 0.084346037174345969123924723988899397111 -0.65187678415125922476703025933216051413 0.30375356830251844953406051866432102826 -0.40608422935459024220472507696440370377 0.16251705063595730345650668876189645828 - 0.30375356830251844953406051866432102826 -0.65187678415125922476703025933216051413 -0.40608422935459024220472507696440370377 0.16251705063595730345650668876189645828 + 0.30375356830251844953406051866432102826 -0.65187678415125922476703025933216051413 -0.40608422935459024220472507696440370377 0.16251705063595730345650668876189645828 -0.65187678415125922476703025933216051413 -0.65187678415125922476703025933216051413 -0.40608422935459024220472507696440370377 0.16251705063595730345650668876189645828 -0.65187678415125922476703025933216051413 0.30375356830251844953406051866432102826 0.40608422935459024220472507696440370377 0.16251705063595730345650668876189645828 - 0.30375356830251844953406051866432102826 -0.65187678415125922476703025933216051413 0.40608422935459024220472507696440370377 0.16251705063595730345650668876189645828 + 0.30375356830251844953406051866432102826 -0.65187678415125922476703025933216051413 0.40608422935459024220472507696440370377 0.16251705063595730345650668876189645828 -0.65187678415125922476703025933216051413 -0.65187678415125922476703025933216051413 0.40608422935459024220472507696440370377 0.16251705063595730345650668876189645828 -0.90552242832046124932977560924577476395 0.8110448566409224986595512184915495279 -0.82881544305868020493486275746014093078 0.028581431014154463281085418946775972209 - 0.8110448566409224986595512184915495279 -0.90552242832046124932977560924577476395 -0.82881544305868020493486275746014093078 0.028581431014154463281085418946775972209 + 0.8110448566409224986595512184915495279 -0.90552242832046124932977560924577476395 -0.82881544305868020493486275746014093078 0.028581431014154463281085418946775972209 -0.90552242832046124932977560924577476395 -0.90552242832046124932977560924577476395 -0.82881544305868020493486275746014093078 0.028581431014154463281085418946775972209 -0.90552242832046124932977560924577476395 0.8110448566409224986595512184915495279 0.82881544305868020493486275746014093078 0.028581431014154463281085418946775972209 - 0.8110448566409224986595512184915495279 -0.90552242832046124932977560924577476395 0.82881544305868020493486275746014093078 0.028581431014154463281085418946775972209 + 0.8110448566409224986595512184915495279 -0.90552242832046124932977560924577476395 0.82881544305868020493486275746014093078 0.028581431014154463281085418946775972209 -0.90552242832046124932977560924577476395 -0.90552242832046124932977560924577476395 0.82881544305868020493486275746014093078 0.028581431014154463281085418946775972209 -0.68050147211482206696479393170526142918 0.36100294422964413392958786341052285835 -0.96586516654065435448682371732369762245 0.044572109393861233332081245114974812183 - 0.36100294422964413392958786341052285835 -0.68050147211482206696479393170526142918 -0.96586516654065435448682371732369762245 0.044572109393861233332081245114974812183 + 0.36100294422964413392958786341052285835 -0.68050147211482206696479393170526142918 -0.96586516654065435448682371732369762245 0.044572109393861233332081245114974812183 -0.68050147211482206696479393170526142918 -0.68050147211482206696479393170526142918 -0.96586516654065435448682371732369762245 0.044572109393861233332081245114974812183 -0.68050147211482206696479393170526142918 0.36100294422964413392958786341052285835 0.96586516654065435448682371732369762245 0.044572109393861233332081245114974812183 - 0.36100294422964413392958786341052285835 -0.68050147211482206696479393170526142918 0.96586516654065435448682371732369762245 0.044572109393861233332081245114974812183 + 0.36100294422964413392958786341052285835 -0.68050147211482206696479393170526142918 0.96586516654065435448682371732369762245 0.044572109393861233332081245114974812183 -0.68050147211482206696479393170526142918 -0.68050147211482206696479393170526142918 0.96586516654065435448682371732369762245 0.044572109393861233332081245114974812183 - -0.4743723986175179830847346899909858658 0.45719614360199995718682043629988661246 -0.57735026918962576450914878050195745565 0.054590116363492292384362848950462321489 - 0.45719614360199995718682043629988661246 -0.4743723986175179830847346899909858658 -0.57735026918962576450914878050195745565 0.054590116363492292384362848950462321489 + -0.4743723986175179830847346899909858658 0.45719614360199995718682043629988661246 -0.57735026918962576450914878050195745565 0.054590116363492292384362848950462321489 + 0.45719614360199995718682043629988661246 -0.4743723986175179830847346899909858658 -0.57735026918962576450914878050195745565 0.054590116363492292384362848950462321489 -0.98282374498448197410208574630890074666 0.45719614360199995718682043629988661246 -0.57735026918962576450914878050195745565 0.054590116363492292384362848950462321489 - 0.45719614360199995718682043629988661246 -0.98282374498448197410208574630890074666 -0.57735026918962576450914878050195745565 0.054590116363492292384362848950462321489 + 0.45719614360199995718682043629988661246 -0.98282374498448197410208574630890074666 -0.57735026918962576450914878050195745565 0.054590116363492292384362848950462321489 -0.98282374498448197410208574630890074666 -0.4743723986175179830847346899909858658 -0.57735026918962576450914878050195745565 0.054590116363492292384362848950462321489 - -0.4743723986175179830847346899909858658 -0.98282374498448197410208574630890074666 -0.57735026918962576450914878050195745565 0.054590116363492292384362848950462321489 - -0.4743723986175179830847346899909858658 0.45719614360199995718682043629988661246 0.57735026918962576450914878050195745565 0.054590116363492292384362848950462321489 - 0.45719614360199995718682043629988661246 -0.4743723986175179830847346899909858658 0.57735026918962576450914878050195745565 0.054590116363492292384362848950462321489 + -0.4743723986175179830847346899909858658 -0.98282374498448197410208574630890074666 -0.57735026918962576450914878050195745565 0.054590116363492292384362848950462321489 + -0.4743723986175179830847346899909858658 0.45719614360199995718682043629988661246 0.57735026918962576450914878050195745565 0.054590116363492292384362848950462321489 + 0.45719614360199995718682043629988661246 -0.4743723986175179830847346899909858658 0.57735026918962576450914878050195745565 0.054590116363492292384362848950462321489 -0.98282374498448197410208574630890074666 0.45719614360199995718682043629988661246 0.57735026918962576450914878050195745565 0.054590116363492292384362848950462321489 - 0.45719614360199995718682043629988661246 -0.98282374498448197410208574630890074666 0.57735026918962576450914878050195745565 0.054590116363492292384362848950462321489 + 0.45719614360199995718682043629988661246 -0.98282374498448197410208574630890074666 0.57735026918962576450914878050195745565 0.054590116363492292384362848950462321489 -0.98282374498448197410208574630890074666 -0.4743723986175179830847346899909858658 0.57735026918962576450914878050195745565 0.054590116363492292384362848950462321489 - -0.4743723986175179830847346899909858658 -0.98282374498448197410208574630890074666 0.57735026918962576450914878050195745565 0.054590116363492292384362848950462321489 + -0.4743723986175179830847346899909858658 -0.98282374498448197410208574630890074666 0.57735026918962576450914878050195745565 0.054590116363492292384362848950462321489 ] elseif n == 9 xw = [ -0.33333333333333333333333333333333333333 -0.33333333333333333333333333333333333333 0 0.19114798844620108508537046584425003736 -0.33333333333333333333333333333333333333 -0.33333333333333333333333333333333333333 -0.87583915879987761660772171906042408394 0.1060969195893273614653564550346218398 -0.33333333333333333333333333333333333333 -0.33333333333333333333333333333333333333 0.87583915879987761660772171906042408394 0.1060969195893273614653564550346218398 - -0.0010699296586281549894456411507705393926 -0.99786014068274369002110871769845892121 0 0.049462405441895223670279761487537762472 + -0.0010699296586281549894456411507705393926 -0.99786014068274369002110871769845892121 0 0.049462405441895223670279761487537762472 -0.99786014068274369002110871769845892121 -0.0010699296586281549894456411507705393926 0 0.049462405441895223670279761487537762472 - -0.0010699296586281549894456411507705393926 -0.0010699296586281549894456411507705393926 0 0.049462405441895223670279761487537762472 + -0.0010699296586281549894456411507705393926 -0.0010699296586281549894456411507705393926 0 0.049462405441895223670279761487537762472 -0.10986499991499267966311447997302837166 -0.78027000017001464067377104005394325668 -0.52963355520607675696300739352733925666 0.15080793261275860374457825128943921743 -0.78027000017001464067377104005394325668 -0.10986499991499267966311447997302837166 -0.52963355520607675696300739352733925666 0.15080793261275860374457825128943921743 -0.10986499991499267966311447997302837166 -0.10986499991499267966311447997302837166 -0.52963355520607675696300739352733925666 0.15080793261275860374457825128943921743 @@ -191,16 +192,16 @@ function _get_gauss_prismdata_polyquad(n::Int) -0.78027000017001464067377104005394325668 -0.10986499991499267966311447997302837166 0.52963355520607675696300739352733925666 0.15080793261275860374457825128943921743 -0.10986499991499267966311447997302837166 -0.10986499991499267966311447997302837166 0.52963355520607675696300739352733925666 0.15080793261275860374457825128943921743 -0.57769113257897895683607913964943464903 0.15538226515795791367215827929886929806 -0.32397688216877005165250824998597314548 0.09338246974553840864616210022748459774 - 0.15538226515795791367215827929886929806 -0.57769113257897895683607913964943464903 -0.32397688216877005165250824998597314548 0.09338246974553840864616210022748459774 + 0.15538226515795791367215827929886929806 -0.57769113257897895683607913964943464903 -0.32397688216877005165250824998597314548 0.09338246974553840864616210022748459774 -0.57769113257897895683607913964943464903 -0.57769113257897895683607913964943464903 -0.32397688216877005165250824998597314548 0.09338246974553840864616210022748459774 -0.57769113257897895683607913964943464903 0.15538226515795791367215827929886929806 0.32397688216877005165250824998597314548 0.09338246974553840864616210022748459774 - 0.15538226515795791367215827929886929806 -0.57769113257897895683607913964943464903 0.32397688216877005165250824998597314548 0.09338246974553840864616210022748459774 + 0.15538226515795791367215827929886929806 -0.57769113257897895683607913964943464903 0.32397688216877005165250824998597314548 0.09338246974553840864616210022748459774 -0.57769113257897895683607913964943464903 -0.57769113257897895683607913964943464903 0.32397688216877005165250824998597314548 0.09338246974553840864616210022748459774 -0.91231503711701435232450671034134809014 0.82463007423402870464901342068269618029 -0.40165166857078872104499428459378049449 0.03838828638520642757038156568015552951 - 0.82463007423402870464901342068269618029 -0.91231503711701435232450671034134809014 -0.40165166857078872104499428459378049449 0.03838828638520642757038156568015552951 + 0.82463007423402870464901342068269618029 -0.91231503711701435232450671034134809014 -0.40165166857078872104499428459378049449 0.03838828638520642757038156568015552951 -0.91231503711701435232450671034134809014 -0.91231503711701435232450671034134809014 -0.40165166857078872104499428459378049449 0.03838828638520642757038156568015552951 -0.91231503711701435232450671034134809014 0.82463007423402870464901342068269618029 0.40165166857078872104499428459378049449 0.03838828638520642757038156568015552951 - 0.82463007423402870464901342068269618029 -0.91231503711701435232450671034134809014 0.40165166857078872104499428459378049449 0.03838828638520642757038156568015552951 + 0.82463007423402870464901342068269618029 -0.91231503711701435232450671034134809014 0.40165166857078872104499428459378049449 0.03838828638520642757038156568015552951 -0.91231503711701435232450671034134809014 -0.91231503711701435232450671034134809014 0.40165166857078872104499428459378049449 0.03838828638520642757038156568015552951 -0.03450013665826621486161695118676603904 -0.93099972668346757027676609762646792192 -0.9677921254642105035410819146400981344 0.026528431202320433845464036710085263608 -0.93099972668346757027676609762646792192 -0.03450013665826621486161695118676603904 -0.9677921254642105035410819146400981344 0.026528431202320433845464036710085263608 @@ -208,36 +209,36 @@ function _get_gauss_prismdata_polyquad(n::Int) -0.03450013665826621486161695118676603904 -0.93099972668346757027676609762646792192 0.9677921254642105035410819146400981344 0.026528431202320433845464036710085263608 -0.93099972668346757027676609762646792192 -0.03450013665826621486161695118676603904 0.9677921254642105035410819146400981344 0.026528431202320433845464036710085263608 -0.03450013665826621486161695118676603904 -0.03450013665826621486161695118676603904 0.9677921254642105035410819146400981344 0.026528431202320433845464036710085263608 - -0.6456435117766454460710959796587760834 0.29128702355329089214219195931755216681 -0.89078174045697066578383528302064143989 0.066719942573448407007300296577585702464 - 0.29128702355329089214219195931755216681 -0.6456435117766454460710959796587760834 -0.89078174045697066578383528302064143989 0.066719942573448407007300296577585702464 - -0.6456435117766454460710959796587760834 -0.6456435117766454460710959796587760834 -0.89078174045697066578383528302064143989 0.066719942573448407007300296577585702464 - -0.6456435117766454460710959796587760834 0.29128702355329089214219195931755216681 0.89078174045697066578383528302064143989 0.066719942573448407007300296577585702464 - 0.29128702355329089214219195931755216681 -0.6456435117766454460710959796587760834 0.89078174045697066578383528302064143989 0.066719942573448407007300296577585702464 - -0.6456435117766454460710959796587760834 -0.6456435117766454460710959796587760834 0.89078174045697066578383528302064143989 0.066719942573448407007300296577585702464 + -0.6456435117766454460710959796587760834 0.29128702355329089214219195931755216681 -0.89078174045697066578383528302064143989 0.066719942573448407007300296577585702464 + 0.29128702355329089214219195931755216681 -0.6456435117766454460710959796587760834 -0.89078174045697066578383528302064143989 0.066719942573448407007300296577585702464 + -0.6456435117766454460710959796587760834 -0.6456435117766454460710959796587760834 -0.89078174045697066578383528302064143989 0.066719942573448407007300296577585702464 + -0.6456435117766454460710959796587760834 0.29128702355329089214219195931755216681 0.89078174045697066578383528302064143989 0.066719942573448407007300296577585702464 + 0.29128702355329089214219195931755216681 -0.6456435117766454460710959796587760834 0.89078174045697066578383528302064143989 0.066719942573448407007300296577585702464 + -0.6456435117766454460710959796587760834 -0.6456435117766454460710959796587760834 0.89078174045697066578383528302064143989 0.066719942573448407007300296577585702464 -0.90753763917811234690103494985844043039 0.81507527835622469380206989971688086078 -0.9577062038929269606887790227035291939 0.012131173836407148944270419030858660558 - 0.81507527835622469380206989971688086078 -0.90753763917811234690103494985844043039 -0.9577062038929269606887790227035291939 0.012131173836407148944270419030858660558 + 0.81507527835622469380206989971688086078 -0.90753763917811234690103494985844043039 -0.9577062038929269606887790227035291939 0.012131173836407148944270419030858660558 -0.90753763917811234690103494985844043039 -0.90753763917811234690103494985844043039 -0.9577062038929269606887790227035291939 0.012131173836407148944270419030858660558 -0.90753763917811234690103494985844043039 0.81507527835622469380206989971688086078 0.9577062038929269606887790227035291939 0.012131173836407148944270419030858660558 - 0.81507527835622469380206989971688086078 -0.90753763917811234690103494985844043039 0.9577062038929269606887790227035291939 0.012131173836407148944270419030858660558 + 0.81507527835622469380206989971688086078 -0.90753763917811234690103494985844043039 0.9577062038929269606887790227035291939 0.012131173836407148944270419030858660558 -0.90753763917811234690103494985844043039 -0.90753763917811234690103494985844043039 0.9577062038929269606887790227035291939 0.012131173836407148944270419030858660558 -0.88126598051326876444819587362986475675 0.44939053910599895722040631866985064464 0 0.087691161312839084087580790508946261895 - 0.44939053910599895722040631866985064464 -0.88126598051326876444819587362986475675 0 0.087691161312839084087580790508946261895 + 0.44939053910599895722040631866985064464 -0.88126598051326876444819587362986475675 0 0.087691161312839084087580790508946261895 -0.56812455859273019277221044503998588789 0.44939053910599895722040631866985064464 0 0.087691161312839084087580790508946261895 - 0.44939053910599895722040631866985064464 -0.56812455859273019277221044503998588789 0 0.087691161312839084087580790508946261895 + 0.44939053910599895722040631866985064464 -0.56812455859273019277221044503998588789 0 0.087691161312839084087580790508946261895 -0.56812455859273019277221044503998588789 -0.88126598051326876444819587362986475675 0 0.087691161312839084087580790508946261895 -0.88126598051326876444819587362986475675 -0.56812455859273019277221044503998588789 0 0.087691161312839084087580790508946261895 - -0.5517449084932878730050536869300298641 0.49681091913207739922639584227322548803 -0.69522055387163478698981196744187399375 0.0495312141698622864915543816230467997 - 0.49681091913207739922639584227322548803 -0.5517449084932878730050536869300298641 -0.69522055387163478698981196744187399375 0.0495312141698622864915543816230467997 + -0.5517449084932878730050536869300298641 0.49681091913207739922639584227322548803 -0.69522055387163478698981196744187399375 0.0495312141698622864915543816230467997 + 0.49681091913207739922639584227322548803 -0.5517449084932878730050536869300298641 -0.69522055387163478698981196744187399375 0.0495312141698622864915543816230467997 -0.94506601063878952622134215534319562393 0.49681091913207739922639584227322548803 -0.69522055387163478698981196744187399375 0.0495312141698622864915543816230467997 - 0.49681091913207739922639584227322548803 -0.94506601063878952622134215534319562393 -0.69522055387163478698981196744187399375 0.0495312141698622864915543816230467997 + 0.49681091913207739922639584227322548803 -0.94506601063878952622134215534319562393 -0.69522055387163478698981196744187399375 0.0495312141698622864915543816230467997 -0.94506601063878952622134215534319562393 -0.5517449084932878730050536869300298641 -0.69522055387163478698981196744187399375 0.0495312141698622864915543816230467997 - -0.5517449084932878730050536869300298641 -0.94506601063878952622134215534319562393 -0.69522055387163478698981196744187399375 0.0495312141698622864915543816230467997 - -0.5517449084932878730050536869300298641 0.49681091913207739922639584227322548803 0.69522055387163478698981196744187399375 0.0495312141698622864915543816230467997 - 0.49681091913207739922639584227322548803 -0.5517449084932878730050536869300298641 0.69522055387163478698981196744187399375 0.0495312141698622864915543816230467997 + -0.5517449084932878730050536869300298641 -0.94506601063878952622134215534319562393 -0.69522055387163478698981196744187399375 0.0495312141698622864915543816230467997 + -0.5517449084932878730050536869300298641 0.49681091913207739922639584227322548803 0.69522055387163478698981196744187399375 0.0495312141698622864915543816230467997 + 0.49681091913207739922639584227322548803 -0.5517449084932878730050536869300298641 0.69522055387163478698981196744187399375 0.0495312141698622864915543816230467997 -0.94506601063878952622134215534319562393 0.49681091913207739922639584227322548803 0.69522055387163478698981196744187399375 0.0495312141698622864915543816230467997 - 0.49681091913207739922639584227322548803 -0.94506601063878952622134215534319562393 0.69522055387163478698981196744187399375 0.0495312141698622864915543816230467997 + 0.49681091913207739922639584227322548803 -0.94506601063878952622134215534319562393 0.69522055387163478698981196744187399375 0.0495312141698622864915543816230467997 -0.94506601063878952622134215534319562393 -0.5517449084932878730050536869300298641 0.69522055387163478698981196744187399375 0.0495312141698622864915543816230467997 - -0.5517449084932878730050536869300298641 -0.94506601063878952622134215534319562393 0.69522055387163478698981196744187399375 0.0495312141698622864915543816230467997 + -0.5517449084932878730050536869300298641 -0.94506601063878952622134215534319562393 0.69522055387163478698981196744187399375 0.0495312141698622864915543816230467997 ] elseif n == 10 xw = [ @@ -246,32 +247,32 @@ function _get_gauss_prismdata_polyquad(n::Int) -0.33333333333333333333333333333333333333 -0.33333333333333333333333333333333333333 -0.2838364013985715684657060577249329797 0.12804920643255787761445727849451714328 -0.33333333333333333333333333333333333333 -0.33333333333333333333333333333333333333 0.2838364013985715684657060577249329797 0.12804920643255787761445727849451714328 -0.58509925002156576804484663776694671178 0.17019850004313153608969327553389342357 0 0.045423158480136973856219994221831113886 - 0.17019850004313153608969327553389342357 -0.58509925002156576804484663776694671178 0 0.045423158480136973856219994221831113886 + 0.17019850004313153608969327553389342357 -0.58509925002156576804484663776694671178 0 0.045423158480136973856219994221831113886 -0.58509925002156576804484663776694671178 -0.58509925002156576804484663776694671178 0 0.045423158480136973856219994221831113886 - -0.087745274263836468012344092631834458624 -0.82450945147232706397531181473633108275 0 0.12078661810034629566292168130821741978 + -0.087745274263836468012344092631834458624 -0.82450945147232706397531181473633108275 0 0.12078661810034629566292168130821741978 -0.82450945147232706397531181473633108275 -0.087745274263836468012344092631834458624 0 0.12078661810034629566292168130821741978 - -0.087745274263836468012344092631834458624 -0.087745274263836468012344092631834458624 0 0.12078661810034629566292168130821741978 + -0.087745274263836468012344092631834458624 -0.087745274263836468012344092631834458624 0 0.12078661810034629566292168130821741978 -0.83336149569989450879622615827585222698 0.66672299139978901759245231655170445397 0 0.070523638001611290833549221721909796384 - 0.66672299139978901759245231655170445397 -0.83336149569989450879622615827585222698 0 0.070523638001611290833549221721909796384 + 0.66672299139978901759245231655170445397 -0.83336149569989450879622615827585222698 0 0.070523638001611290833549221721909796384 -0.83336149569989450879622615827585222698 -0.83336149569989450879622615827585222698 0 0.070523638001611290833549221721909796384 -0.58566729572033783230931886738991607412 0.17133459144067566461863773477983214824 -0.47829026090036813970247985116366265217 0.10435318130434033235265655019864541098 - 0.17133459144067566461863773477983214824 -0.58566729572033783230931886738991607412 -0.47829026090036813970247985116366265217 0.10435318130434033235265655019864541098 + 0.17133459144067566461863773477983214824 -0.58566729572033783230931886738991607412 -0.47829026090036813970247985116366265217 0.10435318130434033235265655019864541098 -0.58566729572033783230931886738991607412 -0.58566729572033783230931886738991607412 -0.47829026090036813970247985116366265217 0.10435318130434033235265655019864541098 -0.58566729572033783230931886738991607412 0.17133459144067566461863773477983214824 0.47829026090036813970247985116366265217 0.10435318130434033235265655019864541098 - 0.17133459144067566461863773477983214824 -0.58566729572033783230931886738991607412 0.47829026090036813970247985116366265217 0.10435318130434033235265655019864541098 + 0.17133459144067566461863773477983214824 -0.58566729572033783230931886738991607412 0.47829026090036813970247985116366265217 0.10435318130434033235265655019864541098 -0.58566729572033783230931886738991607412 -0.58566729572033783230931886738991607412 0.47829026090036813970247985116366265217 0.10435318130434033235265655019864541098 -0.71401760691431835996629386931253079667 0.42803521382863671993258773862506159333 -0.8520666639991396363392553699935906628 0.045353049770314160210925207718221960406 - 0.42803521382863671993258773862506159333 -0.71401760691431835996629386931253079667 -0.8520666639991396363392553699935906628 0.045353049770314160210925207718221960406 + 0.42803521382863671993258773862506159333 -0.71401760691431835996629386931253079667 -0.8520666639991396363392553699935906628 0.045353049770314160210925207718221960406 -0.71401760691431835996629386931253079667 -0.71401760691431835996629386931253079667 -0.8520666639991396363392553699935906628 0.045353049770314160210925207718221960406 -0.71401760691431835996629386931253079667 0.42803521382863671993258773862506159333 0.8520666639991396363392553699935906628 0.045353049770314160210925207718221960406 - 0.42803521382863671993258773862506159333 -0.71401760691431835996629386931253079667 0.8520666639991396363392553699935906628 0.045353049770314160210925207718221960406 + 0.42803521382863671993258773862506159333 -0.71401760691431835996629386931253079667 0.8520666639991396363392553699935906628 0.045353049770314160210925207718221960406 -0.71401760691431835996629386931253079667 -0.71401760691431835996629386931253079667 0.8520666639991396363392553699935906628 0.045353049770314160210925207718221960406 - -0.0059182255205082649355625415633530872236 -0.98816354895898347012887491687329382555 -0.62749011164795345095028595959683589121 0.028126573654953943549801873601641305154 + -0.0059182255205082649355625415633530872236 -0.98816354895898347012887491687329382555 -0.62749011164795345095028595959683589121 0.028126573654953943549801873601641305154 -0.98816354895898347012887491687329382555 -0.0059182255205082649355625415633530872236 -0.62749011164795345095028595959683589121 0.028126573654953943549801873601641305154 - -0.0059182255205082649355625415633530872236 -0.0059182255205082649355625415633530872236 -0.62749011164795345095028595959683589121 0.028126573654953943549801873601641305154 - -0.0059182255205082649355625415633530872236 -0.98816354895898347012887491687329382555 0.62749011164795345095028595959683589121 0.028126573654953943549801873601641305154 + -0.0059182255205082649355625415633530872236 -0.0059182255205082649355625415633530872236 -0.62749011164795345095028595959683589121 0.028126573654953943549801873601641305154 + -0.0059182255205082649355625415633530872236 -0.98816354895898347012887491687329382555 0.62749011164795345095028595959683589121 0.028126573654953943549801873601641305154 -0.98816354895898347012887491687329382555 -0.0059182255205082649355625415633530872236 0.62749011164795345095028595959683589121 0.028126573654953943549801873601641305154 - -0.0059182255205082649355625415633530872236 -0.0059182255205082649355625415633530872236 0.62749011164795345095028595959683589121 0.028126573654953943549801873601641305154 + -0.0059182255205082649355625415633530872236 -0.0059182255205082649355625415633530872236 0.62749011164795345095028595959683589121 0.028126573654953943549801873601641305154 -0.14443508029301579714242731927948333445 -0.71112983941396840571514536144103333111 -0.76897188255294104672722599221030791768 0.09730006751474251906683045094709204535 -0.71112983941396840571514536144103333111 -0.14443508029301579714242731927948333445 -0.76897188255294104672722599221030791768 0.09730006751474251906683045094709204535 -0.14443508029301579714242731927948333445 -0.14443508029301579714242731927948333445 -0.76897188255294104672722599221030791768 0.09730006751474251906683045094709204535 @@ -279,51 +280,51 @@ function _get_gauss_prismdata_polyquad(n::Int) -0.71112983941396840571514536144103333111 -0.14443508029301579714242731927948333445 0.76897188255294104672722599221030791768 0.09730006751474251906683045094709204535 -0.14443508029301579714242731927948333445 -0.14443508029301579714242731927948333445 0.76897188255294104672722599221030791768 0.09730006751474251906683045094709204535 -0.92655062106089238633040808286062465799 0.85310124212178477266081616572124931598 -0.94536185592175700771401046143327478453 0.0075697428403356175236518069263715176348 - 0.85310124212178477266081616572124931598 -0.92655062106089238633040808286062465799 -0.94536185592175700771401046143327478453 0.0075697428403356175236518069263715176348 + 0.85310124212178477266081616572124931598 -0.92655062106089238633040808286062465799 -0.94536185592175700771401046143327478453 0.0075697428403356175236518069263715176348 -0.92655062106089238633040808286062465799 -0.92655062106089238633040808286062465799 -0.94536185592175700771401046143327478453 0.0075697428403356175236518069263715176348 -0.92655062106089238633040808286062465799 0.85310124212178477266081616572124931598 0.94536185592175700771401046143327478453 0.0075697428403356175236518069263715176348 - 0.85310124212178477266081616572124931598 -0.92655062106089238633040808286062465799 0.94536185592175700771401046143327478453 0.0075697428403356175236518069263715176348 + 0.85310124212178477266081616572124931598 -0.92655062106089238633040808286062465799 0.94536185592175700771401046143327478453 0.0075697428403356175236518069263715176348 -0.92655062106089238633040808286062465799 -0.92655062106089238633040808286062465799 0.94536185592175700771401046143327478453 0.0075697428403356175236518069263715176348 -0.99621476080190120325860648054065438352 0.99582008190465265332555390082623777504 0 0.0031208636401827010315915455956052660089 - 0.99582008190465265332555390082623777504 -0.99621476080190120325860648054065438352 0 0.0031208636401827010315915455956052660089 + 0.99582008190465265332555390082623777504 -0.99621476080190120325860648054065438352 0 0.0031208636401827010315915455956052660089 -0.99960532110275145006694742028558339152 0.99582008190465265332555390082623777504 0 0.0031208636401827010315915455956052660089 - 0.99582008190465265332555390082623777504 -0.99960532110275145006694742028558339152 0 0.0031208636401827010315915455956052660089 + 0.99582008190465265332555390082623777504 -0.99960532110275145006694742028558339152 0 0.0031208636401827010315915455956052660089 -0.99960532110275145006694742028558339152 -0.99621476080190120325860648054065438352 0 0.0031208636401827010315915455956052660089 -0.99621476080190120325860648054065438352 -0.99960532110275145006694742028558339152 0 0.0031208636401827010315915455956052660089 -0.91342063244101618001407082339238449491 0.3255064864791910018042153093720481789 -0.94236346745083749482627300953387466221 0.024183540649806648348002441154357646858 - 0.3255064864791910018042153093720481789 -0.91342063244101618001407082339238449491 -0.94236346745083749482627300953387466221 0.024183540649806648348002441154357646858 + 0.3255064864791910018042153093720481789 -0.91342063244101618001407082339238449491 -0.94236346745083749482627300953387466221 0.024183540649806648348002441154357646858 -0.41208585403817482179014448597966368399 0.3255064864791910018042153093720481789 -0.94236346745083749482627300953387466221 0.024183540649806648348002441154357646858 - 0.3255064864791910018042153093720481789 -0.41208585403817482179014448597966368399 -0.94236346745083749482627300953387466221 0.024183540649806648348002441154357646858 + 0.3255064864791910018042153093720481789 -0.41208585403817482179014448597966368399 -0.94236346745083749482627300953387466221 0.024183540649806648348002441154357646858 -0.41208585403817482179014448597966368399 -0.91342063244101618001407082339238449491 -0.94236346745083749482627300953387466221 0.024183540649806648348002441154357646858 -0.91342063244101618001407082339238449491 -0.41208585403817482179014448597966368399 -0.94236346745083749482627300953387466221 0.024183540649806648348002441154357646858 -0.91342063244101618001407082339238449491 0.3255064864791910018042153093720481789 0.94236346745083749482627300953387466221 0.024183540649806648348002441154357646858 - 0.3255064864791910018042153093720481789 -0.91342063244101618001407082339238449491 0.94236346745083749482627300953387466221 0.024183540649806648348002441154357646858 + 0.3255064864791910018042153093720481789 -0.91342063244101618001407082339238449491 0.94236346745083749482627300953387466221 0.024183540649806648348002441154357646858 -0.41208585403817482179014448597966368399 0.3255064864791910018042153093720481789 0.94236346745083749482627300953387466221 0.024183540649806648348002441154357646858 - 0.3255064864791910018042153093720481789 -0.41208585403817482179014448597966368399 0.94236346745083749482627300953387466221 0.024183540649806648348002441154357646858 + 0.3255064864791910018042153093720481789 -0.41208585403817482179014448597966368399 0.94236346745083749482627300953387466221 0.024183540649806648348002441154357646858 -0.41208585403817482179014448597966368399 -0.91342063244101618001407082339238449491 0.94236346745083749482627300953387466221 0.024183540649806648348002441154357646858 -0.91342063244101618001407082339238449491 -0.41208585403817482179014448597966368399 0.94236346745083749482627300953387466221 0.024183540649806648348002441154357646858 - -0.9234169616555928413056660388640430162 0.37513146835671456389900781390965761438 -0.33533610866739435446116498131265141599 0.05460310873669147926531122821390556603 - 0.37513146835671456389900781390965761438 -0.9234169616555928413056660388640430162 -0.33533610866739435446116498131265141599 0.05460310873669147926531122821390556603 + -0.9234169616555928413056660388640430162 0.37513146835671456389900781390965761438 -0.33533610866739435446116498131265141599 0.05460310873669147926531122821390556603 + 0.37513146835671456389900781390965761438 -0.9234169616555928413056660388640430162 -0.33533610866739435446116498131265141599 0.05460310873669147926531122821390556603 -0.45171450670112172259334177504561459817 0.37513146835671456389900781390965761438 -0.33533610866739435446116498131265141599 0.05460310873669147926531122821390556603 - 0.37513146835671456389900781390965761438 -0.45171450670112172259334177504561459817 -0.33533610866739435446116498131265141599 0.05460310873669147926531122821390556603 + 0.37513146835671456389900781390965761438 -0.45171450670112172259334177504561459817 -0.33533610866739435446116498131265141599 0.05460310873669147926531122821390556603 -0.45171450670112172259334177504561459817 -0.9234169616555928413056660388640430162 -0.33533610866739435446116498131265141599 0.05460310873669147926531122821390556603 - -0.9234169616555928413056660388640430162 -0.45171450670112172259334177504561459817 -0.33533610866739435446116498131265141599 0.05460310873669147926531122821390556603 - -0.9234169616555928413056660388640430162 0.37513146835671456389900781390965761438 0.33533610866739435446116498131265141599 0.05460310873669147926531122821390556603 - 0.37513146835671456389900781390965761438 -0.9234169616555928413056660388640430162 0.33533610866739435446116498131265141599 0.05460310873669147926531122821390556603 + -0.9234169616555928413056660388640430162 -0.45171450670112172259334177504561459817 -0.33533610866739435446116498131265141599 0.05460310873669147926531122821390556603 + -0.9234169616555928413056660388640430162 0.37513146835671456389900781390965761438 0.33533610866739435446116498131265141599 0.05460310873669147926531122821390556603 + 0.37513146835671456389900781390965761438 -0.9234169616555928413056660388640430162 0.33533610866739435446116498131265141599 0.05460310873669147926531122821390556603 -0.45171450670112172259334177504561459817 0.37513146835671456389900781390965761438 0.33533610866739435446116498131265141599 0.05460310873669147926531122821390556603 - 0.37513146835671456389900781390965761438 -0.45171450670112172259334177504561459817 0.33533610866739435446116498131265141599 0.05460310873669147926531122821390556603 + 0.37513146835671456389900781390965761438 -0.45171450670112172259334177504561459817 0.33533610866739435446116498131265141599 0.05460310873669147926531122821390556603 -0.45171450670112172259334177504561459817 -0.9234169616555928413056660388640430162 0.33533610866739435446116498131265141599 0.05460310873669147926531122821390556603 - -0.9234169616555928413056660388640430162 -0.45171450670112172259334177504561459817 0.33533610866739435446116498131265141599 0.05460310873669147926531122821390556603 + -0.9234169616555928413056660388640430162 -0.45171450670112172259334177504561459817 0.33533610866739435446116498131265141599 0.05460310873669147926531122821390556603 -0.96792121274553310722108842071500064645 0.74052721727873797554079834546410281777 -0.61432350187707741015732547519719343903 0.024769538519410488660113297222678366236 - 0.74052721727873797554079834546410281777 -0.96792121274553310722108842071500064645 -0.61432350187707741015732547519719343903 0.024769538519410488660113297222678366236 + 0.74052721727873797554079834546410281777 -0.96792121274553310722108842071500064645 -0.61432350187707741015732547519719343903 0.024769538519410488660113297222678366236 -0.77260600453320486831970992474910217133 0.74052721727873797554079834546410281777 -0.61432350187707741015732547519719343903 0.024769538519410488660113297222678366236 - 0.74052721727873797554079834546410281777 -0.77260600453320486831970992474910217133 -0.61432350187707741015732547519719343903 0.024769538519410488660113297222678366236 + 0.74052721727873797554079834546410281777 -0.77260600453320486831970992474910217133 -0.61432350187707741015732547519719343903 0.024769538519410488660113297222678366236 -0.77260600453320486831970992474910217133 -0.96792121274553310722108842071500064645 -0.61432350187707741015732547519719343903 0.024769538519410488660113297222678366236 -0.96792121274553310722108842071500064645 -0.77260600453320486831970992474910217133 -0.61432350187707741015732547519719343903 0.024769538519410488660113297222678366236 -0.96792121274553310722108842071500064645 0.74052721727873797554079834546410281777 0.61432350187707741015732547519719343903 0.024769538519410488660113297222678366236 - 0.74052721727873797554079834546410281777 -0.96792121274553310722108842071500064645 0.61432350187707741015732547519719343903 0.024769538519410488660113297222678366236 + 0.74052721727873797554079834546410281777 -0.96792121274553310722108842071500064645 0.61432350187707741015732547519719343903 0.024769538519410488660113297222678366236 -0.77260600453320486831970992474910217133 0.74052721727873797554079834546410281777 0.61432350187707741015732547519719343903 0.024769538519410488660113297222678366236 - 0.74052721727873797554079834546410281777 -0.77260600453320486831970992474910217133 0.61432350187707741015732547519719343903 0.024769538519410488660113297222678366236 + 0.74052721727873797554079834546410281777 -0.77260600453320486831970992474910217133 0.61432350187707741015732547519719343903 0.024769538519410488660113297222678366236 -0.77260600453320486831970992474910217133 -0.96792121274553310722108842071500064645 0.61432350187707741015732547519719343903 0.024769538519410488660113297222678366236 -0.96792121274553310722108842071500064645 -0.77260600453320486831970992474910217133 0.61432350187707741015732547519719343903 0.024769538519410488660113297222678366236 ] @@ -333,16 +334,16 @@ function _get_gauss_prismdata_polyquad(n::Int) # Transform from [-1,1] × [-1,1] × [-1,1] to [0,1] × [0,1] × [0,1] #x - xw[:, 1] .+= 1.0 - xw[:, 1] ./= 2.0 + xw[:,1] .+= 1.0 + xw[:,1] ./= 2.0 #y - xw[:, 2] .+= 1.0 - xw[:, 2] ./= 2.0 + xw[:,2] .+= 1.0 + xw[:,2] ./= 2.0 #z - xw[:, 3] .+= 1.0 - xw[:, 3] ./= 2.0 + xw[:,3] .+= 1.0 + xw[:,3] ./= 2.0 #w - xw[:, 4] ./= 2^3 + xw[:,4] ./= 2^3 return xw end diff --git a/src/Quadrature/gaussquad_pyramid_table.jl b/src/Quadrature/gaussquad_pyramid_table.jl index 2917b2cda6..6717f7fc7d 100644 --- a/src/Quadrature/gaussquad_pyramid_table.jl +++ b/src/Quadrature/gaussquad_pyramid_table.jl @@ -1,3 +1,4 @@ +# runic: off # Symmetric quadrature rules takes from # Witherden, Freddie D., and Peter E. Vincent. "On the identification of # symmetric quadrature rules for finite element methods." Computers & @@ -5,103 +6,103 @@ # TODO: Implement quadrature data from: # https://www.sciencedirect.com/science/article/pii/S0168874X1200203X?via%3Dihub#s0065 function _get_gauss_pyramiddata_polyquad(n::Int) - if n == 1 - xw = [0 0 -0.5 2.6666666666666666666666666666666666667] - elseif n == 2 - xw = [ - 0 0 0.21658207711955775339238838942231815011 0.60287280353093925911579186632475611728 - 0.71892105581179616210276971993495767914 0 -0.70932703285428855378369530000365161136 0.51594846578393185188771870008547763735 - 0 0.71892105581179616210276971993495767914 -0.70932703285428855378369530000365161136 0.51594846578393185188771870008547763735 - -0.71892105581179616210276971993495767914 0 -0.70932703285428855378369530000365161136 0.51594846578393185188771870008547763735 - 0 -0.71892105581179616210276971993495767914 -0.70932703285428855378369530000365161136 0.51594846578393185188771870008547763735 - ] - elseif n == 3 - xw = [ - 0 0 0.14285714077213670617734974746312582074 0.67254902379402809443607078852738472107 - 0 0 -0.99999998864829993678698817507850804299 0.30000001617617323518941867705084375434 - 0.56108361105873963414196154191891982155 0.56108361105873963414196154191891982155 -0.66666666666666666666666666666666666667 0.42352940667411633426029430027210954782 - 0.56108361105873963414196154191891982155 -0.56108361105873963414196154191891982155 -0.66666666666666666666666666666666666667 0.42352940667411633426029430027210954782 - -0.56108361105873963414196154191891982155 0.56108361105873963414196154191891982155 -0.66666666666666666666666666666666666667 0.42352940667411633426029430027210954782 - -0.56108361105873963414196154191891982155 -0.56108361105873963414196154191891982155 -0.66666666666666666666666666666666666667 0.42352940667411633426029430027210954782 - ] - elseif n == 4 - xw = [ - 0 0 0.35446557777227471722730849524904581806 0.30331168845504517111391728481208001144 - 0 0 -0.74972609378250711033655604388057044149 0.55168907357213937275730716433358729608 - 0.6505815563982325146829577797417295398 0 -0.35523170084357268589593075201816127231 0.28353223437153468006819777082540613962 - 0 0.6505815563982325146829577797417295398 -0.35523170084357268589593075201816127231 0.28353223437153468006819777082540613962 - -0.6505815563982325146829577797417295398 0 -0.35523170084357268589593075201816127231 0.28353223437153468006819777082540613962 - 0 -0.6505815563982325146829577797417295398 -0.35523170084357268589593075201816127231 0.28353223437153468006819777082540613962 - 0.65796699712169008954533549931479427127 0.65796699712169008954533549931479427127 -0.92150343220236930457646242598412224897 0.16938424178833585063066278355484370017 - 0.65796699712169008954533549931479427127 -0.65796699712169008954533549931479427127 -0.92150343220236930457646242598412224897 0.16938424178833585063066278355484370017 - -0.65796699712169008954533549931479427127 0.65796699712169008954533549931479427127 -0.92150343220236930457646242598412224897 0.16938424178833585063066278355484370017 - -0.65796699712169008954533549931479427127 -0.65796699712169008954533549931479427127 -0.92150343220236930457646242598412224897 0.16938424178833585063066278355484370017 - ] - elseif n == 5 - xw = [ - 0 0 0.45971576156501338586164265377920811314 0.18249431975770692138374895897213800931 - 0 0 -0.39919795837246198593385139590712322914 0.45172563864726406056400285032640105704 - 0 0 -0.99999998701645569241460017355590234925 0.15654542887619877154120304977336547704 - 0.70652603154632457420722562974792066862 0 -0.75 0.20384344839498724639142514342645843799 - 0 0.70652603154632457420722562974792066862 -0.75 0.20384344839498724639142514342645843799 - -0.70652603154632457420722562974792066862 0 -0.75 0.20384344839498724639142514342645843799 - 0 -0.70652603154632457420722562974792066862 -0.75 0.20384344839498724639142514342645843799 - 0.70511712277882760181079385797948261057 0.70511712277882760181079385797948261057 -0.87777618587595407108464357252416911085 0.10578907087905457654220386143818487109 - 0.70511712277882760181079385797948261057 -0.70511712277882760181079385797948261057 -0.87777618587595407108464357252416911085 0.10578907087905457654220386143818487109 - -0.70511712277882760181079385797948261057 0.70511712277882760181079385797948261057 -0.87777618587595407108464357252416911085 0.10578907087905457654220386143818487109 - -0.70511712277882760181079385797948261057 -0.70511712277882760181079385797948261057 -0.87777618587595407108464357252416911085 0.10578907087905457654220386143818487109 - 0.43288286410354097685000790909815143591 0.43288286410354097685000790909815143591 -0.15279732576055038842025517341026975071 0.15934280057233240536079894703404722173 - 0.43288286410354097685000790909815143591 -0.43288286410354097685000790909815143591 -0.15279732576055038842025517341026975071 0.15934280057233240536079894703404722173 - -0.43288286410354097685000790909815143591 0.43288286410354097685000790909815143591 -0.15279732576055038842025517341026975071 0.15934280057233240536079894703404722173 - -0.43288286410354097685000790909815143591 -0.43288286410354097685000790909815143591 -0.15279732576055038842025517341026975071 0.15934280057233240536079894703404722173 - ] - elseif n == 6 - xw = [ - 0 0 0.61529159538791884731954955103613269638 0.067901049767045421348323914977088073991 - 0 0 -0.99647238229436073479434618269377000101 0.042809368467176804517723726702995063594 - 0 0 -0.72347438707253884945296925394581802655 0.31887881187339684620076177026181758884 - 0 0 -0.15715217612872593659809486760257994179 0.27482845386440493216991697942238502071 - 0.83459535111470834854355609376418165506 0 -0.80510531794907605316224881154681003606 0.09853490116354529166000184266852321827 - 0 0.83459535111470834854355609376418165506 -0.80510531794907605316224881154681003606 0.09853490116354529166000184266852321827 - -0.83459535111470834854355609376418165506 0 -0.80510531794907605316224881154681003606 0.09853490116354529166000184266852321827 - 0 -0.83459535111470834854355609376418165506 -0.80510531794907605316224881154681003606 0.09853490116354529166000184266852321827 - 0.4339254093766990953588290760534534212 0 0.13214918124660180928234184789309315759 0.084233545301795354894729459206933067324 - 0 0.4339254093766990953588290760534534212 0.13214918124660180928234184789309315759 0.084233545301795354894729459206933067324 - -0.4339254093766990953588290760534534212 0 0.13214918124660180928234184789309315759 0.084233545301795354894729459206933067324 - 0 -0.4339254093766990953588290760534534212 0.13214918124660180928234184789309315759 0.084233545301795354894729459206933067324 - 0.565680854425675497672813848515505886 0.565680854425675497672813848515505886 -0.94104453830855858213371584535608020131 0.099200345038528745418340651788127467643 - 0.565680854425675497672813848515505886 -0.565680854425675497672813848515505886 -0.94104453830855858213371584535608020131 0.099200345038528745418340651788127467643 - -0.565680854425675497672813848515505886 0.565680854425675497672813848515505886 -0.94104453830855858213371584535608020131 0.099200345038528745418340651788127467643 - -0.565680854425675497672813848515505886 -0.565680854425675497672813848515505886 -0.94104453830855858213371584535608020131 0.099200345038528745418340651788127467643 - 0.49807909178070594245642503041316019049 0.49807909178070594245642503041316019049 -0.47016827357574098280216051103358470857 0.19701969247180494546144986676345270691 - 0.49807909178070594245642503041316019049 -0.49807909178070594245642503041316019049 -0.47016827357574098280216051103358470857 0.19701969247180494546144986676345270691 - -0.49807909178070594245642503041316019049 0.49807909178070594245642503041316019049 -0.47016827357574098280216051103358470857 0.19701969247180494546144986676345270691 - -0.49807909178070594245642503041316019049 -0.49807909178070594245642503041316019049 -0.47016827357574098280216051103358470857 0.19701969247180494546144986676345270691 - 0.95089948721448243656573347456644144515 0.95089948721448243656573347456644144515 -0.90350185873612803037779492533363294921 0.011573761697986328172963248398558769736 - 0.95089948721448243656573347456644144515 -0.95089948721448243656573347456644144515 -0.90350185873612803037779492533363294921 0.011573761697986328172963248398558769736 - -0.95089948721448243656573347456644144515 0.95089948721448243656573347456644144515 -0.90350185873612803037779492533363294921 0.011573761697986328172963248398558769736 - -0.95089948721448243656573347456644144515 -0.95089948721448243656573347456644144515 -0.90350185873612803037779492533363294921 0.011573761697986328172963248398558769736 - ] - else - throw(ArgumentError("unsupported order for prism polyquad integration")) - end + if n == 1 + xw = [0 0 -0.5 2.6666666666666666666666666666666666667] + elseif n == 2 + xw = [ + 0 0 0.21658207711955775339238838942231815011 0.60287280353093925911579186632475611728 + 0.71892105581179616210276971993495767914 0 -0.70932703285428855378369530000365161136 0.51594846578393185188771870008547763735 + 0 0.71892105581179616210276971993495767914 -0.70932703285428855378369530000365161136 0.51594846578393185188771870008547763735 + -0.71892105581179616210276971993495767914 0 -0.70932703285428855378369530000365161136 0.51594846578393185188771870008547763735 + 0 -0.71892105581179616210276971993495767914 -0.70932703285428855378369530000365161136 0.51594846578393185188771870008547763735 + ] + elseif n == 3 + xw = [ + 0 0 0.14285714077213670617734974746312582074 0.67254902379402809443607078852738472107 + 0 0 -0.99999998864829993678698817507850804299 0.30000001617617323518941867705084375434 + 0.56108361105873963414196154191891982155 0.56108361105873963414196154191891982155 -0.66666666666666666666666666666666666667 0.42352940667411633426029430027210954782 + 0.56108361105873963414196154191891982155 -0.56108361105873963414196154191891982155 -0.66666666666666666666666666666666666667 0.42352940667411633426029430027210954782 + -0.56108361105873963414196154191891982155 0.56108361105873963414196154191891982155 -0.66666666666666666666666666666666666667 0.42352940667411633426029430027210954782 + -0.56108361105873963414196154191891982155 -0.56108361105873963414196154191891982155 -0.66666666666666666666666666666666666667 0.42352940667411633426029430027210954782 + ] + elseif n == 4 + xw = [ + 0 0 0.35446557777227471722730849524904581806 0.30331168845504517111391728481208001144 + 0 0 -0.74972609378250711033655604388057044149 0.55168907357213937275730716433358729608 + 0.6505815563982325146829577797417295398 0 -0.35523170084357268589593075201816127231 0.28353223437153468006819777082540613962 + 0 0.6505815563982325146829577797417295398 -0.35523170084357268589593075201816127231 0.28353223437153468006819777082540613962 + -0.6505815563982325146829577797417295398 0 -0.35523170084357268589593075201816127231 0.28353223437153468006819777082540613962 + 0 -0.6505815563982325146829577797417295398 -0.35523170084357268589593075201816127231 0.28353223437153468006819777082540613962 + 0.65796699712169008954533549931479427127 0.65796699712169008954533549931479427127 -0.92150343220236930457646242598412224897 0.16938424178833585063066278355484370017 + 0.65796699712169008954533549931479427127 -0.65796699712169008954533549931479427127 -0.92150343220236930457646242598412224897 0.16938424178833585063066278355484370017 + -0.65796699712169008954533549931479427127 0.65796699712169008954533549931479427127 -0.92150343220236930457646242598412224897 0.16938424178833585063066278355484370017 + -0.65796699712169008954533549931479427127 -0.65796699712169008954533549931479427127 -0.92150343220236930457646242598412224897 0.16938424178833585063066278355484370017 + ] + elseif n == 5 + xw = [ + 0 0 0.45971576156501338586164265377920811314 0.18249431975770692138374895897213800931 + 0 0 -0.39919795837246198593385139590712322914 0.45172563864726406056400285032640105704 + 0 0 -0.99999998701645569241460017355590234925 0.15654542887619877154120304977336547704 + 0.70652603154632457420722562974792066862 0 -0.75 0.20384344839498724639142514342645843799 + 0 0.70652603154632457420722562974792066862 -0.75 0.20384344839498724639142514342645843799 + -0.70652603154632457420722562974792066862 0 -0.75 0.20384344839498724639142514342645843799 + 0 -0.70652603154632457420722562974792066862 -0.75 0.20384344839498724639142514342645843799 + 0.70511712277882760181079385797948261057 0.70511712277882760181079385797948261057 -0.87777618587595407108464357252416911085 0.10578907087905457654220386143818487109 + 0.70511712277882760181079385797948261057 -0.70511712277882760181079385797948261057 -0.87777618587595407108464357252416911085 0.10578907087905457654220386143818487109 + -0.70511712277882760181079385797948261057 0.70511712277882760181079385797948261057 -0.87777618587595407108464357252416911085 0.10578907087905457654220386143818487109 + -0.70511712277882760181079385797948261057 -0.70511712277882760181079385797948261057 -0.87777618587595407108464357252416911085 0.10578907087905457654220386143818487109 + 0.43288286410354097685000790909815143591 0.43288286410354097685000790909815143591 -0.15279732576055038842025517341026975071 0.15934280057233240536079894703404722173 + 0.43288286410354097685000790909815143591 -0.43288286410354097685000790909815143591 -0.15279732576055038842025517341026975071 0.15934280057233240536079894703404722173 + -0.43288286410354097685000790909815143591 0.43288286410354097685000790909815143591 -0.15279732576055038842025517341026975071 0.15934280057233240536079894703404722173 + -0.43288286410354097685000790909815143591 -0.43288286410354097685000790909815143591 -0.15279732576055038842025517341026975071 0.15934280057233240536079894703404722173 + ] + elseif n==6 + xw = [ + 0 0 0.61529159538791884731954955103613269638 0.067901049767045421348323914977088073991 + 0 0 -0.99647238229436073479434618269377000101 0.042809368467176804517723726702995063594 + 0 0 -0.72347438707253884945296925394581802655 0.31887881187339684620076177026181758884 + 0 0 -0.15715217612872593659809486760257994179 0.27482845386440493216991697942238502071 + 0.83459535111470834854355609376418165506 0 -0.80510531794907605316224881154681003606 0.09853490116354529166000184266852321827 + 0 0.83459535111470834854355609376418165506 -0.80510531794907605316224881154681003606 0.09853490116354529166000184266852321827 + -0.83459535111470834854355609376418165506 0 -0.80510531794907605316224881154681003606 0.09853490116354529166000184266852321827 + 0 -0.83459535111470834854355609376418165506 -0.80510531794907605316224881154681003606 0.09853490116354529166000184266852321827 + 0.4339254093766990953588290760534534212 0 0.13214918124660180928234184789309315759 0.084233545301795354894729459206933067324 + 0 0.4339254093766990953588290760534534212 0.13214918124660180928234184789309315759 0.084233545301795354894729459206933067324 + -0.4339254093766990953588290760534534212 0 0.13214918124660180928234184789309315759 0.084233545301795354894729459206933067324 + 0 -0.4339254093766990953588290760534534212 0.13214918124660180928234184789309315759 0.084233545301795354894729459206933067324 + 0.565680854425675497672813848515505886 0.565680854425675497672813848515505886 -0.94104453830855858213371584535608020131 0.099200345038528745418340651788127467643 + 0.565680854425675497672813848515505886 -0.565680854425675497672813848515505886 -0.94104453830855858213371584535608020131 0.099200345038528745418340651788127467643 + -0.565680854425675497672813848515505886 0.565680854425675497672813848515505886 -0.94104453830855858213371584535608020131 0.099200345038528745418340651788127467643 + -0.565680854425675497672813848515505886 -0.565680854425675497672813848515505886 -0.94104453830855858213371584535608020131 0.099200345038528745418340651788127467643 + 0.49807909178070594245642503041316019049 0.49807909178070594245642503041316019049 -0.47016827357574098280216051103358470857 0.19701969247180494546144986676345270691 + 0.49807909178070594245642503041316019049 -0.49807909178070594245642503041316019049 -0.47016827357574098280216051103358470857 0.19701969247180494546144986676345270691 + -0.49807909178070594245642503041316019049 0.49807909178070594245642503041316019049 -0.47016827357574098280216051103358470857 0.19701969247180494546144986676345270691 + -0.49807909178070594245642503041316019049 -0.49807909178070594245642503041316019049 -0.47016827357574098280216051103358470857 0.19701969247180494546144986676345270691 + 0.95089948721448243656573347456644144515 0.95089948721448243656573347456644144515 -0.90350185873612803037779492533363294921 0.011573761697986328172963248398558769736 + 0.95089948721448243656573347456644144515 -0.95089948721448243656573347456644144515 -0.90350185873612803037779492533363294921 0.011573761697986328172963248398558769736 + -0.95089948721448243656573347456644144515 0.95089948721448243656573347456644144515 -0.90350185873612803037779492533363294921 0.011573761697986328172963248398558769736 + -0.95089948721448243656573347456644144515 -0.95089948721448243656573347456644144515 -0.90350185873612803037779492533363294921 0.011573761697986328172963248398558769736 + ] + else + throw(ArgumentError("unsupported order for prism polyquad integration")) + end # # The above quadrature rule is defined for a pyramid spanning [-1,1] × [-1,1] × [-1,1], with volume 8/3 and with 5th node in center. # The reference pyramid in ferrite spans [0,1] × [0,1] × [0,1], with volume 1/3 and with 5th node in corner. # Here we map thequadrature points to the pyramid defined in Ferrite. - f1(x, y, z) = (0.5(x + 1.0), 0.5(y + 1.0), 0.5(z + 1.0)) #Shrink pyramid and translate - f2(x, y, z) = (x - 0.5z, y - 0.5z, z) #Skew 5th node to be above first node - f3(x, y, z) = f2(f1(x, y, z)...) + f1(x,y,z) = (0.5(x+1.0), 0.5(y+1.0), 0.5(z+1.0)) #Shrink pyramid and translate + f2(x,y,z) = (x-0.5z, y-0.5z, z) #Skew 5th node to be above first node + f3(x,y,z) = f2(f1(x,y,z)...) for i in axes(xw, 1) - x, y, z, w = xw[i, :] - x, y, z = f3(x, y, z) + x,y,z,w = xw[i,:] + x,y,z = f3(x,y,z) xw[i, 1] = x xw[i, 2] = y xw[i, 3] = z - xw[i, 4] = w * ((1 / 3) / (8 / 3)) + xw[i, 4] = w * ((1/3)/(8/3)) end - return xw + return xw end diff --git a/src/Quadrature/gaussquad_tet_table.jl b/src/Quadrature/gaussquad_tet_table.jl index 711a683b80..6729492cea 100644 --- a/src/Quadrature/gaussquad_tet_table.jl +++ b/src/Quadrature/gaussquad_tet_table.jl @@ -1,32 +1,29 @@ +# runic: off # Yu, Jinyun. Symmetric Gaussian Quadrature Formulae for Tetrahedronal Regions. 1984. CMAME. function _get_jinyun_tet_quadrature_data(n::Int) if n == 1 - a = 1.0 / 4.0 - w = 1.0 / 6.0 + a = 1. / 4. + w = 1. / 6. xw = [a a a w] elseif n == 2 - a = (5.0 + 3.0 * √(5.0)) / 20.0 - b = (5.0 - √(5.0)) / 20.0 - w = 1.0 / 24.0 - xw = [ - a b b w - b a b w - b b a w - b b b w - ] + a = ( 5. + 3. * √(5.) ) / 20. + b = ( 5. - √(5.) ) / 20. + w = 1. / 24. + xw = [a b b w + b a b w + b b a w + b b b w] elseif n == 3 - a1 = 1.0 / 4.0 - a2 = 1.0 / 2.0 - b2 = 1.0 / 6.0 - w1 = -2.0 / 15.0 - w2 = 3.0 / 40.0 - xw = [ - a1 a1 a1 w1 - a2 b2 b2 w2 - b2 a2 b2 w2 - b2 b2 a2 w2 - b2 b2 b2 w2 - ] + a1 = 1. / 4. + a2 = 1. / 2. + b2 = 1. / 6. + w1 = -2. / 15. + w2 = 3. / 40. + xw = [a1 a1 a1 w1 + a2 b2 b2 w2 + b2 a2 b2 w2 + b2 b2 a2 w2 + b2 b2 b2 w2] elseif 4 ≤ n ≤ 6 throw(ArgumentError("Jinyun's Gauss quadrature rule (RefTetrahedron) is not implemented for orders 4 and 6")) else @@ -42,63 +39,59 @@ function _get_keast_a_tet_quadrature_data(n::Int) # The rules of Jinyin and Keast are identical for order 1 to 3, as stated in the Keast paper. xw = _get_jinyun_tet_quadrature_data(n) elseif n == 4 - a1 = 1.0 / 4.0 - w1 = -74.0 / 5625.0 + a1 = 1. / 4.; + w1 = -74. / 5625.; - a2 = 5.0 / 70.0 - b2 = 11.0 / 14.0 - w2 = 343.0 / 45000.0 + a2 = 5. / 70.; + b2 = 11. / 14.; + w2 = 343. / 45000.; - a3 = (1.0 + √(5.0 / 14.0)) / 4.0 - b3 = (1.0 - √(5.0 / 14.0)) / 4.0 - w3 = 28.0 / 1125.0 + a3 = ( 1. + √(5. / 14.) ) / 4.; + b3 = ( 1. - √(5. / 14.) ) / 4.; + w3 = 28. / 1125.; - xw = [ - a1 a1 a1 w1 - b2 a2 a2 w2 - a2 b2 a2 w2 - a2 a2 b2 w2 - a2 a2 a2 w2 - a3 a3 b3 w3 - a3 b3 a3 w3 - a3 b3 b3 w3 - b3 a3 a3 w3 - b3 a3 b3 w3 - b3 b3 a3 w3 - ] + xw = [a1 a1 a1 w1 + b2 a2 a2 w2 + a2 b2 a2 w2 + a2 a2 b2 w2 + a2 a2 a2 w2 + a3 a3 b3 w3 + a3 b3 a3 w3 + a3 b3 b3 w3 + b3 a3 a3 w3 + b3 a3 b3 w3 + b3 b3 a3 w3] elseif n == 5 w1 = 0.602678571428571597e-2 - a1 = 1.0 / 3.0 - b1 = 0.0 + a1 = 1. / 3. + b1 = 0. w2 = 0.302836780970891856e-1 - a2 = 1.0 / 4.0 + a2 = 1. / 4. w3 = 0.116452490860289742e-1 - a3 = 1.0 / 11.0 - b3 = 8.0 / 11.0 + a3 = 1. / 11. + b3 = 8. / 11. w4 = 0.109491415613864534e-1 a4 = 0.665501535736642813e-1 b4 = 0.433449846426335728e-0 - xw = [ - a1 a1 a1 w1 - a1 a1 b1 w1 - a1 b1 a1 w1 - b1 a1 a1 w1 - a2 a2 a2 w2 - a3 a3 a3 w3 - a3 a3 b3 w3 - a3 b3 a3 w3 - b3 a3 a3 w3 - a4 a4 b4 w4 - a4 b4 a4 w4 - a4 b4 b4 w4 - b4 a4 a4 w4 - b4 a4 b4 w4 - b4 b4 a4 w4 - ] + xw = [a1 a1 a1 w1 + a1 a1 b1 w1 + a1 b1 a1 w1 + b1 a1 a1 w1 + a2 a2 a2 w2 + a3 a3 a3 w3 + a3 a3 b3 w3 + a3 b3 a3 w3 + b3 a3 a3 w3 + a4 a4 b4 w4 + a4 b4 a4 w4 + a4 b4 b4 w4 + b4 a4 a4 w4 + b4 a4 b4 w4 + b4 b4 a4 w4] elseif 6 ≤ n ≤ 8 throw(ArgumentError("Keast's Gauss quadrature rule (RefTetrahedron) not implement for order 6 to 8")) else @@ -110,8 +103,8 @@ end # Positive points function _get_keast_b_tet_quadrature_data(n::Int) if n == 4 - w1 = 0.31746031746031745e-2 - a1 = 1.0 / 2.0 + w1 = 0.317460317460317450e-2 + a1 = 1. / 2. b1 = 0.0 w2 = 0.147649707904967828e-1 @@ -122,22 +115,20 @@ function _get_keast_b_tet_quadrature_data(n::Int) a3 = 0.314372873493192195e-0 b3 = 0.568813795204234229e-1 - xw = [ - a1 a1 b1 w1 - a1 b1 a1 w1 - a1 b1 b1 w1 - b1 a1 a1 w1 - b1 a1 b1 w1 - b1 b1 a1 w1 - a2 a2 a2 w2 - a2 a2 b2 w2 - a2 b2 a2 w2 - b2 a2 a2 w2 - a3 a3 a3 w3 - a3 a3 b3 w3 - a3 b3 a3 w3 - b3 a3 a3 w3 - ] + xw = [a1 a1 b1 w1 + a1 b1 a1 w1 + a1 b1 b1 w1 + b1 a1 a1 w1 + b1 a1 b1 w1 + b1 b1 a1 w1 + a2 a2 a2 w2 + a2 a2 b2 w2 + a2 b2 a2 w2 + b2 a2 a2 w2 + a3 a3 a3 w3 + a3 a3 b3 w3 + a3 b3 a3 w3 + b3 a3 a3 w3] else xw = _get_keast_a_tet_quadrature_data(n) end diff --git a/src/Quadrature/gaussquad_tri_table.jl b/src/Quadrature/gaussquad_tri_table.jl index 228cf49c02..d0a1232d5c 100644 --- a/src/Quadrature/gaussquad_tri_table.jl +++ b/src/Quadrature/gaussquad_tri_table.jl @@ -1,3 +1,4 @@ +# runic: off # Order 1 to 8 heights points / wheights have been suggested in # Dunavant, D. A. (1985), High degree efficient symmetrical Gaussian quadrature # rules for the triangle. Int. J. Numer. Meth. Engng., 21: 1129–1148. doi: @@ -7,89 +8,75 @@ function _get_dunavant_gauss_tridata(n::Int) if (n == 1) - xw = [0.33333333333333 0.33333333333333 1.0 / 2.0] + xw=[0.33333333333333 0.33333333333333 1.00000000000000 / 2.0]; elseif (n == 2) - xw = [ - 0.16666666666667 0.16666666666667 0.33333333333333 / 2.0 - 0.16666666666667 0.66666666666667 0.33333333333333 / 2.0 - 0.66666666666667 0.16666666666667 0.33333333333333 / 2.0 - ] + xw=[0.16666666666667 0.16666666666667 0.33333333333333 / 2.0 + 0.16666666666667 0.66666666666667 0.33333333333333 / 2.0 + 0.66666666666667 0.16666666666667 0.33333333333333 / 2.0]; elseif (n == 3) - xw = [ - 0.33333333333333 0.33333333333333 -0.5625 / 2.0 - 0.2 0.2 0.52083333333333 / 2.0 - 0.2 0.6 0.52083333333333 / 2.0 - 0.6 0.2 0.52083333333333 / 2.0 - ] + xw=[0.33333333333333 0.33333333333333 -0.56250000000000 / 2.0 + 0.20000000000000 0.20000000000000 0.52083333333333 / 2.0 + 0.20000000000000 0.60000000000000 0.52083333333333 / 2.0 + 0.60000000000000 0.20000000000000 0.52083333333333 / 2.0]; elseif (n == 4) - xw = [ - 0.44594849091597 0.44594849091597 0.22338158967801 / 2.0 - 0.44594849091597 0.10810301816807 0.22338158967801 / 2.0 - 0.10810301816807 0.44594849091597 0.22338158967801 / 2.0 - 0.09157621350977 0.09157621350977 0.10995174365532 / 2.0 - 0.09157621350977 0.81684757298046 0.10995174365532 / 2.0 - 0.81684757298046 0.09157621350977 0.10995174365532 / 2.0 - ] + xw=[0.44594849091597 0.44594849091597 0.22338158967801 / 2.0 + 0.44594849091597 0.10810301816807 0.22338158967801 / 2.0 + 0.10810301816807 0.44594849091597 0.22338158967801 / 2.0 + 0.09157621350977 0.09157621350977 0.10995174365532 / 2.0 + 0.09157621350977 0.81684757298046 0.10995174365532 / 2.0 + 0.81684757298046 0.09157621350977 0.10995174365532 / 2.0]; elseif (n == 5) - xw = [ - 0.33333333333333 0.33333333333333 0.225 / 2.0 - 0.47014206410511 0.47014206410511 0.13239415278851 / 2.0 - 0.47014206410511 0.05971587178977 0.13239415278851 / 2.0 - 0.05971587178977 0.47014206410511 0.13239415278851 / 2.0 - 0.10128650732346 0.10128650732346 0.12593918054483 / 2.0 - 0.10128650732346 0.79742698535309 0.12593918054483 / 2.0 - 0.79742698535309 0.10128650732346 0.12593918054483 / 2.0 - ] + xw=[0.33333333333333 0.33333333333333 0.22500000000000 / 2.0 + 0.47014206410511 0.47014206410511 0.13239415278851 / 2.0 + 0.47014206410511 0.05971587178977 0.13239415278851 / 2.0 + 0.05971587178977 0.47014206410511 0.13239415278851 / 2.0 + 0.10128650732346 0.10128650732346 0.12593918054483 / 2.0 + 0.10128650732346 0.79742698535309 0.12593918054483 / 2.0 + 0.79742698535309 0.10128650732346 0.12593918054483 / 2.0]; elseif (n == 6) - xw = [ - 0.24928674517091 0.24928674517091 0.11678627572638 / 2.0 - 0.24928674517091 0.50142650965818 0.11678627572638 / 2.0 - 0.50142650965818 0.24928674517091 0.11678627572638 / 2.0 - 0.0630890144915 0.0630890144915 0.05084490637021 / 2.0 - 0.0630890144915 0.873821971017 0.05084490637021 / 2.0 - 0.873821971017 0.0630890144915 0.05084490637021 / 2.0 - 0.31035245103378 0.6365024991214 0.08285107561837 / 2.0 - 0.6365024991214 0.05314504984482 0.08285107561837 / 2.0 - 0.05314504984482 0.31035245103378 0.08285107561837 / 2.0 - 0.6365024991214 0.31035245103378 0.08285107561837 / 2.0 - 0.31035245103378 0.05314504984482 0.08285107561837 / 2.0 - 0.05314504984482 0.6365024991214 0.08285107561837 / 2.0 - ] + xw=[0.24928674517091 0.24928674517091 0.11678627572638 / 2.0 + 0.24928674517091 0.50142650965818 0.11678627572638 / 2.0 + 0.50142650965818 0.24928674517091 0.11678627572638 / 2.0 + 0.06308901449150 0.06308901449150 0.05084490637021 / 2.0 + 0.06308901449150 0.87382197101700 0.05084490637021 / 2.0 + 0.87382197101700 0.06308901449150 0.05084490637021 / 2.0 + 0.31035245103378 0.63650249912140 0.08285107561837 / 2.0 + 0.63650249912140 0.05314504984482 0.08285107561837 / 2.0 + 0.05314504984482 0.31035245103378 0.08285107561837 / 2.0 + 0.63650249912140 0.31035245103378 0.08285107561837 / 2.0 + 0.31035245103378 0.05314504984482 0.08285107561837 / 2.0 + 0.05314504984482 0.63650249912140 0.08285107561837 / 2.0]; elseif (n == 7) - xw = [ - 0.33333333333333 0.33333333333333 -0.14957004446768 / 2.0 - 0.26034596607904 0.26034596607904 0.17561525743321 / 2.0 - 0.26034596607904 0.47930806784192 0.17561525743321 / 2.0 - 0.47930806784192 0.26034596607904 0.17561525743321 / 2.0 - 0.06513010290222 0.06513010290222 0.05334723560884 / 2.0 - 0.06513010290222 0.86973979419557 0.05334723560884 / 2.0 - 0.86973979419557 0.06513010290222 0.05334723560884 / 2.0 - 0.31286549600487 0.63844418856981 0.07711376089026 / 2.0 - 0.63844418856981 0.04869031542532 0.07711376089026 / 2.0 - 0.04869031542532 0.31286549600487 0.07711376089026 / 2.0 - 0.63844418856981 0.31286549600487 0.07711376089026 / 2.0 - 0.31286549600487 0.04869031542532 0.07711376089026 / 2.0 - 0.04869031542532 0.63844418856981 0.07711376089026 / 2.0 - ] + xw=[0.33333333333333 0.33333333333333 -0.14957004446768 / 2.0 + 0.26034596607904 0.26034596607904 0.17561525743321 / 2.0 + 0.26034596607904 0.47930806784192 0.17561525743321 / 2.0 + 0.47930806784192 0.26034596607904 0.17561525743321 / 2.0 + 0.06513010290222 0.06513010290222 0.05334723560884 / 2.0 + 0.06513010290222 0.86973979419557 0.05334723560884 / 2.0 + 0.86973979419557 0.06513010290222 0.05334723560884 / 2.0 + 0.31286549600487 0.63844418856981 0.07711376089026 / 2.0 + 0.63844418856981 0.04869031542532 0.07711376089026 / 2.0 + 0.04869031542532 0.31286549600487 0.07711376089026 / 2.0 + 0.63844418856981 0.31286549600487 0.07711376089026 / 2.0 + 0.31286549600487 0.04869031542532 0.07711376089026 / 2.0 + 0.04869031542532 0.63844418856981 0.07711376089026 / 2.0]; elseif (n == 8) - xw = [ - 0.33333333333333 0.33333333333333 0.14431560767779 / 2.0 - 0.45929258829272 0.45929258829272 0.09509163426728 / 2.0 - 0.45929258829272 0.08141482341455 0.09509163426728 / 2.0 - 0.08141482341455 0.45929258829272 0.09509163426728 / 2.0 - 0.17056930775176 0.17056930775176 0.10321737053472 / 2.0 - 0.17056930775176 0.65886138449648 0.10321737053472 / 2.0 - 0.65886138449648 0.17056930775176 0.10321737053472 / 2.0 - 0.05054722831703 0.05054722831703 0.0324584976232 / 2.0 - 0.05054722831703 0.89890554336594 0.0324584976232 / 2.0 - 0.89890554336594 0.05054722831703 0.0324584976232 / 2.0 - 0.26311282963464 0.7284923929554 0.02723031417443 / 2.0 - 0.7284923929554 0.00839477740996 0.02723031417443 / 2.0 - 0.00839477740996 0.26311282963464 0.02723031417443 / 2.0 - 0.7284923929554 0.26311282963464 0.02723031417443 / 2.0 - 0.26311282963464 0.00839477740996 0.02723031417443 / 2.0 - 0.00839477740996 0.7284923929554 0.02723031417443 / 2.0 - ] + xw=[0.33333333333333 0.33333333333333 0.14431560767779 / 2.0 + 0.45929258829272 0.45929258829272 0.09509163426728 / 2.0 + 0.45929258829272 0.08141482341455 0.09509163426728 / 2.0 + 0.08141482341455 0.45929258829272 0.09509163426728 / 2.0 + 0.17056930775176 0.17056930775176 0.10321737053472 / 2.0 + 0.17056930775176 0.65886138449648 0.10321737053472 / 2.0 + 0.65886138449648 0.17056930775176 0.10321737053472 / 2.0 + 0.05054722831703 0.05054722831703 0.03245849762320 / 2.0 + 0.05054722831703 0.89890554336594 0.03245849762320 / 2.0 + 0.89890554336594 0.05054722831703 0.03245849762320 / 2.0 + 0.26311282963464 0.72849239295540 0.02723031417443 / 2.0 + 0.72849239295540 0.00839477740996 0.02723031417443 / 2.0 + 0.00839477740996 0.26311282963464 0.02723031417443 / 2.0 + 0.72849239295540 0.26311282963464 0.02723031417443 / 2.0 + 0.26311282963464 0.00839477740996 0.02723031417443 / 2.0 + 0.00839477740996 0.72849239295540 0.02723031417443 / 2.0]; else throw(ArgumentError("unsupported order for Dunavant's triangle integration")) end @@ -108,769 +95,755 @@ end # näherungsweise zu finden." (1826): 301-308. function _get_gaussjacobi_tridata(n::Int) if n == 9 - xw = [ - 0.4171034443615992 0.4171034443615992 0.0136554632640511 - 0.1803581162663707 0.1803581162663707 0.013156315294009 - 0.2857065024365867 0.2857065024365867 0.0188581185763976 - 0.066654063479597 0.066654063479597 0.0062295004011527 - 0.0147554916607541 0.0147554916607541 0.0013869437888188 - 0.4655978716188903 0.4655978716188903 0.0125097254752487 - 0.4171034443615992 0.1657931112768016 0.0136554632640511 - 0.1803581162663707 0.6392837674672587 0.013156315294009 - 0.2857065024365867 0.4285869951268266 0.0188581185763976 - 0.066654063479597 0.866691873040806 0.0062295004011527 - 0.0147554916607541 0.9704890166784919 0.0013869437888188 - 0.4655978716188903 0.0688042567622195 0.0125097254752487 - 0.1657931112768016 0.4171034443615992 0.0136554632640511 - 0.6392837674672587 0.1803581162663707 0.013156315294009 - 0.4285869951268266 0.2857065024365867 0.0188581185763976 - 0.866691873040806 0.066654063479597 0.0062295004011527 - 0.9704890166784919 0.0147554916607541 0.0013869437888188 - 0.0688042567622195 0.4655978716188903 0.0125097254752487 - 0.0115751759031807 0.0725054707990024 0.0022921742008679 - 0.013229672760087 0.4154754592952291 0.0051992199779198 - 0.0131358708340028 0.2717918700553548 0.0043461072505006 - 0.1575054779268699 0.2992189424769703 0.0130858129676685 - 0.0673493778673612 0.3062815917461865 0.0112438862733455 - 0.0780423405682825 0.1687225134952594 0.0102789491602273 - 0.0160176423621193 0.1591922874727927 0.0039891501029648 - 0.9159193532978169 0.0115751759031807 0.0022921742008679 - 0.5712948679446841 0.013229672760087 0.0051992199779198 - 0.7150722591106424 0.0131358708340028 0.0043461072505006 - 0.5432755795961598 0.1575054779268699 0.0130858129676685 - 0.6263690303864522 0.0673493778673612 0.0112438862733455 - 0.7532351459364581 0.0780423405682825 0.0102789491602273 - 0.824790070165088 0.0160176423621193 0.0039891501029648 - 0.0725054707990024 0.9159193532978169 0.0022921742008679 - 0.4154754592952291 0.5712948679446841 0.0051992199779198 - 0.2717918700553548 0.7150722591106424 0.0043461072505006 - 0.2992189424769703 0.5432755795961598 0.0130858129676685 - 0.3062815917461865 0.6263690303864522 0.0112438862733455 - 0.1687225134952594 0.7532351459364581 0.0102789491602273 - 0.1591922874727927 0.824790070165088 0.0039891501029648 - 0.0725054707990024 0.0115751759031807 0.0022921742008679 - 0.4154754592952291 0.013229672760087 0.0051992199779198 - 0.2717918700553548 0.0131358708340028 0.0043461072505006 - 0.2992189424769703 0.1575054779268699 0.0130858129676685 - 0.3062815917461865 0.0673493778673612 0.0112438862733455 - 0.1687225134952594 0.0780423405682825 0.0102789491602273 - 0.1591922874727927 0.0160176423621193 0.0039891501029648 - 0.9159193532978169 0.0725054707990024 0.0022921742008679 - 0.5712948679446841 0.4154754592952291 0.0051992199779198 - 0.7150722591106424 0.2717918700553548 0.0043461072505006 - 0.5432755795961598 0.2992189424769703 0.0130858129676685 - 0.6263690303864522 0.3062815917461865 0.0112438862733455 - 0.7532351459364581 0.1687225134952594 0.0102789491602273 - 0.824790070165088 0.1591922874727927 0.0039891501029648 - 0.0115751759031807 0.9159193532978169 0.0022921742008679 - 0.013229672760087 0.5712948679446841 0.0051992199779198 - 0.0131358708340028 0.7150722591106424 0.0043461072505006 - 0.1575054779268699 0.5432755795961598 0.0130858129676685 - 0.0673493778673612 0.6263690303864522 0.0112438862733455 - 0.0780423405682825 0.7532351459364581 0.0102789491602273 - 0.0160176423621193 0.824790070165088 0.0039891501029648 - ] + xw=[0.4171034443615992 0.4171034443615992 0.0136554632640511 + 0.1803581162663707 0.1803581162663707 0.0131563152940090 + 0.2857065024365867 0.2857065024365867 0.0188581185763976 + 0.0666540634795970 0.0666540634795970 0.0062295004011527 + 0.0147554916607541 0.0147554916607541 0.0013869437888188 + 0.4655978716188903 0.4655978716188903 0.0125097254752487 + 0.4171034443615992 0.1657931112768016 0.0136554632640511 + 0.1803581162663707 0.6392837674672587 0.0131563152940090 + 0.2857065024365867 0.4285869951268266 0.0188581185763976 + 0.0666540634795970 0.8666918730408060 0.0062295004011527 + 0.0147554916607541 0.9704890166784919 0.0013869437888188 + 0.4655978716188903 0.0688042567622195 0.0125097254752487 + 0.1657931112768016 0.4171034443615992 0.0136554632640511 + 0.6392837674672587 0.1803581162663707 0.0131563152940090 + 0.4285869951268266 0.2857065024365867 0.0188581185763976 + 0.8666918730408060 0.0666540634795970 0.0062295004011527 + 0.9704890166784919 0.0147554916607541 0.0013869437888188 + 0.0688042567622195 0.4655978716188903 0.0125097254752487 + 0.0115751759031807 0.0725054707990024 0.0022921742008679 + 0.0132296727600870 0.4154754592952291 0.0051992199779198 + 0.0131358708340028 0.2717918700553548 0.0043461072505006 + 0.1575054779268699 0.2992189424769703 0.0130858129676685 + 0.0673493778673612 0.3062815917461865 0.0112438862733455 + 0.0780423405682825 0.1687225134952594 0.0102789491602273 + 0.0160176423621193 0.1591922874727927 0.0039891501029648 + 0.9159193532978169 0.0115751759031807 0.0022921742008679 + 0.5712948679446841 0.0132296727600870 0.0051992199779198 + 0.7150722591106424 0.0131358708340028 0.0043461072505006 + 0.5432755795961598 0.1575054779268699 0.0130858129676685 + 0.6263690303864522 0.0673493778673612 0.0112438862733455 + 0.7532351459364581 0.0780423405682825 0.0102789491602273 + 0.8247900701650880 0.0160176423621193 0.0039891501029648 + 0.0725054707990024 0.9159193532978169 0.0022921742008679 + 0.4154754592952291 0.5712948679446841 0.0051992199779198 + 0.2717918700553548 0.7150722591106424 0.0043461072505006 + 0.2992189424769703 0.5432755795961598 0.0130858129676685 + 0.3062815917461865 0.6263690303864522 0.0112438862733455 + 0.1687225134952594 0.7532351459364581 0.0102789491602273 + 0.1591922874727927 0.8247900701650880 0.0039891501029648 + 0.0725054707990024 0.0115751759031807 0.0022921742008679 + 0.4154754592952291 0.0132296727600870 0.0051992199779198 + 0.2717918700553548 0.0131358708340028 0.0043461072505006 + 0.2992189424769703 0.1575054779268699 0.0130858129676685 + 0.3062815917461865 0.0673493778673612 0.0112438862733455 + 0.1687225134952594 0.0780423405682825 0.0102789491602273 + 0.1591922874727927 0.0160176423621193 0.0039891501029648 + 0.9159193532978169 0.0725054707990024 0.0022921742008679 + 0.5712948679446841 0.4154754592952291 0.0051992199779198 + 0.7150722591106424 0.2717918700553548 0.0043461072505006 + 0.5432755795961598 0.2992189424769703 0.0130858129676685 + 0.6263690303864522 0.3062815917461865 0.0112438862733455 + 0.7532351459364581 0.1687225134952594 0.0102789491602273 + 0.8247900701650880 0.1591922874727927 0.0039891501029648 + 0.0115751759031807 0.9159193532978169 0.0022921742008679 + 0.0132296727600870 0.5712948679446841 0.0051992199779198 + 0.0131358708340028 0.7150722591106424 0.0043461072505006 + 0.1575054779268699 0.5432755795961598 0.0130858129676685 + 0.0673493778673612 0.6263690303864522 0.0112438862733455 + 0.0780423405682825 0.7532351459364581 0.0102789491602273 + 0.0160176423621193 0.8247900701650880 0.0039891501029648] elseif n == 10 - xw = [ - 0.3333333333333333 0.3333333333333333 0.0172345804254526 - 0.0525262798541036 0.0525262798541036 0.0035546968113975 - 0.1114480557169988 0.1114480557169988 0.0076174782585024 - 0.0116390273279227 0.0116390273279227 0.0008825962091543 - 0.2551621331531249 0.2551621331531249 0.015876427293765 - 0.4039697179663861 0.4039697179663861 0.0157686793226198 - 0.1781710060796275 0.1781710060796275 0.0123259905267924 - 0.4591943889568276 0.4591943889568276 0.0114917854885616 - 0.4925124498658742 0.4925124498658742 0.0051609410912094 - 0.0525262798541036 0.8949474402917927 0.0035546968113975 - 0.1114480557169988 0.7771038885660024 0.0076174782585024 - 0.0116390273279227 0.9767219453441547 0.0008825962091543 - 0.2551621331531249 0.4896757336937503 0.015876427293765 - 0.4039697179663861 0.1920605640672278 0.0157686793226198 - 0.1781710060796275 0.6436579878407449 0.0123259905267924 - 0.4591943889568276 0.0816112220863447 0.0114917854885616 - 0.4925124498658742 0.0149751002682516 0.0051609410912094 - 0.8949474402917927 0.0525262798541036 0.0035546968113975 - 0.7771038885660024 0.1114480557169988 0.0076174782585024 - 0.9767219453441547 0.0116390273279227 0.0008825962091543 - 0.4896757336937503 0.2551621331531249 0.015876427293765 - 0.1920605640672278 0.4039697179663861 0.0157686793226198 - 0.6436579878407449 0.1781710060796275 0.0123259905267924 - 0.0816112220863447 0.4591943889568276 0.0114917854885616 - 0.0149751002682516 0.4925124498658742 0.0051609410912094 - 0.0050051423523504 0.1424222825711269 0.00146284624394 - 0.0097770614386769 0.0600838999627024 0.001663694420297 - 0.0391424494346088 0.1307006699605345 0.0048477595408121 - 0.129312809767979 0.3113183832239869 0.0131731323537227 - 0.0745611893043551 0.2214339418891134 0.0090540372952153 - 0.0408883144649781 0.3540259269997119 0.0080511047304697 - 0.0149236389074385 0.2418941040068926 0.0042279624195467 - 0.0020691038491024 0.36462041433871 0.0016410687574199 - 0.8525725750765227 0.0050051423523504 0.00146284624394 - 0.9301390385986208 0.0097770614386769 0.001663694420297 - 0.8301568806048566 0.0391424494346088 0.0048477595408121 - 0.5593688070080342 0.129312809767979 0.0131731323537227 - 0.7040048688065313 0.0745611893043551 0.0090540372952153 - 0.60508575853531 0.0408883144649781 0.0080511047304697 - 0.7431822570856689 0.0149236389074385 0.0042279624195467 - 0.6333104818121875 0.0020691038491024 0.0016410687574199 - 0.1424222825711269 0.8525725750765227 0.00146284624394 - 0.0600838999627024 0.9301390385986208 0.001663694420297 - 0.1307006699605345 0.8301568806048566 0.0048477595408121 - 0.3113183832239869 0.5593688070080342 0.0131731323537227 - 0.2214339418891134 0.7040048688065313 0.0090540372952153 - 0.3540259269997119 0.60508575853531 0.0080511047304697 - 0.2418941040068926 0.7431822570856689 0.0042279624195467 - 0.36462041433871 0.6333104818121875 0.0016410687574199 - 0.1424222825711269 0.0050051423523504 0.00146284624394 - 0.0600838999627024 0.0097770614386769 0.001663694420297 - 0.1307006699605345 0.0391424494346088 0.0048477595408121 - 0.3113183832239869 0.129312809767979 0.0131731323537227 - 0.2214339418891134 0.0745611893043551 0.0090540372952153 - 0.3540259269997119 0.0408883144649781 0.0080511047304697 - 0.2418941040068926 0.0149236389074385 0.0042279624195467 - 0.36462041433871 0.0020691038491024 0.0016410687574199 - 0.8525725750765227 0.1424222825711269 0.00146284624394 - 0.9301390385986208 0.0600838999627024 0.001663694420297 - 0.8301568806048566 0.1307006699605345 0.0048477595408121 - 0.5593688070080342 0.3113183832239869 0.0131731323537227 - 0.7040048688065313 0.2214339418891134 0.0090540372952153 - 0.60508575853531 0.3540259269997119 0.0080511047304697 - 0.7431822570856689 0.2418941040068926 0.0042279624195467 - 0.6333104818121875 0.36462041433871 0.0016410687574199 - 0.0050051423523504 0.8525725750765227 0.00146284624394 - 0.0097770614386769 0.9301390385986208 0.001663694420297 - 0.0391424494346088 0.8301568806048566 0.0048477595408121 - 0.129312809767979 0.5593688070080342 0.0131731323537227 - 0.0745611893043551 0.7040048688065313 0.0090540372952153 - 0.0408883144649781 0.60508575853531 0.0080511047304697 - 0.0149236389074385 0.7431822570856689 0.0042279624195467 - 0.0020691038491024 0.6333104818121875 0.0016410687574199 - ] + xw=[0.3333333333333333 0.3333333333333333 0.0172345804254526 + 0.0525262798541036 0.0525262798541036 0.0035546968113975 + 0.1114480557169988 0.1114480557169988 0.0076174782585024 + 0.0116390273279227 0.0116390273279227 0.0008825962091543 + 0.2551621331531249 0.2551621331531249 0.0158764272937650 + 0.4039697179663861 0.4039697179663861 0.0157686793226198 + 0.1781710060796275 0.1781710060796275 0.0123259905267924 + 0.4591943889568276 0.4591943889568276 0.0114917854885616 + 0.4925124498658742 0.4925124498658742 0.0051609410912094 + 0.0525262798541036 0.8949474402917927 0.0035546968113975 + 0.1114480557169988 0.7771038885660024 0.0076174782585024 + 0.0116390273279227 0.9767219453441547 0.0008825962091543 + 0.2551621331531249 0.4896757336937503 0.0158764272937650 + 0.4039697179663861 0.1920605640672278 0.0157686793226198 + 0.1781710060796275 0.6436579878407449 0.0123259905267924 + 0.4591943889568276 0.0816112220863447 0.0114917854885616 + 0.4925124498658742 0.0149751002682516 0.0051609410912094 + 0.8949474402917927 0.0525262798541036 0.0035546968113975 + 0.7771038885660024 0.1114480557169988 0.0076174782585024 + 0.9767219453441547 0.0116390273279227 0.0008825962091543 + 0.4896757336937503 0.2551621331531249 0.0158764272937650 + 0.1920605640672278 0.4039697179663861 0.0157686793226198 + 0.6436579878407449 0.1781710060796275 0.0123259905267924 + 0.0816112220863447 0.4591943889568276 0.0114917854885616 + 0.0149751002682516 0.4925124498658742 0.0051609410912094 + 0.0050051423523504 0.1424222825711269 0.0014628462439400 + 0.0097770614386769 0.0600838999627024 0.0016636944202970 + 0.0391424494346088 0.1307006699605345 0.0048477595408121 + 0.1293128097679790 0.3113183832239869 0.0131731323537227 + 0.0745611893043551 0.2214339418891134 0.0090540372952153 + 0.0408883144649781 0.3540259269997119 0.0080511047304697 + 0.0149236389074385 0.2418941040068926 0.0042279624195467 + 0.0020691038491024 0.3646204143387100 0.0016410687574199 + 0.8525725750765227 0.0050051423523504 0.0014628462439400 + 0.9301390385986208 0.0097770614386769 0.0016636944202970 + 0.8301568806048566 0.0391424494346088 0.0048477595408121 + 0.5593688070080342 0.1293128097679790 0.0131731323537227 + 0.7040048688065313 0.0745611893043551 0.0090540372952153 + 0.6050857585353100 0.0408883144649781 0.0080511047304697 + 0.7431822570856689 0.0149236389074385 0.0042279624195467 + 0.6333104818121875 0.0020691038491024 0.0016410687574199 + 0.1424222825711269 0.8525725750765227 0.0014628462439400 + 0.0600838999627024 0.9301390385986208 0.0016636944202970 + 0.1307006699605345 0.8301568806048566 0.0048477595408121 + 0.3113183832239869 0.5593688070080342 0.0131731323537227 + 0.2214339418891134 0.7040048688065313 0.0090540372952153 + 0.3540259269997119 0.6050857585353100 0.0080511047304697 + 0.2418941040068926 0.7431822570856689 0.0042279624195467 + 0.3646204143387100 0.6333104818121875 0.0016410687574199 + 0.1424222825711269 0.0050051423523504 0.0014628462439400 + 0.0600838999627024 0.0097770614386769 0.0016636944202970 + 0.1307006699605345 0.0391424494346088 0.0048477595408121 + 0.3113183832239869 0.1293128097679790 0.0131731323537227 + 0.2214339418891134 0.0745611893043551 0.0090540372952153 + 0.3540259269997119 0.0408883144649781 0.0080511047304697 + 0.2418941040068926 0.0149236389074385 0.0042279624195467 + 0.3646204143387100 0.0020691038491024 0.0016410687574199 + 0.8525725750765227 0.1424222825711269 0.0014628462439400 + 0.9301390385986208 0.0600838999627024 0.0016636944202970 + 0.8301568806048566 0.1307006699605345 0.0048477595408121 + 0.5593688070080342 0.3113183832239869 0.0131731323537227 + 0.7040048688065313 0.2214339418891134 0.0090540372952153 + 0.6050857585353100 0.3540259269997119 0.0080511047304697 + 0.7431822570856689 0.2418941040068926 0.0042279624195467 + 0.6333104818121875 0.3646204143387100 0.0016410687574199 + 0.0050051423523504 0.8525725750765227 0.0014628462439400 + 0.0097770614386769 0.9301390385986208 0.0016636944202970 + 0.0391424494346088 0.8301568806048566 0.0048477595408121 + 0.1293128097679790 0.5593688070080342 0.0131731323537227 + 0.0745611893043551 0.7040048688065313 0.0090540372952153 + 0.0408883144649781 0.6050857585353100 0.0080511047304697 + 0.0149236389074385 0.7431822570856689 0.0042279624195467 + 0.0020691038491024 0.6333104818121875 0.0016410687574199] elseif n == 11 - xw = [ - 0.2989362353149826 0.2989362353149826 0.0107255609645662 - 0.4970078754686856 0.4970078754686856 0.0022189148485329 - 0.4036175865463851 0.4036175865463851 0.0115003523266419 - 0.1189885776227195 0.1189885776227195 0.0068280162261151 - 0.1902887180912786 0.1902887180912786 0.0097276209303754 - 0.4815978686532166 0.4815978686532166 0.0061072050816922 - 0.4498127917753624 0.4498127917753624 0.009807237613912 - 0.053627575546145 0.053627575546145 0.0035760425506418 - 0.0107424564328285 0.0107424564328285 0.0007543496361893 - 0.2989362353149826 0.4021275293700348 0.0107255609645662 - 0.4970078754686856 0.0059842490626288 0.0022189148485329 - 0.4036175865463851 0.1927648269072297 0.0115003523266419 - 0.1189885776227195 0.7620228447545609 0.0068280162261151 - 0.1902887180912786 0.6194225638174429 0.0097276209303754 - 0.4815978686532166 0.0368042626935668 0.0061072050816922 - 0.4498127917753624 0.1003744164492752 0.009807237613912 - 0.053627575546145 0.89274484890771 0.0035760425506418 - 0.0107424564328285 0.978515087134343 0.0007543496361893 - 0.4021275293700348 0.2989362353149826 0.0107255609645662 - 0.0059842490626288 0.4970078754686856 0.0022189148485329 - 0.1927648269072297 0.4036175865463851 0.0115003523266419 - 0.7620228447545609 0.1189885776227195 0.0068280162261151 - 0.6194225638174429 0.1902887180912786 0.0097276209303754 - 0.0368042626935668 0.4815978686532166 0.0061072050816922 - 0.1003744164492752 0.4498127917753624 0.009807237613912 - 0.89274484890771 0.053627575546145 0.0035760425506418 - 0.978515087134343 0.0107424564328285 0.0007543496361893 - 0.2052955593351615 0.2891894960785947 0.0087477080778816 - 0.0069318090314681 0.237873382597994 0.0021030601440749 - 0.1237794004054928 0.3188653107948283 0.0092237424239664 - 0.0389913626232203 0.231873625370401 0.0052349520926624 - 0.0095362475297106 0.1331671229413703 0.0022404065609507 - 0.0530521917012168 0.3468079798099111 0.0072501529594855 - 0.1004580200741145 0.2165996231899825 0.007952018352714 - 0.0494510655685406 0.1288298079620515 0.0049059859112752 - 0.0102546358729245 0.3609534080189222 0.0034199424289672 - 0.0103019036434239 0.055719565072372 0.001632714292022 - 0.5055149445862437 0.2052955593351615 0.0087477080778816 - 0.755194808370538 0.0069318090314681 0.0021030601440749 - 0.557355288799679 0.1237794004054928 0.0092237424239664 - 0.7291350120063786 0.0389913626232203 0.0052349520926624 - 0.8572966295289191 0.0095362475297106 0.0022404065609507 - 0.6001398284888722 0.0530521917012168 0.0072501529594855 - 0.6829423567359031 0.1004580200741145 0.007952018352714 - 0.8217191264694079 0.0494510655685406 0.0049059859112752 - 0.6287919561081533 0.0102546358729245 0.0034199424289672 - 0.9339785312842042 0.0103019036434239 0.001632714292022 - 0.2891894960785947 0.5055149445862437 0.0087477080778816 - 0.237873382597994 0.755194808370538 0.0021030601440749 - 0.3188653107948283 0.557355288799679 0.0092237424239664 - 0.231873625370401 0.7291350120063786 0.0052349520926624 - 0.1331671229413703 0.8572966295289191 0.0022404065609507 - 0.3468079798099111 0.6001398284888722 0.0072501529594855 - 0.2165996231899825 0.6829423567359031 0.007952018352714 - 0.1288298079620515 0.8217191264694079 0.0049059859112752 - 0.3609534080189222 0.6287919561081533 0.0034199424289672 - 0.055719565072372 0.9339785312842042 0.001632714292022 - 0.2891894960785947 0.2052955593351615 0.0087477080778816 - 0.237873382597994 0.0069318090314681 0.0021030601440749 - 0.3188653107948283 0.1237794004054928 0.0092237424239664 - 0.231873625370401 0.0389913626232203 0.0052349520926624 - 0.1331671229413703 0.0095362475297106 0.0022404065609507 - 0.3468079798099111 0.0530521917012168 0.0072501529594855 - 0.2165996231899825 0.1004580200741145 0.007952018352714 - 0.1288298079620515 0.0494510655685406 0.0049059859112752 - 0.3609534080189222 0.0102546358729245 0.0034199424289672 - 0.055719565072372 0.0103019036434239 0.001632714292022 - 0.5055149445862437 0.2891894960785947 0.0087477080778816 - 0.755194808370538 0.237873382597994 0.0021030601440749 - 0.557355288799679 0.3188653107948283 0.0092237424239664 - 0.7291350120063786 0.231873625370401 0.0052349520926624 - 0.8572966295289191 0.1331671229413703 0.0022404065609507 - 0.6001398284888722 0.3468079798099111 0.0072501529594855 - 0.6829423567359031 0.2165996231899825 0.007952018352714 - 0.8217191264694079 0.1288298079620515 0.0049059859112752 - 0.6287919561081533 0.3609534080189222 0.0034199424289672 - 0.9339785312842042 0.055719565072372 0.001632714292022 - 0.2052955593351615 0.5055149445862437 0.0087477080778816 - 0.0069318090314681 0.755194808370538 0.0021030601440749 - 0.1237794004054928 0.557355288799679 0.0092237424239664 - 0.0389913626232203 0.7291350120063786 0.0052349520926624 - 0.0095362475297106 0.8572966295289191 0.0022404065609507 - 0.0530521917012168 0.6001398284888722 0.0072501529594855 - 0.1004580200741145 0.6829423567359031 0.007952018352714 - 0.0494510655685406 0.8217191264694079 0.0049059859112752 - 0.0102546358729245 0.6287919561081533 0.0034199424289672 - 0.0103019036434239 0.9339785312842042 0.001632714292022 - ] + xw=[0.2989362353149826 0.2989362353149826 0.0107255609645662 + 0.4970078754686856 0.4970078754686856 0.0022189148485329 + 0.4036175865463851 0.4036175865463851 0.0115003523266419 + 0.1189885776227195 0.1189885776227195 0.0068280162261151 + 0.1902887180912786 0.1902887180912786 0.0097276209303754 + 0.4815978686532166 0.4815978686532166 0.0061072050816922 + 0.4498127917753624 0.4498127917753624 0.0098072376139120 + 0.0536275755461450 0.0536275755461450 0.0035760425506418 + 0.0107424564328285 0.0107424564328285 0.0007543496361893 + 0.2989362353149826 0.4021275293700348 0.0107255609645662 + 0.4970078754686856 0.0059842490626288 0.0022189148485329 + 0.4036175865463851 0.1927648269072297 0.0115003523266419 + 0.1189885776227195 0.7620228447545609 0.0068280162261151 + 0.1902887180912786 0.6194225638174429 0.0097276209303754 + 0.4815978686532166 0.0368042626935668 0.0061072050816922 + 0.4498127917753624 0.1003744164492752 0.0098072376139120 + 0.0536275755461450 0.8927448489077100 0.0035760425506418 + 0.0107424564328285 0.9785150871343430 0.0007543496361893 + 0.4021275293700348 0.2989362353149826 0.0107255609645662 + 0.0059842490626288 0.4970078754686856 0.0022189148485329 + 0.1927648269072297 0.4036175865463851 0.0115003523266419 + 0.7620228447545609 0.1189885776227195 0.0068280162261151 + 0.6194225638174429 0.1902887180912786 0.0097276209303754 + 0.0368042626935668 0.4815978686532166 0.0061072050816922 + 0.1003744164492752 0.4498127917753624 0.0098072376139120 + 0.8927448489077100 0.0536275755461450 0.0035760425506418 + 0.9785150871343430 0.0107424564328285 0.0007543496361893 + 0.2052955593351615 0.2891894960785947 0.0087477080778816 + 0.0069318090314681 0.2378733825979940 0.0021030601440749 + 0.1237794004054928 0.3188653107948283 0.0092237424239664 + 0.0389913626232203 0.2318736253704010 0.0052349520926624 + 0.0095362475297106 0.1331671229413703 0.0022404065609507 + 0.0530521917012168 0.3468079798099111 0.0072501529594855 + 0.1004580200741145 0.2165996231899825 0.0079520183527140 + 0.0494510655685406 0.1288298079620515 0.0049059859112752 + 0.0102546358729245 0.3609534080189222 0.0034199424289672 + 0.0103019036434239 0.0557195650723720 0.0016327142920220 + 0.5055149445862437 0.2052955593351615 0.0087477080778816 + 0.7551948083705380 0.0069318090314681 0.0021030601440749 + 0.5573552887996790 0.1237794004054928 0.0092237424239664 + 0.7291350120063786 0.0389913626232203 0.0052349520926624 + 0.8572966295289191 0.0095362475297106 0.0022404065609507 + 0.6001398284888722 0.0530521917012168 0.0072501529594855 + 0.6829423567359031 0.1004580200741145 0.0079520183527140 + 0.8217191264694079 0.0494510655685406 0.0049059859112752 + 0.6287919561081533 0.0102546358729245 0.0034199424289672 + 0.9339785312842042 0.0103019036434239 0.0016327142920220 + 0.2891894960785947 0.5055149445862437 0.0087477080778816 + 0.2378733825979940 0.7551948083705380 0.0021030601440749 + 0.3188653107948283 0.5573552887996790 0.0092237424239664 + 0.2318736253704010 0.7291350120063786 0.0052349520926624 + 0.1331671229413703 0.8572966295289191 0.0022404065609507 + 0.3468079798099111 0.6001398284888722 0.0072501529594855 + 0.2165996231899825 0.6829423567359031 0.0079520183527140 + 0.1288298079620515 0.8217191264694079 0.0049059859112752 + 0.3609534080189222 0.6287919561081533 0.0034199424289672 + 0.0557195650723720 0.9339785312842042 0.0016327142920220 + 0.2891894960785947 0.2052955593351615 0.0087477080778816 + 0.2378733825979940 0.0069318090314681 0.0021030601440749 + 0.3188653107948283 0.1237794004054928 0.0092237424239664 + 0.2318736253704010 0.0389913626232203 0.0052349520926624 + 0.1331671229413703 0.0095362475297106 0.0022404065609507 + 0.3468079798099111 0.0530521917012168 0.0072501529594855 + 0.2165996231899825 0.1004580200741145 0.0079520183527140 + 0.1288298079620515 0.0494510655685406 0.0049059859112752 + 0.3609534080189222 0.0102546358729245 0.0034199424289672 + 0.0557195650723720 0.0103019036434239 0.0016327142920220 + 0.5055149445862437 0.2891894960785947 0.0087477080778816 + 0.7551948083705380 0.2378733825979940 0.0021030601440749 + 0.5573552887996790 0.3188653107948283 0.0092237424239664 + 0.7291350120063786 0.2318736253704010 0.0052349520926624 + 0.8572966295289191 0.1331671229413703 0.0022404065609507 + 0.6001398284888722 0.3468079798099111 0.0072501529594855 + 0.6829423567359031 0.2165996231899825 0.0079520183527140 + 0.8217191264694079 0.1288298079620515 0.0049059859112752 + 0.6287919561081533 0.3609534080189222 0.0034199424289672 + 0.9339785312842042 0.0557195650723720 0.0016327142920220 + 0.2052955593351615 0.5055149445862437 0.0087477080778816 + 0.0069318090314681 0.7551948083705380 0.0021030601440749 + 0.1237794004054928 0.5573552887996790 0.0092237424239664 + 0.0389913626232203 0.7291350120063786 0.0052349520926624 + 0.0095362475297106 0.8572966295289191 0.0022404065609507 + 0.0530521917012168 0.6001398284888722 0.0072501529594855 + 0.1004580200741145 0.6829423567359031 0.0079520183527140 + 0.0494510655685406 0.8217191264694079 0.0049059859112752 + 0.0102546358729245 0.6287919561081533 0.0034199424289672 + 0.0103019036434239 0.9339785312842042 0.0016327142920220] elseif n == 12 - xw = [ - 0.3333333333333333 0.3333333333333333 0.0126265301615181 - 0.0390072687570322 0.0390072687570322 0.0019578701295165 - 0.4803288773373085 0.4803288773373085 0.0056989446339004 - 0.0868410482076332 0.0868410482076332 0.0044799585127568 - 0.3943235060115415 0.3943235060115415 0.011837304231564 - 0.2662513178772473 0.2662513178772473 0.0119039314437499 - 0.1371293873116477 0.1371293873116477 0.0072797246963709 - 0.4989594312095863 0.4989594312095863 0.0012037723020907 - 0.4446924421277275 0.4446924421277275 0.0094759753346694 - 0.1987498063965363 0.1987498063965363 0.0099676389400525 - 0.0090164402055984 0.0090164402055984 0.0005326806164147 - 0.0390072687570322 0.9219854624859356 0.0019578701295165 - 0.4803288773373085 0.039342245325383 0.0056989446339004 - 0.0868410482076332 0.8263179035847336 0.0044799585127568 - 0.3943235060115415 0.2113529879769169 0.011837304231564 - 0.2662513178772473 0.4674973642455054 0.0119039314437499 - 0.1371293873116477 0.7257412253767046 0.0072797246963709 - 0.4989594312095863 0.0020811375808274 0.0012037723020907 - 0.4446924421277275 0.110615115744545 0.0094759753346694 - 0.1987498063965363 0.6025003872069274 0.0099676389400525 - 0.0090164402055984 0.9819671195888031 0.0005326806164147 - 0.9219854624859356 0.0390072687570322 0.0019578701295165 - 0.039342245325383 0.4803288773373085 0.0056989446339004 - 0.8263179035847336 0.0868410482076332 0.0044799585127568 - 0.2113529879769169 0.3943235060115415 0.011837304231564 - 0.4674973642455054 0.2662513178772473 0.0119039314437499 - 0.7257412253767046 0.1371293873116477 0.0072797246963709 - 0.0020811375808274 0.4989594312095863 0.0012037723020907 - 0.110615115744545 0.4446924421277275 0.0094759753346694 - 0.6025003872069274 0.1987498063965363 0.0099676389400525 - 0.9819671195888031 0.0090164402055984 0.0005326806164147 - 0.0238702536543536 0.1595037989247572 0.0012640830276911 - 0.0051898217608445 0.1141013603223645 0.0011125098648623 - 0.0327410291887064 0.0955398781717349 0.0026640152155974 - 0.0024475998559664 0.3111622680517019 0.0011405518381279 - 0.0087252895853085 0.2056172320580521 0.002057375172208 - 0.0071625399102445 0.0472616294497253 0.0009762956639454 - 0.068526954187213 0.3585095935696251 0.0074905566965996 - 0.1017283293272842 0.2404827720350127 0.0080606208185086 - 0.0583515752375154 0.172932303129224 0.005235128246565 - 0.1548301554055162 0.3163043076538381 0.0104221979294844 - 0.0147589697299452 0.3977585768030076 0.0035488894172609 - 0.0329937081925328 0.2787941698141023 0.0050877873283535 - 0.8166259474208892 0.0238702536543536 0.0012640830276911 - 0.880708817916791 0.0051898217608445 0.0011125098648623 - 0.8717190926395587 0.0327410291887064 0.0026640152155974 - 0.6863901320923316 0.0024475998559664 0.0011405518381279 - 0.7856574783566395 0.0087252895853085 0.002057375172208 - 0.9455758306400301 0.0071625399102445 0.0009762956639454 - 0.5729634522431619 0.068526954187213 0.0074905566965996 - 0.6577888986377031 0.1017283293272842 0.0080606208185086 - 0.7687161216332605 0.0583515752375154 0.005235128246565 - 0.5288655369406456 0.1548301554055162 0.0104221979294844 - 0.5874824534670472 0.0147589697299452 0.0035488894172609 - 0.688212121993365 0.0329937081925328 0.0050877873283535 - 0.1595037989247572 0.8166259474208892 0.0012640830276911 - 0.1141013603223645 0.880708817916791 0.0011125098648623 - 0.0955398781717349 0.8717190926395587 0.0026640152155974 - 0.3111622680517019 0.6863901320923316 0.0011405518381279 - 0.2056172320580521 0.7856574783566395 0.002057375172208 - 0.0472616294497253 0.9455758306400301 0.0009762956639454 - 0.3585095935696251 0.5729634522431619 0.0074905566965996 - 0.2404827720350127 0.6577888986377031 0.0080606208185086 - 0.172932303129224 0.7687161216332605 0.005235128246565 - 0.3163043076538381 0.5288655369406456 0.0104221979294844 - 0.3977585768030076 0.5874824534670472 0.0035488894172609 - 0.2787941698141023 0.688212121993365 0.0050877873283535 - 0.1595037989247572 0.0238702536543536 0.0012640830276911 - 0.1141013603223645 0.0051898217608445 0.0011125098648623 - 0.0955398781717349 0.0327410291887064 0.0026640152155974 - 0.3111622680517019 0.0024475998559664 0.0011405518381279 - 0.2056172320580521 0.0087252895853085 0.002057375172208 - 0.0472616294497253 0.0071625399102445 0.0009762956639454 - 0.3585095935696251 0.068526954187213 0.0074905566965996 - 0.2404827720350127 0.1017283293272842 0.0080606208185086 - 0.172932303129224 0.0583515752375154 0.005235128246565 - 0.3163043076538381 0.1548301554055162 0.0104221979294844 - 0.3977585768030076 0.0147589697299452 0.0035488894172609 - 0.2787941698141023 0.0329937081925328 0.0050877873283535 - 0.8166259474208892 0.1595037989247572 0.0012640830276911 - 0.880708817916791 0.1141013603223645 0.0011125098648623 - 0.8717190926395587 0.0955398781717349 0.0026640152155974 - 0.6863901320923316 0.3111622680517019 0.0011405518381279 - 0.7856574783566395 0.2056172320580521 0.002057375172208 - 0.9455758306400301 0.0472616294497253 0.0009762956639454 - 0.5729634522431619 0.3585095935696251 0.0074905566965996 - 0.6577888986377031 0.2404827720350127 0.0080606208185086 - 0.7687161216332605 0.172932303129224 0.005235128246565 - 0.5288655369406456 0.3163043076538381 0.0104221979294844 - 0.5874824534670472 0.3977585768030076 0.0035488894172609 - 0.688212121993365 0.2787941698141023 0.0050877873283535 - 0.0238702536543536 0.8166259474208892 0.0012640830276911 - 0.0051898217608445 0.880708817916791 0.0011125098648623 - 0.0327410291887064 0.8717190926395587 0.0026640152155974 - 0.0024475998559664 0.6863901320923316 0.0011405518381279 - 0.0087252895853085 0.7856574783566395 0.002057375172208 - 0.0071625399102445 0.9455758306400301 0.0009762956639454 - 0.068526954187213 0.5729634522431619 0.0074905566965996 - 0.1017283293272842 0.6577888986377031 0.0080606208185086 - 0.0583515752375154 0.7687161216332605 0.005235128246565 - 0.1548301554055162 0.5288655369406456 0.0104221979294844 - 0.0147589697299452 0.5874824534670472 0.0035488894172609 - 0.0329937081925328 0.688212121993365 0.0050877873283535 - ] + xw=[0.3333333333333333 0.3333333333333333 0.0126265301615181 + 0.0390072687570322 0.0390072687570322 0.0019578701295165 + 0.4803288773373085 0.4803288773373085 0.0056989446339004 + 0.0868410482076332 0.0868410482076332 0.0044799585127568 + 0.3943235060115415 0.3943235060115415 0.0118373042315640 + 0.2662513178772473 0.2662513178772473 0.0119039314437499 + 0.1371293873116477 0.1371293873116477 0.0072797246963709 + 0.4989594312095863 0.4989594312095863 0.0012037723020907 + 0.4446924421277275 0.4446924421277275 0.0094759753346694 + 0.1987498063965363 0.1987498063965363 0.0099676389400525 + 0.0090164402055984 0.0090164402055984 0.0005326806164147 + 0.0390072687570322 0.9219854624859356 0.0019578701295165 + 0.4803288773373085 0.0393422453253830 0.0056989446339004 + 0.0868410482076332 0.8263179035847336 0.0044799585127568 + 0.3943235060115415 0.2113529879769169 0.0118373042315640 + 0.2662513178772473 0.4674973642455054 0.0119039314437499 + 0.1371293873116477 0.7257412253767046 0.0072797246963709 + 0.4989594312095863 0.0020811375808274 0.0012037723020907 + 0.4446924421277275 0.1106151157445450 0.0094759753346694 + 0.1987498063965363 0.6025003872069274 0.0099676389400525 + 0.0090164402055984 0.9819671195888031 0.0005326806164147 + 0.9219854624859356 0.0390072687570322 0.0019578701295165 + 0.0393422453253830 0.4803288773373085 0.0056989446339004 + 0.8263179035847336 0.0868410482076332 0.0044799585127568 + 0.2113529879769169 0.3943235060115415 0.0118373042315640 + 0.4674973642455054 0.2662513178772473 0.0119039314437499 + 0.7257412253767046 0.1371293873116477 0.0072797246963709 + 0.0020811375808274 0.4989594312095863 0.0012037723020907 + 0.1106151157445450 0.4446924421277275 0.0094759753346694 + 0.6025003872069274 0.1987498063965363 0.0099676389400525 + 0.9819671195888031 0.0090164402055984 0.0005326806164147 + 0.0238702536543536 0.1595037989247572 0.0012640830276911 + 0.0051898217608445 0.1141013603223645 0.0011125098648623 + 0.0327410291887064 0.0955398781717349 0.0026640152155974 + 0.0024475998559664 0.3111622680517019 0.0011405518381279 + 0.0087252895853085 0.2056172320580521 0.0020573751722080 + 0.0071625399102445 0.0472616294497253 0.0009762956639454 + 0.0685269541872130 0.3585095935696251 0.0074905566965996 + 0.1017283293272842 0.2404827720350127 0.0080606208185086 + 0.0583515752375154 0.1729323031292240 0.0052351282465650 + 0.1548301554055162 0.3163043076538381 0.0104221979294844 + 0.0147589697299452 0.3977585768030076 0.0035488894172609 + 0.0329937081925328 0.2787941698141023 0.0050877873283535 + 0.8166259474208892 0.0238702536543536 0.0012640830276911 + 0.8807088179167910 0.0051898217608445 0.0011125098648623 + 0.8717190926395587 0.0327410291887064 0.0026640152155974 + 0.6863901320923316 0.0024475998559664 0.0011405518381279 + 0.7856574783566395 0.0087252895853085 0.0020573751722080 + 0.9455758306400301 0.0071625399102445 0.0009762956639454 + 0.5729634522431619 0.0685269541872130 0.0074905566965996 + 0.6577888986377031 0.1017283293272842 0.0080606208185086 + 0.7687161216332605 0.0583515752375154 0.0052351282465650 + 0.5288655369406456 0.1548301554055162 0.0104221979294844 + 0.5874824534670472 0.0147589697299452 0.0035488894172609 + 0.6882121219933650 0.0329937081925328 0.0050877873283535 + 0.1595037989247572 0.8166259474208892 0.0012640830276911 + 0.1141013603223645 0.8807088179167910 0.0011125098648623 + 0.0955398781717349 0.8717190926395587 0.0026640152155974 + 0.3111622680517019 0.6863901320923316 0.0011405518381279 + 0.2056172320580521 0.7856574783566395 0.0020573751722080 + 0.0472616294497253 0.9455758306400301 0.0009762956639454 + 0.3585095935696251 0.5729634522431619 0.0074905566965996 + 0.2404827720350127 0.6577888986377031 0.0080606208185086 + 0.1729323031292240 0.7687161216332605 0.0052351282465650 + 0.3163043076538381 0.5288655369406456 0.0104221979294844 + 0.3977585768030076 0.5874824534670472 0.0035488894172609 + 0.2787941698141023 0.6882121219933650 0.0050877873283535 + 0.1595037989247572 0.0238702536543536 0.0012640830276911 + 0.1141013603223645 0.0051898217608445 0.0011125098648623 + 0.0955398781717349 0.0327410291887064 0.0026640152155974 + 0.3111622680517019 0.0024475998559664 0.0011405518381279 + 0.2056172320580521 0.0087252895853085 0.0020573751722080 + 0.0472616294497253 0.0071625399102445 0.0009762956639454 + 0.3585095935696251 0.0685269541872130 0.0074905566965996 + 0.2404827720350127 0.1017283293272842 0.0080606208185086 + 0.1729323031292240 0.0583515752375154 0.0052351282465650 + 0.3163043076538381 0.1548301554055162 0.0104221979294844 + 0.3977585768030076 0.0147589697299452 0.0035488894172609 + 0.2787941698141023 0.0329937081925328 0.0050877873283535 + 0.8166259474208892 0.1595037989247572 0.0012640830276911 + 0.8807088179167910 0.1141013603223645 0.0011125098648623 + 0.8717190926395587 0.0955398781717349 0.0026640152155974 + 0.6863901320923316 0.3111622680517019 0.0011405518381279 + 0.7856574783566395 0.2056172320580521 0.0020573751722080 + 0.9455758306400301 0.0472616294497253 0.0009762956639454 + 0.5729634522431619 0.3585095935696251 0.0074905566965996 + 0.6577888986377031 0.2404827720350127 0.0080606208185086 + 0.7687161216332605 0.1729323031292240 0.0052351282465650 + 0.5288655369406456 0.3163043076538381 0.0104221979294844 + 0.5874824534670472 0.3977585768030076 0.0035488894172609 + 0.6882121219933650 0.2787941698141023 0.0050877873283535 + 0.0238702536543536 0.8166259474208892 0.0012640830276911 + 0.0051898217608445 0.8807088179167910 0.0011125098648623 + 0.0327410291887064 0.8717190926395587 0.0026640152155974 + 0.0024475998559664 0.6863901320923316 0.0011405518381279 + 0.0087252895853085 0.7856574783566395 0.0020573751722080 + 0.0071625399102445 0.9455758306400301 0.0009762956639454 + 0.0685269541872130 0.5729634522431619 0.0074905566965996 + 0.1017283293272842 0.6577888986377031 0.0080606208185086 + 0.0583515752375154 0.7687161216332605 0.0052351282465650 + 0.1548301554055162 0.5288655369406456 0.0104221979294844 + 0.0147589697299452 0.5874824534670472 0.0035488894172609 + 0.0329937081925328 0.6882121219933650 0.0050877873283535] elseif n == 13 - xw = [ - 0.3876420304045634 0.3876420304045634 0.0068449257741361 - 0.2110045080614967 0.2110045080614967 0.0057936316180053 - 0.2994923158045085 0.2994923158045085 0.0090088203508507 - 0.0372229259924409 0.0372229259924409 0.0016986488609524 - 0.1451092435745004 0.1451092435745004 0.0057457629312824 - 0.4247593045405748 0.4247593045405748 0.0079556550687292 - 0.4622087087487061 0.4622087087487061 0.006827137593764 - 0.0929497017007699 0.0929497017007699 0.00459141062991 - 0.0078353442826039 0.0078353442826039 0.0004032551441623 - 0.4890393696603955 0.4890393696603955 0.0042220429732605 - 0.3876420304045634 0.2247159391908732 0.0068449257741361 - 0.2110045080614967 0.5779909838770066 0.0057936316180053 - 0.2994923158045085 0.401015368390983 0.0090088203508507 - 0.0372229259924409 0.9255541480151183 0.0016986488609524 - 0.1451092435745004 0.7097815128509992 0.0057457629312824 - 0.4247593045405748 0.1504813909188505 0.0079556550687292 - 0.4622087087487061 0.0755825825025878 0.006827137593764 - 0.0929497017007699 0.8141005965984601 0.00459141062991 - 0.0078353442826039 0.9843293114347923 0.0004032551441623 - 0.4890393696603955 0.0219212606792091 0.0042220429732605 - 0.2247159391908732 0.3876420304045634 0.0068449257741361 - 0.5779909838770066 0.2110045080614967 0.0057936316180053 - 0.401015368390983 0.2994923158045085 0.0090088203508507 - 0.9255541480151183 0.0372229259924409 0.0016986488609524 - 0.7097815128509992 0.1451092435745004 0.0057457629312824 - 0.1504813909188505 0.4247593045405748 0.0079556550687292 - 0.0755825825025878 0.4622087087487061 0.006827137593764 - 0.8141005965984601 0.0929497017007699 0.00459141062991 - 0.9843293114347923 0.0078353442826039 0.0004032551441623 - 0.0219212606792091 0.4890393696603955 0.0042220429732605 - 0.0018188666342744 0.4404169274793433 0.0008374089159674 - 0.0369601415796715 0.1590079061973279 0.0031557390123796 - 0.0788580680056353 0.1773537967572529 0.0047575107837279 - 0.0688475294314979 0.2700667358209594 0.0054421968062185 - 0.1159998076409602 0.3413910330211499 0.0079201761439492 - 0.0483174342873769 0.3739379797195844 0.0053200853477544 - 0.0071283145012574 0.0991330633416822 0.0012726358126745 - 0.203692910584251 0.2995064186296745 0.008956910446138 - 0.0072361617479482 0.1786298486036162 0.0016318698410246 - 0.0129138832500325 0.362068801895972 0.0027273191839872 - 0.0376879497842591 0.0887929154893666 0.0026362809607147 - 0.1370066940870709 0.2336228101417152 0.0068700412960113 - 0.0245400602475244 0.2565954097090198 0.0036571704539664 - 0.007188828261693 0.0410688191117846 0.0008464918170637 - 0.0008914643174981 0.2794161886492607 0.0007558510392294 - 0.5577642058863823 0.0018188666342744 0.0008374089159674 - 0.8040319522230007 0.0369601415796715 0.0031557390123796 - 0.7437881352371118 0.0788580680056353 0.0047575107837279 - 0.6610857347475427 0.0688475294314979 0.0054421968062185 - 0.5426091593378899 0.1159998076409602 0.0079201761439492 - 0.5777445859930387 0.0483174342873769 0.0053200853477544 - 0.8937386221570605 0.0071283145012574 0.0012726358126745 - 0.4968006707860745 0.203692910584251 0.008956910446138 - 0.8141339896484356 0.0072361617479482 0.0016318698410246 - 0.6250173148539955 0.0129138832500325 0.0027273191839872 - 0.8735191347263744 0.0376879497842591 0.0026362809607147 - 0.6293704957712138 0.1370066940870709 0.0068700412960113 - 0.7188645300434557 0.0245400602475244 0.0036571704539664 - 0.9517423526265223 0.007188828261693 0.0008464918170637 - 0.7196923470332413 0.0008914643174981 0.0007558510392294 - 0.4404169274793433 0.5577642058863823 0.0008374089159674 - 0.1590079061973279 0.8040319522230007 0.0031557390123796 - 0.1773537967572529 0.7437881352371118 0.0047575107837279 - 0.2700667358209594 0.6610857347475427 0.0054421968062185 - 0.3413910330211499 0.5426091593378899 0.0079201761439492 - 0.3739379797195844 0.5777445859930387 0.0053200853477544 - 0.0991330633416822 0.8937386221570605 0.0012726358126745 - 0.2995064186296745 0.4968006707860745 0.008956910446138 - 0.1786298486036162 0.8141339896484356 0.0016318698410246 - 0.362068801895972 0.6250173148539955 0.0027273191839872 - 0.0887929154893666 0.8735191347263744 0.0026362809607147 - 0.2336228101417152 0.6293704957712138 0.0068700412960113 - 0.2565954097090198 0.7188645300434557 0.0036571704539664 - 0.0410688191117846 0.9517423526265223 0.0008464918170637 - 0.2794161886492607 0.7196923470332413 0.0007558510392294 - 0.4404169274793433 0.0018188666342744 0.0008374089159674 - 0.1590079061973279 0.0369601415796715 0.0031557390123796 - 0.1773537967572529 0.0788580680056353 0.0047575107837279 - 0.2700667358209594 0.0688475294314979 0.0054421968062185 - 0.3413910330211499 0.1159998076409602 0.0079201761439492 - 0.3739379797195844 0.0483174342873769 0.0053200853477544 - 0.0991330633416822 0.0071283145012574 0.0012726358126745 - 0.2995064186296745 0.203692910584251 0.008956910446138 - 0.1786298486036162 0.0072361617479482 0.0016318698410246 - 0.362068801895972 0.0129138832500325 0.0027273191839872 - 0.0887929154893666 0.0376879497842591 0.0026362809607147 - 0.2336228101417152 0.1370066940870709 0.0068700412960113 - 0.2565954097090198 0.0245400602475244 0.0036571704539664 - 0.0410688191117846 0.007188828261693 0.0008464918170637 - 0.2794161886492607 0.0008914643174981 0.0007558510392294 - 0.5577642058863823 0.4404169274793433 0.0008374089159674 - 0.8040319522230007 0.1590079061973279 0.0031557390123796 - 0.7437881352371118 0.1773537967572529 0.0047575107837279 - 0.6610857347475427 0.2700667358209594 0.0054421968062185 - 0.5426091593378899 0.3413910330211499 0.0079201761439492 - 0.5777445859930387 0.3739379797195844 0.0053200853477544 - 0.8937386221570605 0.0991330633416822 0.0012726358126745 - 0.4968006707860745 0.2995064186296745 0.008956910446138 - 0.8141339896484356 0.1786298486036162 0.0016318698410246 - 0.6250173148539955 0.362068801895972 0.0027273191839872 - 0.8735191347263744 0.0887929154893666 0.0026362809607147 - 0.6293704957712138 0.2336228101417152 0.0068700412960113 - 0.7188645300434557 0.2565954097090198 0.0036571704539664 - 0.9517423526265223 0.0410688191117846 0.0008464918170637 - 0.7196923470332413 0.2794161886492607 0.0007558510392294 - 0.0018188666342744 0.5577642058863823 0.0008374089159674 - 0.0369601415796715 0.8040319522230007 0.0031557390123796 - 0.0788580680056353 0.7437881352371118 0.0047575107837279 - 0.0688475294314979 0.6610857347475427 0.0054421968062185 - 0.1159998076409602 0.5426091593378899 0.0079201761439492 - 0.0483174342873769 0.5777445859930387 0.0053200853477544 - 0.0071283145012574 0.8937386221570605 0.0012726358126745 - 0.203692910584251 0.4968006707860745 0.008956910446138 - 0.0072361617479482 0.8141339896484356 0.0016318698410246 - 0.0129138832500325 0.6250173148539955 0.0027273191839872 - 0.0376879497842591 0.8735191347263744 0.0026362809607147 - 0.1370066940870709 0.6293704957712138 0.0068700412960113 - 0.0245400602475244 0.7188645300434557 0.0036571704539664 - 0.007188828261693 0.9517423526265223 0.0008464918170637 - 0.0008914643174981 0.7196923470332413 0.0007558510392294 - ] + xw=[0.3876420304045634 0.3876420304045634 0.0068449257741361 + 0.2110045080614967 0.2110045080614967 0.0057936316180053 + 0.2994923158045085 0.2994923158045085 0.0090088203508507 + 0.0372229259924409 0.0372229259924409 0.0016986488609524 + 0.1451092435745004 0.1451092435745004 0.0057457629312824 + 0.4247593045405748 0.4247593045405748 0.0079556550687292 + 0.4622087087487061 0.4622087087487061 0.0068271375937640 + 0.0929497017007699 0.0929497017007699 0.0045914106299100 + 0.0078353442826039 0.0078353442826039 0.0004032551441623 + 0.4890393696603955 0.4890393696603955 0.0042220429732605 + 0.3876420304045634 0.2247159391908732 0.0068449257741361 + 0.2110045080614967 0.5779909838770066 0.0057936316180053 + 0.2994923158045085 0.4010153683909830 0.0090088203508507 + 0.0372229259924409 0.9255541480151183 0.0016986488609524 + 0.1451092435745004 0.7097815128509992 0.0057457629312824 + 0.4247593045405748 0.1504813909188505 0.0079556550687292 + 0.4622087087487061 0.0755825825025878 0.0068271375937640 + 0.0929497017007699 0.8141005965984601 0.0045914106299100 + 0.0078353442826039 0.9843293114347923 0.0004032551441623 + 0.4890393696603955 0.0219212606792091 0.0042220429732605 + 0.2247159391908732 0.3876420304045634 0.0068449257741361 + 0.5779909838770066 0.2110045080614967 0.0057936316180053 + 0.4010153683909830 0.2994923158045085 0.0090088203508507 + 0.9255541480151183 0.0372229259924409 0.0016986488609524 + 0.7097815128509992 0.1451092435745004 0.0057457629312824 + 0.1504813909188505 0.4247593045405748 0.0079556550687292 + 0.0755825825025878 0.4622087087487061 0.0068271375937640 + 0.8141005965984601 0.0929497017007699 0.0045914106299100 + 0.9843293114347923 0.0078353442826039 0.0004032551441623 + 0.0219212606792091 0.4890393696603955 0.0042220429732605 + 0.0018188666342744 0.4404169274793433 0.0008374089159674 + 0.0369601415796715 0.1590079061973279 0.0031557390123796 + 0.0788580680056353 0.1773537967572529 0.0047575107837279 + 0.0688475294314979 0.2700667358209594 0.0054421968062185 + 0.1159998076409602 0.3413910330211499 0.0079201761439492 + 0.0483174342873769 0.3739379797195844 0.0053200853477544 + 0.0071283145012574 0.0991330633416822 0.0012726358126745 + 0.2036929105842510 0.2995064186296745 0.0089569104461380 + 0.0072361617479482 0.1786298486036162 0.0016318698410246 + 0.0129138832500325 0.3620688018959720 0.0027273191839872 + 0.0376879497842591 0.0887929154893666 0.0026362809607147 + 0.1370066940870709 0.2336228101417152 0.0068700412960113 + 0.0245400602475244 0.2565954097090198 0.0036571704539664 + 0.0071888282616930 0.0410688191117846 0.0008464918170637 + 0.0008914643174981 0.2794161886492607 0.0007558510392294 + 0.5577642058863823 0.0018188666342744 0.0008374089159674 + 0.8040319522230007 0.0369601415796715 0.0031557390123796 + 0.7437881352371118 0.0788580680056353 0.0047575107837279 + 0.6610857347475427 0.0688475294314979 0.0054421968062185 + 0.5426091593378899 0.1159998076409602 0.0079201761439492 + 0.5777445859930387 0.0483174342873769 0.0053200853477544 + 0.8937386221570605 0.0071283145012574 0.0012726358126745 + 0.4968006707860745 0.2036929105842510 0.0089569104461380 + 0.8141339896484356 0.0072361617479482 0.0016318698410246 + 0.6250173148539955 0.0129138832500325 0.0027273191839872 + 0.8735191347263744 0.0376879497842591 0.0026362809607147 + 0.6293704957712138 0.1370066940870709 0.0068700412960113 + 0.7188645300434557 0.0245400602475244 0.0036571704539664 + 0.9517423526265223 0.0071888282616930 0.0008464918170637 + 0.7196923470332413 0.0008914643174981 0.0007558510392294 + 0.4404169274793433 0.5577642058863823 0.0008374089159674 + 0.1590079061973279 0.8040319522230007 0.0031557390123796 + 0.1773537967572529 0.7437881352371118 0.0047575107837279 + 0.2700667358209594 0.6610857347475427 0.0054421968062185 + 0.3413910330211499 0.5426091593378899 0.0079201761439492 + 0.3739379797195844 0.5777445859930387 0.0053200853477544 + 0.0991330633416822 0.8937386221570605 0.0012726358126745 + 0.2995064186296745 0.4968006707860745 0.0089569104461380 + 0.1786298486036162 0.8141339896484356 0.0016318698410246 + 0.3620688018959720 0.6250173148539955 0.0027273191839872 + 0.0887929154893666 0.8735191347263744 0.0026362809607147 + 0.2336228101417152 0.6293704957712138 0.0068700412960113 + 0.2565954097090198 0.7188645300434557 0.0036571704539664 + 0.0410688191117846 0.9517423526265223 0.0008464918170637 + 0.2794161886492607 0.7196923470332413 0.0007558510392294 + 0.4404169274793433 0.0018188666342744 0.0008374089159674 + 0.1590079061973279 0.0369601415796715 0.0031557390123796 + 0.1773537967572529 0.0788580680056353 0.0047575107837279 + 0.2700667358209594 0.0688475294314979 0.0054421968062185 + 0.3413910330211499 0.1159998076409602 0.0079201761439492 + 0.3739379797195844 0.0483174342873769 0.0053200853477544 + 0.0991330633416822 0.0071283145012574 0.0012726358126745 + 0.2995064186296745 0.2036929105842510 0.0089569104461380 + 0.1786298486036162 0.0072361617479482 0.0016318698410246 + 0.3620688018959720 0.0129138832500325 0.0027273191839872 + 0.0887929154893666 0.0376879497842591 0.0026362809607147 + 0.2336228101417152 0.1370066940870709 0.0068700412960113 + 0.2565954097090198 0.0245400602475244 0.0036571704539664 + 0.0410688191117846 0.0071888282616930 0.0008464918170637 + 0.2794161886492607 0.0008914643174981 0.0007558510392294 + 0.5577642058863823 0.4404169274793433 0.0008374089159674 + 0.8040319522230007 0.1590079061973279 0.0031557390123796 + 0.7437881352371118 0.1773537967572529 0.0047575107837279 + 0.6610857347475427 0.2700667358209594 0.0054421968062185 + 0.5426091593378899 0.3413910330211499 0.0079201761439492 + 0.5777445859930387 0.3739379797195844 0.0053200853477544 + 0.8937386221570605 0.0991330633416822 0.0012726358126745 + 0.4968006707860745 0.2995064186296745 0.0089569104461380 + 0.8141339896484356 0.1786298486036162 0.0016318698410246 + 0.6250173148539955 0.3620688018959720 0.0027273191839872 + 0.8735191347263744 0.0887929154893666 0.0026362809607147 + 0.6293704957712138 0.2336228101417152 0.0068700412960113 + 0.7188645300434557 0.2565954097090198 0.0036571704539664 + 0.9517423526265223 0.0410688191117846 0.0008464918170637 + 0.7196923470332413 0.2794161886492607 0.0007558510392294 + 0.0018188666342744 0.5577642058863823 0.0008374089159674 + 0.0369601415796715 0.8040319522230007 0.0031557390123796 + 0.0788580680056353 0.7437881352371118 0.0047575107837279 + 0.0688475294314979 0.6610857347475427 0.0054421968062185 + 0.1159998076409602 0.5426091593378899 0.0079201761439492 + 0.0483174342873769 0.5777445859930387 0.0053200853477544 + 0.0071283145012574 0.8937386221570605 0.0012726358126745 + 0.2036929105842510 0.4968006707860745 0.0089569104461380 + 0.0072361617479482 0.8141339896484356 0.0016318698410246 + 0.0129138832500325 0.6250173148539955 0.0027273191839872 + 0.0376879497842591 0.8735191347263744 0.0026362809607147 + 0.1370066940870709 0.6293704957712138 0.0068700412960113 + 0.0245400602475244 0.7188645300434557 0.0036571704539664 + 0.0071888282616930 0.9517423526265223 0.0008464918170637 + 0.0008914643174981 0.7196923470332413 0.0007558510392294] elseif n == 14 - xw = [ - 0.3807140211811872 0.3807140211811872 0.00478004248373 - 0.4466678037038646 0.4466678037038646 0.0047050799047271 - 0.4161413788054121 0.4161413788054121 0.0060251135120752 - 0.0803046477884384 0.0803046477884384 0.0026063109364009 - 0.2334004066698712 0.2334004066698712 0.0067356576990247 - 0.3011654651665092 0.3011654651665092 0.0078739828906813 - 0.1747799663549001 0.1747799663549001 0.0056412212723492 - 0.4855650541851628 0.4855650541851628 0.0035586187064373 - 0.0325715201801817 0.0325715201801817 0.0013886697644771 - 0.1275709019046776 0.1275709019046776 0.0048716224614089 - 0.0066392191809589 0.0066392191809589 0.0002877212028353 - 0.3807140211811872 0.2385719576376256 0.00478004248373 - 0.4466678037038646 0.1066643925922708 0.0047050799047271 - 0.4161413788054121 0.1677172423891757 0.0060251135120752 - 0.0803046477884384 0.8393907044231231 0.0026063109364009 - 0.2334004066698712 0.5331991866602577 0.0067356576990247 - 0.3011654651665092 0.3976690696669816 0.0078739828906813 - 0.1747799663549001 0.6504400672901999 0.0056412212723492 - 0.4855650541851628 0.0288698916296745 0.0035586187064373 - 0.0325715201801817 0.9348569596396366 0.0013886697644771 - 0.1275709019046776 0.7448581961906448 0.0048716224614089 - 0.0066392191809589 0.9867215616380822 0.0002877212028353 - 0.2385719576376256 0.3807140211811872 0.00478004248373 - 0.1066643925922708 0.4466678037038646 0.0047050799047271 - 0.1677172423891757 0.4161413788054121 0.0060251135120752 - 0.8393907044231231 0.0803046477884384 0.0026063109364009 - 0.5331991866602577 0.2334004066698712 0.0067356576990247 - 0.3976690696669816 0.3011654651665092 0.0078739828906813 - 0.6504400672901999 0.1747799663549001 0.0056412212723492 - 0.0288698916296745 0.4855650541851628 0.0035586187064373 - 0.9348569596396366 0.0325715201801817 0.0013886697644771 - 0.7448581961906448 0.1275709019046776 0.0048716224614089 - 0.9867215616380822 0.0066392191809589 0.0002877212028353 - 0.0307306047272729 0.2870421965934966 0.0027658974168834 - 0.1291526400634497 0.3450878417155684 0.0062787181020183 - 0.02803348609525 0.3759301570486618 0.0031975763497272 - 0.2091309211376687 0.316945588933132 0.0068576966152754 - 0.0660389128497386 0.4072283930427199 0.0049311350594948 - 0.0410305768191818 0.2135535984578239 0.0032276864524648 - 0.005299640371799 0.3288528780688926 0.0014639131808996 - 0.0630739954149509 0.1392953061421487 0.0035653176552435 - 0.1489628509382401 0.255246254696978 0.0061738315654307 - 0.0946970824331307 0.2083760156003741 0.0053468502948081 - 0.0055807170152601 0.4400105519462155 0.0016212337988197 - 0.0750769024331962 0.3022209412278211 0.0054653055464566 - 0.006982529324459 0.0819468025835337 0.0010075615636449 - 0.0060935694037648 0.034364969912142 0.0005983868042366 - 0.0350344225276974 0.0801120738471011 0.0021635790176804 - 0.019352001318039 0.1472134318989225 0.0023111935558906 - 0.0073324725490405 0.2297196532578432 0.0016971268694035 - 0.000490328443463 0.1476555211198698 0.0004233030678819 - 0.6822271986792305 0.0307306047272729 0.0027658974168834 - 0.5257595182209819 0.1291526400634497 0.0062787181020183 - 0.5960363568560882 0.02803348609525 0.0031975763497272 - 0.4739234899291994 0.2091309211376687 0.0068576966152754 - 0.5267326941075414 0.0660389128497386 0.0049311350594948 - 0.7454158247229942 0.0410305768191818 0.0032276864524648 - 0.6658474815593083 0.005299640371799 0.0014639131808996 - 0.7976306984429005 0.0630739954149509 0.0035653176552435 - 0.5957908943647818 0.1489628509382401 0.0061738315654307 - 0.6969269019664952 0.0946970824331307 0.0053468502948081 - 0.5544087310385244 0.0055807170152601 0.0016212337988197 - 0.6227021563389827 0.0750769024331962 0.0054653055464566 - 0.9110706680920073 0.006982529324459 0.0010075615636449 - 0.9595414606840932 0.0060935694037648 0.0005983868042366 - 0.8848535036252014 0.0350344225276974 0.0021635790176804 - 0.8334345667830386 0.019352001318039 0.0023111935558906 - 0.7629478741931164 0.0073324725490405 0.0016971268694035 - 0.8518541504366672 0.000490328443463 0.0004233030678819 - 0.2870421965934966 0.6822271986792305 0.0027658974168834 - 0.3450878417155684 0.5257595182209819 0.0062787181020183 - 0.3759301570486618 0.5960363568560882 0.0031975763497272 - 0.316945588933132 0.4739234899291994 0.0068576966152754 - 0.4072283930427199 0.5267326941075414 0.0049311350594948 - 0.2135535984578239 0.7454158247229942 0.0032276864524648 - 0.3288528780688926 0.6658474815593083 0.0014639131808996 - 0.1392953061421487 0.7976306984429005 0.0035653176552435 - 0.255246254696978 0.5957908943647818 0.0061738315654307 - 0.2083760156003741 0.6969269019664952 0.0053468502948081 - 0.4400105519462155 0.5544087310385244 0.0016212337988197 - 0.3022209412278211 0.6227021563389827 0.0054653055464566 - 0.0819468025835337 0.9110706680920073 0.0010075615636449 - 0.034364969912142 0.9595414606840932 0.0005983868042366 - 0.0801120738471011 0.8848535036252014 0.0021635790176804 - 0.1472134318989225 0.8334345667830386 0.0023111935558906 - 0.2297196532578432 0.7629478741931164 0.0016971268694035 - 0.1476555211198698 0.8518541504366672 0.0004233030678819 - 0.2870421965934966 0.0307306047272729 0.0027658974168834 - 0.3450878417155684 0.1291526400634497 0.0062787181020183 - 0.3759301570486618 0.02803348609525 0.0031975763497272 - 0.316945588933132 0.2091309211376687 0.0068576966152754 - 0.4072283930427199 0.0660389128497386 0.0049311350594948 - 0.2135535984578239 0.0410305768191818 0.0032276864524648 - 0.3288528780688926 0.005299640371799 0.0014639131808996 - 0.1392953061421487 0.0630739954149509 0.0035653176552435 - 0.255246254696978 0.1489628509382401 0.0061738315654307 - 0.2083760156003741 0.0946970824331307 0.0053468502948081 - 0.4400105519462155 0.0055807170152601 0.0016212337988197 - 0.3022209412278211 0.0750769024331962 0.0054653055464566 - 0.0819468025835337 0.006982529324459 0.0010075615636449 - 0.034364969912142 0.0060935694037648 0.0005983868042366 - 0.0801120738471011 0.0350344225276974 0.0021635790176804 - 0.1472134318989225 0.019352001318039 0.0023111935558906 - 0.2297196532578432 0.0073324725490405 0.0016971268694035 - 0.1476555211198698 0.000490328443463 0.0004233030678819 - 0.6822271986792305 0.2870421965934966 0.0027658974168834 - 0.5257595182209819 0.3450878417155684 0.0062787181020183 - 0.5960363568560882 0.3759301570486618 0.0031975763497272 - 0.4739234899291994 0.316945588933132 0.0068576966152754 - 0.5267326941075414 0.4072283930427199 0.0049311350594948 - 0.7454158247229942 0.2135535984578239 0.0032276864524648 - 0.6658474815593083 0.3288528780688926 0.0014639131808996 - 0.7976306984429005 0.1392953061421487 0.0035653176552435 - 0.5957908943647818 0.255246254696978 0.0061738315654307 - 0.6969269019664952 0.2083760156003741 0.0053468502948081 - 0.5544087310385244 0.4400105519462155 0.0016212337988197 - 0.6227021563389827 0.3022209412278211 0.0054653055464566 - 0.9110706680920073 0.0819468025835337 0.0010075615636449 - 0.9595414606840932 0.034364969912142 0.0005983868042366 - 0.8848535036252014 0.0801120738471011 0.0021635790176804 - 0.8334345667830386 0.1472134318989225 0.0023111935558906 - 0.7629478741931164 0.2297196532578432 0.0016971268694035 - 0.8518541504366672 0.1476555211198698 0.0004233030678819 - 0.0307306047272729 0.6822271986792305 0.0027658974168834 - 0.1291526400634497 0.5257595182209819 0.0062787181020183 - 0.02803348609525 0.5960363568560882 0.0031975763497272 - 0.2091309211376687 0.4739234899291994 0.0068576966152754 - 0.0660389128497386 0.5267326941075414 0.0049311350594948 - 0.0410305768191818 0.7454158247229942 0.0032276864524648 - 0.005299640371799 0.6658474815593083 0.0014639131808996 - 0.0630739954149509 0.7976306984429005 0.0035653176552435 - 0.1489628509382401 0.5957908943647818 0.0061738315654307 - 0.0946970824331307 0.6969269019664952 0.0053468502948081 - 0.0055807170152601 0.5544087310385244 0.0016212337988197 - 0.0750769024331962 0.6227021563389827 0.0054653055464566 - 0.006982529324459 0.9110706680920073 0.0010075615636449 - 0.0060935694037648 0.9595414606840932 0.0005983868042366 - 0.0350344225276974 0.8848535036252014 0.0021635790176804 - 0.019352001318039 0.8334345667830386 0.0023111935558906 - 0.0073324725490405 0.7629478741931164 0.0016971268694035 - 0.000490328443463 0.8518541504366672 0.0004233030678819 - ] + xw=[0.3807140211811872 0.3807140211811872 0.0047800424837300 + 0.4466678037038646 0.4466678037038646 0.0047050799047271 + 0.4161413788054121 0.4161413788054121 0.0060251135120752 + 0.0803046477884384 0.0803046477884384 0.0026063109364009 + 0.2334004066698712 0.2334004066698712 0.0067356576990247 + 0.3011654651665092 0.3011654651665092 0.0078739828906813 + 0.1747799663549001 0.1747799663549001 0.0056412212723492 + 0.4855650541851628 0.4855650541851628 0.0035586187064373 + 0.0325715201801817 0.0325715201801817 0.0013886697644771 + 0.1275709019046776 0.1275709019046776 0.0048716224614089 + 0.0066392191809589 0.0066392191809589 0.0002877212028353 + 0.3807140211811872 0.2385719576376256 0.0047800424837300 + 0.4466678037038646 0.1066643925922708 0.0047050799047271 + 0.4161413788054121 0.1677172423891757 0.0060251135120752 + 0.0803046477884384 0.8393907044231231 0.0026063109364009 + 0.2334004066698712 0.5331991866602577 0.0067356576990247 + 0.3011654651665092 0.3976690696669816 0.0078739828906813 + 0.1747799663549001 0.6504400672901999 0.0056412212723492 + 0.4855650541851628 0.0288698916296745 0.0035586187064373 + 0.0325715201801817 0.9348569596396366 0.0013886697644771 + 0.1275709019046776 0.7448581961906448 0.0048716224614089 + 0.0066392191809589 0.9867215616380822 0.0002877212028353 + 0.2385719576376256 0.3807140211811872 0.0047800424837300 + 0.1066643925922708 0.4466678037038646 0.0047050799047271 + 0.1677172423891757 0.4161413788054121 0.0060251135120752 + 0.8393907044231231 0.0803046477884384 0.0026063109364009 + 0.5331991866602577 0.2334004066698712 0.0067356576990247 + 0.3976690696669816 0.3011654651665092 0.0078739828906813 + 0.6504400672901999 0.1747799663549001 0.0056412212723492 + 0.0288698916296745 0.4855650541851628 0.0035586187064373 + 0.9348569596396366 0.0325715201801817 0.0013886697644771 + 0.7448581961906448 0.1275709019046776 0.0048716224614089 + 0.9867215616380822 0.0066392191809589 0.0002877212028353 + 0.0307306047272729 0.2870421965934966 0.0027658974168834 + 0.1291526400634497 0.3450878417155684 0.0062787181020183 + 0.0280334860952500 0.3759301570486618 0.0031975763497272 + 0.2091309211376687 0.3169455889331320 0.0068576966152754 + 0.0660389128497386 0.4072283930427199 0.0049311350594948 + 0.0410305768191818 0.2135535984578239 0.0032276864524648 + 0.0052996403717990 0.3288528780688926 0.0014639131808996 + 0.0630739954149509 0.1392953061421487 0.0035653176552435 + 0.1489628509382401 0.2552462546969780 0.0061738315654307 + 0.0946970824331307 0.2083760156003741 0.0053468502948081 + 0.0055807170152601 0.4400105519462155 0.0016212337988197 + 0.0750769024331962 0.3022209412278211 0.0054653055464566 + 0.0069825293244590 0.0819468025835337 0.0010075615636449 + 0.0060935694037648 0.0343649699121420 0.0005983868042366 + 0.0350344225276974 0.0801120738471011 0.0021635790176804 + 0.0193520013180390 0.1472134318989225 0.0023111935558906 + 0.0073324725490405 0.2297196532578432 0.0016971268694035 + 0.0004903284434630 0.1476555211198698 0.0004233030678819 + 0.6822271986792305 0.0307306047272729 0.0027658974168834 + 0.5257595182209819 0.1291526400634497 0.0062787181020183 + 0.5960363568560882 0.0280334860952500 0.0031975763497272 + 0.4739234899291994 0.2091309211376687 0.0068576966152754 + 0.5267326941075414 0.0660389128497386 0.0049311350594948 + 0.7454158247229942 0.0410305768191818 0.0032276864524648 + 0.6658474815593083 0.0052996403717990 0.0014639131808996 + 0.7976306984429005 0.0630739954149509 0.0035653176552435 + 0.5957908943647818 0.1489628509382401 0.0061738315654307 + 0.6969269019664952 0.0946970824331307 0.0053468502948081 + 0.5544087310385244 0.0055807170152601 0.0016212337988197 + 0.6227021563389827 0.0750769024331962 0.0054653055464566 + 0.9110706680920073 0.0069825293244590 0.0010075615636449 + 0.9595414606840932 0.0060935694037648 0.0005983868042366 + 0.8848535036252014 0.0350344225276974 0.0021635790176804 + 0.8334345667830386 0.0193520013180390 0.0023111935558906 + 0.7629478741931164 0.0073324725490405 0.0016971268694035 + 0.8518541504366672 0.0004903284434630 0.0004233030678819 + 0.2870421965934966 0.6822271986792305 0.0027658974168834 + 0.3450878417155684 0.5257595182209819 0.0062787181020183 + 0.3759301570486618 0.5960363568560882 0.0031975763497272 + 0.3169455889331320 0.4739234899291994 0.0068576966152754 + 0.4072283930427199 0.5267326941075414 0.0049311350594948 + 0.2135535984578239 0.7454158247229942 0.0032276864524648 + 0.3288528780688926 0.6658474815593083 0.0014639131808996 + 0.1392953061421487 0.7976306984429005 0.0035653176552435 + 0.2552462546969780 0.5957908943647818 0.0061738315654307 + 0.2083760156003741 0.6969269019664952 0.0053468502948081 + 0.4400105519462155 0.5544087310385244 0.0016212337988197 + 0.3022209412278211 0.6227021563389827 0.0054653055464566 + 0.0819468025835337 0.9110706680920073 0.0010075615636449 + 0.0343649699121420 0.9595414606840932 0.0005983868042366 + 0.0801120738471011 0.8848535036252014 0.0021635790176804 + 0.1472134318989225 0.8334345667830386 0.0023111935558906 + 0.2297196532578432 0.7629478741931164 0.0016971268694035 + 0.1476555211198698 0.8518541504366672 0.0004233030678819 + 0.2870421965934966 0.0307306047272729 0.0027658974168834 + 0.3450878417155684 0.1291526400634497 0.0062787181020183 + 0.3759301570486618 0.0280334860952500 0.0031975763497272 + 0.3169455889331320 0.2091309211376687 0.0068576966152754 + 0.4072283930427199 0.0660389128497386 0.0049311350594948 + 0.2135535984578239 0.0410305768191818 0.0032276864524648 + 0.3288528780688926 0.0052996403717990 0.0014639131808996 + 0.1392953061421487 0.0630739954149509 0.0035653176552435 + 0.2552462546969780 0.1489628509382401 0.0061738315654307 + 0.2083760156003741 0.0946970824331307 0.0053468502948081 + 0.4400105519462155 0.0055807170152601 0.0016212337988197 + 0.3022209412278211 0.0750769024331962 0.0054653055464566 + 0.0819468025835337 0.0069825293244590 0.0010075615636449 + 0.0343649699121420 0.0060935694037648 0.0005983868042366 + 0.0801120738471011 0.0350344225276974 0.0021635790176804 + 0.1472134318989225 0.0193520013180390 0.0023111935558906 + 0.2297196532578432 0.0073324725490405 0.0016971268694035 + 0.1476555211198698 0.0004903284434630 0.0004233030678819 + 0.6822271986792305 0.2870421965934966 0.0027658974168834 + 0.5257595182209819 0.3450878417155684 0.0062787181020183 + 0.5960363568560882 0.3759301570486618 0.0031975763497272 + 0.4739234899291994 0.3169455889331320 0.0068576966152754 + 0.5267326941075414 0.4072283930427199 0.0049311350594948 + 0.7454158247229942 0.2135535984578239 0.0032276864524648 + 0.6658474815593083 0.3288528780688926 0.0014639131808996 + 0.7976306984429005 0.1392953061421487 0.0035653176552435 + 0.5957908943647818 0.2552462546969780 0.0061738315654307 + 0.6969269019664952 0.2083760156003741 0.0053468502948081 + 0.5544087310385244 0.4400105519462155 0.0016212337988197 + 0.6227021563389827 0.3022209412278211 0.0054653055464566 + 0.9110706680920073 0.0819468025835337 0.0010075615636449 + 0.9595414606840932 0.0343649699121420 0.0005983868042366 + 0.8848535036252014 0.0801120738471011 0.0021635790176804 + 0.8334345667830386 0.1472134318989225 0.0023111935558906 + 0.7629478741931164 0.2297196532578432 0.0016971268694035 + 0.8518541504366672 0.1476555211198698 0.0004233030678819 + 0.0307306047272729 0.6822271986792305 0.0027658974168834 + 0.1291526400634497 0.5257595182209819 0.0062787181020183 + 0.0280334860952500 0.5960363568560882 0.0031975763497272 + 0.2091309211376687 0.4739234899291994 0.0068576966152754 + 0.0660389128497386 0.5267326941075414 0.0049311350594948 + 0.0410305768191818 0.7454158247229942 0.0032276864524648 + 0.0052996403717990 0.6658474815593083 0.0014639131808996 + 0.0630739954149509 0.7976306984429005 0.0035653176552435 + 0.1489628509382401 0.5957908943647818 0.0061738315654307 + 0.0946970824331307 0.6969269019664952 0.0053468502948081 + 0.0055807170152601 0.5544087310385244 0.0016212337988197 + 0.0750769024331962 0.6227021563389827 0.0054653055464566 + 0.0069825293244590 0.9110706680920073 0.0010075615636449 + 0.0060935694037648 0.9595414606840932 0.0005983868042366 + 0.0350344225276974 0.8848535036252014 0.0021635790176804 + 0.0193520013180390 0.8334345667830386 0.0023111935558906 + 0.0073324725490405 0.7629478741931164 0.0016971268694035 + 0.0004903284434630 0.8518541504366672 0.0004233030678819] elseif n == 15 - xw = [ - 0.4989148246376862 0.4989148246376862 0.0007582310515785 - 0.4343804267617306 0.4343804267617306 0.0055855501475839 - 0.0410973356271182 0.0410973356271182 0.0014302457530784 - 0.2084053051324009 0.2084053051324009 0.0062696017213116 - 0.1607458844319636 0.1607458844319636 0.0052857089291138 - 0.4884016029326028 0.4884016029326028 0.0030672005823595 - 0.3023864112151285 0.3023864112151285 0.0081551194038716 - 0.1144268129944256 0.1144268129944256 0.0040864392206136 - 0.4647624310807389 0.4647624310807389 0.0051565583176292 - 0.0737218813900999 0.0737218813900999 0.0028044235664157 - 0.3906191787832637 0.3906191787832637 0.0079566076420445 - 0.4989148246376862 0.0021703507246277 0.0007582310515785 - 0.4343804267617306 0.1312391464765388 0.0055855501475839 - 0.0410973356271182 0.9178053287457636 0.0014302457530784 - 0.2084053051324009 0.5831893897351982 0.0062696017213116 - 0.1607458844319636 0.6785082311360727 0.0052857089291138 - 0.4884016029326028 0.0231967941347945 0.0030672005823595 - 0.3023864112151285 0.395227177569743 0.0081551194038716 - 0.1144268129944256 0.7711463740111488 0.0040864392206136 - 0.4647624310807389 0.0704751378385221 0.0051565583176292 - 0.0737218813900999 0.8525562372198002 0.0028044235664157 - 0.3906191787832637 0.2187616424334725 0.0079566076420445 - 0.0021703507246277 0.4989148246376862 0.0007582310515785 - 0.1312391464765388 0.4343804267617306 0.0055855501475839 - 0.9178053287457636 0.0410973356271182 0.0014302457530784 - 0.5831893897351982 0.2084053051324009 0.0062696017213116 - 0.6785082311360727 0.1607458844319636 0.0052857089291138 - 0.0231967941347945 0.4884016029326028 0.0030672005823595 - 0.395227177569743 0.3023864112151285 0.0081551194038716 - 0.7711463740111488 0.1144268129944256 0.0040864392206136 - 0.0704751378385221 0.4647624310807389 0.0051565583176292 - 0.8525562372198002 0.0737218813900999 0.0028044235664157 - 0.2187616424334725 0.3906191787832637 0.0079566076420445 - 0.0027287432479211 0.0589421088402292 0.0003846264857381 - 0.1571776998671934 0.3497880100093319 0.0052261073484612 - 0.0021009666448276 0.3230018235435502 0.0006764119746262 - 0.0681658088137464 0.1581458542495161 0.0032195683537669 - 0.0108309586036093 0.0295494682613534 0.0006360972185858 - 0.2189323419801725 0.2918191734265371 0.0067726232860038 - 0.0212868962407332 0.0755221785129958 0.0013807653747952 - 0.0408472165761024 0.1171166695088989 0.0022563434227437 - 0.0016034964960438 0.0111662181081692 0.0001347461159294 - 0.101545985226834 0.2080456492790871 0.0046931653381418 - 0.0415270612688227 0.3922101149804348 0.0039114592291532 - 0.0938490411451324 0.3597112755099759 0.0053151981815983 - 0.0086860298043841 0.2458746994828754 0.0015256194116726 - 0.0175891240440456 0.1670027381749231 0.001912683335865 - 0.0055235245122126 0.1150085986319464 0.0008708476156509 - 0.0238589269426556 0.3153953981173191 0.0028345767408327 - 0.0402953345447718 0.2232226502248206 0.0032909988819261 - 0.0678784043114471 0.2883958599187324 0.0045894620824638 - 0.1395356071810826 0.2673663502727756 0.0062591832494172 - 0.0080665857041666 0.4057653952988916 0.0018206702056404 - 0.0001234468122874 0.1863207276753595 0.0003443363125209 - 0.9383291479118497 0.0027287432479211 0.0003846264857381 - 0.4930342901234747 0.1571776998671934 0.0052261073484612 - 0.6748972098116224 0.0021009666448276 0.0006764119746262 - 0.7736883369367374 0.0681658088137464 0.0032195683537669 - 0.9596195731350372 0.0108309586036093 0.0006360972185858 - 0.4892484845932904 0.2189323419801725 0.0067726232860038 - 0.903190925246271 0.0212868962407332 0.0013807653747952 - 0.8420361139149987 0.0408472165761024 0.0022563434227437 - 0.9872302853957871 0.0016034964960438 0.0001347461159294 - 0.6904083654940789 0.101545985226834 0.0046931653381418 - 0.5662628237507425 0.0415270612688227 0.0039114592291532 - 0.5464396833448917 0.0938490411451324 0.0053151981815983 - 0.7454392707127404 0.0086860298043841 0.0015256194116726 - 0.8154081377810312 0.0175891240440456 0.001912683335865 - 0.8794678768558409 0.0055235245122126 0.0008708476156509 - 0.6607456749400253 0.0238589269426556 0.0028345767408327 - 0.7364820152304077 0.0402953345447718 0.0032909988819261 - 0.6437257357698205 0.0678784043114471 0.0045894620824638 - 0.5930980425461418 0.1395356071810826 0.0062591832494172 - 0.5861680189969418 0.0080665857041666 0.0018206702056404 - 0.8135558255123531 0.0001234468122874 0.0003443363125209 - 0.0589421088402292 0.9383291479118497 0.0003846264857381 - 0.3497880100093319 0.4930342901234747 0.0052261073484612 - 0.3230018235435502 0.6748972098116224 0.0006764119746262 - 0.1581458542495161 0.7736883369367374 0.0032195683537669 - 0.0295494682613534 0.9596195731350372 0.0006360972185858 - 0.2918191734265371 0.4892484845932904 0.0067726232860038 - 0.0755221785129958 0.903190925246271 0.0013807653747952 - 0.1171166695088989 0.8420361139149987 0.0022563434227437 - 0.0111662181081692 0.9872302853957871 0.0001347461159294 - 0.2080456492790871 0.6904083654940789 0.0046931653381418 - 0.3922101149804348 0.5662628237507425 0.0039114592291532 - 0.3597112755099759 0.5464396833448917 0.0053151981815983 - 0.2458746994828754 0.7454392707127404 0.0015256194116726 - 0.1670027381749231 0.8154081377810312 0.001912683335865 - 0.1150085986319464 0.8794678768558409 0.0008708476156509 - 0.3153953981173191 0.6607456749400253 0.0028345767408327 - 0.2232226502248206 0.7364820152304077 0.0032909988819261 - 0.2883958599187324 0.6437257357698205 0.0045894620824638 - 0.2673663502727756 0.5930980425461418 0.0062591832494172 - 0.4057653952988916 0.5861680189969418 0.0018206702056404 - 0.1863207276753595 0.8135558255123531 0.0003443363125209 - 0.0589421088402292 0.0027287432479211 0.0003846264857381 - 0.3497880100093319 0.1571776998671934 0.0052261073484612 - 0.3230018235435502 0.0021009666448276 0.0006764119746262 - 0.1581458542495161 0.0681658088137464 0.0032195683537669 - 0.0295494682613534 0.0108309586036093 0.0006360972185858 - 0.2918191734265371 0.2189323419801725 0.0067726232860038 - 0.0755221785129958 0.0212868962407332 0.0013807653747952 - 0.1171166695088989 0.0408472165761024 0.0022563434227437 - 0.0111662181081692 0.0016034964960438 0.0001347461159294 - 0.2080456492790871 0.101545985226834 0.0046931653381418 - 0.3922101149804348 0.0415270612688227 0.0039114592291532 - 0.3597112755099759 0.0938490411451324 0.0053151981815983 - 0.2458746994828754 0.0086860298043841 0.0015256194116726 - 0.1670027381749231 0.0175891240440456 0.001912683335865 - 0.1150085986319464 0.0055235245122126 0.0008708476156509 - 0.3153953981173191 0.0238589269426556 0.0028345767408327 - 0.2232226502248206 0.0402953345447718 0.0032909988819261 - 0.2883958599187324 0.0678784043114471 0.0045894620824638 - 0.2673663502727756 0.1395356071810826 0.0062591832494172 - 0.4057653952988916 0.0080665857041666 0.0018206702056404 - 0.1863207276753595 0.0001234468122874 0.0003443363125209 - 0.9383291479118497 0.0589421088402292 0.0003846264857381 - 0.4930342901234747 0.3497880100093319 0.0052261073484612 - 0.6748972098116224 0.3230018235435502 0.0006764119746262 - 0.7736883369367374 0.1581458542495161 0.0032195683537669 - 0.9596195731350372 0.0295494682613534 0.0006360972185858 - 0.4892484845932904 0.2918191734265371 0.0067726232860038 - 0.903190925246271 0.0755221785129958 0.0013807653747952 - 0.8420361139149987 0.1171166695088989 0.0022563434227437 - 0.9872302853957871 0.0111662181081692 0.0001347461159294 - 0.6904083654940789 0.2080456492790871 0.0046931653381418 - 0.5662628237507425 0.3922101149804348 0.0039114592291532 - 0.5464396833448917 0.3597112755099759 0.0053151981815983 - 0.7454392707127404 0.2458746994828754 0.0015256194116726 - 0.8154081377810312 0.1670027381749231 0.001912683335865 - 0.8794678768558409 0.1150085986319464 0.0008708476156509 - 0.6607456749400253 0.3153953981173191 0.0028345767408327 - 0.7364820152304077 0.2232226502248206 0.0032909988819261 - 0.6437257357698205 0.2883958599187324 0.0045894620824638 - 0.5930980425461418 0.2673663502727756 0.0062591832494172 - 0.5861680189969418 0.4057653952988916 0.0018206702056404 - 0.8135558255123531 0.1863207276753595 0.0003443363125209 - 0.0027287432479211 0.9383291479118497 0.0003846264857381 - 0.1571776998671934 0.4930342901234747 0.0052261073484612 - 0.0021009666448276 0.6748972098116224 0.0006764119746262 - 0.0681658088137464 0.7736883369367374 0.0032195683537669 - 0.0108309586036093 0.9596195731350372 0.0006360972185858 - 0.2189323419801725 0.4892484845932904 0.0067726232860038 - 0.0212868962407332 0.903190925246271 0.0013807653747952 - 0.0408472165761024 0.8420361139149987 0.0022563434227437 - 0.0016034964960438 0.9872302853957871 0.0001347461159294 - 0.101545985226834 0.6904083654940789 0.0046931653381418 - 0.0415270612688227 0.5662628237507425 0.0039114592291532 - 0.0938490411451324 0.5464396833448917 0.0053151981815983 - 0.0086860298043841 0.7454392707127404 0.0015256194116726 - 0.0175891240440456 0.8154081377810312 0.001912683335865 - 0.0055235245122126 0.8794678768558409 0.0008708476156509 - 0.0238589269426556 0.6607456749400253 0.0028345767408327 - 0.0402953345447718 0.7364820152304077 0.0032909988819261 - 0.0678784043114471 0.6437257357698205 0.0045894620824638 - 0.1395356071810826 0.5930980425461418 0.0062591832494172 - 0.0080665857041666 0.5861680189969418 0.0018206702056404 - 0.0001234468122874 0.8135558255123531 0.0003443363125209 - ] + xw=[0.4989148246376862 0.4989148246376862 0.0007582310515785 + 0.4343804267617306 0.4343804267617306 0.0055855501475839 + 0.0410973356271182 0.0410973356271182 0.0014302457530784 + 0.2084053051324009 0.2084053051324009 0.0062696017213116 + 0.1607458844319636 0.1607458844319636 0.0052857089291138 + 0.4884016029326028 0.4884016029326028 0.0030672005823595 + 0.3023864112151285 0.3023864112151285 0.0081551194038716 + 0.1144268129944256 0.1144268129944256 0.0040864392206136 + 0.4647624310807389 0.4647624310807389 0.0051565583176292 + 0.0737218813900999 0.0737218813900999 0.0028044235664157 + 0.3906191787832637 0.3906191787832637 0.0079566076420445 + 0.4989148246376862 0.0021703507246277 0.0007582310515785 + 0.4343804267617306 0.1312391464765388 0.0055855501475839 + 0.0410973356271182 0.9178053287457636 0.0014302457530784 + 0.2084053051324009 0.5831893897351982 0.0062696017213116 + 0.1607458844319636 0.6785082311360727 0.0052857089291138 + 0.4884016029326028 0.0231967941347945 0.0030672005823595 + 0.3023864112151285 0.3952271775697430 0.0081551194038716 + 0.1144268129944256 0.7711463740111488 0.0040864392206136 + 0.4647624310807389 0.0704751378385221 0.0051565583176292 + 0.0737218813900999 0.8525562372198002 0.0028044235664157 + 0.3906191787832637 0.2187616424334725 0.0079566076420445 + 0.0021703507246277 0.4989148246376862 0.0007582310515785 + 0.1312391464765388 0.4343804267617306 0.0055855501475839 + 0.9178053287457636 0.0410973356271182 0.0014302457530784 + 0.5831893897351982 0.2084053051324009 0.0062696017213116 + 0.6785082311360727 0.1607458844319636 0.0052857089291138 + 0.0231967941347945 0.4884016029326028 0.0030672005823595 + 0.3952271775697430 0.3023864112151285 0.0081551194038716 + 0.7711463740111488 0.1144268129944256 0.0040864392206136 + 0.0704751378385221 0.4647624310807389 0.0051565583176292 + 0.8525562372198002 0.0737218813900999 0.0028044235664157 + 0.2187616424334725 0.3906191787832637 0.0079566076420445 + 0.0027287432479211 0.0589421088402292 0.0003846264857381 + 0.1571776998671934 0.3497880100093319 0.0052261073484612 + 0.0021009666448276 0.3230018235435502 0.0006764119746262 + 0.0681658088137464 0.1581458542495161 0.0032195683537669 + 0.0108309586036093 0.0295494682613534 0.0006360972185858 + 0.2189323419801725 0.2918191734265371 0.0067726232860038 + 0.0212868962407332 0.0755221785129958 0.0013807653747952 + 0.0408472165761024 0.1171166695088989 0.0022563434227437 + 0.0016034964960438 0.0111662181081692 0.0001347461159294 + 0.1015459852268340 0.2080456492790871 0.0046931653381418 + 0.0415270612688227 0.3922101149804348 0.0039114592291532 + 0.0938490411451324 0.3597112755099759 0.0053151981815983 + 0.0086860298043841 0.2458746994828754 0.0015256194116726 + 0.0175891240440456 0.1670027381749231 0.0019126833358650 + 0.0055235245122126 0.1150085986319464 0.0008708476156509 + 0.0238589269426556 0.3153953981173191 0.0028345767408327 + 0.0402953345447718 0.2232226502248206 0.0032909988819261 + 0.0678784043114471 0.2883958599187324 0.0045894620824638 + 0.1395356071810826 0.2673663502727756 0.0062591832494172 + 0.0080665857041666 0.4057653952988916 0.0018206702056404 + 0.0001234468122874 0.1863207276753595 0.0003443363125209 + 0.9383291479118497 0.0027287432479211 0.0003846264857381 + 0.4930342901234747 0.1571776998671934 0.0052261073484612 + 0.6748972098116224 0.0021009666448276 0.0006764119746262 + 0.7736883369367374 0.0681658088137464 0.0032195683537669 + 0.9596195731350372 0.0108309586036093 0.0006360972185858 + 0.4892484845932904 0.2189323419801725 0.0067726232860038 + 0.9031909252462710 0.0212868962407332 0.0013807653747952 + 0.8420361139149987 0.0408472165761024 0.0022563434227437 + 0.9872302853957871 0.0016034964960438 0.0001347461159294 + 0.6904083654940789 0.1015459852268340 0.0046931653381418 + 0.5662628237507425 0.0415270612688227 0.0039114592291532 + 0.5464396833448917 0.0938490411451324 0.0053151981815983 + 0.7454392707127404 0.0086860298043841 0.0015256194116726 + 0.8154081377810312 0.0175891240440456 0.0019126833358650 + 0.8794678768558409 0.0055235245122126 0.0008708476156509 + 0.6607456749400253 0.0238589269426556 0.0028345767408327 + 0.7364820152304077 0.0402953345447718 0.0032909988819261 + 0.6437257357698205 0.0678784043114471 0.0045894620824638 + 0.5930980425461418 0.1395356071810826 0.0062591832494172 + 0.5861680189969418 0.0080665857041666 0.0018206702056404 + 0.8135558255123531 0.0001234468122874 0.0003443363125209 + 0.0589421088402292 0.9383291479118497 0.0003846264857381 + 0.3497880100093319 0.4930342901234747 0.0052261073484612 + 0.3230018235435502 0.6748972098116224 0.0006764119746262 + 0.1581458542495161 0.7736883369367374 0.0032195683537669 + 0.0295494682613534 0.9596195731350372 0.0006360972185858 + 0.2918191734265371 0.4892484845932904 0.0067726232860038 + 0.0755221785129958 0.9031909252462710 0.0013807653747952 + 0.1171166695088989 0.8420361139149987 0.0022563434227437 + 0.0111662181081692 0.9872302853957871 0.0001347461159294 + 0.2080456492790871 0.6904083654940789 0.0046931653381418 + 0.3922101149804348 0.5662628237507425 0.0039114592291532 + 0.3597112755099759 0.5464396833448917 0.0053151981815983 + 0.2458746994828754 0.7454392707127404 0.0015256194116726 + 0.1670027381749231 0.8154081377810312 0.0019126833358650 + 0.1150085986319464 0.8794678768558409 0.0008708476156509 + 0.3153953981173191 0.6607456749400253 0.0028345767408327 + 0.2232226502248206 0.7364820152304077 0.0032909988819261 + 0.2883958599187324 0.6437257357698205 0.0045894620824638 + 0.2673663502727756 0.5930980425461418 0.0062591832494172 + 0.4057653952988916 0.5861680189969418 0.0018206702056404 + 0.1863207276753595 0.8135558255123531 0.0003443363125209 + 0.0589421088402292 0.0027287432479211 0.0003846264857381 + 0.3497880100093319 0.1571776998671934 0.0052261073484612 + 0.3230018235435502 0.0021009666448276 0.0006764119746262 + 0.1581458542495161 0.0681658088137464 0.0032195683537669 + 0.0295494682613534 0.0108309586036093 0.0006360972185858 + 0.2918191734265371 0.2189323419801725 0.0067726232860038 + 0.0755221785129958 0.0212868962407332 0.0013807653747952 + 0.1171166695088989 0.0408472165761024 0.0022563434227437 + 0.0111662181081692 0.0016034964960438 0.0001347461159294 + 0.2080456492790871 0.1015459852268340 0.0046931653381418 + 0.3922101149804348 0.0415270612688227 0.0039114592291532 + 0.3597112755099759 0.0938490411451324 0.0053151981815983 + 0.2458746994828754 0.0086860298043841 0.0015256194116726 + 0.1670027381749231 0.0175891240440456 0.0019126833358650 + 0.1150085986319464 0.0055235245122126 0.0008708476156509 + 0.3153953981173191 0.0238589269426556 0.0028345767408327 + 0.2232226502248206 0.0402953345447718 0.0032909988819261 + 0.2883958599187324 0.0678784043114471 0.0045894620824638 + 0.2673663502727756 0.1395356071810826 0.0062591832494172 + 0.4057653952988916 0.0080665857041666 0.0018206702056404 + 0.1863207276753595 0.0001234468122874 0.0003443363125209 + 0.9383291479118497 0.0589421088402292 0.0003846264857381 + 0.4930342901234747 0.3497880100093319 0.0052261073484612 + 0.6748972098116224 0.3230018235435502 0.0006764119746262 + 0.7736883369367374 0.1581458542495161 0.0032195683537669 + 0.9596195731350372 0.0295494682613534 0.0006360972185858 + 0.4892484845932904 0.2918191734265371 0.0067726232860038 + 0.9031909252462710 0.0755221785129958 0.0013807653747952 + 0.8420361139149987 0.1171166695088989 0.0022563434227437 + 0.9872302853957871 0.0111662181081692 0.0001347461159294 + 0.6904083654940789 0.2080456492790871 0.0046931653381418 + 0.5662628237507425 0.3922101149804348 0.0039114592291532 + 0.5464396833448917 0.3597112755099759 0.0053151981815983 + 0.7454392707127404 0.2458746994828754 0.0015256194116726 + 0.8154081377810312 0.1670027381749231 0.0019126833358650 + 0.8794678768558409 0.1150085986319464 0.0008708476156509 + 0.6607456749400253 0.3153953981173191 0.0028345767408327 + 0.7364820152304077 0.2232226502248206 0.0032909988819261 + 0.6437257357698205 0.2883958599187324 0.0045894620824638 + 0.5930980425461418 0.2673663502727756 0.0062591832494172 + 0.5861680189969418 0.4057653952988916 0.0018206702056404 + 0.8135558255123531 0.1863207276753595 0.0003443363125209 + 0.0027287432479211 0.9383291479118497 0.0003846264857381 + 0.1571776998671934 0.4930342901234747 0.0052261073484612 + 0.0021009666448276 0.6748972098116224 0.0006764119746262 + 0.0681658088137464 0.7736883369367374 0.0032195683537669 + 0.0108309586036093 0.9596195731350372 0.0006360972185858 + 0.2189323419801725 0.4892484845932904 0.0067726232860038 + 0.0212868962407332 0.9031909252462710 0.0013807653747952 + 0.0408472165761024 0.8420361139149987 0.0022563434227437 + 0.0016034964960438 0.9872302853957871 0.0001347461159294 + 0.1015459852268340 0.6904083654940789 0.0046931653381418 + 0.0415270612688227 0.5662628237507425 0.0039114592291532 + 0.0938490411451324 0.5464396833448917 0.0053151981815983 + 0.0086860298043841 0.7454392707127404 0.0015256194116726 + 0.0175891240440456 0.8154081377810312 0.0019126833358650 + 0.0055235245122126 0.8794678768558409 0.0008708476156509 + 0.0238589269426556 0.6607456749400253 0.0028345767408327 + 0.0402953345447718 0.7364820152304077 0.0032909988819261 + 0.0678784043114471 0.6437257357698205 0.0045894620824638 + 0.1395356071810826 0.5930980425461418 0.0062591832494172 + 0.0080665857041666 0.5861680189969418 0.0018206702056404 + 0.0001234468122874 0.8135558255123531 0.0003443363125209] else throw(ArgumentError("unsupported order for triangle Gauss-Jacobi integration")) end diff --git a/src/Quadrature/quadrature.jl b/src/Quadrature/quadrature.jl index 4fdf6a45e8..dae3cc9795 100644 --- a/src/Quadrature/quadrature.jl +++ b/src/Quadrature/quadrature.jl @@ -239,7 +239,8 @@ function _FacetQuadratureRulePrism(::Type{T}, quad_types::Tuple{Symbol, Symbol}, qr_tri = QuadratureRule{RefTriangle}(T, quad_types[1], order) # Interval scaled and shifted in facet_to_element_transformation for quadrilateral faces from (-1,1)² to (0,1)² -> quarter the area -> quarter the quadrature weights return create_facet_quad_rule( - RefPrism, [2, 3, 4], qr_quad.weights / 4, qr_quad.points, + RefPrism, + [2, 3, 4], qr_quad.weights / 4, qr_quad.points, [1, 5], qr_tri.weights, qr_tri.points ) end @@ -249,7 +250,8 @@ function _FacetQuadratureRulePyramid(::Type{T}, quad_types::Tuple{Symbol, Symbol qr_tri = QuadratureRule{RefTriangle}(T, quad_types[1], order) # Interval scaled and shifted in facet_to_element_transformation for quadrilateral faces from (-1,1)² to (0,1)² -> quarter the area -> quarter the quadrature weights return create_facet_quad_rule( - RefPyramid, [1], qr_quad.weights / 4, qr_quad.points, + RefPyramid, + [1], qr_quad.weights / 4, qr_quad.points, [2, 3, 4, 5], qr_tri.weights, qr_tri.points ) end diff --git a/src/assembler.jl b/src/assembler.jl index 8c3d9d5f24..078f5fcd34 100644 --- a/src/assembler.jl +++ b/src/assembler.jl @@ -109,12 +109,13 @@ function assemble!(a::COOAssembler{T}, rowdofs::AbstractVector{Int}, coldofs::Ab @assert(size(Ke, 2) == ncols) append!(a.V, Ke) - return @inbounds for i in 1:ncols + @inbounds for i in 1:ncols append!(a.I, rowdofs) for _ in 1:nrows push!(a.J, coldofs[i]) end end + return end """ @@ -153,9 +154,10 @@ Assembles the element residual `ge` into the global residual vector `g`. @propagate_inbounds function assemble!(g::AbstractVector{T}, dofs::AbstractVector{Int}, ge::AbstractVector{T}) where {T} @boundscheck checkbounds(g, dofs) @boundscheck checkbounds(ge, keys(dofs)) - return @inbounds for (i, dof) in pairs(dofs) + @inbounds for (i, dof) in pairs(dofs) addindex!(g, ge[i], dof) end + return end """ @@ -191,10 +193,11 @@ function Base.show(io::IO, ::MIME"text/plain", a::Union{CSCAssembler, SymmetricC print(io, typeof(a), " for assembling into:\n - ") summary(io, a.K) f = a.f - return if !isempty(f) + if !isempty(f) print(io, "\n - ") summary(io, f) end + return end matrix_handle(a::AbstractCSCAssembler) = a.K @@ -287,7 +290,7 @@ end sorteddofs, permutation = _sortdofs_for_assembly!(A.permutation, A.sorteddofs, dofs) current_col = 1 - return @inbounds for Kcol in sorteddofs + @inbounds for Kcol in sorteddofs maxlookups = sym ? current_col : ld Kecol = permutation[current_col] ri = 1 # row index pointer for the local matrix @@ -324,19 +327,17 @@ end end current_col += 1 end + return end function _missing_sparsity_pattern_error(Krow::Int, Kcol::Int) - throw( - ErrorException( - "You are trying to assemble values in to K[$(Krow), $(Kcol)], but K[$(Krow), " * - "$(Kcol)] is missing in the sparsity pattern. Make sure you have called `K = " * - "allocate_matrix(dh)` or `K = allocate_matrix(dh, ch)` if you " * - "have affine constraints. This error might also happen if you are using " * - "the assembler in a threaded assembly loop (you need to create one " * - "`assembler` for each task)." - ) - ) + msg = "You are trying to assemble values in to K[$(Krow), $(Kcol)], but K[$(Krow), " * + "$(Kcol)] is missing in the sparsity pattern. Make sure you have called `K = " * + "allocate_matrix(dh)` or `K = allocate_matrix(dh, ch)` if you " * + "have affine constraints. This error might also happen if you are using " * + "the assembler in a threaded assembly loop (you need to create one " * + "`assembler` for each task)." + throw(ErrorException(msg)) end ## assemble! with local condensation ## diff --git a/src/deprecations.jl b/src/deprecations.jl index 2970b1819a..1e6417b72e 100644 --- a/src/deprecations.jl +++ b/src/deprecations.jl @@ -12,7 +12,8 @@ end function Base.showerror(io::IO, err::DeprecationError) print(io, "DeprecationError: ") - return print(io, err.msg) + print(io, err.msg) + return end function _iobuffer() @@ -83,6 +84,7 @@ struct Cell{refdim, nnodes, nfaces} else throw(DeprecationError("Cell{$refdim, $nnodes, $nfaces}(nodes)" => "$replacement(nodes)")) end + return end end export Cell @@ -96,14 +98,11 @@ using WriteVTK: vtk_grid export vtk_grid # To give better error function WriteVTK.vtk_grid(::String, ::Union{AbstractGrid, AbstractDofHandler}; kwargs...) - throw( - DeprecationError( - "The vtk interface has been updated in Ferrite v1.0. " * - "See https://github.com/Ferrite-FEM/Ferrite.jl/pull/692. " * - "Use VTKGridFile to open a vtk file, and the functions " * - "write_solution, write_cell_data, and write_projection to save data." - ) - ) + msg = "The vtk interface has been updated in Ferrite v1.0. " * + "See https://github.com/Ferrite-FEM/Ferrite.jl/pull/692. " * + "Use VTKGridFile to open a vtk file, and the functions " * + "write_solution, write_cell_data, and write_projection to save data." + throw(DeprecationError(msg)) end # Deprecation of auto-vectorized methods diff --git a/src/interpolations.jl b/src/interpolations.jl index 04b8197632..8620d11d0d 100644 --- a/src/interpolations.jl +++ b/src/interpolations.jl @@ -154,9 +154,10 @@ Evaluate all shape functions of `ip` at once at the reference point `ξ` and sto """ @propagate_inbounds function reference_shape_values!(values::AT, ip::IP, ξ::Vec) where {IP <: Interpolation, AT <: AbstractArray} @boundscheck checkbounds(values, 1:getnbasefunctions(ip)) - return @inbounds for i in 1:getnbasefunctions(ip) + @inbounds for i in 1:getnbasefunctions(ip) values[i] = reference_shape_value(ip, ξ, i) end + return end """ @@ -167,9 +168,10 @@ them in `gradients`. """ function reference_shape_gradients!(gradients::AT, ip::IP, ξ::Vec) where {IP <: Interpolation, AT <: AbstractArray} @boundscheck checkbounds(gradients, 1:getnbasefunctions(ip)) - return @inbounds for i in 1:getnbasefunctions(ip) + @inbounds for i in 1:getnbasefunctions(ip) gradients[i] = reference_shape_gradient(ip, ξ, i) end + return end """ @@ -181,9 +183,10 @@ and store them in `values`. function reference_shape_gradients_and_values!(gradients::GAT, values::SAT, ip::IP, ξ::Vec) where {IP <: Interpolation, SAT <: AbstractArray, GAT <: AbstractArray} @boundscheck checkbounds(gradients, 1:getnbasefunctions(ip)) @boundscheck checkbounds(values, 1:getnbasefunctions(ip)) - return @inbounds for i in 1:getnbasefunctions(ip) + @inbounds for i in 1:getnbasefunctions(ip) gradients[i], values[i] = reference_shape_gradient_and_value(ip, ξ, i) end + return end """ @@ -196,9 +199,10 @@ and store them in `hessians`, `gradients`, and `values`. @boundscheck checkbounds(hessians, 1:getnbasefunctions(ip)) @boundscheck checkbounds(gradients, 1:getnbasefunctions(ip)) @boundscheck checkbounds(values, 1:getnbasefunctions(ip)) - return @inbounds for i in 1:getnbasefunctions(ip) + @inbounds for i in 1:getnbasefunctions(ip) hessians[i], gradients[i], values[i] = reference_shape_hessian_gradient_and_value(ip, ξ, i) end + return end @@ -1659,7 +1663,8 @@ end function Base.show(io::IO, mime::MIME"text/plain", ip::VectorizedInterpolation{vdim}) where {vdim} show(io, mime, ip.ip) - return print(io, "^", vdim) + print(io, "^", vdim) + return end # Helper to get number of copies for DoF distribution diff --git a/src/iterators.jl b/src/iterators.jl index 697548734b..0abf2972b1 100644 --- a/src/iterators.jl +++ b/src/iterators.jl @@ -394,15 +394,17 @@ Base.length(iterator::GridIterators) = length(_getset(iterator)) function _check_same_celltype(grid::AbstractGrid, cellset::IntegerCollection) isconcretetype(getcelltype(grid)) && return nothing # Short circuit check celltype = getcelltype(grid, first(cellset)) - return if !all(getcelltype(grid, i) == celltype for i in cellset) + if !all(getcelltype(grid, i) == celltype for i in cellset) error("The cells in the cellset are not all of the same celltype.") end + return end function _check_same_celltype(grid::AbstractGrid, facetset::AbstractVecOrSet{<:BoundaryIndex}) isconcretetype(getcelltype(grid)) && return nothing # Short circuit check celltype = getcelltype(grid, first(facetset)[1]) - return if !all(getcelltype(grid, facet[1]) == celltype for facet in facetset) + if !all(getcelltype(grid, facet[1]) == celltype for facet in facetset) error("The cells in the set (set of $(eltype(facetset))) are not all of the same celltype.") end + return end diff --git a/src/utils.jl b/src/utils.jl index 3fc01cc817..a53ffe89bb 100644 --- a/src/utils.jl +++ b/src/utils.jl @@ -11,7 +11,7 @@ Debug mode influences `Ferrite.@debug expr`: when debug mode is enabled, `expr` evaluated, and when debug mode is disabled `expr` is ignored. """ function debug_mode(; enable = true) - return if DEBUG == enable == true + if DEBUG == enable == true @info "Debug mode already enabled." elseif DEBUG == enable == false @info "Debug mode already disabled." @@ -19,6 +19,7 @@ function debug_mode(; enable = true) Preferences.@set_preferences!("use_debug" => enable) @info "Debug mode $(enable ? "en" : "dis")abled. Restart the Julia session for this change to take effect!" end + return end @static if DEBUG