René's URL Explorer Experiment


Title: Fix calculation of phase equilibria if one or more component has 0 composition by prehner · Pull Request #331 · feos-org/feos · GitHub

Open Graph Title: Fix calculation of phase equilibria if one or more component has 0 composition by prehner · Pull Request #331 · feos-org/feos

X Title: Fix calculation of phase equilibria if one or more component has 0 composition by prehner · Pull Request #331 · feos-org/feos

Description: This is based on the discussion in #254 This issue seems to affect most phase equilibrium algorithms in feos. We focus on the most important ones Critical points ✅ The issue is related to the eigenvectors of the 0 components, as well as their composition going to 0 which creates numerical problems. I did not find a way to circumvent this by rewriting the expressions, but we can simply catch the special case (although that might effect the calculation of derivatives) Fixed the evaluation of eigenvectors of 2x2 matrices in num-dual itt-ustutt/num-dual#98 Manually overrode the components which have 0 composition in the calculation of the 2nd criticality condition. Bubble and dew points ℹ️ There are actually a number of points where x_i=0 leads to failure: The definition of the residual in the outer loop |(k_i x_i)/y_i| -> could be changed to absolute error The residual in the newton step mu_i^L=mu_i^V due to to the divergence in the ideal gas term -> could be changed to isofugacity related: Other divisions by 0/divergences in the ideal gas term in the calculation of the Jacobian -> should be gone when switching to fugacities Tp flash ✅ An actual bug that set `ln(x/y)` to zero instead of the residual `ln(x phi_l/(y phi_v))`. Fixed by changing the residual (which is only used for determining convergence) from `ln(x phi_l/(y phi_v))` to `x phi_l/phi_v - y`.

Open Graph Description: This is based on the discussion in #254 This issue seems to affect most phase equilibrium algorithms in feos. We focus on the most important ones Critical points ✅ The issue is related to the eige...

X Description: This is based on the discussion in #254 This issue seems to affect most phase equilibrium algorithms in feos. We focus on the most important ones Critical points ✅ The issue is related to the eige...

Opengraph URL: https://github.com/feos-org/feos/pull/331

X: @github

direct link

Domain: github.com

route-pattern/:user_id/:repository/pull/:id/files(.:format)
route-controllerpull_requests
route-actionfiles
fetch-noncev2:87e43e1c-68d5-9bab-06bd-6e0ffdbd588c
current-catalog-service-hashae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b
request-idA4FC:13D4B0:98324:CAD0B:698F9A04
html-safe-nonced22ab873bc713d97d68f4904b2ad62c2fb63fa440abb4d4e1b58c205d3728dea
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJBNEZDOjEzRDRCMDo5ODMyNDpDQUQwQjo2OThGOUEwNCIsInZpc2l0b3JfaWQiOiI1MTcyMTExNjkxMjUwMTQwMjAiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ==
visitor-hmac1a8544d9eea3a2937d9020804d22c82c92b7bac928ded1aa307631ca86001def
hovercard-subject-tagpull_request:3112807613
github-keyboard-shortcutsrepository,pull-request-list,pull-request-conversation,pull-request-files-changed,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///pull_requests/show/files
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/feos-org/feos/pull/331/files
twitter:imagehttps://avatars.githubusercontent.com/u/69816385?s=400&v=4
twitter:cardsummary_large_image
og:imagehttps://avatars.githubusercontent.com/u/69816385?s=400&v=4
og:image:altThis is based on the discussion in #254 This issue seems to affect most phase equilibrium algorithms in feos. We focus on the most important ones Critical points ✅ The issue is related to the eige...
og:site_nameGitHub
og:typeobject
hostnamegithub.com
expected-hostnamegithub.com
None5f47eb8d0aaafbfcb6a8220a40bd81431acf688857c575e6489670c394cfa36f
turbo-cache-controlno-preview
diff-viewunified
go-importgithub.com/feos-org/feos git https://github.com/feos-org/feos.git
octolytics-dimension-user_id87855701
octolytics-dimension-user_loginfeos-org
octolytics-dimension-repository_id424905104
octolytics-dimension-repository_nwofeos-org/feos
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id424905104
octolytics-dimension-repository_network_root_nwofeos-org/feos
turbo-body-classeslogged-out env-production page-responsive full-width
disable-turbotrue
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
release09a8136f6e8f8fd3078d54ce5f8b7adb493d44a7
ui-targetfull
theme-color#1e2327
color-schemelight dark

