Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Cool Math for Hot Music 輪読会 Sec.5

Cool Math for Hot Music 輪読会 Sec.5

2021-05-24

Ryo Sakuma

May 17, 2021
Tweet

More Decks by Ryo Sakuma

Other Decks in Science

Transcript

  1. େ·͔ͳྲྀΕ 1. ಋೖɿؔ਺ͷू߹ʢ഑ஔू߹ʣ§5.0 2. ௚ੵʢ௚࿨ʣͱࣹӨɾؔ਺ͷؔ܎ §5.2, 5.3 3. ௚ੵΛू߹ 2

    ݸ͔Βແݶݸ΁֦ு §5.6 4. Ұൠͷ௚ੵʹ͓͚Δʮॱংʯ §5.6 5. ႈू߹ͷه๏ 2a ͷҙຯ §5.4, 5.5ʢ͓·͚ʣ
  2. 1. ಋೖɿؔ਺ͷू߹ʢ഑ஔू߹ʣ b a 1 2 3 x y f1

    ```python def f1(a1): return x ``` • ؔ਺ f : a → b ͸ͨ͘͞Μ͋Δ
  3. 1. ಋೖɿؔ਺ͷू߹ʢ഑ஔू߹ʣ b a 1 2 3 x y f2

    ```python def f2(a1): if a1 == 1: return x if a1 == 2: return x else: return y ``` ؔ਺ͷ໼ҹͰ͸ͳ͘ ཁૉରԠͷ໼ҹ • ؔ਺ f : a → b ͸ͨ͘͞Μ͋Δ
  4. 1. ಋೖɿؔ਺ͷू߹ʢ഑ஔू߹ʣ b a 1 2 3 x y fi

    ཁૉରԠͷ໼ҹΛଋͶͨ 1 ຊͷؔ਺ͷ໼ҹ f ͷ࣮૷͸ 23 = 8 ௨Γ • ؔ਺ f : a → b ͸ͨ͘͞Μ͋Δ { f1, f2, ..., f8 }
  5. 1. ಋೖɿؔ਺ͷू߹ʢ഑ஔू߹ʣ b a 1 2 3 x y fi

    ཁૉରԠͷ໼ҹΛଋͶͨ 1 ຊͷؔ਺ͷ໼ҹ { f1, f2, ..., f8 } := baʮ഑ஔू߹ʯ := Set(a, b) ...ݍ࿦ Hom(a, b) • ؔ਺ f : a → b ͸ͨ͘͞Μ͋Δ දه๏ͷҙຯɿ ू߹ͷཁૉ਺Λ |A| Ͱॻ͘ͱ |ba| = |b||a| = 23 f ͷ࣮૷͸ 23 = 8 ௨Γ
  6. େ·͔ͳྲྀΕ 1. ಋೖɿؔ਺ͷू߹ʢ഑ஔू߹ʣ§5.0 2. ௚ੵʢ௚࿨ʣͱࣹӨɾؔ਺ͷؔ܎ §5.2, 5.3 3. ௚ੵΛू߹ 2

    ݸ͔Β N ݸ΁֦ு §5.6 4. Ұൠͷ௚ੵʹ͓͚Δʮॱংʯ §5.6 5. ႈू߹ͷه๏ 2a ͷҙຯ §5.4, 5.5ʢ͓·͚ʣ
  7. 2. ௚ੵʢ௚࿨ʣͱࣹӨɾؔ਺ͷؔ܎ • ͍͖ͳΓ Fig. 5.1 ΛݟͪΌ͍·͢ʢԻఔ interval ͷଌఆ͕໨ඪʣ •

    ͍͖ͳΓ Fig. 5.1 ΛݟͪΌ͍·͢ʢԻఔ interval ͷଌఆ͕໨ඪʣ c (1) ू߹ c = { 0, 1 } Λ༻ҙ
  8. 2. ௚ੵʢ௚࿨ʣͱࣹӨɾؔ਺ͷؔ܎ (1) ू߹ c = { 0, 1 }

    Λ༻ҙ • ͍͖ͳΓ Fig. 5.1 ΛݟͪΌ͍·͢ʢԻఔ interval ͷଌఆ͕໨ඪʣ • ͍͖ͳΓ Fig. 5.1 ΛݟͪΌ͍·͢ʢԻఔ interval ͷଌఆ͕໨ඪʣ (2) c ͷ 2 ఺Λ a ্࣠ͷ 2 ఺ʹରԠͤ͞Δ ؔ਺ fa Λ༻ҙ c fa
  9. 2. ௚ੵʢ௚࿨ʣͱࣹӨɾؔ਺ͷؔ܎ (1) ू߹ c = { 0, 1 }

    Λ༻ҙ • ͍͖ͳΓ Fig. 5.1 ΛݟͪΌ͍·͢ʢԻఔ interval ͷଌఆ͕໨ඪʣ • ͍͖ͳΓ Fig. 5.1 ΛݟͪΌ͍·͢ʢԻఔ interval ͷଌఆ͕໨ඪʣ (2) c ͷ 2 ఺Λ a ্࣠ͷ 2 ఺ʹରԠͤ͞Δ ؔ਺ fa Λ༻ҙ c fb (3) c ͷ 2 ఺Λ b ্࣠ͷ 2 ఺ʹରԠͤ͞Δ ؔ਺ fb Λ༻ҙ
  10. 2. ௚ੵʢ௚࿨ʣͱࣹӨɾؔ਺ͷؔ܎ (1) ू߹ c = { 0, 1 }

    Λ༻ҙ • ͍͖ͳΓ Fig. 5.1 ΛݟͪΌ͍·͢ʢԻఔ interval ͷଌఆ͕໨ඪʣ • ͍͖ͳΓ Fig. 5.1 ΛݟͪΌ͍·͢ʢԻఔ interval ͷଌఆ͕໨ඪʣ (2) c ͷ 2 ఺Λ a ্࣠ͷ 2 ఺ʹରԠͤ͞Δ ؔ਺ fa Λ༻ҙ c (3) c ͷ 2 ఺Λ b ্࣠ͷ 2 ఺ʹରԠͤ͞Δ ؔ਺ fb Λ༻ҙ (4) ab ฏ໘্ͷ࠲ඪʢ௚ੵ a×b ͷཁૉʣ͕ 2 ఺ܾ·ΔʢԻఔͷଌఆʣ
  11. 2. ௚ੵʢ௚࿨ʣͱࣹӨɾؔ਺ͷؔ܎ (1) ू߹ c = { 0, 1 }

    Λ༻ҙ • ͍͖ͳΓ Fig. 5.1 ΛݟͪΌ͍·͢ʢԻఔ interval ͷଌఆ͕໨ඪʣ • ͍͖ͳΓ Fig. 5.1 ΛݟͪΌ͍·͢ʢԻఔ interval ͷଌఆ͕໨ඪʣ (2) c ͷ 2 ఺Λ a ্࣠ͷ 2 ఺ʹରԠͤ͞Δ ؔ਺ fa Λ༻ҙ c (3) c ͷ 2 ఺Λ b ্࣠ͷ 2 ఺ʹରԠͤ͞Δ ؔ਺ fb Λ༻ҙ (4) ab ฏ໘্ͷ࠲ඪʢ௚ੵ a×b ͷཁૉʣ͕ 2 ఺ܾ·ΔʢԻఔͷଌఆʣ (5) c ͷ 2 ఺Λ ab ฏ໘্ͷ 2 ఺΁௚઀ରԠ ͤ͞Δؔ਺ f ͕͋ͬͯ΋ྑ͍͸ͣ f
  12. 2. ௚ੵʢ௚࿨ʣͱࣹӨɾؔ਺ͷؔ܎ (1) ू߹ c = { 0, 1 }

    Λ༻ҙ • ͍͖ͳΓ Fig. 5.1 ΛݟͪΌ͍·͢ʢԻఔ interval ͷଌఆ͕໨ඪʣ • ͍͖ͳΓ Fig. 5.1 ΛݟͪΌ͍·͢ʢԻఔ interval ͷଌఆ͕໨ඪʣ (2) c ͷ 2 ఺Λ a ্࣠ͷ 2 ఺ʹରԠͤ͞Δ ؔ਺ fa Λ༻ҙ c (3) c ͷ 2 ఺Λ b ্࣠ͷ 2 ఺ʹରԠͤ͞Δ ؔ਺ fb Λ༻ҙ (4) ab ฏ໘্ͷ࠲ඪʢ௚ੵ a×b ͷཁૉʣ͕ 2 ఺ܾ·ΔʢԻఔͷଌఆʣ pra prb (6) ͱ͜ΖͰࣹӨ pra, prb ͕ଘࡏ (5) c ͷ 2 ఺Λ ab ฏ໘্ͷ 2 ఺΁௚઀ରԠ ͤ͞Δؔ਺ f ͕͋ͬͯ΋ྑ͍͸ͣ
  13. 2. ௚ੵʢ௚࿨ʣͱࣹӨɾؔ਺ͷؔ܎ ໌Β͔ʹ ( fa , fb ) = (

    pra ∘ f , prb ∘ f ) • ͍͖ͳΓ Fig. 5.1 ΛݟͪΌ͍·͢ʢԻఔ interval ͷଌఆ͕໨ඪʣ • ͍͖ͳΓ Fig. 5.1 ΛݟͪΌ͍·͢ʢԻఔ interval ͷଌఆ͕໨ඪʣ c pra prb f fb fa ໰ɿ͜ͷؔ਺ f ͱ ( fa , fb ) ͸࣮࣭ಉ͡ʁ
  14. 2. ௚ੵʢ௚࿨ʣͱࣹӨɾؔ਺ͷؔ܎ • ͍͖ͳΓ Fig. 5.1 ΛݟͪΌ͍·͢ʢԻఔ interval ͷଌఆ͕໨ඪʣ •

    ͍͖ͳΓ Fig. 5.1 ΛݟͪΌ͍·͢ʢԻఔ interval ͷଌఆ͕໨ඪʣ c pra prb f fb fa ౴ɿఆཧ 1ʢ௚ੵͷීวੑʣ ࣍ͷؔ਺͕ଘࡏ͠ɺ͔ͭશ୯ࣹ Set(c, a × b) → Set(c, a) × Set(c, b) : f ( pra ∘ f , prb ∘ f ) ໌Β͔ʹ ( fa , fb ) = ( pra ∘ f , prb ∘ f ) ໰ɿ͜ͷؔ਺ f ͱ ( fa , fb ) ͸࣮࣭ಉ͡ʁ
  15. 2. ௚ੵʢ௚࿨ʣͱࣹӨɾؔ਺ͷؔ܎ • ͍͖ͳΓ Fig. 5.1 ΛݟͪΌ͍·͢ʢԻఔ interval ͷଌఆ͕໨ඪʣ •

    ͍͖ͳΓ Fig. 5.1 ΛݟͪΌ͍·͢ʢԻఔ interval ͷଌఆ͕໨ඪʣ (1) ू߹ {0, 1} = {0} ∪ {1} ͱ෼ׂ ߹ซͱඇަ࿨ͷҧ͍͸ޱ಄Ͱผ్આ໌༧ఆ
  16. 2. ௚ੵʢ௚࿨ʣͱࣹӨɾؔ਺ͷؔ܎ • ͍͖ͳΓ Fig. 5.1 ΛݟͪΌ͍·͢ʢԻఔ interval ͷଌఆ͕໨ඪʣ •

    ͍͖ͳΓ Fig. 5.1 ΛݟͪΌ͍·͢ʢԻఔ interval ͷଌఆ͕໨ඪʣ (1) ू߹ {0, 1} = {0} ∪ {1} ͱ෼ׂ (2) a = {0}, b = {1} ͱ͓͘ a b
  17. 2. ௚ੵʢ௚࿨ʣͱࣹӨɾؔ਺ͷؔ܎ • ͍͖ͳΓ Fig. 5.1 ΛݟͪΌ͍·͢ʢԻఔ interval ͷଌఆ͕໨ඪʣ •

    ͍͖ͳΓ Fig. 5.1 ΛݟͪΌ͍·͢ʢԻఔ interval ͷଌఆ͕໨ඪʣ (1) ू߹ {0, 1} = {0} ∪ {1} ͱ෼ׂ a b fa fb (3) ҎԼ 2 ͭͷؔ਺Λ༻ҙʢԻఔͷଌఆʣ a ͷཁૉ 0 Λ࠲ඪ 1 ͭʹରԠͤ͞Δؔ਺ fa b ͷཁૉ 1 Λ࠲ඪ 1 ͭʹରԠͤ͞Δؔ਺ fb (2) a = {0}, b = {1} ͱ͓͘
  18. 2. ௚ੵʢ௚࿨ʣͱࣹӨɾؔ਺ͷؔ܎ • ͍͖ͳΓ Fig. 5.1 ΛݟͪΌ͍·͢ʢԻఔ interval ͷଌఆ͕໨ඪʣ •

    ͍͖ͳΓ Fig. 5.1 ΛݟͪΌ͍·͢ʢԻఔ interval ͷଌఆ͕໨ඪʣ (1) ू߹ {0, 1} = {0} ∪ {1} ͱ෼ׂ (3) ҎԼ 2 ͭͷؔ਺Λ༻ҙʢԻఔͷଌఆʣ a ͷཁૉ 0 Λ࠲ඪ 1 ͭʹରԠͤ͞Δؔ਺ fa b ͷཁૉ 1 Λ࠲ඪ 1 ͭʹରԠͤ͞Δؔ਺ fb (4) c ΛҰؾʹ ab ฏ໘্ͷ 2 ఺΁௚઀ରԠ ͤ͞Δؔ਺ f ͕͋ͬͯ΋ྑ͍͸ͣ f (2) a = {0}, b = {1} ͱ͓͘
  19. 2. ௚ੵʢ௚࿨ʣͱࣹӨɾؔ਺ͷؔ܎ • ͍͖ͳΓ Fig. 5.1 ΛݟͪΌ͍·͢ʢԻఔ interval ͷଌఆ͕໨ඪʣ •

    ͍͖ͳΓ Fig. 5.1 ΛݟͪΌ͍·͢ʢԻఔ interval ͷଌఆ͕໨ඪʣ (4) c ΛҰؾʹ ab ฏ໘্ͷ 2 ఺΁௚઀ରԠ ͤ͞Δؔ਺ f ͕͋ͬͯ΋ྑ͍͸ͣ (1) ू߹ {0, 1} = {0} ∪ {1} ͱ෼ׂ (3) ҎԼ 2 ͭͷؔ਺Λ༻ҙʢԻఔͷଌఆʣ a ͷཁૉ 0 Λ࠲ඪ 1 ͭʹରԠͤ͞Δؔ਺ fa b ͷཁૉ 1 Λ࠲ඪ 1 ͭʹରԠͤ͞Δؔ਺ fb (5) ͱ͜ΖͰ୯ࣹ ina, inb ͕ଘࡏ a b a 0 b 1 c 1 0 inb ina (2) a = {0}, b = {1} ͱ͓͘
  20. 2. ௚ੵʢ௚࿨ʣͱࣹӨɾؔ਺ͷؔ܎ • ͍͖ͳΓ Fig. 5.1 ΛݟͪΌ͍·͢ʢԻఔ interval ͷଌఆ͕໨ඪʣ •

    ͍͖ͳΓ Fig. 5.1 ΛݟͪΌ͍·͢ʢԻఔ interval ͷଌఆ͕໨ඪʣ a b a 0 b 1 c 1 0 inb ina fa fb f ໌Β͔ʹ ( fa , fb ) = ( f ∘ ina , f ∘ inb ) ໰ɿ͜ͷؔ਺ f ͱ ( fa , fb ) ͸࣮࣭ಉ͡ʁ
  21. 2. ௚ੵʢ௚࿨ʣͱࣹӨɾؔ਺ͷؔ܎ • ͍͖ͳΓ Fig. 5.1 ΛݟͪΌ͍·͢ʢԻఔ interval ͷଌఆ͕໨ඪʣ •

    ͍͖ͳΓ Fig. 5.1 ΛݟͪΌ͍·͢ʢԻఔ interval ͷଌఆ͕໨ඪʣ c a b a 0 b 1 c 1 0 inb ina fa fb f ౴ɿఆཧ 2ʢ௚࿨ͷීวੑʣ ࣍ͷؔ਺͕ଘࡏ͠ɺ͔ͭશ୯ࣹ Set(a b, c) → Set(a, c) × Set(b, c) : f ( f ∘ ina , f ∘ inb ) ༨ੵ coproduct ͸௚࿨ͷݍ࿦༻ޠ ໌Β͔ʹ ( fa , fb ) = ( f ∘ ina , f ∘ inb ) ໰ɿ͜ͷؔ਺ f ͱ ( fa , fb ) ͸࣮࣭ಉ͡ʁ
  22. େ·͔ͳྲྀΕ 1. ಋೖɿؔ਺ͷू߹ʢ഑ஔू߹ʣ§5.0 2. ௚ੵʢ௚࿨ʣͱࣹӨɾؔ਺ͷؔ܎ §5.2, 5.3 3. ௚ੵΛू߹ 2

    ݸ͔Β N ݸ΁֦ு §5.6 4. Ұൠͷ௚ੵʹ͓͚Δʮॱংʯ §5.6 5. ႈू߹ͷه๏ 2a ͷҙຯ §5.4, 5.5ʢ͓·͚ʣ
  23. • ू߹ 2 ݸͷ௚ੵ a × b ͱ͸ʮॱংରͷू߹ʯ a ×

    b = { (x, y) | x ∈ a, y ∈ b } (§4 Def. 6) 3. ௚ੵΛू߹ 2 ݸ͔Βແݶݸ΁֦ு
  24. • ू߹ 2 ݸͷ௚ੵ a × b ͱ͸ʮॱংରͷू߹ʯ a ×

    b = { (x, y) | x ∈ a, y ∈ b } (§4 Def. 6) • ݁ہʮ࠲ඪͷू߹ʯ͡ΌΜ……ʁ 3. ௚ੵΛू߹ 2 ݸ͔Βແݶݸ΁֦ு
  25. • ू߹ 2 ݸͷ௚ੵ a × b ͱ͸ʮॱংରͷू߹ʯ a ×

    b = { (x, y) | x ∈ a, y ∈ b } (§4 Def. 6) • ݁ہʮ࠲ඪͷू߹ʯ͡ΌΜ……ʁ • ू߹ N ݸͷ௚ੵ a1 × ... × aN ͱ͸ʮ࠲ඪͷू߹ʯ a1 × ... × aN = { (x1, ..., xN) | x1 ∈ a1, ..., xN ∈ aN }ʢDef. Hashʣ 3. ௚ੵΛू߹ 2 ݸ͔Βແݶݸ΁֦ு
  26. େ·͔ͳྲྀΕ 1. ಋೖɿؔ਺ͷू߹ʢ഑ஔू߹ʣ§5.0 2. ௚ੵʢ௚࿨ʣͱࣹӨɾؔ਺ͷؔ܎ §5.2, 5.3 3. ௚ੵΛू߹ 2

    ݸ͔Β N ݸ΁֦ு §5.6 4. Ұൠͷ௚ੵʹ͓͚Δʮॱংʯ §5.6 5. ႈू߹ͷه๏ 2a ͷҙຯ §5.4, 5.5ʢ͓·͚ʣ
  27. • Ұൠͷ௚ੵू߹ͰʮݩͷॱংʯΛͲͷΑ͏ʹܾΊΔ͔ • Example 15ɿC Major ͱ C minor ͸ʮͲ͕ͬͪઌʁʯ

    4. Ұൠͷ௚ੵʹ͓͚Δʮॱংʯ (0, 1, 1, 1, 0, 1, 1, 0, 1, 1, 1, 1) (0, 1, 1, 0, 1, 1, 1, 0, 1, 1, 1, 1) C ͔Β B ·Ͱ 12 Ի ࢖༻͢ΔԻʹ͸ 0 ࢖༻͠ͳ͍Իʹ 1 ΛׂΓ౰ͯͯΈΔ True/False ͷϑϥάͱ ٯͳؾ͕͢Δ͚ΕͲ ޙͰҙຯ͕෼͔Δ େલఏɿ֤੒෼Ͳ͏͠͸ൺֱՄೳʢઢܕॱংʣ
  28. • ܾΊํ 1ɿࣙॻࣜॱংʢDef. 19 lexicographic orderingʣ • ֤੒෼Ͳ͏͠Λࠨ͔Βॱʹݟ͍ͯͬͯɺॳΊͯ஋͕ҟͳΔҐஔ y Λ୳ͯ͠ɺ

    ... the smallest index y, where ty ≠ sy • Ґஔ y ͷ੒෼Ͳ͏͠ͷॱংΛɺͦͷ··௚ੵू߹ʹ͓͚Δʮॱংʯͱ͢Δ ... (tx)a < (sx)a iff (snip), has ty <y sy 4. Ұൠͷ௚ੵʹ͓͚Δʮॱংʯ (0, 1, 1, 1, 0, 1, 1, 0, 1, 1, 1, 1) (0, 1, 1, 0, 1, 1, 1, 0, 1, 1, 1, 1) t4 s4 > > C Major (tx)a C minor (sx)a ઌʂ
  29. • ܾΊํ 2ɿ௚ੵॱংʢDef. 20 product relationʣ • ೚ҙͷ੒෼Ͳ͏͕͠ಉ͡ॱংؔ܎Ͱ͋Ε͹ɺͦΕΛ௚ੵू߹ʹ͓͚Δʮॱংʯͱ͢Δ ... (tx)aR(sx)a

    iff txrxsx for each x ∈ a 4. Ұൠͷ௚ੵʹ͓͚Δʮॱংʯ (0, 1, 1, 1, 0, 1, 1, 0, 1, 1, 1, 1) (0, 1, 1, 0, 1, 1, 1, 0, 1, 1, 1, 1) t4 s4 > ? C Major (tx)a C minor (sx)a t5 s5 < ௚ੵॱং͸Ұൠʹઢܕॱংͱ͸ͳΒͳ͍
  30. • Mazzola ઌੜͷ American Set Theory ʹର͢Δ dis Γ۩߹ΛຯΘ͏ʢpp.67ʣ •

    American Set Theory ͷ࿈த͸ࣙॻࣜॱং΋஌ΒΜౕΒ͡Όɻ ނʹ "most packed to the left" ͱ͔ݴ͍ͳ͕Βӈ͔Βൺֱ͓ͯ͠Δͷ͡Όɻ 4. Ұൠͷ௚ੵʹ͓͚Δʮॱংʯ (0, 1, 1, 0, 1, 1, 1, 0, 1, 1, 1, 1) > (0, 1, 1, 1, 0, 1, 1, 0, 1, 1, 1, 1) s8 t8 > C Major C minor ࣙॻࣜॱংͱ͸ٯͷ݁Ռ
  31. • American Set Theory ͸ࠞཚ͍ͯ͠Δʂʂʂ • Forte, Allen. (1973). The

    Structure of Atonal Music => packed from the left • Rahn, John. (1980). Basic Atonal Theory => packed from the right • Straus, Joseph N. (1990). Introduction to Post-Tonal Theory => packed from the right • Mazzola ઌੜ͕Ҿ༻͍ͯ͠Δ [180] ͸ Straus 1990 4. Ұൠͷ௚ੵʹ͓͚Δʮॱংʯ https://www.mta.ca/pc-set/pc-set_new/pages/sources/sources.html
  32. େ·͔ͳྲྀΕ 1. ಋೖɿؔ਺ͷू߹ʢ഑ஔू߹ʣ§5.0 2. ௚ੵʢ௚࿨ʣͱࣹӨɾؔ਺ͷؔ܎ §5.2, 5.3 3. ௚ੵΛू߹ 2

    ݸ͔Β N ݸ΁֦ு §5.6 4. Ұൠͷ௚ੵʹ͓͚Δʮॱংʯ §5.6 5. ႈू߹ͷه๏ 2a ͷҙຯ §5.4, 5.5ʢ͓·͚ʣ
  33. • Example 13 • c = { 0, 1 }

    ͱͯ͠ɺԻ͕৐͍ͬͯΔηϧ͕ 0ɺ৐͍ͬͯͳ͍ηϧ͕ 1 • ࡞ۂͱ͸ؔ਺ f : a × b → { 0, 1 } ͰϞσϧԽͰ͖Δ 5. ႈू߹ͷه๏ 2a ͷҙຯ ```python def f(a1, b1): if (a1, b1) == (3, 5): return 0 # do stuff return 1 ``` a b
  34. • Example 13 • ผͷϞσϧԽͱͯ͠ɺa ͷ஋Λड͚औͬͯʮb ͷ஋Λड͚औͬͯ c Λฦؔ͢਺ʯΛฦؔ͢਺ g

    5. ႈू߹ͷه๏ 2a ͷҙຯ a b ```python def g(a1): def b_to_c(b1): if (a1, b1) == (3, 5): return 0 # do stuff return 1 return b_to_c ```
  35. • f(3, 5) == g(3)(5) == 0 • ͲͪΒ΋݁Ռ͸ಉ͡ =>

    f Λ g ͷܗ΁ҰରҰม׵Ͱ͖Δؔ਺͕ଘࡏ͢ΔͷͰ͸ʁ 5. ႈू߹ͷه๏ 2a ͷҙຯ ```python def g(a1): def b_to_c(b1): if (a1, b1) == (3, 5): return 0 # do stuff return 1 return b_to_c ``` ```python def f(a1, b1): if (a1, b1) == (3, 5): return 0 # do stuff return 1 ```
  36. • ౴ɿఆཧ 3ʢႈͷීวੑʣ શ୯ࣹͱͳΔؔ਺ δ : Set(a × b, c)

    → Set(a, cb) ͕ଘࡏ 5. ႈू߹ͷه๏ 2a ͷҙຯ ```python def delta(f1): def take_a(a1): def take_b(b1): return f1(a1, b1) return take_b return take_a ``` ```python def f(a1, b1): if (a1, b1) == (3, 5): return 0 # do stuff return 1 ```
  37. • Example 14ɿ࿨ԻΛ਺ֶతʹදݱ͢Δ • 12 Իͷू߹ P = { p0,

    p1, ..., p12 } • ࿨Ի ch ͱ͸ ch ⊂ P Ͱ͋Γ ch ∈ 2P Ͱ΋͋Δʢe.g. C Major { c, e, g } = { p0, p4, p7 }ʣ 5. ႈू߹ͷه๏ 2a ͷҙຯ
  38. • Example 14ɿ࿨ԻΛ਺ֶతʹදݱ͢Δ • 12 Իͷू߹ P = { p0,

    p1, ..., p12 } • ࿨Ի ch ͱ͸ ch ⊂ P Ͱ͋Γ ch ∈ 2P Ͱ΋͋Δʢe.g. C Major { c, e, g } = { p0, p4, p7 }ʣ • ผͷݟํͱͯ͠ɺP → { 0, 1 } ͷʮؔ਺ʯͦΕࣗମΛ࿨ԻͱಉҰࢹ 5. ႈू߹ͷه๏ 2a ͷҙຯ ```python def c_major(pitch): if pitch in [p0, p4, p7]: return 0 return 1 ``` ```python def c_minor(pitch): if pitch in [p0, p3, p7]: return 0 return 1 ```
  39. 5. ႈू߹ͷه๏ 2a ͷҙຯ ```python def chi(ch): def chord_as_func(pitch): if

    pitch in ch: return 0 return 1 return chord_as_func ``` ```python ch = [p0, p4, p7] def c_major(pitch): if pitch in [p0, p4, p7]: return 0 return 1 ``` • ౴ɿఆཧ 4ʢ෦෼ର৅෼ྨࢠ subobject classifierʣ શ୯ࣹͱͳΔؔ਺ χ : 2a → Set(a, 2) ͕ଘࡏ ͨͩ͠ 2 := { 0, 1 } Ͱɺ͜ΕΛ෦෼ର৅෼ྨࢠʢݍ࿦༻ޠʣͱݺͿ
  40. • ͭ·Γ 2a ͱ͸ɺa ͷ෦෼ू߹Λ 2 := { 0, 1

    } ΁ૹΔؔ਺ͷू߹ʢ഑ஔू߹ʣ • P.43 Lemma 1 ΍ P.52 Example 2 Λࢀর • 0 := ∅ • 1 := 0+ = 0 ∪ { 0 } = ∅ ∪ { ∅ } = { ∅ } = { 0 } • 2 := 1+ = 1 ∪ { 1 } = { ∅ } ∪ { { ∅ } } = { ∅, { ∅ } } = { 0, { 0 } } = { 0, 1 } 5. ႈू߹ͷه๏ 2a ͷҙຯ