Calculating infrared contributions to vacuum expectation values of gluonic and quark fields