Skip to content

63 implement cell by cell electrical model in fvs#75

Draft
goob10000 wants to merge 2 commits into
main-sim-maintenencefrom
63-implement-cell-by-cell-electrical-model-in-fvs
Draft

63 implement cell by cell electrical model in fvs#75
goob10000 wants to merge 2 commits into
main-sim-maintenencefrom
63-implement-cell-by-cell-electrical-model-in-fvs

Conversation

@goob10000
Copy link
Copy Markdown
Member

No description provided.

Copy link
Copy Markdown
Member Author

@goob10000 goob10000 left a comment

Choose a reason for hiding this comment

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

Pretty good job so far but missing some key elements!

Comment thread FullVehicleSim/battery_model.py
Comment thread FullVehicleSim/battery_model.py
Comment on lines +113 to +120
for step in range(num_steps):
all_currents, module_voltage = module.step(pack_current, dt, capacity_Ah)
print(f"\nStep {step}")
print(f"Module Voltage: {module_voltage:.2f} V")

for g, group_currents in enumerate(all_currents):
print(f" Group {g}: {group_currents}")
print(f" Group {g} Sum: {np.sum(group_currents):.2f} A") No newline at end of file
Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

I think we spoke about this already but make sure you're logging not just printing the values. Not only is it easier to process afterward but it is critical for your hysteresis calculation.

Comment thread FullVehicleSim/battery_model.py
Comment thread FullVehicleSim/battery_model.py
soc = np.random.uniform(0.85, 0.95)
cells.append(Cell(soc=soc, resistance=resistances[h, w]))
groups.append(Parallel_Groups(cells))
return Module(groups)
Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

I see that you have internal cell resistances but I don't see where you implemented inter cell resistances. (horizontally if you imagine current mainly flowing vertically).


def build_modules(width = 4, height = 2, resistances = None):
#if no given csv
if resistances is None:
Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

To be clear, this is internal cell resistances right? Worth naming the variable more clearly because there are other resistors in the circuit.

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