# Step-wise current using PyBaMM v 25.6.0

**URL:** <https://pybamm.discourse.group/t/step-wise-current-using-pybamm-v-25-6-0/339>\
**Category:** General\
**Created:** [12 June 2025 18:46 UTC](https://pybamm.discourse.group/t/step-wise-current-using-pybamm-v-25-6-0/339 "2025-06-12T18:46:02Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Lucas](https://avatars.discourse-cdn.com/v4/letter/l/ba8739/32.png) [@Lucas](https://pybamm.discourse.group/u/Lucas)\
**Post date:** [12 June 2025 18:46 UTC](https://pybamm.discourse.group/t/step-wise-current-using-pybamm-v-25-6-0/339/1 "2025-06-12T18:46:02Z")

</div>

I’m trying to simulate a battery with a step-wise current profile using PyBaMM version 25.6.0. I’ve defined a function to represent the current that changes value at a specific time. However, when I assign this function (or variations using pybamm.step , pybamm.Piecewise , or pybamm. Interpolant ) to param[“Current function [A]”] , I consistently get the error Boolean operator not defined for Symbols . Could someone please advise on the correct method to define a time-dependent current function with step changes in PyBaMM that is compatible with its symbolic framework and avoids this error?

Just to mention, I’m running this code on Google Colab — could that cause any issues?
