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

Plot Voltage Components for Composite Electrodes #4434

Open
mleot opened this issue Sep 12, 2024 · 1 comment · May be fixed by #4435
Open

Plot Voltage Components for Composite Electrodes #4434

mleot opened this issue Sep 12, 2024 · 1 comment · May be fixed by #4435
Labels

Comments

@mleot
Copy link
Contributor

mleot commented Sep 12, 2024

Description

I would like to see the functionality for plotting the different over potentials separated by particle phases for a composite electrode, in the plot_voltage_components function.

Motivation

Having visibility into the contributions of each phase toward the net overpotentials would allow for better understanding of the dynamics in composite electrode systems.

Possible Implementation

I suggest that the definitions of overpotentials and labels be done differently when the cell is a half-cell. I also suggest that the new 'battery' overpotential variables be defined when the composite electrode model is being used.

Additional context

I attempted to make the changes locally, when I noticed a few interesting things that may deserve attention. I noticed in the BaseBatteryModel.set_voltage_variables() method, it appeared that there was no case where the secondary phase overpotentials would be extracted from the variables.

def set_voltage_variables(self):
        if self.options.negative["particle phases"] == "1":
            # Only one phase, no need to distinguish between
            # "primary" and "secondary"
            phase_n = ""
        else:
            # add a space so that we can use "" or (e.g.) "primary " interchangeably
            # when naming variables
            phase_n = "primary "
        if self.options.positive["particle phases"] == "1":
            phase_p = ""
        else:
            phase_p = "primary "

I wasn't sure if this behavior was a bug, or if this is the intended behavior. Maybe I am missing it, but I don't see where exactly the secondary phase overpotentials would be stored or accessed.

@mleot mleot added the feature label Sep 12, 2024
@mleot mleot linked a pull request Sep 12, 2024 that will close this issue
8 tasks
@mleot
Copy link
Contributor Author

mleot commented Sep 12, 2024

I opened a pull request (draft) just to demonstrate an example and ask others for their opinion. In this version, I pulled both primary and secondary reaction and particle concentration overpotentials for a half cell, and took the average of the two. I know this isn't the correct way to go about this, but this is the result:

image

The dashed voltage line is not aligned with the sum of the overpotentials. Maybe there is something fundamentally different for half-cell plot voltage_components that I don't understand yet.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant