What Is Hamiltonian

This section provides a quick introduction to the Hamiltonian, which is a derived property of a mechanical system defined as the total energy, the sum of kinetic energy and potential energy of the system.

What Is Hamiltonian? Hamiltonian, H, is a derived property of a a mechanical system defined as the total energy, or the sum of kinetic energy and potential energy, of the system:

```H = T + V                          (H.1)
# H is the total energy
# T is the kinetic energy
# V is the potential energy
```

When a mechanical system changes over time, t, the value of Hamiltonian may change too. The kinetic energy, the potential energy and Hamiltonian of the system can be viewed as functions of t. So Hamiltonian can also be expressed as:

```H(t) = T(t) + V(t)                 (H.1)
```

Based on the law of conservation of energy, the Hamiltonian should be a constant for an isolated conservative system. In other words, the derivative of Hamiltonian against time is zero.

```T(t) + V(t) = constant
H(t) = constant                    (H.2)

or:
dH/dt = 0                        (H.3)
dT/dt + dV/dt = 0
dT/dt = -dV/dt
```

Hamiltonian was introduced by Sir William Rowan Hamilton (1805-1865), an Irish mathematician.

Hamiltonian for a Single Object

For a single object, the kinetic energy, T, can be expressed as:

```T = 0.5*m*v*v
# m is the mass of the object
# v is the velocity of the object
```

So applying the Law of Conservation of Energy on the Hamiltonian, we get:

```H = constant
T + V = constant                   (H.2)

or:
dT/dt = -dV/dt                   (H.3)

or:
d(0.5*m*v*v)/dt = -dV/dt
# kinetic energy is applied.

or:
m*v*dv/dt = -dV/dt
m*v*a = -dV/dt
```