Repeating elements along ciphertext

Hey, I was wondering if there was a way to perform this repeat operation:

c: [1, ?, ?, ?, 2, ?, ?, ?, 3, ?, ?, ?, 4, ?, ?, ?]\\ \downarrow\\ c: [1, 1, 1, 1, 2, 2, 2, 2, 3, 3, 3, 3, 4, 4, 4, 4]

Without using multiplications? Now I am masking positions 0, 4, 8, 12 and i repeat using rotations. ? represents slots with random values that I want to cancel out. I would like to do it without using the product to mask (so I make a shorter circuit). I use CKKS, thank you

No, there is not. The multiplication here is needed to clear out the garbage in slots with ?. If you have control over how the input gets generated, maybe you can do the prior computation differently so that the ? items do not appear.

1 Like