\begin{align}
    W(\{s^i_t\},D_t) =& \max_{\{x^i_t\}^N_{i=1} \geq 0}
            ~~\left( \sum^N_{i=1}  u^i(s^i_t,S_t,D_t)\right) - FX_t 
            + \beta W(\{s^i_{t+1}\}, D_{t+1}) \\
    \text{Subject To:}& \notag\\
    D_{t+1} =& (1-\delta) D_t + m X_t + M\cdot \left( \sum^N_{i=1} s^i_t l^i(s^i_t,S_t,D_t) \right) + g(D_t) \\
    s^i_{t+1} =& \left[ 1-l^i(s^i_t,S_t,D_t) \right] s^i_t + x^i_t \\
    S_t =&\sum_{i=1}^N s^i_t \\
    X_t =&\sum_{i=1}^N x^i_t 
\end{align}
Solving for the euler equation follows the steps laid out in
the section 
% appendix section \ref{APX:Derivations:Constellation}
for constellation operators.

\subsubsection{Characterizing solutions}
The $N+1$ Envelope Conditions are:
\begin{align}
        \parder{W}{s_t^i}{} =& \sum^N_{j=1} \der{u^j}{s_t^i}{}
                    + \beta \left[ \sum^N_{j=1} \parder{W}{s_{t+1}^j}{} \parder{s_{t+1}^j}{s_t^i}{} 
                        + \parder{W}{D_{t+1}}{} \parder{D_{t+1}}{s_t^i}{} \right]
    ~~~ \forall i \in \{1,\dots,N\} \\
        \parder{W}{D_t}{} =& \sum^N_{j=1} \der{u^j}{D_t}{}
                    + \beta \left[ \sum^N_{j=1} \parder{W}{s_{t+1}^j}{} \parder{s_{t+1}^j}{D_t}{} 
                        + \parder{W}{D_{t+1}}{} \parder{D_{t+1}}{D_t}{} \right] \\
    \nabla W_t - \sum^N_{j=1} \nabla u^j_t =& \beta B \cdot \nabla W_{t+1}
\end{align}
Assuming $B$ is non-singular, we again find that:
\begin{align}
    \nabla W_{t+1} =& (\beta B)^{-1} (\nabla W_t - \sum^N_{j=1} \nabla u^j_t) \label{EQ:viii}
\end{align}


The $N$ Optimality Conditions are:
\begin{align}
    0 =& -F + \beta \left[ \sum^N_{j=1} \parder{W}{s^j_{t+1}}{} \parder{s^j_{t+1}}{x^i_t}{} 
                        + \parder{W}{D_{t+1}}{} \parder{D_{t+1}}{x^i_t}{}\right]
    ~~~ \forall i \in \{1,\dots,N\}  \label{EQ:ix}\\
    \frac{F}{\beta} \vect{1} =& C \nabla W_{t+1} 
   % = C(\beta B)^{-1} (\nabla W_t - \sum^N_{j=1} \nabla u^j_t) \label{EQ:viii}
\end{align}
Where $C$ is a $N \times N+1$ matrix.
Iterating \cref{EQ:ix} one period forward (from $t+1$ to $t+2$) for $i=1$ and and substituting in \cref{EQ:viii}
twice provides the final equation for a system of $N+1$ equations for $\nabla W_t$.

Finally, iterating \cref{EQ:ix} one period backward (from $t+1$ to $t$) for all $i$, and substituting the 
previously found values for $\nabla W_t$ into these optimality conditions defines the system of euler equations
that characterize $\{x^i_t\}$.
