Get chroline concentration at each node


#1

Hello everyone,

I am trying to get the chroline concentrations in all of the network nodes but can’t seem to find a method to do so. This is my sample code:

%% Chroline decay simulation. CyberPhysical systems optimization.
G = epanet(‘net2-cl2.inp’)

%% Properties
properties(G) % List of all available parameters
diameters = G.LinkDiameter % Link diameters from parameters
elevations = G.NodeElevations % Node elevations from parameters

%% Methods
methods(G) % List of all available methods
elevations = G.getNodeElevations([2 5]) % Node elevations for Nodes 2 & 5
diameters = G.getLinkDiameter % Link diameters from library
G.setLinkDiameter(diameters) % Set new link diameter
G.plot % Plots the network in a MATLAB Figure
A = G.getConnectivityMatrix % Create the connectivity matrix

%% Calling EPANET-MSX
H = G.getComputedHydraulicTimeSeries % Solve hydraulic dynamics in library
Q = G.getComputedQualityTimeSeries % Solve quality dynamics in library
B = G.getBinComputedAllParameters % Solve in library, create Binary file

%% EPANET-MSX
G.loadMSXFile(‘net2-cl2.msx’) % Load MSX file with reactions
Q_msx = G.getMSXComputedQualityNode % Compute water quality using MSX
G.plotMSXSpeciesNodeConcentration(4,1) % Plot MSX species in MATLAB Figure
G.getMSXSpeciesNodeConcentration(4,1)
%plotting chroline concentrations
%% Unload all libraries
G.unloadMSX % Unload EPANET-MSX
G.unload % Unload EPANET

The problem is that I only get this variable as a result Q_msx but I need a list of concentrations for each node over a period of time.