CostFormulationSpec

@Serializable
sealed class CostFormulationSpec(source)

Serializable description of a cost formulation to attach to the network. A NetworkSpec may carry several (a comparative study on one simulation — see the cost-redesign doc's multi-attach support). The builder constructs and attaches each one last, after the topology is final, satisfying the cost-formulation ordering and coverage guards.

v1 variants:

  • Default — one CostParamsSpec applied network-wide (DefaultMultiEchelonCostFormulation).

  • PerNodeIHP — a default CostParamsSpec with per-node overrides keyed by node name. Requires a small new framework type, landing with the cost-spec phase (D5).

Custom user formulations are a v1 escape hatch (attach in Kotlin after building).

Inheritors

Constructors

Link copied to clipboard
protected constructor()

Types

Link copied to clipboard
@Serializable
@SerialName(value = "default")
data class Default(val name: String? = null, val params: CostParamsSpec = CostParamsSpec()) : CostFormulationSpec

Uniform-parameters formulation applied across the whole network.

Link copied to clipboard
@Serializable
@SerialName(value = "perNodeIHP")
data class PerNodeIHP(val name: String? = null, val default: CostParamsSpec = CostParamsSpec(), val overrides: Map<String, CostParamsSpec> = emptyMap()) : CostFormulationSpec

Per-node-override formulation: a default parameter set plus overrides keyed by node name. Nodes not in overrides use default.

Properties

Link copied to clipboard
abstract val name: String?

Optional report-name prefix, distinguishing formulations in the report.