To begin with, a trial solution \( g_t(t) \) must be chosen. A general trial solution for ordinary differential equations could be $$ g_t(x, P) = h_1(x) + h_2(x, N(x, P)), $$
with \( h_1(x) \) ensuring that \( g_t(x) \) satisfies some conditions and \( h_2(x,N(x, P)) \) an expression involving \( x \) and the output from the neural network \( N(x,P) \) with \( P \) being the collection of the weights and biases for each layer.
It is assumed that there are no weights and bias at the input layer, so \( P = \{ P_{\mathrm{hidden}}, P_{\mathrm{output}} \} \). If there are \( N_{\mathrm{hidden} } \) neurons in the hidden layer, then \( P_{\mathrm{hidden}} \) is an \( N_{\mathrm{hidden} } \times 2 \) matrix.
The first column in \( P_{\mathrm{hidden} } \) represents the bias for each neuron in the hidden layer and the second column represents the weigths for each neuron. If there are \( N_{\mathrm{output} } \) neurons in the output layer, then \( P_{\mathrm{output}} \) is a \( N_{\mathrm{output} } \times (1 + N_{\mathrm{hidden} }) \) matrix. Its first column represents the bias of each neuron and the remaining columns represents the weights to each neuron.