Ms. Podolskaya,
Your 2nd question is related to matrix copositivity, I believe. Take a look at the 5th chapter of Parrilo's doctoral dissertation.
A quadratic form in $\mathbb{R}[x_1,x_2,x_3]$ is of the form
$P (x_1,x_2,x_3) = \left[\begin{array}{c} x_1\\\ x_2\\\ x_3\end{array}\right]^T \left[\begin{array}{ccc} q_{11} & q_{12} & q_{13}\\\ q_{12} & q_{22} & q_{23}\\\ q_{13} & q_{23} & q_{33}\end{array}\right] \left[\begin{array}{c} x_1\\\ x_2\\\ x_3\end{array}\right]$
or, more compactly, $P (x) = x^T Q x$. You ask: when is $P$ positive on the positive octant? If $P > 0$ when $x > 0$, then
$(\forall x \in \mathbb{R^3}) (x > 0 \implies x^T Q x > 0)$
and, in theory, one could use quantifier elimination to obtain conditions on the $q_{ij}$ coefficients so that $P > 0$ on the positive octant. The following REDLOG script
% positivity on the positive octant
load_package redlog;
rlset ofsf;
% define quadratic form
P := 1 * q11 * x1 * x1 +
+ 1 * q22 * x2 * x2 +
+ 1 * q33 * x3 * x3 +
+ 2 * q12 * x1 * x2 +
+ 2 * q13 * x1 * x3 +
+ 2 * q23 * x2 * x3;
% define universally quantified formula
phi := all({x1,x2,x3}, (x1 > 0 and x2 > 0 and x3 > 0) impl P>0);
% perform quantifier elimination
rlqe phi;
end;
produces results in a few seconds, but the conditions on the $q_{ij}$ coefficients are enormously long quantifier-free formulas. So enormous that REDLOG crashed!
If $P$ is nonnegative on the nonnegative octant, then
$(\forall x \in \mathbb{R^3}) (x \geq 0 \implies x^T Q x \geq 0)$
which is equivalent to saying that matrix $Q = Q^T$ is copositive.