Hi Terry, I'm using Prime 5 and I'm ultimately trying to plot the piecewise function that I was attempting to define with the code posted. I made those changes, but it still is not working. T0 is a single value, where T is an array, I tried a while loop to populate Sa but I could not get that to work either. I'm just trying to populate Sa with values and then plot Sa and T.