vault backup: 2025-12-19 08:02:33

This commit is contained in:
2025-12-19 08:02:33 -05:00
parent a561aaf128
commit 3ae6edeb65
+48
View File
@@ -0,0 +1,48 @@
---
id:
aliases: []
title: "2025-12-19"
tags:
- authorship/original
- destiny/permanent
- status/draft
- type/daily
---
# 2025-12-19
## 2025-12-19 06:22
PowerShell module to assist in translating between banjo fingerings and concert notes,
as well as between [[lilypond]] and conventional notation.
```powershell
$Db4 = [Note]::FromLilyPond("des'")
$Db4.PlayInTime(1/4,120)
$str1 = [FrettedStringTuning]::FromOpen([Note]::FromLilyPond("d,,,"))
$str1c2 = $str1.Capo(2)
$openGtuning = [FrettedStringInstrumentTuning]::FromStringTunings(@(
[FrettedStringTuning]::FromOpen([Note]::FromLilyPond("d,,,")),
[FrettedStringTuning]::FromOpen([Note]::FromLilyPond("b,,")),
[FrettedStringTuning]::FromOpen([Note]::FromLilyPond("g,")),
[FrettedStringTuning]::FromOpen([Note]::FromLilyPond("d")),
[FrettedStringTuning]::FromOpen([Note]::FromLilyPond("g'")),
# note: the notation used above is concert octave,
# banjo is transposed up one octave.
))
$openGtuning.GetNoteFromFingering(4,11).PlayInTime(1/4,120) # play Db4
$openGc2tuning = $openGtuning.Capo(2)
$openGc2tuning.GetNoteFromFingering(4,9).PlayInTime(1/4,120) # play Db4
# TODO: class FrettedStringInstrument
```
```powershell
class Note {
[Note] TransposeOctave([Note]$note1,[Note]$note2) {}
[Note] TransposeOctave([int]$modifier) {}
}
```