{"id":20186369,"url":"https://github.com/ipqa-research/fenvelopes","last_synced_at":"2026-02-13T04:14:48.908Z","repository":{"id":190174604,"uuid":"637955680","full_name":"ipqa-research/fenvelopes","owner":"ipqa-research","description":"Program to calculate phase boundaries of multicomponent systems using Equations of State. WIP now suporting PT envelopes and PX envelopes with partial three-phase-behaviour","archived":false,"fork":false,"pushed_at":"2024-04-12T18:43:18.000Z","size":2250,"stargazers_count":6,"open_issues_count":0,"forks_count":2,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-03T06:45:11.299Z","etag":null,"topics":["envelope","equation-of-state","fortran","fortran-package-manager","phase-equilibria","phase-equilibrium","thermodynamic-calculations","thermodynamics-models"],"latest_commit_sha":null,"homepage":"","language":"Fortran","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ipqa-research.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null}},"created_at":"2023-05-08T19:16:33.000Z","updated_at":"2024-06-28T05:06:22.000Z","dependencies_parsed_at":"2023-10-04T23:45:44.120Z","dependency_job_id":"687a23ab-756c-48a2-b704-ba3b783bfb17","html_url":"https://github.com/ipqa-research/fenvelopes","commit_stats":null,"previous_names":["fedebenelli/envelopes","ipqa-research/fenvelopes"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/ipqa-research/fenvelopes","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ipqa-research%2Ffenvelopes","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ipqa-research%2Ffenvelopes/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ipqa-research%2Ffenvelopes/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ipqa-research%2Ffenvelopes/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ipqa-research","download_url":"https://codeload.github.com/ipqa-research/fenvelopes/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ipqa-research%2Ffenvelopes/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":272873500,"owners_count":25007553,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-08-30T02:00:09.474Z","response_time":77,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["envelope","equation-of-state","fortran","fortran-package-manager","phase-equilibria","phase-equilibrium","thermodynamic-calculations","thermodynamics-models"],"created_at":"2024-11-14T03:16:58.721Z","updated_at":"2026-02-13T04:14:48.838Z","avatar_url":"https://github.com/ipqa-research.png","language":"Fortran","funding_links":[],"categories":[],"sub_categories":[],"readme":"# fenvelopes: Phase diagrams with Equations of State.\n\n![Phase diagram PTA](figs/pta.png)\n\nThis is an ongoing project that intends te be a fully fledged generator of\nphase equilibria diagrams from multicomponent systems, using Equations of\nState.\n\n## Capabilities\nRight now `fenvelopes` calculates three kinds of phase-envelopes.\n\n- [x] Two-phase PT envelopes\n- [ ] Three-phase PT envelopes\n    - [x] PT envelopes based on double saturation points.\n    - [ ] Isolated PT envelopes\n- [ ] DSP lines:\n    - [x] DSP lines from a PT DSP\n- [x] Two-phase Px envelopes\n- [ ] Three-phase Px envelopes\n    - [x] Px envelopes based on double saturation points.\n    - [ ] Isolated Px envelopes:\n        - [x] Isolated Px from PT\n        - [ ] Isolated Px from search\n- [ ] Python wrappers to ease up scripting and plotting.\n\n## Usage\nThis program is intended to be used as a `CLI` software. The command used to\ncalculate phase diagrams is:\n\n```bash\nfenvelopes --infile input_file.nml\n```\n\nThis will generate an `fenvelopes_output` directory. Which contains all the\ngenerated output files with the relevant data.\n\n### Input files\nThe input files \n\n```fortran\n! input.nml\n!\n! Namelist based input file\n! =========================\n!\n! Units:\n!  - Pressure: bar\n!  - Temperature: K\n!  - Volume: L\n! =========================\n\n\n\u0026nml_setup\n    ! General settings\n    nc=5,                ! Number of components\n    model=\"PR78\",        ! SRK PR76 PR78\n    mixrule=\"ClassicVdW\" ! only ClassicVdW for now\n/\n\n\u0026nml_composition\n    names=\"PC1\" \"PC2\" \"PC3\" \"PC4\" \"H2O\"\n    spec=\"critical\", ! critical or parameters specification\n    z=0.15 0.10 0.10 0.15 0.50\n/\n\n\u0026nml_classicvdw ! Classic VdW mixing rule parameters\n    ! kij matrix\n    kij(1, :)=0      0      0      0      0.7192\n    kij(2, :)=0      0      0      0      0.4598\n    kij(3, :)=0      0      0      0      0.2673\n    kij(4, :)=0      0      0      0      0.2417\n    kij(5, :)=0.7192 0.4598 0.2673 0.2417 0\n    \n    ! lij matrix\n    lij(:, :) = 0\n/\n\n\u0026nml_critical\n    ! Critical constants\n    \n    ! Critical Temperature\n    tc=305.586 638.889 788.889 838.889 647.3\n    \n    ! Critical Pressure\n    pc=48.82 19.65 10.2 7.72 220.89\n\n    ! Acentric Factor\n    w=0.098 0.535 0.891 1.085 0.344\n/\n\n\u0026nml_px ! Px envelopes relevant info\n    ! Temperature\n    T=350.0\n    \n    ! Initial composition, ussualy the same as the main fluid.\n    z_0=0.15 0.10 0.10 0.15 0.50 \n    \n    ! Injection fluid composition\n    z_injection=1 0 0 0 0\n\n    ! Which kind of injection to realize\n    injection_case=\"displace\" ! [dilute|displace]\n/\n```\n\n### Output\nAll the output is directed to a generated folder `fenvelopes_output`. With the files\n\n`env-\u003cnphases\u003eph-\u003cenv_kind\u003e_\u003cenvnumber\u003e.dat`\n\nWere all the envelope's calculated points are written in a `csv-like` format,\ndelimited by spaces.\n\n## Installation\nThis program uses [`fpm`](https://fpm.fortran-lang.org) as a builder. `fpm`\nhandles all the needed dependencies and compiling procedures.\nIt is distributed in many ways, but we recommend the `pip` distribution. \n\n```bash\n# using pipx\npipx install fpm\n```\n\nTo install this program is as simple as:\n\n```\ngit clone https://www.github.com/fedebenelli/envelopes\ncd envelopes\nfpm install --profile release\n```\nThis will make `fenvelopes` accessible from any directory of your computer\n\nIf you don't want to install the program and just run it you can also run it\nwith `fpm`\n\n```bash\nfpm run --profile release -- --infile \u003cinfile.nml PATH\u003e\n```\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fipqa-research%2Ffenvelopes","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fipqa-research%2Ffenvelopes","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fipqa-research%2Ffenvelopes/lists"}