The coefficient signs alone do not imply the assertion as printed. Two interior nodes can have rows and , with a separate boundary node. Taking interior values one and boundary value zero satisfies every stated coefficient inequality and , but its maximum is not on the boundary. Connectedness of the geometric domain does not ensure connectedness of this stencil graph.
The usual extra assumption is that every interior node has a path of positive stencil coefficients to a prescribed boundary node. Under this assumption let be the global maximum and suppose an interior node attains it. ThenAll summands are nonpositive, so equality forces at every neighbor with . Propagate along a path to the boundary to find a boundary node with value . This proves the discrete maximum principle under boundary-reaching stencil connectivity, and exhibits why the literal hypotheses need that qualification.