POSYDON-code / POSYDON-code/POSYDON

Consolidate duplicated XRB wind and BHL utilities

Open
#887 0 comments 0 reactions 1 assignee View on GitHub

@tassos25 is already working on this.

Since Aug 14, 2026.

discuss
Dominant language
Python
Stars
45
Forks
37
Avg merge
8d 20h
Merged PRs (30d)
5

Description

Context

PR #881 introduces property-based, vectorized XRB utilities in posydon.utils.xrb without changing existing POSYDON functions. This deliberately leaves some duplicated physics in posydon.utils.common_functions.bondi_hoyle, principally the wind-velocity and Bondi--Hoyle--Lyttleton calculations.

Keeping both paths temporarily makes #881 small and avoids changing established BinaryStar behavior in the same review. Long term, the duplicated implementations should not evolve independently.

Proposed follow-up

  • Compare the new property-based functions against every existing caller of common_functions.bondi_hoyle.
  • Agree on the supported wind and orbital-averaging prescriptions.
  • Make the BinaryStar-based function a thin adapter to the reviewed property-based implementation, or move the shared primitive to a single canonical location.
  • Preserve the public signature through a documented deprecation period if removal is appropriate.
  • Add regression tests before removing duplicated code.

Out of scope

Do not perform this consolidation in #881. The physics questions and compatibility impact require a dedicated review.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.