  We introduce calculus-based formulas for the continuous Euler and homotopy
operators. The 1D continuous homotopy operator automates integration by parts
on the jet space. Its 3D generalization allows one to invert the total
divergence operator. As a practical application, we show how the operators can
be used to symbolically compute local conservation laws of nonlinear systems of
partial differential equations in multi-dimensions.
  By analogy to the continuous case, we also present concrete formulas for the
discrete Euler and homotopy operators. Essentially, the discrete homotopy
operator carries out summation by parts. We use it to algorithmically invert
the forward difference operator. We apply the discrete operator to compute
fluxes of differential-difference equations in (1+1) dimensions.
  Our calculus-based approach allows for a straightforward implementation of
the operators in major computer algebra system, such as Mathematica and Maple.
The symbolic algorithms for integration and summation by parts are illustrated
with elementary examples. The algorithms to compute conservation laws are
illustrated with nonlinear PDEs and their discretizations arising in fluid
dynamics and mathematical physics.
