a, \(f\left(x\right)-g\left(x\right)+h\left(x\right)\)
\(=\left(x^3-2x^3+3x+1\right)-\left(x^3+x+1\right)+\left(2x^2-1\right)\)
\(=x^3-2x^3+3x+1-x^3-x-1+2x^2-1\)
\(=\left(x^3-2x^3-x^3\right)+2x^2+\left(3x-x\right)+\left(1-1-1\right)\)
\(=-2x^3+2x^2+2x-1\)