multiply_imaginary_integer

Engine.multiply_imaginary_integer(x, y)
암호문과 실수부가 0이고 허수부가 정수인 복소수를 곱한 암호문을 반환합니다. 레벨을 소모하지 않습니다.
  • 인풋:
    • x: int | Ciphertext
    • y: int | Ciphertext
    • x와 y는 위치 인자로만 전달해야 합니다.
    • 인풋 둘 중 하나는 Ciphertext여야 합니다. 나머지 인풋은 허수부의 정수값이 됩니다.
  • 아웃풋:
    • Ciphertext

Warning

  • 행렬 엔진은 이 연산을 아직 지원하지 않습니다.
from desilofhe import Engine

engine = Engine()
secret_key = engine.create_secret_key()
public_key = engine.create_public_key(secret_key)

message = [1, 2, 3]
ciphertext = engine.encrypt(message, public_key)

multiplied1 = engine.multiply_imaginary_integer(ciphertext, 2)
multiplied2 = engine.multiply_imaginary_integer(2, ciphertext)