Holy Grailsort: Prototyping a New Buffer Redistribution

Поділитися
Вставка
  • Опубліковано 29 січ 2022
  • Presenting the rough draft of a much faster final merge dubbed "split merging", created by our team member Control!
    Follow our project here: github.com/HolyGrailSortProje...
    Visit our community Discord: / discord
    Check out the NEW home for ArrayV here: github.com/gaming32/ArrayV-v4.0
    Check out the Mother 1+2 Restoration project: / discord
    Thank you to Kalmar Republic and The Marshal Star for supporting my videos!
    Join this channel to get access to perks:
    / @musicombo
  • Наука та технологія

КОМЕНТАРІ • 15

  • @Musicombo
    @Musicombo  2 роки тому

    Visit our community Discord: discord.gg/thestudio
    Check out the NEW home for ArrayV here: github.com/gaming32/ArrayV-v4.0

  • @swed4490
    @swed4490 2 роки тому +5

    your vids always help me calm down whenever im stressed, even though its not the intention i still wanna say thank you :)

    • @Musicombo
      @Musicombo  2 роки тому +1

      You are more than welcome!! ❤

  • @leehaswell4206
    @leehaswell4206 2 роки тому +6

    i didn't come here understanding what the holy grail sort was, but i was enchanted by it anyways. it's weird how this makes "sense" to you as you watch it and see the computer's thoughts translated to GUI.

  • @LordControl
    @LordControl 2 роки тому +3

    ohhh
    ohhh that's a good one
    that's a good one
    yeah, no i see it

  • @RedstoneNguyen
    @RedstoneNguyen 2 роки тому +4

    Is this still stable? I see shellsort.

    • @LordControl
      @LordControl 2 роки тому +3

      well spotted!
      Shellsort is used during the algorithm to sort the buffer. This buffer is collected at the start and is made up entirely of unique values.
      The buffer is used as a work area and the algorithm doesn't have to maintain stability inside the buffer (since it's all unique values).
      Shellsort was choosen for this since it works well on small arrays and the buffer is size O(sqrt(n)) (small in comparison to the array length)
      There are also fallbacks in case the algorithm doesn't find enough unique values, see ~ 3:00 for that.
      In those cases it switches to a block selection with less unique values and then a lazy merge (which is a relatively fast inplace merge that works better if there are less unique values).

    • @RedstoneNguyen
      @RedstoneNguyen 2 роки тому +1

      @@LordControl as i see, the buffer is completely in-place (it's in the main array) and at the end, it will be sorted back into the whole main array. how could that be stable if the buffer itself is "unstable"?

    • @jeremy.N
      @jeremy.N 2 роки тому +2

      @@RedstoneNguyen The buffer is made up of unique items meaning that you don't have to worry about the stability of them (no two items in the buffer are the same), that is why you don't have to maintain stability, you can always recover the original order.

    • @RedstoneNguyen
      @RedstoneNguyen 2 роки тому

      @@jeremy.N oh my bad, i missed what is unique 😅

  • @ToppCuber
    @ToppCuber 2 роки тому

    I just thought of an idea for a sort, i don’t know if it will work: basically you put all the elements in a poplar heap and then use merge sort

  • @ToppCuber
    @ToppCuber 2 роки тому +4

    I’ll be honest, I don’t really like those sounds. I don’t know what it is, but I much rather prefer the old sounds than this.

    • @Musicombo
      @Musicombo  2 роки тому +1

      Fair enough! They are customizable with ArrayV version 4!

    • @ToppCuber
      @ToppCuber 2 роки тому +1

      @@Musicombo I’m glad they are, but if you like them the way they are right now, that’s perfectly fine.

    • @Musicombo
      @Musicombo  2 роки тому +1

      I like either rock organ sample for my videos.