Find the integral solution with minimum sum given the product is constant. 
Let $x,y,z,n$ be positive integers such that $n$ has at least three prime divisors.
Find the minimum of $x+y+z$ such that $xyz=n$.

First, note that $x,y,z$ must be positive integers.
Consider $n=945$. Then its prime factorization is $3\cdot 3 \cdot 3 \cdot 5 \cdot 7$.
The following is my approach:
Choose two smallest integers in the prime factorization, which are $3,3$ and multiply them, we get $$9\cdot 3 \cdot 5 \cdot 7$$
Next choose two smallest integers among the numbers above, which are $3,5$ and multiply them, we get
$$9\cdot 15\cdot 7$$
So the minimum of $x+y+z$ should be $9+15+7=31$.
My question is: Is there a general solution for the minimum of $x+y+z$ in terms of $n$?

You can solve the problem via integer linear programming as follows.  Given prime factorization $n=\prod_p p^{n_p}$, there are $\prod_p (n_p+1)$ possible factors.  For each factor $j=\prod_p p^{j_p}$, where $j_p \le n_p$, let nonnegative integer decision variable $x_j$ be the number of times the factor is used.  The problem is to minimize $\sum_j j x_j$ subject to
\begin{align}
\sum_j x_j &= 3 \tag1 \\
\sum_j j_p x_j &= n_p &&\text{for all $p$} \tag2
\end{align}
Constraint $(1)$ selects three factors.  Constraint $(2)$ uses each prime factor the correct number of times.
For example, $n=2160=2^4 3^3 5^1$ has $n_2=4$, $n_3=3$, and $n_5=1$, and there are $(4+1)(3+1)(1+1)=40$ factors.  An optimal solution is $x_{12}=2$, $x_{15}=1$, with objective value $2 \cdot 12 + 1 \cdot 15 = 39$.
