CADET Process 3 Column PCC Script Not Working with Tubing Included

Expected behavior.

I am trying to model a 3 column periodic counter current chromatography setup. Have modeled just the 3 columns in PCC_functions with CADET and worded fine. However due to the amount of tubbing in the experimental setup I also need to model that. I did this by implementing 3 tubular reactors. It should work exactly like the model without tubbing but account for the delay due to the tubbing.

Actual behavior

CADET never finishes and timeouts after 10 minutes.

How to produce bug (including a minimal reproducible example)

Run as is.

File produced by conda env export > environment.yml

environment.yml (7.7 KB)

Optional link to repository (oriented around this template: GitHub - modsim/bug_report_example: Template for reporting bugs including code and data)

I’ll add this here for protocol: when we looked at this during the last Office-hours, I found no ill-configuration of the Process. So I think that the CADET-Process side of things is working fine.

We did note, however, that (given the axial dispersion of 0 for the tubing) a reduction of the diameter of the tubing from 7.5e-4 to 7.5e-5 for all three tubings resulted in functional simulations
PCC_working_d7.5e-5.h5 (851.0 KB) while a diameter of 7.5e-4
lead to a stuck simulation
PCC_not_working_d7.5e-4.h5 (271.8 KB). Alternatively a raise of the axial dispersion to 1e-4 also lead to functional simulations.
PCC_working_d7.5e-4_dAx1e-4.h5 (867.6 KB).

Axial dispersion 0 Axial dispersion 1e-4
Diameter 7.5e-4 X :heavy_check_mark:
Diameter 7.5e-5 :heavy_check_mark: :heavy_check_mark:

I have not had time to load these into a CADET-Core debugger to check where they get stuck. This would most likely benefit from an inspection by @j.breuer or @AntoniaBerger .

Edit: I can lower the dispersion down to 1e-5, but no lower, at 1e-6 it crashes.

Without a binding model, the simulations run fine with dispersions as low as 1e-10

1 Like

Hi everyone, I’m on vacation this week but hope to have a look next week.

I remember having trouble with axial dispersion of zero too, at some point.
@Daniel, are you planning on joining the next office hour? I’d be free and could have a look.

I would avoid to numerically solve a plug flow reactor with zero dispersion whenever possible. An accurate solution can require extreme fine discretization, and any physical tubing must cause some degree of dispersion due to the parabolic flow profile.

1 Like

While I generally agree, I would argue that, from a modeling perspective and in line with Occam’s razor, setting the dispersion coefficient to zero is preferable when its value is not identifiable.

Also, it should still crash…

Hey sorry didnt see this post. I could come next office hours or if you have any specific questions I could answer them here.

Best,
Daniel

I have finalized the experimental setup and have updated the github to the actual tubbing lengths. Though the volume is off a bit since not all the tubbing is the same ID. The model worked with dispersion of 1e-3 but not with 1e-4. I am not sure what the actual value dispersion would end up being but it would it still be possible to get it to where it can run with smaller dispersion?

Also im not sure how big of an ask this is but I did have a ambitious idea of molding every piece of tubbing on the AKTA so that I could predict the peaks caused by liquid trapped in the tubbing. However I am pessimistic that would work since instability issues are arising with 3 tubular reactor models.

Best,
Daniel

Hi Daniel, please excuse the long silence, work and life are quite busy these days but I will have a look soon.

I added tubbing after the single column and it turns out it was too much and the model started stalling again. I tried increasing the dispersion even more but that did not seem to help.

Also the script is PCC_functions_V4.

Best,
Daniel

Using the Taylor expression for axial dispersion in open tubes D_{ax}=\frac{\nu^2d_{tubing}^2}{192D_o}, a 1 mm ID tubing should give you D_{ax} on the order of 10^{-4}. This value should work should not cause issues in the simulation… I would check the tolerances of the simulation, \text{RelTol}=10^{-6} and \text{AbsTol}=10^{-8} usually work well for me. Also a general comment – many of the transport parameters of the chromatography system, column, and resin can be determined using physical correlations, which are numerous. In my experience, these correlations will get you within an order of magnitude of the “true” value (let’s not get into the philisophy of this) at minimum. I am going to be uploading an Excel sheet that my co-op student made which I think will be useful for the community, since this is a pretty universal challenge.