def center_of_mass(elements, coordinates):
mass = molecular_weight(elements)<EOL>mass_array = np.array([[atomic_mass[i.upper()]] * <NUM_LIT:3> for i in elements])<EOL>mass_coordinates = coordinates * mass_array<EOL>return (np.sum(mass_coordinates, axis=<NUM_LIT:0>) / np.array([mass, mass, mass]))<EOL>
Return the centre of mass (COM).

Parameters
----------
elements : numpy.ndarray
    An array of all elements (type: str) in a molecule.

coordinates : numpy.ndarray
    An array containing molecule's coordinates.

Returns
-------
numpy.ndarray
    An 1d array with coordinates of the centre of mass including elements'
    masses.