(* ::Package:: *)

(* ::Text:: *)
(*This file contains the function F(z) defined in eq. (14) of 1507.00047 in terms of HPLs.*)
(*The notation for HPLs follows the HPL package (hep-ph/0507152).*)
(**)
(*The function F(z) is called by FHPL[z].*)
(**)
(*The file also contains the expressions of F(1-z), F(1/z), F(1-1/z), F(1/(1-z)), F(z/(z-1)) in terms of HPLs in z, referring to eq. (7) in the paper, which reduces in the 4-line case to:*)
(**)
(*Delta_4^{(3)}=16 T_1^a T_2^b T_3^c T_4^d [*)
(*  f_{abe}f_{cde} ( F(1-1/z,1-1/zb) - F(1/z,1/zb) )*)
(*+f_{ace}f_{bde} ( F(1-z,1-zb) - F(z,zb) )*)
(*+f_{ade}f_{bce} ( F(1/(1-z), 1/(1-zb)) - F(z/(z-1),zb/(zb-1) )]*)
(*- C \sum_{i=1}^4 \sum_{1\leq j<k\leq n ; j,k\neq i}  f_{abe} f_{cde} {T_i^a,T_i^b} T_j^b T_k^c*)
(**)
(*with z zb = \rho_{1234}*)
(*and (1-z)(1-zb)=\rho_{1432}*)
(*Note that z and zb must have imaginary parts of opposite signs (any any region).*)


FHPL[z] = (Pi^2*HPL[{0}, zb]^2*HPL[{1}, z])/6 + 
    (Pi^2*HPL[{0}, z]^2*HPL[{1}, zb])/6 + 
    (Pi^2*HPL[{0}, zb]*(HPL[{0}, z]*HPL[{1}, z] - HPL[{2}, z]))/3 + 
    (Pi^2*HPL[{0}, z]*(HPL[{0}, zb]*HPL[{1}, zb] - HPL[{2}, zb]))/3 + 
    (Pi^2*HPL[{3}, z])/3 + (Pi^2*((HPL[{0}, z]^2*HPL[{1}, z])/2 - 
       HPL[{0}, z]*HPL[{2}, z] + HPL[{3}, z]))/3 + (Pi^2*HPL[{3}, zb])/3 + 
    (Pi^2*((HPL[{0}, zb]^2*HPL[{1}, zb])/2 - HPL[{0}, zb]*HPL[{2}, zb] + 
       HPL[{3}, zb]))/3 + (HPL[{0}, zb]*HPL[{1}, zb] - HPL[{2}, zb])*
     (HPL[{1}, z]*HPL[{2}, z] - 2*HPL[{2, 1}, z]) + 
    (HPL[{0}, z]*HPL[{1}, z] - HPL[{2}, z])*(HPL[{1}, zb]*HPL[{2}, zb] - 
      2*HPL[{2, 1}, zb]) + HPL[{1}, zb]*
     (HPL[{0}, z]*HPL[{1}, z]*HPL[{2}, z] + HPL[{2}, z]^2 - 
      2*HPL[{1}, z]*HPL[{3}, z] - 2*HPL[{0}, z]*HPL[{2, 1}, z] - 
      HPL[{2, 2}, z]) + HPL[{1}, z]*HPL[{2, 2}, z] + 
    HPL[{1}, z]*(HPL[{0}, zb]*HPL[{1}, zb]*HPL[{2}, zb] + HPL[{2}, zb]^2 - 
      2*HPL[{1}, zb]*HPL[{3}, zb] - 2*HPL[{0}, zb]*HPL[{2, 1}, zb] - 
      HPL[{2, 2}, zb]) + HPL[{1}, zb]*HPL[{2, 2}, zb] - 
    2*(HPL[{2, 1, 2}, z] + HPL[{2, 2, 1}, z]) - 
    2*(HPL[{2, 1, 2}, zb] + HPL[{2, 2, 1}, zb]) + 4*HPL[{1}, z]*HPL[{1}, zb]*
     Zeta[3]


FHPL[1 - z^(-1)] = (Pi^2*HPL[{0}, z]^3)/9 + HPL[{0}, z]^5/120 + 
    (Pi^2*HPL[{0}, z]^2*HPL[{0}, zb])/3 + (HPL[{0}, z]^4*HPL[{0}, zb])/24 + 
    (Pi^2*HPL[{0}, z]*HPL[{0}, zb]^2)/3 + (HPL[{0}, z]^3*HPL[{0}, zb]^2)/12 + 
    (Pi^2*HPL[{0}, zb]^3)/9 + (HPL[{0}, z]^2*HPL[{0}, zb]^3)/12 + 
    (HPL[{0}, z]*HPL[{0}, zb]^4)/24 + HPL[{0}, zb]^5/120 + 
    (Pi^2*HPL[{0}, zb]^2*HPL[{1}, z])/6 + (Pi^2*HPL[{0}, zb]*HPL[{1}, z]^2)/
     6 + (Pi^2*HPL[{0}, z]^2*HPL[{1}, zb])/6 + 
    (Pi^2*HPL[{0}, z]*HPL[{1}, zb]^2)/6 + 
    (Pi^2*HPL[{0}, zb]*(HPL[{0}, z]*HPL[{1}, z] - HPL[{2}, z]))/3 + 
    (HPL[{0}, z]^3*HPL[{2}, z])/6 + (2*Pi^2*HPL[{0}, zb]*HPL[{2}, z])/3 + 
    (HPL[{0}, zb]^3*HPL[{2}, z])/6 + (Pi^2*HPL[{1}, zb]*HPL[{2}, z])/3 + 
    (Pi^2*HPL[{0}, z]*(HPL[{0}, zb]*HPL[{1}, zb] - HPL[{2}, zb]))/3 + 
    (2*Pi^2*HPL[{0}, z]*HPL[{2}, zb])/3 + (HPL[{0}, z]^3*HPL[{2}, zb])/6 + 
    (HPL[{0}, zb]^3*HPL[{2}, zb])/6 + (Pi^2*HPL[{1}, z]*HPL[{2}, zb])/3 + 
    (2*Pi^2*(HPL[{0}, z]*HPL[{2}, z] - 2*HPL[{3}, z]))/3 + 
    (HPL[{0}, zb]^2*(HPL[{0}, z]*HPL[{2}, z] - 2*HPL[{3}, z]))/2 + 
    HPL[{2}, zb]*(HPL[{0}, z]*HPL[{2}, z] - 2*HPL[{3}, z]) + 
    (Pi^2*HPL[{3}, z])/3 - HPL[{0}, z]^2*HPL[{3}, z] + 
    (Pi^2*((HPL[{0}, z]^2*HPL[{1}, z])/2 - HPL[{0}, z]*HPL[{2}, z] + 
       HPL[{3}, z]))/3 + (2*Pi^2*(HPL[{0}, zb]*HPL[{2}, zb] - 
       2*HPL[{3}, zb]))/3 + (HPL[{0}, z]^2*(HPL[{0}, zb]*HPL[{2}, zb] - 
       2*HPL[{3}, zb]))/2 + HPL[{2}, z]*(HPL[{0}, zb]*HPL[{2}, zb] - 
      2*HPL[{3}, zb]) + (Pi^2*HPL[{3}, zb])/3 - HPL[{0}, zb]^2*HPL[{3}, zb] + 
    (Pi^2*((HPL[{0}, zb]^2*HPL[{1}, zb])/2 - HPL[{0}, zb]*HPL[{2}, zb] + 
       HPL[{3}, zb]))/3 + 4*HPL[{0}, z]*HPL[{4}, z] + 
    HPL[{0}, zb]*HPL[{4}, z] + (HPL[{0}, zb]*(HPL[{0}, z]^2*HPL[{2}, z] - 
       4*HPL[{0}, z]*HPL[{3}, z] + 6*HPL[{4}, z]))/2 + 
    HPL[{0}, z]*HPL[{4}, zb] + 4*HPL[{0}, zb]*HPL[{4}, zb] + 
    (HPL[{0}, z]*(HPL[{0}, zb]^2*HPL[{2}, zb] - 4*HPL[{0}, zb]*HPL[{3}, zb] + 
       6*HPL[{4}, zb]))/2 - 8*HPL[{5}, z] - 8*HPL[{5}, zb] + 
    (Pi^2*HPL[{2, 1}, z])/3 + (Pi^2*((HPL[{0}, z]*HPL[{1}, z]^2)/2 - 
       HPL[{1}, z]*HPL[{2}, z] + HPL[{2, 1}, z]))/3 + 
    (Pi^2*HPL[{2, 1}, zb])/3 + (Pi^2*((HPL[{0}, zb]*HPL[{1}, zb]^2)/2 - 
       HPL[{1}, zb]*HPL[{2}, zb] + HPL[{2, 1}, zb]))/3 + 
    HPL[{0}, z]*HPL[{2, 2}, z] + HPL[{0}, zb]*HPL[{2, 2}, z] + 
    HPL[{0}, z]*HPL[{2, 2}, zb] + HPL[{0}, zb]*HPL[{2, 2}, zb] - 
    2*(HPL[{2, 3}, z] + HPL[{3, 2}, z]) - 
    2*(HPL[{2, 3}, zb] + HPL[{3, 2}, zb]) + 2*HPL[{0}, z]^2*Zeta[3] + 
    4*HPL[{0}, z]*HPL[{0}, zb]*Zeta[3] + 2*HPL[{0}, zb]^2*Zeta[3] + 
    4*HPL[{2}, z]*Zeta[3] + 4*HPL[{2}, zb]*Zeta[3] + 12*Zeta[5]


FHPL[(1 - z)^(-1)] = -(Pi^2*HPL[{0}, zb]*HPL[{1}, z]^2)/6 - 
    (Pi^2*HPL[{1}, z]^3)/9 - (HPL[{0}, z]*HPL[{1}, z]^4)/24 - 
    (HPL[{0}, zb]*HPL[{1}, z]^4)/24 - HPL[{1}, z]^5/120 - 
    (Pi^2*HPL[{1}, z]^2*HPL[{1}, zb])/3 - (HPL[{1}, z]^4*HPL[{1}, zb])/24 - 
    (Pi^2*HPL[{0}, z]*HPL[{1}, zb]^2)/6 - (Pi^2*HPL[{1}, z]*HPL[{1}, zb]^2)/
     3 - (HPL[{1}, z]^3*HPL[{1}, zb]^2)/12 - (Pi^2*HPL[{1}, zb]^3)/9 - 
    (HPL[{1}, z]^2*HPL[{1}, zb]^3)/12 - (HPL[{0}, z]*HPL[{1}, zb]^4)/24 - 
    (HPL[{0}, zb]*HPL[{1}, zb]^4)/24 - (HPL[{1}, z]*HPL[{1}, zb]^4)/24 - 
    HPL[{1}, zb]^5/120 - (HPL[{0}, z]*HPL[{1}, z]^2*HPL[{2}, z])/2 + 
    (HPL[{1}, z]^3*HPL[{2}, z])/6 - (Pi^2*HPL[{1}, zb]*HPL[{2}, z])/3 - 
    (HPL[{1}, zb]^3*HPL[{2}, z])/6 - HPL[{1}, z]*HPL[{2}, z]^2 - 
    (Pi^2*HPL[{1}, z]*HPL[{2}, zb])/3 - (HPL[{1}, z]^3*HPL[{2}, zb])/6 - 
    (HPL[{0}, zb]*HPL[{1}, zb]^2*HPL[{2}, zb])/2 + 
    (HPL[{1}, zb]^3*HPL[{2}, zb])/6 - HPL[{1}, zb]*HPL[{2}, zb]^2 - 
    (HPL[{1}, zb]^2*(HPL[{0}, z]*HPL[{2}, z] - 2*HPL[{3}, z]))/2 - 
    HPL[{2}, zb]*(HPL[{0}, z]*HPL[{2}, z] - 2*HPL[{3}, z]) + 
    HPL[{1}, z]^2*HPL[{3}, z] - (HPL[{1}, z]^2*(HPL[{0}, zb]*HPL[{2}, zb] - 
       2*HPL[{3}, zb]))/2 - HPL[{2}, z]*(HPL[{0}, zb]*HPL[{2}, zb] - 
      2*HPL[{3}, zb]) + HPL[{1}, zb]^2*HPL[{3}, zb] - 
    (Pi^2*HPL[{2, 1}, z])/3 + 2*HPL[{0}, z]*HPL[{1}, z]*HPL[{2, 1}, z] - 
    HPL[{1}, z]^2*HPL[{2, 1}, z] - (HPL[{1}, zb]^2*HPL[{2, 1}, z])/2 + 
    HPL[{2}, z]*HPL[{2, 1}, z] - HPL[{2}, zb]*HPL[{2, 1}, z] - 
    (Pi^2*((HPL[{0}, z]*HPL[{1}, z]^2)/2 - HPL[{1}, z]*HPL[{2}, z] + 
       HPL[{2, 1}, z]))/3 - (HPL[{1}, zb]^2*((HPL[{0}, z]*HPL[{1}, z]^2)/2 - 
       HPL[{1}, z]*HPL[{2}, z] + HPL[{2, 1}, z]))/2 - 
    HPL[{2}, zb]*((HPL[{0}, z]*HPL[{1}, z]^2)/2 - HPL[{1}, z]*HPL[{2}, z] + 
      HPL[{2, 1}, z]) - (Pi^2*HPL[{2, 1}, zb])/3 - 
    (HPL[{1}, z]^2*HPL[{2, 1}, zb])/2 + 2*HPL[{0}, zb]*HPL[{1}, zb]*
     HPL[{2, 1}, zb] - HPL[{1}, zb]^2*HPL[{2, 1}, zb] - 
    HPL[{2}, z]*HPL[{2, 1}, zb] + HPL[{2}, zb]*HPL[{2, 1}, zb] - 
    (Pi^2*((HPL[{0}, zb]*HPL[{1}, zb]^2)/2 - HPL[{1}, zb]*HPL[{2}, zb] + 
       HPL[{2, 1}, zb]))/3 - 
    (HPL[{1}, z]^2*((HPL[{0}, zb]*HPL[{1}, zb]^2)/2 - 
       HPL[{1}, zb]*HPL[{2}, zb] + HPL[{2, 1}, zb]))/2 - 
    HPL[{2}, z]*((HPL[{0}, zb]*HPL[{1}, zb]^2)/2 - 
      HPL[{1}, zb]*HPL[{2}, zb] + HPL[{2, 1}, zb]) - 
    HPL[{0}, z]*HPL[{2, 2}, z] - HPL[{0}, zb]*HPL[{2, 2}, z] + 
    HPL[{1}, z]*HPL[{2, 2}, z] - HPL[{1}, zb]*HPL[{2, 2}, z] - 
    HPL[{0}, z]*HPL[{2, 2}, zb] - HPL[{0}, zb]*HPL[{2, 2}, zb] - 
    HPL[{1}, z]*HPL[{2, 2}, zb] + HPL[{1}, zb]*HPL[{2, 2}, zb] + 
    2*(HPL[{2, 3}, z] + HPL[{3, 2}, z]) + 
    2*(HPL[{2, 3}, zb] + HPL[{3, 2}, zb]) - 4*HPL[{0}, z]*HPL[{2, 1, 1}, z] - 
    HPL[{0}, zb]*HPL[{2, 1, 1}, z] + 4*HPL[{1}, z]*HPL[{2, 1, 1}, z] - 
    HPL[{1}, zb]*HPL[{2, 1, 1}, z] - 
    (HPL[{0}, zb]*(HPL[{1}, z]^2*HPL[{2}, z] - 4*HPL[{1}, z]*HPL[{2, 1}, z] + 
       6*HPL[{2, 1, 1}, z]))/2 - 
    (HPL[{1}, zb]*(HPL[{1}, z]^2*HPL[{2}, z] - 4*HPL[{1}, z]*HPL[{2, 1}, z] + 
       6*HPL[{2, 1, 1}, z]))/2 - HPL[{0}, z]*HPL[{2, 1, 1}, zb] - 
    4*HPL[{0}, zb]*HPL[{2, 1, 1}, zb] - HPL[{1}, z]*HPL[{2, 1, 1}, zb] + 
    4*HPL[{1}, zb]*HPL[{2, 1, 1}, zb] - 
    (HPL[{0}, z]*(HPL[{1}, zb]^2*HPL[{2}, zb] - 4*HPL[{1}, zb]*
        HPL[{2, 1}, zb] + 6*HPL[{2, 1, 1}, zb]))/2 - 
    (HPL[{1}, z]*(HPL[{1}, zb]^2*HPL[{2}, zb] - 4*HPL[{1}, zb]*
        HPL[{2, 1}, zb] + 6*HPL[{2, 1, 1}, zb]))/2 + HPL[{2, 1, 2}, z] + 
    HPL[{2, 1, 2}, zb] + (HPL[{2}, z]*HPL[{2, 1}, z] - HPL[{2, 1, 2}, z] - 
      3*HPL[{2, 2, 1}, z])/3 - HPL[{2, 2, 1}, z] + 
    (HPL[{2}, zb]*HPL[{2, 1}, zb] - HPL[{2, 1, 2}, zb] - 
      3*HPL[{2, 2, 1}, zb])/3 - HPL[{2, 2, 1}, zb] - 8*HPL[{2, 1, 1, 1}, z] - 
    8*HPL[{2, 1, 1, 1}, zb] + (4*Pi^2*Zeta[3])/3 + 2*HPL[{1}, z]^2*Zeta[3] + 
    2*HPL[{1}, zb]^2*Zeta[3] + 4*HPL[{2}, z]*Zeta[3] + 
    4*HPL[{2}, zb]*Zeta[3] + 4*Zeta[5]


FHPL[1 - z] = -(Pi^2*HPL[{0}, zb]*HPL[{1}, z]^2)/6 - 
    (Pi^2*HPL[{0}, z]*HPL[{1}, zb]^2)/6 - (Pi^2*HPL[{1}, zb]*HPL[{2}, z])/3 - 
    (Pi^2*HPL[{1}, z]*HPL[{2}, zb])/3 - HPL[{2}, zb]*
     (HPL[{0}, z]*HPL[{2}, z] - 2*HPL[{3}, z]) - 
    HPL[{2}, z]*(HPL[{0}, zb]*HPL[{2}, zb] - 2*HPL[{3}, zb]) - 
    (Pi^2*HPL[{2, 1}, z])/3 - (Pi^2*((HPL[{0}, z]*HPL[{1}, z]^2)/2 - 
       HPL[{1}, z]*HPL[{2}, z] + HPL[{2, 1}, z]))/3 - 
    (Pi^2*HPL[{2, 1}, zb])/3 - (Pi^2*((HPL[{0}, zb]*HPL[{1}, zb]^2)/2 - 
       HPL[{1}, zb]*HPL[{2}, zb] + HPL[{2, 1}, zb]))/3 - 
    HPL[{0}, z]*HPL[{2, 2}, z] - HPL[{0}, zb]*HPL[{2, 2}, z] - 
    HPL[{0}, z]*HPL[{2, 2}, zb] - HPL[{0}, zb]*HPL[{2, 2}, zb] + 
    2*(HPL[{2, 3}, z] + HPL[{3, 2}, z]) + 
    2*(HPL[{2, 3}, zb] + HPL[{3, 2}, zb]) + (4*Pi^2*Zeta[3])/3 - 
    4*HPL[{2}, z]*Zeta[3] - 4*HPL[{2}, zb]*Zeta[3] + 4*Zeta[5]


FHPL[z^(-1)] = (Pi^2*HPL[{0}, z]^3)/9 + HPL[{0}, z]^5/120 + 
    (Pi^2*HPL[{0}, z]^2*HPL[{0}, zb])/3 + (HPL[{0}, z]^4*HPL[{0}, zb])/24 + 
    (Pi^2*HPL[{0}, z]*HPL[{0}, zb]^2)/3 + (HPL[{0}, z]^3*HPL[{0}, zb]^2)/12 + 
    (Pi^2*HPL[{0}, zb]^3)/9 + (HPL[{0}, z]^2*HPL[{0}, zb]^3)/12 + 
    (HPL[{0}, z]*HPL[{0}, zb]^4)/24 + HPL[{0}, zb]^5/120 + 
    (HPL[{0}, z]^4*HPL[{1}, z])/24 + (Pi^2*HPL[{0}, zb]^2*HPL[{1}, z])/6 + 
    (HPL[{0}, zb]^4*HPL[{1}, z])/24 + (Pi^2*HPL[{0}, z]^2*HPL[{1}, zb])/6 + 
    (HPL[{0}, z]^4*HPL[{1}, zb])/24 + (HPL[{0}, zb]^4*HPL[{1}, zb])/24 + 
    (Pi^2*HPL[{0}, zb]*(HPL[{0}, z]*HPL[{1}, z] - HPL[{2}, z]))/3 + 
    (HPL[{0}, zb]^3*(HPL[{0}, z]*HPL[{1}, z] - HPL[{2}, z]))/6 - 
    (HPL[{0}, z]^3*HPL[{2}, z])/6 + (HPL[{0}, z]^2*HPL[{1}, z]*HPL[{2}, z])/
     2 + HPL[{0}, z]*HPL[{2}, z]^2 + 
    (Pi^2*HPL[{0}, z]*(HPL[{0}, zb]*HPL[{1}, zb] - HPL[{2}, zb]))/3 + 
    (HPL[{0}, z]^3*(HPL[{0}, zb]*HPL[{1}, zb] - HPL[{2}, zb]))/6 - 
    (HPL[{0}, zb]^3*HPL[{2}, zb])/6 + (HPL[{0}, zb]^2*HPL[{1}, zb]*
      HPL[{2}, zb])/2 + HPL[{0}, zb]*HPL[{2}, zb]^2 + (Pi^2*HPL[{3}, z])/3 + 
    HPL[{0}, z]^2*HPL[{3}, z] + (HPL[{0}, zb]^2*HPL[{3}, z])/2 - 
    2*HPL[{0}, z]*HPL[{1}, z]*HPL[{3}, z] - HPL[{2}, z]*HPL[{3}, z] + 
    (HPL[{0}, zb]*HPL[{1}, zb] - HPL[{2}, zb])*HPL[{3}, z] + 
    (Pi^2*((HPL[{0}, z]^2*HPL[{1}, z])/2 - HPL[{0}, z]*HPL[{2}, z] + 
       HPL[{3}, z]))/3 + (HPL[{0}, zb]^2*((HPL[{0}, z]^2*HPL[{1}, z])/2 - 
       HPL[{0}, z]*HPL[{2}, z] + HPL[{3}, z]))/2 + 
    (HPL[{0}, zb]*HPL[{1}, zb] - HPL[{2}, zb])*
     ((HPL[{0}, z]^2*HPL[{1}, z])/2 - HPL[{0}, z]*HPL[{2}, z] + 
      HPL[{3}, z]) + (Pi^2*HPL[{3}, zb])/3 + (HPL[{0}, z]^2*HPL[{3}, zb])/2 + 
    HPL[{0}, zb]^2*HPL[{3}, zb] - 2*HPL[{0}, zb]*HPL[{1}, zb]*HPL[{3}, zb] + 
    (HPL[{0}, z]*HPL[{1}, z] - HPL[{2}, z])*HPL[{3}, zb] - 
    HPL[{2}, zb]*HPL[{3}, zb] + (Pi^2*((HPL[{0}, zb]^2*HPL[{1}, zb])/2 - 
       HPL[{0}, zb]*HPL[{2}, zb] + HPL[{3}, zb]))/3 + 
    (HPL[{0}, z]^2*((HPL[{0}, zb]^2*HPL[{1}, zb])/2 - 
       HPL[{0}, zb]*HPL[{2}, zb] + HPL[{3}, zb]))/2 + 
    (HPL[{0}, z]*HPL[{1}, z] - HPL[{2}, z])*
     ((HPL[{0}, zb]^2*HPL[{1}, zb])/2 - HPL[{0}, zb]*HPL[{2}, zb] + 
      HPL[{3}, zb]) + (HPL[{0}, zb]*(HPL[{0}, z]^3*HPL[{1}, z] - 
       3*HPL[{0}, z]^2*HPL[{2}, z] + 6*HPL[{0}, z]*HPL[{3}, z] - 
       6*HPL[{4}, z]))/6 + (HPL[{1}, zb]*(HPL[{0}, z]^3*HPL[{1}, z] - 
       3*HPL[{0}, z]^2*HPL[{2}, z] + 6*HPL[{0}, z]*HPL[{3}, z] - 
       6*HPL[{4}, z]))/6 + HPL[{0}, zb]*(HPL[{0}, z]*HPL[{3}, z] - 
      3*HPL[{4}, z]) + HPL[{1}, zb]*(HPL[{0}, z]*HPL[{3}, z] - 
      3*HPL[{4}, z]) - 4*HPL[{0}, z]*HPL[{4}, z] + 
    4*HPL[{1}, z]*HPL[{4}, z] + (HPL[{0}, z]*(HPL[{0}, zb]^3*HPL[{1}, zb] - 
       3*HPL[{0}, zb]^2*HPL[{2}, zb] + 6*HPL[{0}, zb]*HPL[{3}, zb] - 
       6*HPL[{4}, zb]))/6 + (HPL[{1}, z]*(HPL[{0}, zb]^3*HPL[{1}, zb] - 
       3*HPL[{0}, zb]^2*HPL[{2}, zb] + 6*HPL[{0}, zb]*HPL[{3}, zb] - 
       6*HPL[{4}, zb]))/6 + HPL[{0}, z]*(HPL[{0}, zb]*HPL[{3}, zb] - 
      3*HPL[{4}, zb]) + HPL[{1}, z]*(HPL[{0}, zb]*HPL[{3}, zb] - 
      3*HPL[{4}, zb]) - 4*HPL[{0}, zb]*HPL[{4}, zb] + 
    4*HPL[{1}, zb]*HPL[{4}, zb] + 8*HPL[{5}, z] + 8*HPL[{5}, zb] + 
    (HPL[{0}, zb]^2*(HPL[{1}, z]*HPL[{2}, z] - 2*HPL[{2, 1}, z]))/2 + 
    (HPL[{0}, zb]*HPL[{1}, zb] - HPL[{2}, zb])*(HPL[{1}, z]*HPL[{2}, z] - 
      2*HPL[{2, 1}, z]) - HPL[{0}, z]^2*HPL[{2, 1}, z] + 
    (HPL[{0}, z]^2*(HPL[{1}, zb]*HPL[{2}, zb] - 2*HPL[{2, 1}, zb]))/2 + 
    (HPL[{0}, z]*HPL[{1}, z] - HPL[{2}, z])*(HPL[{1}, zb]*HPL[{2}, zb] - 
      2*HPL[{2, 1}, zb]) - HPL[{0}, zb]^2*HPL[{2, 1}, zb] + 
    HPL[{0}, zb]*(HPL[{0}, z]*HPL[{1}, z]*HPL[{2}, z] + HPL[{2}, z]^2 - 
      2*HPL[{1}, z]*HPL[{3}, z] - 2*HPL[{0}, z]*HPL[{2, 1}, z] - 
      HPL[{2, 2}, z]) + HPL[{1}, zb]*(HPL[{0}, z]*HPL[{1}, z]*HPL[{2}, z] + 
      HPL[{2}, z]^2 - 2*HPL[{1}, z]*HPL[{3}, z] - 
      2*HPL[{0}, z]*HPL[{2, 1}, z] - HPL[{2, 2}, z]) - 
    HPL[{0}, z]*HPL[{2, 2}, z] + HPL[{1}, z]*HPL[{2, 2}, z] + 
    HPL[{0}, z]*(HPL[{0}, zb]*HPL[{1}, zb]*HPL[{2}, zb] + HPL[{2}, zb]^2 - 
      2*HPL[{1}, zb]*HPL[{3}, zb] - 2*HPL[{0}, zb]*HPL[{2, 1}, zb] - 
      HPL[{2, 2}, zb]) + HPL[{1}, z]*(HPL[{0}, zb]*HPL[{1}, zb]*
       HPL[{2}, zb] + HPL[{2}, zb]^2 - 2*HPL[{1}, zb]*HPL[{3}, zb] - 
      2*HPL[{0}, zb]*HPL[{2, 1}, zb] - HPL[{2, 2}, zb]) - 
    HPL[{0}, zb]*HPL[{2, 2}, zb] + HPL[{1}, zb]*HPL[{2, 2}, zb] - 
    HPL[{2, 3}, z] - HPL[{2, 3}, zb] + HPL[{3, 2}, z] + 
    (-(HPL[{2}, z]*HPL[{3}, z]) + HPL[{2, 3}, z] + 3*HPL[{3, 2}, z])/3 + 
    HPL[{3, 2}, zb] + (-(HPL[{2}, zb]*HPL[{3}, zb]) + HPL[{2, 3}, zb] + 
      3*HPL[{3, 2}, zb])/3 - 2*(HPL[{2, 1, 2}, z] + HPL[{2, 2, 1}, z]) - 
    2*(HPL[{2, 1, 2}, zb] + HPL[{2, 2, 1}, zb]) + 2*HPL[{0}, z]^2*Zeta[3] + 
    4*HPL[{0}, z]*HPL[{0}, zb]*Zeta[3] + 2*HPL[{0}, zb]^2*Zeta[3] + 
    4*HPL[{0}, zb]*HPL[{1}, z]*Zeta[3] + 4*HPL[{0}, z]*HPL[{1}, zb]*Zeta[3] + 
    4*HPL[{1}, z]*HPL[{1}, zb]*Zeta[3] + 
    4*(HPL[{0}, z]*HPL[{1}, z] - HPL[{2}, z])*Zeta[3] + 
    4*(HPL[{0}, zb]*HPL[{1}, zb] - HPL[{2}, zb])*Zeta[3] + 12*Zeta[5]


FHPL[z/(-1 + z)] = -(Pi^2*HPL[{0}, zb]^2*HPL[{1}, z])/6 - 
    (Pi^2*HPL[{0}, zb]*HPL[{1}, z]^2)/6 - (Pi^2*HPL[{1}, z]^3)/9 - 
    HPL[{1}, z]^5/120 - (Pi^2*HPL[{0}, z]^2*HPL[{1}, zb])/6 - 
    (Pi^2*HPL[{1}, z]^2*HPL[{1}, zb])/3 - (HPL[{1}, z]^4*HPL[{1}, zb])/24 - 
    (Pi^2*HPL[{0}, z]*HPL[{1}, zb]^2)/6 - (Pi^2*HPL[{1}, z]*HPL[{1}, zb]^2)/
     3 - (HPL[{1}, z]^3*HPL[{1}, zb]^2)/12 - (Pi^2*HPL[{1}, zb]^3)/9 - 
    (HPL[{1}, z]^2*HPL[{1}, zb]^3)/12 - (HPL[{1}, z]*HPL[{1}, zb]^4)/24 - 
    HPL[{1}, zb]^5/120 - (Pi^2*HPL[{0}, zb]*(HPL[{0}, z]*HPL[{1}, z] - 
       HPL[{2}, z]))/3 - (2*Pi^2*HPL[{1}, zb]*(HPL[{0}, z]*HPL[{1}, z] - 
       HPL[{2}, z]))/3 - (HPL[{1}, zb]^3*(HPL[{0}, z]*HPL[{1}, z] - 
       HPL[{2}, z]))/6 - (HPL[{1}, z]^3*HPL[{2}, z])/6 - 
    (Pi^2*HPL[{1}, zb]*HPL[{2}, z])/3 - 
    (Pi^2*HPL[{0}, z]*(HPL[{0}, zb]*HPL[{1}, zb] - HPL[{2}, zb]))/3 - 
    (2*Pi^2*HPL[{1}, z]*(HPL[{0}, zb]*HPL[{1}, zb] - HPL[{2}, zb]))/3 - 
    (HPL[{1}, z]^3*(HPL[{0}, zb]*HPL[{1}, zb] - HPL[{2}, zb]))/6 - 
    (Pi^2*HPL[{1}, z]*HPL[{2}, zb])/3 - (HPL[{1}, zb]^3*HPL[{2}, zb])/6 - 
    (Pi^2*HPL[{3}, z])/3 - (Pi^2*((HPL[{0}, z]^2*HPL[{1}, z])/2 - 
       HPL[{0}, z]*HPL[{2}, z] + HPL[{3}, z]))/3 - (Pi^2*HPL[{3}, zb])/3 - 
    (Pi^2*((HPL[{0}, zb]^2*HPL[{1}, zb])/2 - HPL[{0}, zb]*HPL[{2}, zb] + 
       HPL[{3}, zb]))/3 - (2*Pi^2*(HPL[{1}, z]*HPL[{2}, z] - 
       2*HPL[{2, 1}, z]))/3 - (HPL[{1}, zb]^2*(HPL[{1}, z]*HPL[{2}, z] - 
       2*HPL[{2, 1}, z]))/2 - (HPL[{0}, zb]*HPL[{1}, zb] - HPL[{2}, zb])*
     (HPL[{1}, z]*HPL[{2}, z] - 2*HPL[{2, 1}, z]) - (Pi^2*HPL[{2, 1}, z])/3 + 
    HPL[{1}, z]^2*HPL[{2, 1}, z] - 
    (Pi^2*((HPL[{0}, z]*HPL[{1}, z]^2)/2 - HPL[{1}, z]*HPL[{2}, z] + 
       HPL[{2, 1}, z]))/3 - (2*Pi^2*(HPL[{1}, zb]*HPL[{2}, zb] - 
       2*HPL[{2, 1}, zb]))/3 - (HPL[{1}, z]^2*(HPL[{1}, zb]*HPL[{2}, zb] - 
       2*HPL[{2, 1}, zb]))/2 - (HPL[{0}, z]*HPL[{1}, z] - HPL[{2}, z])*
     (HPL[{1}, zb]*HPL[{2}, zb] - 2*HPL[{2, 1}, zb]) - 
    (Pi^2*HPL[{2, 1}, zb])/3 + HPL[{1}, zb]^2*HPL[{2, 1}, zb] - 
    (Pi^2*((HPL[{0}, zb]*HPL[{1}, zb]^2)/2 - HPL[{1}, zb]*HPL[{2}, zb] + 
       HPL[{2, 1}, zb]))/3 - HPL[{1}, zb]*
     (HPL[{0}, z]*HPL[{1}, z]*HPL[{2}, z] + HPL[{2}, z]^2 - 
      2*HPL[{1}, z]*HPL[{3}, z] - 2*HPL[{0}, z]*HPL[{2, 1}, z] - 
      HPL[{2, 2}, z]) - HPL[{1}, z]*HPL[{2, 2}, z] - 
    HPL[{1}, z]*(HPL[{0}, zb]*HPL[{1}, zb]*HPL[{2}, zb] + HPL[{2}, zb]^2 - 
      2*HPL[{1}, zb]*HPL[{3}, zb] - 2*HPL[{0}, zb]*HPL[{2, 1}, zb] - 
      HPL[{2, 2}, zb]) - HPL[{1}, zb]*HPL[{2, 2}, zb] - 
    (HPL[{1}, zb]*(HPL[{0}, z]*HPL[{1}, z]^3 - 3*HPL[{1}, z]^2*HPL[{2}, z] + 
       6*HPL[{1}, z]*HPL[{2, 1}, z] - 6*HPL[{2, 1, 1}, z]))/6 - 
    HPL[{1}, zb]*(HPL[{1}, z]*HPL[{2, 1}, z] - 3*HPL[{2, 1, 1}, z]) - 
    4*HPL[{1}, z]*HPL[{2, 1, 1}, z] - 
    (HPL[{1}, z]*(HPL[{0}, zb]*HPL[{1}, zb]^3 - 3*HPL[{1}, zb]^2*
        HPL[{2}, zb] + 6*HPL[{1}, zb]*HPL[{2, 1}, zb] - 
       6*HPL[{2, 1, 1}, zb]))/6 - HPL[{1}, z]*(HPL[{1}, zb]*HPL[{2, 1}, zb] - 
      3*HPL[{2, 1, 1}, zb]) - 4*HPL[{1}, zb]*HPL[{2, 1, 1}, zb] + 
    2*(HPL[{2, 1, 2}, z] + HPL[{2, 2, 1}, z]) + 
    2*(HPL[{2, 1, 2}, zb] + HPL[{2, 2, 1}, zb]) + 8*HPL[{2, 1, 1, 1}, z] + 
    8*HPL[{2, 1, 1, 1}, zb] + 4*HPL[{1}, z]*HPL[{1}, zb]*Zeta[3]
