mirror of
https://github.com/ANL-CEEESA/RELOG.git
synced 2025-12-05 23:38:52 -06:00
Replace Array by Vector
This commit is contained in:
@@ -15,21 +15,21 @@ end
|
|||||||
mutable struct ProcessNode <: Node
|
mutable struct ProcessNode <: Node
|
||||||
index::Int
|
index::Int
|
||||||
location::Plant
|
location::Plant
|
||||||
incoming_arcs::Array{Arc}
|
incoming_arcs::Vector{Arc}
|
||||||
outgoing_arcs::Array{Arc}
|
outgoing_arcs::Vector{Arc}
|
||||||
end
|
end
|
||||||
|
|
||||||
mutable struct ShippingNode <: Node
|
mutable struct ShippingNode <: Node
|
||||||
index::Int
|
index::Int
|
||||||
location::Union{Plant,CollectionCenter}
|
location::Union{Plant,CollectionCenter}
|
||||||
product::Product
|
product::Product
|
||||||
incoming_arcs::Array{Arc}
|
incoming_arcs::Vector{Arc}
|
||||||
outgoing_arcs::Array{Arc}
|
outgoing_arcs::Vector{Arc}
|
||||||
end
|
end
|
||||||
|
|
||||||
mutable struct Graph
|
mutable struct Graph
|
||||||
process_nodes::Array{ProcessNode}
|
process_nodes::Vector{ProcessNode}
|
||||||
plant_shipping_nodes::Array{ShippingNode}
|
plant_shipping_nodes::Vector{ShippingNode}
|
||||||
collection_shipping_nodes::Array{ShippingNode}
|
collection_shipping_nodes::Vector{ShippingNode}
|
||||||
arcs::Array{Arc}
|
arcs::Vector{Arc}
|
||||||
end
|
end
|
||||||
|
|||||||
@@ -10,9 +10,9 @@ using Statistics
|
|||||||
|
|
||||||
mutable struct Product
|
mutable struct Product
|
||||||
name::String
|
name::String
|
||||||
transportation_cost::Array{Float64}
|
transportation_cost::Vector{Float64}
|
||||||
transportation_energy::Array{Float64}
|
transportation_energy::Vector{Float64}
|
||||||
transportation_emissions::Dict{String,Array{Float64}}
|
transportation_emissions::Dict{String,Vector{Float64}}
|
||||||
end
|
end
|
||||||
|
|
||||||
mutable struct CollectionCenter
|
mutable struct CollectionCenter
|
||||||
@@ -21,14 +21,14 @@ mutable struct CollectionCenter
|
|||||||
latitude::Float64
|
latitude::Float64
|
||||||
longitude::Float64
|
longitude::Float64
|
||||||
product::Product
|
product::Product
|
||||||
amount::Array{Float64}
|
amount::Vector{Float64}
|
||||||
end
|
end
|
||||||
|
|
||||||
mutable struct PlantSize
|
mutable struct PlantSize
|
||||||
capacity::Float64
|
capacity::Float64
|
||||||
variable_operating_cost::Array{Float64}
|
variable_operating_cost::Vector{Float64}
|
||||||
fixed_operating_cost::Array{Float64}
|
fixed_operating_cost::Vector{Float64}
|
||||||
opening_cost::Array{Float64}
|
opening_cost::Vector{Float64}
|
||||||
end
|
end
|
||||||
|
|
||||||
mutable struct Plant
|
mutable struct Plant
|
||||||
@@ -39,19 +39,19 @@ mutable struct Plant
|
|||||||
output::Dict{Product,Float64}
|
output::Dict{Product,Float64}
|
||||||
latitude::Float64
|
latitude::Float64
|
||||||
longitude::Float64
|
longitude::Float64
|
||||||
disposal_limit::Dict{Product,Array{Float64}}
|
disposal_limit::Dict{Product,Vector{Float64}}
|
||||||
disposal_cost::Dict{Product,Array{Float64}}
|
disposal_cost::Dict{Product,Vector{Float64}}
|
||||||
sizes::Array{PlantSize}
|
sizes::Vector{PlantSize}
|
||||||
energy::Array{Float64}
|
energy::Vector{Float64}
|
||||||
emissions::Dict{String,Array{Float64}}
|
emissions::Dict{String,Vector{Float64}}
|
||||||
storage_limit::Float64
|
storage_limit::Float64
|
||||||
storage_cost::Array{Float64}
|
storage_cost::Vector{Float64}
|
||||||
end
|
end
|
||||||
|
|
||||||
mutable struct Instance
|
mutable struct Instance
|
||||||
time::Int64
|
time::Int64
|
||||||
products::Array{Product,1}
|
products::Vector{Product}
|
||||||
collection_centers::Array{CollectionCenter,1}
|
collection_centers::Vector{CollectionCenter}
|
||||||
plants::Array{Plant,1}
|
plants::Vector{Plant}
|
||||||
building_period::Array{Int64}
|
building_period::Vector{Int64}
|
||||||
end
|
end
|
||||||
|
|||||||
Reference in New Issue
Block a user