Generates a quick plot of a subset of key outputs of the model so that the model outputs can be easily assessed.
solutions ((iter of) pybamm.Solution
or pybamm.Simulation
) – The numerical solution(s) for the model(s), or the simulation object(s)
containing the solution(s).
output_variables (list of str, optional) – List of variables to plot
labels (list of str, optional) – Labels for the different models. Defaults to model names
colors (list of str, optional) – The colors to loop over when plotting. Defaults to None, in which case the default color loop defined by matplotlib style sheet or rcParams is used.
linestyles (list of str, optional) – The linestyles to loop over when plotting. Defaults to [“-”, “:”, “–”, “-.”]
figsize (tuple of floats, optional) – The size of the figure to make
n_rows (int, optional) – The number of rows to use. If None (default), floor(n // sqrt(n)) is used where n = len(output_variables) so that the plot is as square as possible
time_unit (str, optional) – Format for the time output (“hours”, “minutes”, or “seconds”)
spatial_unit (str, optional) – Format for the spatial axes (“m”, “mm”, or “um”)
variable_limits (str or dict of str, optional) –
How to set the axis limits (for 0D or 1D variables) or colorbar limits (for 2D variables). Options are:
”fixed” (default): keep all axes fixes so that all data is visible
”tight”: make axes tight to plot at each time
dictionary: fine-grain control for each variable, can be either “fixed” or “tight” or a specific tuple (lower, upper).
Generates x plots over a time span of max_t - min_t and compiles them to create a GIF.
Generate a dynamic plot with a slider to control the time.
Produces a quick plot with the internal states at time t.
t (float) – Dimensional time (in ‘time_units’) at which to plot.