a: \(=x^2\left(x-1\right)-4\left(x^2-2x+1\right)\)
\(=x^2\left(x-1\right)-4\left(x-1\right)^2\)
\(=\left(x-1\right)\left(x^2-4x+4\right)\)
\(=\left(x-1\right)\left(x-2\right)^2\)
b: \(=\left(2x-5\right)\left(2x+5\right)-\left(2x-5\right)\left(2x+7\right)\)
\(=\left(2x-5\right)\left(2x+5-2x-7\right)\)
\(=-2\left(2x-5\right)\)
c: \(=\left(x+3\right)\left(x^2-3x+9\right)+\left(x+3\right)\left(x-9\right)\)
\(=\left(x+3\right)\left(x^2-3x+9+x-9\right)\)
\(=\left(x+3\right)\left(x^2-2x\right)\)
\(=x\left(x-2\right)\left(x+3\right)\)
d: \(=\left(2xy-x^2-y^2+z^2\right)\left(2xy+x^2+y^2-z^2\right)\)
\(=\left[z^2-\left(x-y\right)^2\right]\left[\left(x+y\right)^2-z^2\right]\)
\(=\left(z-x+y\right)\left(z+x-y\right)\left(x+y-z\right)\left(x+y+z\right)\)