mirror of
https://github.com/ANL-CEEESA/RELOG.git
synced 2025-12-06 15:48:51 -06:00
Allow user to specify product acquisition costs
This commit is contained in:
@@ -51,6 +51,7 @@ function parse(json)::Instance
|
||||
emissions = Dict()
|
||||
disposal_limit = zeros(T)
|
||||
disposal_cost = zeros(T)
|
||||
acquisition_cost = zeros(T)
|
||||
|
||||
if "transportation energy (J/km/tonne)" in keys(product_dict)
|
||||
energy = product_dict["transportation energy (J/km/tonne)"]
|
||||
@@ -68,6 +69,10 @@ function parse(json)::Instance
|
||||
disposal_cost = product_dict["disposal cost (\$/tonne)"]
|
||||
end
|
||||
|
||||
if "acquisition cost (\$/tonne)" in keys(product_dict)
|
||||
acquisition_cost = product_dict["acquisition cost (\$/tonne)"]
|
||||
end
|
||||
|
||||
prod_centers = []
|
||||
|
||||
product = Product(
|
||||
@@ -77,6 +82,7 @@ function parse(json)::Instance
|
||||
emissions,
|
||||
disposal_limit,
|
||||
disposal_cost,
|
||||
acquisition_cost,
|
||||
prod_centers,
|
||||
)
|
||||
push!(products, product)
|
||||
|
||||
@@ -15,6 +15,7 @@ mutable struct Product
|
||||
transportation_emissions::Dict{String,Vector{Float64}}
|
||||
disposal_limit::Vector{Float64}
|
||||
disposal_cost::Vector{Float64}
|
||||
acquisition_cost::Vector{Float64}
|
||||
collection_centers::Vector
|
||||
end
|
||||
|
||||
|
||||
Reference in New Issue
Block a user