Previous topic

Vector

Next topic

Binary Operators

This Page

State Vector

class pybamm.StateVector(*y_slices, name=None, domain=None, auxiliary_domains=None, evaluation_array=None)[source]

node in the expression tree that holds a slice to read from an external vector type

Parameters:
  • y_slice (slice) – the slice of an external y to read
  • name (str, optional) – the name of the node
  • domain (iterable of str, optional) – list of domains the parameter is valid over, defaults to empty list
  • auxiliary_domains (dict of str, optional) – dictionary of auxiliary domains
  • evaluation_array (list, optional) – List of boolean arrays representing slices. Default is None, in which case the evaluation_array is computed from y_slices.
  • *Extends
evaluation_array

Array to use for evaluating

new_copy()[source]

See pybamm.Symbol.new_copy().

set_evaluation_array(y_slices, evaluation_array)[source]

Set evaluation array using slices

set_id()[source]

See pybamm.Symbol.set_id()

size

Size of an object, found by evaluating it with appropriate t and y