ClapeyronThermo / Clapeyron.jl

Clapeyron provides a framework for the development and use of fluid-thermodynamic models, including SAFT, cubic, activity, multi-parameter, and COSMO-SAC.
MIT License
193 stars 49 forks source link

Bug Fixes for example notebooks #173

Open pw0908 opened 1 year ago

pw0908 commented 1 year ago

It's been a while since we've checked the example notebooks to see if they still run and, in the process of checking them, I found a few bugs:

julia> bubble_pressure(model,218.15,[1e-5,1-1e-5]) (NaN, NaN, NaN, [NaN, NaN])


- [x] `GE_mixing_SAFT.ipynb`: `bubble_temperature` no longer takes `T0` as an initial guess for activity coefficient models
- [x] `user_defined_eos.ipynb`: We've updated SAFT-VR Mie and that needs to be reflected here.
- [ ] `multi-component_vle_vlle_lle_crit.ipynb`: There's unfortunately a few bugs here:
    - [x] For the 12-component pT-isopleth, SAFT-gamma Mie struggles to split the model:
```julia
julia> model4 = SAFTgammaMie(["methane","nitrogen","carbon dioxide","ethane","propane","butane","isobutane",
                          "pentane","isopentane","hexane","heptane","octane"]);
julia> x =[0.833482,0.056510,0.002840,0.075260,0.020090,0.005200,0.003050,0.001440,0.001200,0.000680,0.000138,0.000110];

julia> bubble_pressure(model4,150.,x)
┌ Error: SAFTVRMie{BasicIdeal} cannot be splitted
longemen3000 commented 1 year ago

the 12 component split was a bug on group_sum. looking on the others