Hey @Will_m32 and welcome to the forum!
The simplest thing you could to is to use the slice_solution
method.
It expects a solution object and allows you to specify flags such as use_total_concentration
(which sums up all components) and components
(a list of components you want to sum up).
In your example, this could look something like this:
from CADETProcess.solution import slice_solution
solution_new = slice_solution(simulation_results.solution.column.outlet, use_total_concentration=True, components=['A', 'B', 'C'])
solution_new.plot()
Which produces the following figure:
Note that I excluded the Salt
component for the new solution object.
Also note that both the Comparator
, as well as the Fractionator
already support slicing so you can add the components
list and use_total_concentration
arguments in the corresponding methods.