I'm not sure what I need to use, collections, compositing, masking or something else.
I want my final render to include two objects.
One object has motion blur. The other object is the same dimensions, material, etc as the first object and is in the same location but it has no motion blur. I want the object with no motion blur to be “in front” of the the object with motion blur and I do not want any optical interaction between the two objects (no blending of the two and no shadows from from object to the other, etc.)
There is a also a background. This can go in the same collection as the object with motion blur.
I am using Cycles.
I have avoided mentioning Collections, etc, because I do not have any preferred method. The best method will do!
Here is a crude illustration of what I want to achieve in Blender:
Picture 1: the object with motion blur and background.
Picture 2: the object with no motion blur (has a transparent background).
Picture 3: the two combined.