Nanomechanics and quantum mechanics of molecular systems