Here is the question I am trying to answer:
Let $D$ be a domain and let $a \in D,$ prove that the map defined by $X \mapsto X + a, d \mapsto d$ for all $d \in D$ is an automorphism of $D[X].$
Here is my trial:
Recall that an automorphism is an isomorphism from a mathematical object to itself. So, if we call the given map $\varphi,$ clearly, it is a map $D[X] \to D[X].$ Now, it remains to show that it is $1-1,$ onto and homomorphism.
First. Showing that $\varphi$ is a homomorphism
1- we want to show that $\varphi(X + Y) = \varphi (X) + \varphi (Y)$ and the identity function in the second part of the definition of $\varphi$ is always a homomorphism.
Now, since $\varphi(X + Y) = X + Y + a$ (but then it is not a homomorphism, right? )
Second. Showing that $\varphi$ is 1-1
2- Assume that $\varphi(X) = \varphi(Y)$ then $X + a = Y +a$ then by cancelling we will get that $X = Y$ and off course the identity function in the second part of the definition of $\varphi$ is always one-one. Therefore, $\varphi$ is $1-1$ as required.
Third. Showing that $\varphi$ is onto.
This is obviously correct.
So could anyone help me in the part of showing the homomorphism please?
You are using the notation $X$ for two different purposes. The ring automorphism $\varphi \colon D[X] \to D[X]$ is the substitution of $X+a$ for $X$ in all polynomials: for $f$ in $D[X]$, $\varphi(f)$ is the following new polynomial: $(\varphi(f))(X) = f(X+a)$. Explicitly, $$ f(X) = \sum_{i=0}^m a_iX^i \Longrightarrow \varphi(f) = \sum_{i=0}^m a_i(X+a)^i. $$ That $\varphi$ is additive and multiplicative says $(f+g)(X+a) = f(X+a) + g(X+a)$ and $(fg)(X+a) = f(X+a)g(X+a)$ for all $f$ and $g$ in $D[X]$.
Quite generally, if $R$ is a ring containing $D$ and $r \in R$, show "evaluation of $D[X]$ at $r$" is a ring homomorphism $\varphi_r \colon D[X] \to R$.
$$ f(X) = \sum_{i=0}^m a_iX^i \Longrightarrow \varphi_r(f) = \sum_{i=0}^m a_ir^i. $$
You're using the special case $R = D[X]$ and $r = X+a$, but it's good to realize the whole setup works more broadly: evaluation of all polynomials in $D[X]$ at a fixed element $r$ of a ring $R$ that contains $D$ gives you a ring homomorphism $\varphi_r \colon D[X] \to R$.
Such evaluation maps are usually not ring isomorphisms, but they are in your situation ($R = D[X]$, $r = X+a$), since the map that is the inverse of evaluation at $X+a$ is just evaluation at $X-a$: show the ring homomorphisms $\varphi_{X+a} \colon D[X] \to D[X]$ and $\varphi_{X-a} \colon D[X] \to D[X]$ have compositions in both orders equal to the identity on $D[X]$.