             ql[mq] = qold[I_q-1];
             qr[mq] = qold[I_q];
 
-            //amdq[mq] = amdq_trans[I_q];
             apdq[mq] = apdq_trans[I_q];
         }            
 

            qr[mq] = qold[I_q];
            qd[mq] = qold[I_q - ys];

            //bmdq[mq] = bmdq_trans[I_q];
            bpdq[mq] = bpdq_trans[I_q];
        }            


            qd[mq] = qold[I_q - ys];

            bmdq[mq] = bmdq_trans[I_q];
        }            

        for(int imp = 0; imp < 2; imp++)
