Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Borefield class #260

Closed

Conversation

j-c-cook
Copy link
Contributor

@j-c-cook j-c-cook commented Jan 28, 2023

@MassimoCimmino I've modified your Borefield class to utilize property methods that return numpy views of a single private instance of _boreholes.

@j-c-cook
Copy link
Contributor Author

Current example usage:

import pygfunction as gt

borefield = gt.boreholes.rectangle_field(5, 5, 5, 5, 100, 5, 0.075)

borefield = gt.boreholes.Borefield(borefield)

n = borefield.nBoreholes

H = borefield.H

borehole = gt.boreholes.Borehole(50, 5, 0.075, 70, 70)

borefield.append(borehole)

H = borefield.H

print(H)

borefield.H[0] = 15  # Effects every instance of H (in borefield.H as well)

@j-c-cook j-c-cook changed the base branch from master to issue210_BorefieldClass January 28, 2023 05:14
@j-c-cook j-c-cook changed the base branch from issue210_BorefieldClass to master January 28, 2023 05:14
@j-c-cook j-c-cook marked this pull request as draft January 28, 2023 05:24
@j-c-cook
Copy link
Contributor Author

Resolved in #308.

@j-c-cook j-c-cook closed this Dec 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants