Skip to content

Commit

Permalink
#759 add docs for event
Browse files Browse the repository at this point in the history
  • Loading branch information
martinjrobins committed Feb 6, 2020
1 parent d844228 commit 3a0001f
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 4 deletions.
1 change: 1 addition & 0 deletions docs/source/models/base_models/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,4 @@ Base Models

base_model
base_battery_model
event
2 changes: 1 addition & 1 deletion pybamm/models/base_model.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ class BaseModel(object):
variables: dict
A dictionary that maps strings to expressions that represent
the useful variables
events: list of pybamm.Event
events: list of :class:`pybamm.Event`
A list of events. Each event can either cause the solver to terminate
(e.g. concentration goes negative), or be used to inform the solver of the
existance of a discontinuity (e.g. discontinuity in the input current)
Expand Down
6 changes: 3 additions & 3 deletions pybamm/models/event.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

class EventType(Enum):
"""
Defines the type of event, see Event
Defines the type of event, see :class:`pybamm.Event`
TERMINATION indicates an event that will terminate the solver, the expression should
return 0 when the event is triggered
Expand All @@ -27,9 +27,9 @@ class Event:
name: str
A string giving the name of the event
event_type: EventType
event_type: :class:`pybamm.EventType`
An enum defining the type of event
expression: pybamm.Symbol
expression: :class:`pybamm.Symbol`
An expression that defines when the event occurs
Expand Down

0 comments on commit 3a0001f

Please sign in to comment.