BR PT TY LAB PAR(1) L2-NORM PAR(8) 1 1 EP 1 0.000000E+00 4.000000E-01 ... 0.000000E+00 1 5 UZ 2 2.500000E-01 4.030545E-01 ... -3.620329E-11 1 10 EP 3 7.384434E-01 4.339575E-01 ... -9.038826E-09and saved in more detail as b.1, s.1 and d.1.
Next we want to add a solution to the adjoint equation to the solution obtained at . This is achieved by making the change ITWIST = 1 saved in h.san.2, and IRS = 2, NMX = 2 and ICP(1) = 9 saved in c.san.2. We also disable any user-defined functions NUZR=0. The computation so-defined is a single step in a trivial parameter PAR(9) (namely a parameter that does not appear in the problem). The effect is to perform a Newton step to enable AUTO to converge to a solution of the adjoint equation.
We can now continue the homoclinic plus adjoint in =(PAR(4), PAR(8)) by changing the constants (stored in c.san.3) to read IRS = 4, NMX = 50 and ICP(1) = 4. We also add PAR(10) to the list of continuation parameters NICP,(ICP(I),I=1 NICP). Here PAR(10) is a dummy parameter used in order to make the continuation of the adjoint well posed. Theoretically, it should be zero if the computation of the adjoint is successful [#!Sa:95b!#]. The test functions for detecting resonant bifurcations (ISPI(1)=1) and inclination flips (ISPI(1)=13) are also activated. Recall that this should be specified in three ways. First we add PAR(21) and PAR(33) to the list of continuation parameters in c.san.3, second we set up user defined output at zeros of these parameters in the same file, and finally we set NPSI=2 (IPSI(1),IPSI(2))=1,13 in h.san.3. We also add to c.san.3 another user zero for detecting when PAR(4)=1.0. Running
BR PT TY LAB PAR(4) ... PAR(8) PAR(10) ... PAR(33) 1 20 5 7.847219E-01 ... -3.001440E-11 -4.268884E-09 ... -1.441124E+01 1 27 UZ 6 1.000000E+00 ... -3.844872E-11 -4.460769E-09 ... -5.701675E+00 1 35 UZ 7 1.230857E+00 ... -5.833977E-11 -4.530541E-09 ... 9.434843E-06 1 40 8 1.383969E+00 ... -8.133899E-11 -4.671817E-09 ... 1.348810E+00 1 50 EP 9 1.695209E+00 ... -1.386324E-10 -5.098460E-09 ... 5.311065E-01Full output is stored in b.3, s.3 and d.3.
ORIENTABLE ( 0.2982090775D-03)at PT=35 would seems to contradict the detection of the inclination flip at this point. Nonetheless, the important fact is the zero of the test function; and note that the value of the variable indicating the orientation is small compared to its value at the other regular points. Data for the adjoint equation at LAB= 5, 7 and 9 at and on either side of the inclination flip are presented in Fig. 21.1. The switching of the solution between components of the leading unstable left eigenvector is apparent. Finally, we remark that the Newton step in the dummy parameter PAR(20) performed above is crucial to obtain convergence. Indeed, if instead we try to continue the homoclinic orbit and the solution of the adjoint equation directly by setting
ITWIST = 1 IRS = 2 NMX = 50 ICP(1) = 4 NPUSZR = 0(as saved in c.san.4) and running