class AbstractEquation implements Equation {

    protected List<PropertyChangeListener> listeners;

    protected AbstractEquation() {
        this.listeners = new LinkedList<>();
    }

    public void addPropertyChangeListener(PropertyChangeListener listener) {
        if (listener != null && !listeners.contains(listener)) {
            listeners.add(listener);
        }
    }

    public void removePropertyChangeListener(PropertyChangeListener listener) {
        if (listener != null) {
            listeners.remove(listener);
        }
    }

    protected void firePropertyChange(String propertyName,
                                      double oldValue,
                                      double newValue) {<FILL_FUNCTION_BODY>}
}

        PropertyChangeEvent changeEvent = new PropertyChangeEvent(this,
            propertyName,
            oldValue,
            newValue);
        for (PropertyChangeListener listener : listeners) {
            listener.propertyChange(changeEvent);
        }
    
<no_super_class>