 buffer2(i+imax*( 7 -1)) = buffer2(i+imax*( 7 -1)) + buffer1( 1 +(i-1)*kmax) * sphi_b( 1, 7 +s_offset_b1)
 buffer2(i+imax*( 9 -1)) = buffer2(i+imax*( 9 -1)) + buffer1( 1 +(i-1)*kmax) * sphi_b( 1, 9 +s_offset_b1)
 buffer2(i+imax*(11 -1)) = buffer2(i+imax*(11 -1)) + buffer1( 1 +(i-1)*kmax) * sphi_b( 1,11 +s_offset_b1)
 buffer2(i+imax*( 1 -1)) = buffer2(i+imax*( 1 -1)) + buffer1( 2 +(i-1)*kmax) * sphi_b( 2, 1 +s_offset_b1)
 buffer2(i+imax*( 3 -1)) = buffer2(i+imax*( 3 -1)) + buffer1( 2 +(i-1)*kmax) * sphi_b( 2, 3 +s_offset_b1)
 buffer2(i+imax*( 5 -1)) = buffer2(i+imax*( 5 -1)) + buffer1( 2 +(i-1)*kmax) * sphi_b( 2, 5 +s_offset_b1)
 buffer2(i+imax*( 6 -1)) = buffer2(i+imax*( 6 -1)) + buffer1( 3 +(i-1)*kmax) * sphi_b( 3, 6 +s_offset_b1)
 buffer2(i+imax*( 8 -1)) = buffer2(i+imax*( 8 -1)) + buffer1( 3 +(i-1)*kmax) * sphi_b( 3, 8 +s_offset_b1)
 buffer2(i+imax*(10 -1)) = buffer2(i+imax*(10 -1)) + buffer1( 3 +(i-1)*kmax) * sphi_b( 3,10 +s_offset_b1)
 buffer2(i+imax*( 7 -1)) = buffer2(i+imax*( 7 -1)) + buffer1( 4 +(i-1)*kmax) * sphi_b( 4, 7 +s_offset_b1)
 buffer2(i+imax*( 9 -1)) = buffer2(i+imax*( 9 -1)) + buffer1( 4 +(i-1)*kmax) * sphi_b( 4, 9 +s_offset_b1)
 buffer2(i+imax*(11 -1)) = buffer2(i+imax*(11 -1)) + buffer1( 4 +(i-1)*kmax) * sphi_b( 4,11 +s_offset_b1)
 buffer2(i+imax*( 2 -1)) = buffer2(i+imax*( 2 -1)) + buffer1( 5 +(i-1)*kmax) * sphi_b( 5, 2 +s_offset_b1)
 buffer2(i+imax*( 4 -1)) = buffer2(i+imax*( 4 -1)) + buffer1( 5 +(i-1)*kmax) * sphi_b( 5, 4 +s_offset_b1)
 buffer2(i+imax*( 7 -1)) = buffer2(i+imax*( 7 -1)) + buffer1( 6 +(i-1)*kmax) * sphi_b( 6, 7 +s_offset_b1)
 buffer2(i+imax*( 9 -1)) = buffer2(i+imax*( 9 -1)) + buffer1( 6 +(i-1)*kmax) * sphi_b( 6, 9 +s_offset_b1)
 buffer2(i+imax*( 1 -1)) = buffer2(i+imax*( 1 -1)) + buffer1( 7 +(i-1)*kmax) * sphi_b( 7, 1 +s_offset_b1)
 buffer2(i+imax*( 3 -1)) = buffer2(i+imax*( 3 -1)) + buffer1( 7 +(i-1)*kmax) * sphi_b( 7, 3 +s_offset_b1)
 buffer2(i+imax*( 5 -1)) = buffer2(i+imax*( 5 -1)) + buffer1( 7 +(i-1)*kmax) * sphi_b( 7, 5 +s_offset_b1)
 buffer2(i+imax*( 6 -1)) = buffer2(i+imax*( 6 -1)) + buffer1( 8 +(i-1)*kmax) * sphi_b( 8, 6 +s_offset_b1)
 buffer2(i+imax*(10 -1)) = buffer2(i+imax*(10 -1)) + buffer1( 8 +(i-1)*kmax) * sphi_b( 8,10 +s_offset_b1)
 buffer2(i+imax*( 3 -1)) = buffer2(i+imax*( 3 -1)) + buffer1( 9 +(i-1)*kmax) * sphi_b( 9, 3 +s_offset_b1)
 buffer2(i+imax*( 5 -1)) = buffer2(i+imax*( 5 -1)) + buffer1( 9 +(i-1)*kmax) * sphi_b( 9, 5 +s_offset_b1)
 buffer2(i+imax*( 6 -1)) = buffer2(i+imax*( 6 -1)) + buffer1(10 +(i-1)*kmax) * sphi_b(10, 6 +s_offset_b1)
 buffer2(i+imax*( 8 -1)) = buffer2(i+imax*( 8 -1)) + buffer1(10 +(i-1)*kmax) * sphi_b(10, 8 +s_offset_b1)
 buffer2(i+imax*( 7 -1)) = buffer2(i+imax*( 7 -1)) + buffer1(11 +(i-1)*kmax) * sphi_b(11, 7 +s_offset_b1)
 buffer2(i+imax*( 9 -1)) = buffer2(i+imax*( 9 -1)) + buffer1(11 +(i-1)*kmax) * sphi_b(11, 9 +s_offset_b1)
 buffer2(i+imax*(11 -1)) = buffer2(i+imax*(11 -1)) + buffer1(11 +(i-1)*kmax) * sphi_b(11,11 +s_offset_b1)
 buffer2(i+imax*( 2 -1)) = buffer2(i+imax*( 2 -1)) + buffer1(12 +(i-1)*kmax) * sphi_b(12, 2 +s_offset_b1)
 buffer2(i+imax*( 4 -1)) = buffer2(i+imax*( 4 -1)) + buffer1(12 +(i-1)*kmax) * sphi_b(12, 4 +s_offset_b1)
 buffer2(i+imax*( 7 -1)) = buffer2(i+imax*( 7 -1)) + buffer1(13 +(i-1)*kmax) * sphi_b(13, 7 +s_offset_b1)
 buffer2(i+imax*( 9 -1)) = buffer2(i+imax*( 9 -1)) + buffer1(13 +(i-1)*kmax) * sphi_b(13, 9 +s_offset_b1)
 buffer2(i+imax*( 4 -1)) = buffer2(i+imax*( 4 -1)) + buffer1(14 +(i-1)*kmax) * sphi_b(14, 4 +s_offset_b1)
 buffer2(i+imax*( 7 -1)) = buffer2(i+imax*( 7 -1)) + buffer1(15 +(i-1)*kmax) * sphi_b(15, 7 +s_offset_b1)
 buffer2(i+imax*( 1 -1)) = buffer2(i+imax*( 1 -1)) + buffer1(16 +(i-1)*kmax) * sphi_b(16, 1 +s_offset_b1)
 buffer2(i+imax*( 3 -1)) = buffer2(i+imax*( 3 -1)) + buffer1(16 +(i-1)*kmax) * sphi_b(16, 3 +s_offset_b1)
 buffer2(i+imax*( 5 -1)) = buffer2(i+imax*( 5 -1)) + buffer1(16 +(i-1)*kmax) * sphi_b(16, 5 +s_offset_b1)
 buffer2(i+imax*( 6 -1)) = buffer2(i+imax*( 6 -1)) + buffer1(17 +(i-1)*kmax) * sphi_b(17, 6 +s_offset_b1)
 buffer2(i+imax*( 8 -1)) = buffer2(i+imax*( 8 -1)) + buffer1(17 +(i-1)*kmax) * sphi_b(17, 8 +s_offset_b1)
 buffer2(i+imax*(10 -1)) = buffer2(i+imax*(10 -1)) + buffer1(17 +(i-1)*kmax) * sphi_b(17,10 +s_offset_b1)
 buffer2(i+imax*( 3 -1)) = buffer2(i+imax*( 3 -1)) + buffer1(18 +(i-1)*kmax) * sphi_b(18, 3 +s_offset_b1)
 buffer2(i+imax*( 5 -1)) = buffer2(i+imax*( 5 -1)) + buffer1(18 +(i-1)*kmax) * sphi_b(18, 5 +s_offset_b1)
 buffer2(i+imax*( 6 -1)) = buffer2(i+imax*( 6 -1)) + buffer1(19 +(i-1)*kmax) * sphi_b(19, 6 +s_offset_b1)
 buffer2(i+imax*( 8 -1)) = buffer2(i+imax*( 8 -1)) + buffer1(19 +(i-1)*kmax) * sphi_b(19, 8 +s_offset_b1)
 buffer2(i+imax*( 5 -1)) = buffer2(i+imax*( 5 -1)) + buffer1(20 +(i-1)*kmax) * sphi_b(20, 5 +s_offset_b1)
 buffer2(i+imax*( 6 -1)) = buffer2(i+imax*( 6 -1)) + buffer1(21 +(i-1)*kmax) * sphi_b(21, 6 +s_offset_b1)
