Calculating the equation of state of dense quark-gluon plasma using the complex Langevin equation