  Let us denote ${\cal V}$, the finite dimensional vector spaces of functions
of the form $\psi(x) = p_n(x) + f(x) p_m(x)$ where $p_n(x)$ and $p_m(x)$ are
arbitrary polynomials of degree at most $n$ and $m$ in the variable $x$ while
$f(x)$ represents a fixed function of $x$.
  Conditions on $m,n$ and $f(x)$ are found such that families of linear
differential operators exist which preserve ${\cal V}$. A special emphasis is
accorded to the cases where the set of differential operators represents the
envelopping algebra of some abstract algebra. These operators can be
transformed into linear matrix valued differential operators. In the second
part, such types of operators are considered and a connection is established
between their solutions and series of polynomials-valued vectors obeying three
terms recurence relations. When the operator is quasi exactly solvable, it
possesses a finite dimensional invariant vector space. We study how this
property leads to the truncation of the polynomials series.
