construct.percussion_note — Abjad v1.1.1 documentation

### Navigation

- index
- modules |
- next |
- previous |
- Project Abjad »
- Abjad v1.1.1 documentation »
- Abjad API »

# construct.percussion_note

`abjad.tools.construct.` `percussion_note`(pitch, total_duration, max_note_duration=(1, 8))

  Returns a list containing a single Note and possibly a succession of Rests, depending on the values given to the duration arguments. The duration of the note returned is always smaller or equal to max_note_duration. The total duration of the rests returned is the difference between total_duration and the duration of the note returned. Rests are used to pad the duration of the note to fit the total_duration if the total_duration will result in tied Notes. Useful for percussion music where the duration of the attack is negligible and you don’t want tied notes.

  - pitch can be any pitch token.
  - total_duration is the duration resulting from the sum of the durations of the objects returned.
  - max_note_duration is the maximum duration that the note returned will have.

  Examples:

      abjad> percussion_note(2, (1, 4), (1, 8))
      [Note(d', 8), Rest(8)]

      abjad> percussion_note(2, (1, 64), (1, 8))
      [Note(d', 64)]

      abjad> percussion_note(2, (5, 64), (1, 8))
      [Note(d', 16), Rest(64)]

      abjad> percussion_note(2, (5, 4), (1, 8))
      [Note(d', 8), Rest(1), Rest(8)]

### Navigation

- index
- modules |
- next |
- previous |
- Project Abjad »
- Abjad v1.1.1 documentation »
- Abjad API »