Existence of a solution for a ODE defined on an open set in $\mathbb{R}^n$. Let $U \subset \mathbb{R}^n$ be an open set, and $B$ a smooth matrix valuated function $B:U \to M_n(\mathbb{R})$ .
Let $\frac{\partial}{\partial x^1}$ be the constant vector field defined on $U$.  I am trying (with no success)  to prove that given $x_0 \in U$, and $A_0 \in M_n(\mathbb{R})$ there exist a smooth matrix valuated function  $A:U \to M_n(\mathbb{R})$ , such that:
$\frac{\partial A}{ \partial x^1}= B \cdot A $, with $A(x_0)=A_0$. And that the dependence on $(x_0 , A_0)$ is smooth.
Well i arrived to this problem trying to show the smoothness of a distribution defined on a manifold, and using a chart (reading Spivak introduction to differentiable geometry vol 2, pp 338 2nd edition), and i have been trying with the classical existence theorems, my idea is: 
Take $x_0=(x_0^1 , \dots , x_0^n) \in U$ and define the first ODE:
$A'(t)= B(c(t))\cdot A(c(t))$.
Where $c$ is an integral curve for $\frac{\partial}{\partial x^1}$ such that $c(0)= x_0$, this equation is very well know to have a solution, with initial condition $A_0$, and seems natural to try to define $A(c(t)) = A(t)$. If I take curves by $(x_0^1 \pm \epsilon, x_0^2, \dots x_0^n)$ I can define  ODE with the same initial condition. The problem is i can't see why all these solutions, glue together! I would appreciate any help or advise. in fact, i don't know if it is true! (one friend told me to use a more general existence of solution theorem which lets $B$ be a smooth function of $\mathbb{R}^n$, but i can't find this theorem anywhere) ... 
Any help or advise is welcome. Thank you all! 
 A: Edited Version: Note first that your equation cannot have a unique solution, since you are prescribing only one partial derivative and hence multiplying any solution by a function of the other coordinates is again a solution. What I describe is the simplest solution, which is independent of all other coordinates. 
More or less by definition of the matrix exponential, the curve $c:\mathbb R\to M_n(\mathbb R)$ defined by $c(t)=e^{tB}$ is the unique solution of the ODE $c'(t)=B\cdot c(t)$ (where the dot indicates the matrix product) with $c(0)=\mathbb I$. If you want to change the initial condition you simply multiply from the right by an appropriate matrix.
To apply this to your problem, you simply take the first coordinate function $x^1$ and subtract the constant $x_0^1$. Then you see that if you define $\tilde A(x):=e^{(x^1-x_0^1)B}=e^{x^1B}e^{-x_0^1B}$, then this solves the equation $\frac{\partial}{\partial x^1}A(x)=B\cdot A(x)$ by definition of the partial derivative with initial condition $\tilde A(x_0)=\mathbb I$. To get the solution with the initial condition you want you have to take $A(x):=e^{(x^1-x_0^1)B}A_0$.  
In general, the fact that the solutions do glue together basically is due to the smooth dependence of the solution on a system of ODEs on the initial condition. But in this case, the explicit formula for the solutions sorts out everything. 
