Can we simplify objective function based on the property of optimal solution? Consider the non-convex optimization problem
\begin{equation}
\begin{aligned}
\max_{x} & \quad f(x)\\
s.t. & \quad 0 \leq x\leq 1
\end{aligned} \tag{1}
\end{equation}
where $f(x)$ is non-concave. But $\forall y \in X = \{x| Ax=b\}$ we have $f(y) = g(y)$, where $g(y)$ is concave. We know the optimal solution $x^* \in X$ .
So can we transform the non-convex optimization problem into the following convex problem?
\begin{equation}
\begin{aligned}
\max_{x} & \quad g(x)\\
s.t. & \quad Ax = b\\
& \quad 0 \leq x\leq 1
\end{aligned}
\end{equation}

Yes.  The following are equivalent problems:
$$\max_x f(x) \quad \text{subject to} \quad 0 \le x \le 1$$
$$\max_x f(x) \quad \text{subject to} \quad x\in X,\ 0 \le x \le 1$$
$$\max_x f(x) \quad \text{subject to} \quad Ax=b,\ 0 \le x \le 1$$
$$\max_x g(x) \quad \text{subject to} \quad Ax=b,\ 0 \le x \le 1$$
