Skip to content

Materials class and temperature processing#596

Merged
jhdark merged 41 commits into
festim-dev:fenicsxfrom
jhdark:materials_class
Oct 13, 2023
Merged

Materials class and temperature processing#596
jhdark merged 41 commits into
festim-dev:fenicsxfrom
jhdark:materials_class

Conversation

@jhdark
Copy link
Copy Markdown
Collaborator

@jhdark jhdark commented Oct 11, 2023

Proposed changes

Introducing the Material class, this will be an argument of a VolumeSubdomain class and will define certain hydrogen transport properties within a given subdomain. Additionally, some minor processing of the temperature argument is added to ensure its in the correct format for the formulation. More complex temperature arguments to come in the future.

Types of changes

What types of changes does your code introduce to FESTIM?

  • Bugfix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Code refactoring
  • Documentation Update (if none of the other choices apply)
  • New tests

Checklist

  • Black formatted
  • Unit tests pass locally with my changes
  • I have added tests that prove my fix is effective or that my feature works
  • I have added necessary documentation (if appropriate)

Further comments

If this is a relatively large or complex change, kick off the discussion by explaining why you chose the solution you did and what alternatives you considered, etc...

@jhdark jhdark added enhancement New feature or request fenicsx Issue that is related to the fenicsx support labels Oct 11, 2023
@jhdark jhdark self-assigned this Oct 11, 2023
@codecov
Copy link
Copy Markdown

codecov Bot commented Oct 11, 2023

Codecov Report

All modified lines are covered by tests ✅

Comparison is base (028fff4) 91.77% compared to head (ce48583) 93.98%.

Additional details and impacted files
@@             Coverage Diff             @@
##           fenicsx     #596      +/-   ##
===========================================
+ Coverage    91.77%   93.98%   +2.21%     
===========================================
  Files            7        9       +2     
  Lines          158      183      +25     
===========================================
+ Hits           145      172      +27     
+ Misses          13       11       -2     
Files Coverage Δ
festim/__init__.py 66.66% <100.00%> (+3.50%) ⬆️
festim/helpers.py 100.00% <100.00%> (ø)
festim/hydrogen_transport_problem.py 96.70% <100.00%> (+2.51%) ⬆️
festim/material.py 100.00% <100.00%> (ø)
festim/mesh/mesh.py 100.00% <ø> (ø)
festim/mesh/mesh_1d.py 100.00% <ø> (ø)
festim/species.py 88.88% <ø> (ø)
festim/subdomain/volume_subdomain.py 100.00% <ø> (ø)

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@jhdark jhdark marked this pull request as ready for review October 12, 2023 16:48
Copy link
Copy Markdown
Collaborator

@RemDelaporteMathurin RemDelaporteMathurin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

First round of comments

Comment thread festim/hydrogen_transport_problem.py Outdated
Comment thread festim/hydrogen_transport_problem.py Outdated
Comment thread festim/hydrogen_transport_problem.py Outdated
Comment thread festim/hydrogen_transport_problem.py
Comment thread festim/material.py Outdated
Comment thread test/test_material.py Outdated
Comment thread test/test_material.py Outdated
Comment thread test/test_material.py Outdated
Comment thread test/test_material.py Outdated
Comment thread test/test_temperature.py Outdated
Copy link
Copy Markdown
Collaborator

@RemDelaporteMathurin RemDelaporteMathurin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great!

I have a few more comments

Comment thread festim/helpers.py
Comment thread festim/hydrogen_transport_problem.py Outdated
Comment thread festim/hydrogen_transport_problem.py Outdated
Comment thread festim/material.py
Comment thread festim/material.py Outdated
Comment thread test/test_material.py Outdated
Comment thread test/test_material.py Outdated
Comment thread test/test_permeation_problem.py Outdated
@jhdark
Copy link
Copy Markdown
Collaborator Author

jhdark commented Oct 12, 2023

now contains a fix for issue #594

@jhdark jhdark linked an issue Oct 12, 2023 that may be closed by this pull request
Copy link
Copy Markdown
Collaborator

@RemDelaporteMathurin RemDelaporteMathurin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some more comments.

If you're happy with the material implementation I would merge this without the boders check, and keep that for another PR as I have some comments on it.

Smaller PRs = better PRs

Comment thread festim/subdomain/volume_subdomain.py Outdated
Comment thread festim/subdomain/volume_subdomain.py Outdated
Comment thread festim/subdomain/volume_subdomain.py Outdated
Comment thread festim/hydrogen_transport_problem.py Outdated
Comment thread test/test_subdomains.py Outdated
Comment thread test/test_subdomains.py Outdated
Comment thread test/test_subdomains.py Outdated
Comment thread test/test_subdomains.py Outdated
Comment thread test/test_subdomains.py Outdated
Comment thread test/test_subdomains.py Outdated
@jhdark jhdark merged commit dcb3b8c into festim-dev:fenicsx Oct 13, 2023
@jhdark jhdark deleted the materials_class branch October 13, 2023 14:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request fenicsx Issue that is related to the fenicsx support

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

2 participants