This operation can be done in Packed encoding using the logic @dcousins described. It would be hard in the CoeffPacked encoding. The only ideas that come to mind are: (1) homomorphic encoding (expensive) and (2) using extraction to LWE. This topic is similar to the discussion we had at Inverting a Coefficient Packed Ciphertext
Manipulating DCRTPOLY would not be a good idea as you need to perform these operations homorphically, as pointed out by @dcousins