Links:

Skip to contenthttps://github.com/feos-org/feos/pull/331/files#start-of-content
https://github.com/
Sign in https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Ffeos-org%2Ffeos%2Fpull%2F331%2Ffiles
GitHub CopilotWrite better code with AIhttps://github.com/features/copilot
GitHub SparkBuild and deploy intelligent appshttps://github.com/features/spark
GitHub ModelsManage and compare promptshttps://github.com/features/models
MCP RegistryNewIntegrate external toolshttps://github.com/mcp
ActionsAutomate any workflowhttps://github.com/features/actions
CodespacesInstant dev environmentshttps://github.com/features/codespaces
IssuesPlan and track workhttps://github.com/features/issues
Code ReviewManage code changeshttps://github.com/features/code-review
GitHub Advanced SecurityFind and fix vulnerabilitieshttps://github.com/security/advanced-security
Code securitySecure your code as you buildhttps://github.com/security/advanced-security/code-security
Secret protectionStop leaks before they starthttps://github.com/security/advanced-security/secret-protection
Why GitHubhttps://github.com/why-github
Documentationhttps://docs.github.com
Bloghttps://github.blog
Changeloghttps://github.blog/changelog
Marketplacehttps://github.com/marketplace
View all featureshttps://github.com/features
Enterpriseshttps://github.com/enterprise
Small and medium teamshttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
App Modernizationhttps://github.com/solutions/use-case/app-modernization
DevSecOpshttps://github.com/solutions/use-case/devsecops
DevOpshttps://github.com/solutions/use-case/devops
CI/CDhttps://github.com/solutions/use-case/ci-cd
View all use caseshttps://github.com/solutions/use-case
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
View all industrieshttps://github.com/solutions/industry
View all solutionshttps://github.com/solutions
AIhttps://github.com/resources/articles?topic=ai
Software Developmenthttps://github.com/resources/articles?topic=software-development
DevOpshttps://github.com/resources/articles?topic=devops
Securityhttps://github.com/resources/articles?topic=security
View all topicshttps://github.com/resources/articles
Customer storieshttps://github.com/customer-stories
Events & webinarshttps://github.com/resources/events
Ebooks & reportshttps://github.com/resources/whitepapers
Business insightshttps://github.com/solutions/executive-insights
GitHub Skillshttps://skills.github.com
Documentationhttps://docs.github.com
Customer supporthttps://support.github.com
Community forumhttps://github.com/orgs/community/discussions
Trust centerhttps://github.com/trust-center
Partnershttps://github.com/partners
GitHub SponsorsFund open source developershttps://github.com/sponsors
Security Labhttps://securitylab.github.com
Maintainer Communityhttps://maintainers.github.com
Acceleratorhttps://github.com/accelerator
Archive Programhttps://archiveprogram.github.com
Topicshttps://github.com/topics
Trendinghttps://github.com/trending
Collectionshttps://github.com/collections
Enterprise platformAI-powered developer platformhttps://github.com/enterprise
GitHub Advanced SecurityEnterprise-grade security featureshttps://github.com/security/advanced-security
Copilot for BusinessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/premium-support
Pricinghttps://github.com/pricing
Search syntax tipshttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
documentationhttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
Sign in https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Ffeos-org%2Ffeos%2Fpull%2F331%2Ffiles
Sign up https://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fpull_requests%2Fshow%2Ffiles&source=header-repo&source_repo=feos-org%2Ffeos
Reloadhttps://github.com/feos-org/feos/pull/331/files
Reloadhttps://github.com/feos-org/feos/pull/331/files
Reloadhttps://github.com/feos-org/feos/pull/331/files
feos-org https://github.com/feos-org
feoshttps://github.com/feos-org/feos
Notifications https://github.com/login?return_to=%2Ffeos-org%2Ffeos
Fork 30 https://github.com/login?return_to=%2Ffeos-org%2Ffeos
Star 177 https://github.com/login?return_to=%2Ffeos-org%2Ffeos
Code https://github.com/feos-org/feos
Issues 22 https://github.com/feos-org/feos/issues
Pull requests 6 https://github.com/feos-org/feos/pulls
Discussions https://github.com/feos-org/feos/discussions
Actions https://github.com/feos-org/feos/actions
Projects 0 https://github.com/feos-org/feos/projects
Security 0 https://github.com/feos-org/feos/security
Insights https://github.com/feos-org/feos/pulse
Code https://github.com/feos-org/feos
Issues https://github.com/feos-org/feos/issues
Pull requests https://github.com/feos-org/feos/pulls
Discussions https://github.com/feos-org/feos/discussions
Actions https://github.com/feos-org/feos/actions
Projects https://github.com/feos-org/feos/projects
Security https://github.com/feos-org/feos/security
Insights https://github.com/feos-org/feos/pulse
Sign up for GitHub https://github.com/signup?return_to=%2Ffeos-org%2Ffeos%2Fissues%2Fnew%2Fchoose
terms of servicehttps://docs.github.com/terms
privacy statementhttps://docs.github.com/privacy
Sign inhttps://github.com/login?return_to=%2Ffeos-org%2Ffeos%2Fissues%2Fnew%2Fchoose
prehnerhttps://github.com/prehner
mainhttps://github.com/feos-org/feos/tree/main
zero_compositionhttps://github.com/feos-org/feos/tree/zero_composition
Conversation 1 https://github.com/feos-org/feos/pull/331
Commits 5 https://github.com/feos-org/feos/pull/331/commits
Checks 16 https://github.com/feos-org/feos/pull/331/checks
Files changed https://github.com/feos-org/feos/pull/331/files
Please reload this pagehttps://github.com/feos-org/feos/pull/331/files
Fix calculation of phase equilibria if one or more component has 0 composition https://github.com/feos-org/feos/pull/331/files#top
Show all changes 5 commits https://github.com/feos-org/feos/pull/331/files
b09ea33 Fix critical point evaluation if one component has 0 composition prehner Dec 17, 2025 https://github.com/feos-org/feos/pull/331/commits/b09ea331bdf34d7c58c966ff2618a672a37f9f56
7eef180 fix tp-flash and add test prehner Jan 9, 2026 https://github.com/feos-org/feos/pull/331/commits/7eef180dcdf66c6185a50d2232a930ad8bf4c023
5c2f606 makes slightly more sense to check for zeros in the feed composition … prehner Jan 9, 2026 https://github.com/feos-org/feos/pull/331/commits/5c2f6063f767ba411be97aded0c0486040c9945b
899a66d change residual in tp flash to avoid division by 0 prehner Jan 9, 2026 https://github.com/feos-org/feos/pull/331/commits/899a66d3d4335f78debeffa16b699b36e64690f3
bbc8494 add changelog entry prehner Jan 15, 2026 https://github.com/feos-org/feos/pull/331/commits/bbc84941455db6687d14e9edf333fdbbcc6ef474
Clear filters https://github.com/feos-org/feos/pull/331/files
Please reload this pagehttps://github.com/feos-org/feos/pull/331/files
Please reload this pagehttps://github.com/feos-org/feos/pull/331/files
CHANGELOG.md https://github.com/feos-org/feos/pull/331/files#diff-06572a96a58dc510037d5efa622f9bec8519bc1beab13c9f251e97e657a9d4ed
tp_flash.rs https://github.com/feos-org/feos/pull/331/files#diff-7eccb83cb487832276202ce73ac6476b9d732812ad522164bef571c703d7d105
critical_point.rs https://github.com/feos-org/feos/pull/331/files#diff-d07e6b044671ccf79cb1d3fed0d2fa7fe2d57dc72e7602735be6dab6df9463ae
critical_point.rs https://github.com/feos-org/feos/pull/331/files#diff-7388d944188ad6b39f9181c362d99a4faf1e5e1ab22d7f746f1ba7f927921b22
tp_flash.rs https://github.com/feos-org/feos/pull/331/files#diff-10ef8d8e8e1011f4f9825fe278284ba45565961505581eb11a724b60a391ccd9
CHANGELOG.mdhttps://github.com/feos-org/feos/pull/331/files#diff-06572a96a58dc510037d5efa622f9bec8519bc1beab13c9f251e97e657a9d4ed
View file https://github.com/feos-org/feos/blob/bbc84941455db6687d14e9edf333fdbbcc6ef474/CHANGELOG.md
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/feos-org/feos/pull/331/{{ revealButtonHref }}
https://github.com/feos-org/feos/pull/331/files#diff-06572a96a58dc510037d5efa622f9bec8519bc1beab13c9f251e97e657a9d4ed
https://github.com/feos-org/feos/pull/331/files#diff-06572a96a58dc510037d5efa622f9bec8519bc1beab13c9f251e97e657a9d4ed
crates/feos-core/src/phase_equilibria/tp_flash.rshttps://github.com/feos-org/feos/pull/331/files#diff-7eccb83cb487832276202ce73ac6476b9d732812ad522164bef571c703d7d105
View file https://github.com/feos-org/feos/blob/bbc84941455db6687d14e9edf333fdbbcc6ef474/crates/feos-core/src/phase_equilibria/tp_flash.rs
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/feos-org/feos/pull/331/{{ revealButtonHref }}
https://github.com/feos-org/feos/pull/331/files#diff-7eccb83cb487832276202ce73ac6476b9d732812ad522164bef571c703d7d105
https://github.com/feos-org/feos/pull/331/files#diff-7eccb83cb487832276202ce73ac6476b9d732812ad522164bef571c703d7d105
crates/feos-core/src/state/critical_point.rshttps://github.com/feos-org/feos/pull/331/files#diff-d07e6b044671ccf79cb1d3fed0d2fa7fe2d57dc72e7602735be6dab6df9463ae
View file https://github.com/feos-org/feos/blob/bbc84941455db6687d14e9edf333fdbbcc6ef474/crates/feos-core/src/state/critical_point.rs
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/feos-org/feos/pull/331/{{ revealButtonHref }}
https://github.com/feos-org/feos/pull/331/files#diff-d07e6b044671ccf79cb1d3fed0d2fa7fe2d57dc72e7602735be6dab6df9463ae
https://github.com/feos-org/feos/pull/331/files#diff-d07e6b044671ccf79cb1d3fed0d2fa7fe2d57dc72e7602735be6dab6df9463ae
https://github.com/feos-org/feos/pull/331/files#diff-d07e6b044671ccf79cb1d3fed0d2fa7fe2d57dc72e7602735be6dab6df9463ae
https://github.com/feos-org/feos/pull/331/files#diff-d07e6b044671ccf79cb1d3fed0d2fa7fe2d57dc72e7602735be6dab6df9463ae
crates/feos/tests/pcsaft/critical_point.rshttps://github.com/feos-org/feos/pull/331/files#diff-7388d944188ad6b39f9181c362d99a4faf1e5e1ab22d7f746f1ba7f927921b22
View file https://github.com/feos-org/feos/blob/bbc84941455db6687d14e9edf333fdbbcc6ef474/crates/feos/tests/pcsaft/critical_point.rs
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/feos-org/feos/pull/331/{{ revealButtonHref }}
https://github.com/feos-org/feos/pull/331/files#diff-7388d944188ad6b39f9181c362d99a4faf1e5e1ab22d7f746f1ba7f927921b22
https://github.com/feos-org/feos/pull/331/files#diff-7388d944188ad6b39f9181c362d99a4faf1e5e1ab22d7f746f1ba7f927921b22
crates/feos/tests/pcsaft/tp_flash.rshttps://github.com/feos-org/feos/pull/331/files#diff-10ef8d8e8e1011f4f9825fe278284ba45565961505581eb11a724b60a391ccd9
View file https://github.com/feos-org/feos/blob/bbc84941455db6687d14e9edf333fdbbcc6ef474/crates/feos/tests/pcsaft/tp_flash.rs
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/feos-org/feos/pull/331/{{ revealButtonHref }}
https://github.com/feos-org/feos/pull/331/files#diff-10ef8d8e8e1011f4f9825fe278284ba45565961505581eb11a724b60a391ccd9
https://github.com/feos-org/feos/pull/331/files#diff-10ef8d8e8e1011f4f9825fe278284ba45565961505581eb11a724b60a391ccd9
https://github.com/feos-org/feos/pull/331/files#diff-10ef8d8e8e1011f4f9825fe278284ba45565961505581eb11a724b60a391ccd9
https://github.com/feos-org/feos/pull/331/files#diff-10ef8d8e8e1011f4f9825fe278284ba45565961505581eb11a724b60a391ccd9
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.