• xthexder@l.sw0.com
      link
      fedilink
      English
      arrow-up
      11
      ·
      6 months ago

      Yes, but also no. We use giant prime numbers for cryptography because the more factors it has, the weaker the encryption becomes (because now there’s more than one answer for A * ? = B)

    • Wugmeister@lemmy.dbzer0.com
      link
      fedilink
      English
      arrow-up
      7
      ·
      6 months ago

      This actually is the main application for 2-almost primes. For example, instead of having an arbitrarily large prime be used for the hash, you could use a very large 2-almost prime as a key with its factors being used as 2 layers of hashing. I know there’s better uses, but the more I try to learn about cryptography the more confused I get

  • Dalvoron@lemm.ee
    link
    fedilink
    English
    arrow-up
    14
    arrow-down
    1
    ·
    6 months ago

    *numbers that are the product of exactly two prime factors

    • Xavienth@lemmygrad.ml
      link
      fedilink
      English
      arrow-up
      3
      ·
      6 months ago

      Presumably if they’re the product of exactly two factors then those factors would have to be prime, otherwise it wouldn’t be exactly two.

      • Dalvoron@lemm.ee
        link
        fedilink
        English
        arrow-up
        2
        ·
        edit-2
        6 months ago

        Well primes themselves are the product of exactly two (natural) factors, only one of which is prime, so we need to specify semi primes as having exactly two prime factors.

        • Xavienth@lemmygrad.ml
          link
          fedilink
          English
          arrow-up
          2
          arrow-down
          1
          ·
          6 months ago

          The definitions often exclude 1. In the case where you include it you could then say a semi prime has exactly three factors.

          • Dalvoron@lemm.ee
            link
            fedilink
            English
            arrow-up
            2
            ·
            6 months ago

            I have seen 1 called a trivial factor, but I have never seen it excluded entirely from a factor list: perhaps it’s a cultural thing like how 0 is/isn’t a natural number depending on where you are from.

            On further research it seems like my earlier critique about requiring exactly two prime factors is a little off in any case, as it would exclude e.g. 4 (which only has one prime factor). It seems like semi primes must be a product of exactly two prime numbers so I think any definition based on number of factors is doomed to over- or under- define these semi primes as they could have either three or four factors.