# Implicit A-Stable Peer Triplets for ODE Constrained Optimal Control Problems
## 2 Materials and Methods
### Existence of Boundary Methods Imposes Restrictions on the Standard Method
#### 2.3.1 Combined Conditions for the End Method
Here \(tr(X_{2}^{\mathsf{T}}\mathds{1}_{q}\mathbb{I}_{s}^{\mathsf{T}}\mathcal{P}_{s} )=\mathds{1}_{s}^{\mathsf{T}}\mathcal{P}_{s}e_{2}-\mathds{1}_{s}^{\mathsf{T}} \mathcal{P}_{s}e_{1}=1\) and  
\[tr(X_{2}^{\mathsf{T}}V_{q}^{\mathsf{T}}BV_{s})=\bar{\varepsilon}_{1}^{\mathsf{ T}}V_{q}BV_{s}e_{2}-\bar{\varepsilon}_{2}^{\mathsf{T}}V_{q}BV_{s}e_{1}=\mathbb{I}_{s}^{ \mathsf{T}}B\mathbf{c}-\mathbf{c}^{\mathsf{T}}B\mathds{1}_{s}.\]  
For the third element, \(X_{3}=\bar{\varepsilon}_{1}e_{3}^{\mathsf{T}}-2\bar{\varepsilon}_{2}e_{2}^{ \mathsf{T}}+\bar{\varepsilon}_{3}e_{1}^{\mathsf{T}}\), one gets \(tr(X_{3}^{\mathsf{T}}\mathds{1}_{q}\mathbb{I}_{s}^{\mathsf{T}}\mathcal{P}_{s })=\mathds{1}_{s}^{\mathsf{T}}\mathcal{P}_{s}(e_{3}-2e_{2}+e_{1})=4-4+1=1\). The third condition on \(B\) is  
\[tr(X_{3}^{\mathsf{T}}V_{q}^{\mathsf{T}}BV_{s})=\mathbb{I}_{s}^{\mathsf{T}}B \mathbf{c}^{2}-2\mathbf{c}^{\mathsf{T}}B\mathbf{c}+(\mathbf{c}^{2})^{\mathsf{ T}}B\mathds{1}_{s}.\]  
The versions for \(A\) follow from the order conditions. Let again \(\mathds{1}:=\mathds{1}_{s}\). The first columns of (30) and (33) show \(B\mathds{1}=A\mathds{1}\) and \(\mathds{1}^{\mathsf{T}}B=\mathds{1}^{\mathsf{T}}A\), which gives \(\mathds{1}^{\mathsf{T}}B\mathds{1}=\mathds{1}^{\mathsf{T}}A\mathds{1}=1\). The second column of (30) reads \(B\mathbf{c}=A\mathbf{c}+A\mathds{1}-K\mathds{1}\) and leads to \(\mathds{1}^{\mathsf{T}}A\mathbf{c}=\mathds{1}^{\mathsf{T}}B\mathbf{c}+ \mathds{1}^{\mathsf{T}}A\mathds{1}-\mathds{1}^{\mathsf{T}}K\mathds{1}\) showing also \(\mathds{1}^{\mathsf{T}}K\mathds{1}=\mathds{1}^{\mathsf{T}}A\mathds{1}=1\). Hence, the second condition in (67) is equivalent with  
\[\mathds{1}\stackrel{{!}}{{=}}\mathds{1}^{\mathsf{T}}(B\mathbf{c} )-\mathbf{c}^{\mathsf{T}}(B\mathds{1})=\mathds{1}^{\mathsf{T}}(A\mathbf{c}+A \mathds{1}-K\mathds{1})-\mathbf{c}^{\mathsf{T}}A\mathds{1}=\mathds{1}^{ \mathsf{T}}A\mathbf{c}-\mathbf{c}^{\mathsf{T}}A\mathds{1}.\]  
In order to show the last equivalence in (67), we have to look ahead at the forward condition (30) for order 3, which is \(B\mathbf{c}^{2}=A(\mathbf{c}^{2}+2\mathbf{c}+\mathds{1})-2K(\mathbf{c}+ \mathds{1})\). This leads to \(\mathds{1}^{\mathsf{T}}A\mathbf{c}^{2}=\mathds{1}^{\mathsf{T}}B\mathbf{c}^{2}= \mathds{1}^{\mathsf{T}}A(\mathbf{c}^{2}+2\mathbf{c}+\mathds{1})-2\mathds{1}^ {\mathsf{T}}K(\mathbf{c}+\mathds{1})\), which is equivalent to \(2(\mathds{1}^{\mathsf{T}}A\mathbf{c}-\mathds{1}^{\mathsf{T}}K\mathbf{c})=1\). Now, this expression is required in the last reformulation which also uses the second adjoint order condition \(B^{\mathsf{T}}\mathbf{c}=A^{\mathsf{T}}\mathbf{c}-A^{\mathsf{T}}\mathds{1}+K ^{\mathsf{T}}\mathds{1}\), yielding  
\[1\stackrel{{!}}{{=}}(\mathds{1}^{\mathsf{T}}B) \mathbf{c}^{2}+(\mathbf{c}^{2})^{\mathsf{T}}(B\mathds{1})-2\mathbf{c}^{ \mathsf{T}}(B^{\mathsf{T}}\mathbf{c})\] \[=\mathds{1}^{\mathsf{T}}A\mathbf{c}^{2}+(\mathbf{c}^{2})^{ \mathsf{T}}A\mathds{1}-2\mathbf{c}^{\mathsf{T}}A^{\mathsf{T}}\mathbf{c}+ \underbrace{2(\mathbf{c}^{\mathsf{T}}A^{\mathsf{T}}\mathds{1}-\mathbf{c}^{ \mathsf{T}}K^{\mathsf{T}}\mathds{1})}_{=1}.\]  
\(\square\)  
**Remark 6**. : _It can be shown that only the first condition \(\mathds{1}^{\mathsf{T}}A\mathds{1}=1\) in (67) is required if the matrix \(K\) is diagonal. This first condition is merely a normalization fixing the free common factor in the class \(\{\alpha\cdot(A,B,K):\,\alpha\
eq 0\}\) of equivalent methods. The other two conditions are consequences of the order conditions on the standard method \((A,B,K)\) with diagonal \(K\). However, the proof is rather lengthy and very technical and is omitted._  
_The restrictions (67) on the standard method also seem to be sufficient with (61) posing no further restrictions. In fact, with (67) the construction of boundary methods was always possible in Section 2.4._