Class MRVMNationalBidder
- java.lang.Object
-
- org.spectrumauctions.sats.core.model.SATSBidder
-
- org.spectrumauctions.sats.core.model.mrvm.MRVMBidder
-
- org.spectrumauctions.sats.core.model.mrvm.MRVMNationalBidder
-
- All Implemented Interfaces:
java.io.Serializable,org.marketdesignresearch.mechlib.core.bidder.Bidder,org.marketdesignresearch.mechlib.instrumentation.MipInstrumentationable
public final class MRVMNationalBidder extends MRVMBidder
- Author:
- Michael Weiss
- See Also:
- Serialized Form
-
-
Field Summary
-
Fields inherited from class org.spectrumauctions.sats.core.model.SATSBidder
DEFAULT_DEMAND_QUERY_EPSILON, DEFAULT_DEMAND_QUERY_TIME_LIMIT
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidbidderTypeSpecificDemandQueryMIPAdjustments(MRVM_MIP mip)Allows a specific bidder type (subclass) to change the demand query mip before execution.MRVMNationalBidderdrawSimilarBidder(RNGSupplier rngSupplier)booleanequals(java.lang.Object obj)java.math.BigDecimalgammaFactor(MRVMRegionsMap.Region r, java.util.Set<MRVMLicense> bundle)Calculates the gamma factor, as explained in the model writeup.java.util.Map<MRVMRegionsMap.Region,java.math.BigDecimal>gammaFactors(java.util.Set<MRVMLicense> bundle)Calculates the gamma factors for all regions.java.math.BigDecimalgetGamma(int uncoveredRegions)Reads the gammavalue form the stored map.intgetKMax()<T extends BiddingLanguage>
TgetValueFunction(java.lang.Class<T> type, RNGSupplier rngSupplier)inthashCode()-
Methods inherited from class org.spectrumauctions.sats.core.model.mrvm.MRVMBidder
calculateValue, canEqual, getAllocationLimit, getAlpha, getBestBundles, getBeta, getWorld, getzHigh, getzLow, omegaFactor, refreshReference, setAllocationLimit, svFunction, svFunction
-
Methods inherited from class org.spectrumauctions.sats.core.model.SATSBidder
getDescription, getId, getLongId, getMipInstrumentation, getName, getPopulation, getSetup, getSetupType, getShortDescription, getStrategy, getValue, getValueFunction, getValueFunction, getWorldId, setMipInstrumentation, setStrategy, store, toString
-
-
-
-
Method Detail
-
gammaFactor
public java.math.BigDecimal gammaFactor(MRVMRegionsMap.Region r, java.util.Set<MRVMLicense> bundle)
Calculates the gamma factor, as explained in the model writeup.
The gamma factor represents a bidder-specific discount of the the regional (omega) values.- Specified by:
gammaFactorin classMRVMBidder- Parameters:
r- Not required for gamma calculation of national bidder and will be ignoredbundle- The complete bundle (not only containing the licenses of r).
-
gammaFactors
public java.util.Map<MRVMRegionsMap.Region,java.math.BigDecimal> gammaFactors(java.util.Set<MRVMLicense> bundle)
Calculates the gamma factors for all regions. For explanations of the gamma factors, seeMRVMBidder.gammaFactor(MRVMRegionsMap.Region, Set)
As gamma is not dependent on the region for national bidders, the returned map will contain the same value for all keys, i.e. the same gamma for all regions- Specified by:
gammaFactorsin classMRVMBidder- Parameters:
bundle- The bundle for which the discounts will be calculated.
-
getKMax
public int getKMax()
-
getGamma
public java.math.BigDecimal getGamma(int uncoveredRegions)
Reads the gammavalue form the stored map. If uncoveredRegions greater thangetKMax(), then the value for kMax is returned (see model writeup for explanation).- Parameters:
uncoveredRegions- the number of regions that are uncovered- Returns:
- the gamma value for the number of uncovered regions
-
drawSimilarBidder
public MRVMNationalBidder drawSimilarBidder(RNGSupplier rngSupplier)
- Specified by:
drawSimilarBidderin classSATSBidder
-
getValueFunction
public <T extends BiddingLanguage> T getValueFunction(java.lang.Class<T> type, RNGSupplier rngSupplier) throws UnsupportedBiddingLanguageException
- Overrides:
getValueFunctionin classMRVMBidder- Throws:
UnsupportedBiddingLanguageException
-
hashCode
public int hashCode()
- Overrides:
hashCodein classMRVMBidder
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equalsin classMRVMBidder
-
bidderTypeSpecificDemandQueryMIPAdjustments
protected void bidderTypeSpecificDemandQueryMIPAdjustments(MRVM_MIP mip)
Description copied from class:MRVMBidderAllows a specific bidder type (subclass) to change the demand query mip before execution. I.e. restrict demand query result to items where the bidder is interested in.- Specified by:
bidderTypeSpecificDemandQueryMIPAdjustmentsin classMRVMBidder
-
-