euro-hpc-pl / SpinGlassEngine.jl

Apache License 2.0
1 stars 1 forks source link

Default value for AbstractGauge in MpsContractor #30

Open annamariadziubyna opened 1 month ago

annamariadziubyna commented 1 month ago

We are using the MpsContractor structure, which is currently defined as follows: MpsContractor{T<:AbstractStrategy,R<:AbstractGauge,S<:Real} I would like to know if it's possible to modify this structure so that when R is not provided, it defaults to a predefined value, such as NoUpdate. Specifically, the desired behavior is for MpsContractor to behave like MpsContractor{T<:AbstractStrategy,S<:Real} where R is automatically set to NoUpdate.

lpawela commented 1 week ago

You can define a new constructor, something like MpsContractor(T, S, args...) where {T, S} = MpsContractor{T, NoUpdate, S}(args...).