Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
PaulOlyslager committed Nov 14, 2024
1 parent 258bd74 commit 48ae54e
Showing 1 changed file with 1 addition and 24 deletions.
25 changes: 1 addition & 24 deletions src/quadstrat.jl
Original file line number Diff line number Diff line change
Expand Up @@ -4,30 +4,7 @@ struct AssignQuadStrat <: BEAST.AbstractOperator
op::BEAST.AbstractOperator
qs
end
# struct DefaultQuadstrat end
# AssignQuadStrat(op,qs::DefaultQuadstrat) = op
# function AssignQuadStrat(op::AssignQuadStrat,qs)
# @warn "tryed but failed to overwrite quadstrat "*string(typeof(op.qs))*" assigned to "*string(typeof(op))*" with "*string(typeof(qs))
# op
# end
# assign_quadstrat(op::Operator, qs::AbstractQuadStrat) = AssignQuadStrat(op, qs)
# operatortype(a::AbstractQuadStrat) = error("assign operatortype for quadstrat "*string(typeof(a)))

# assign_quadstrat(op::LinearCombinationOfOperators, qs::AbstractQuadStrat) = sum([c*assign_quadstrat(opi, qs) for (c,opi) in zip(op.coeffs,op.ops)])
# function assign_quadstrat(op::LinearCombinationOfOperators, qss::Vector{<:AbstractQuadStrat})
# assign_quadstrat(op,qss,operatortype.(qss))
# end
# function assign_quadstrat(op::LinearCombinationOfOperators, qss::Vector{<:AbstractQuadStrat}, operator_types::Vector)
# return sum([c*assign_quadstrat(opi,qss[findfirst(x-> typeof(opi) ∈ x ,operator_types)]) for (c,opi) in zip(op.coeffs,op.ops)])
# end

# assign_quadstrat(op::BilForm, qs) = BilForm(op.test_space,op.trial_space,assign_quadstrat(op.terms,qs))
# assign_quadstrat(op::BilTerm, qs) = BilTerm(op.test_id,op.trial_id,op.test_ops,op.trial_ops,op.coeff,assign_quadstrat(op.kernel,qs))

# assign_quadstrat(op::BilForm, qs, types) = BilForm(op.test_space,op.trial_space,assign_quadstrat(op.terms,qs,types))
# assign_quadstrat(op::BilTerm, qs, types) = BilTerm(op.test_id,op.trial_id,op.test_ops,op.trial_ops,op.coeff,assign_quadstrat(op.kernel,qs,types))
# scalartype(a::AssignQuadStrat) = scalartype(a.operator_types)

export AssignQuadStrat
function BEAST.assemble!(op::AssignQuadStrat,test_functions::BEAST.Space, trial_functions::BEAST.Space,
store, threading;quadstrat=nothing)
BEAST.assemble!(op.op,test_functions,trial_functions,store,threading; quadstrat=op.qs)
Expand Down

0 comments on commit 48ae54e

Please sign in to comment.