Re: fingerings added to tabs?

2015-12-01 Thread Blöchl Bernhard

Am 01.12.2015 20:05, schrieb David Kastrup:

Blöchl Bernhard  writes:


Am 01.12.2015 18:55, schrieb David Kastrup:

BB  writes:

Exactly like the manual describes adding fingerings.

It is irritating that they are not printed by default.  I'm not sure
what the rationale for that is.


I tried it this way, as the manual describes:

%%%
\new TabStaff \relative c' {
  a,8 a'-2  a-2
  d,8 a'-2  a-2
}
%%%

What is wrong?


Uh, the fingerings are not printed?  Are you confusing fret numbers 
with
fingerings?  The fret numbers are calculated as 2 for your a' notes, 
but

that has nothing whatsoever to do with the -2 fingering you add to the
notes.  You could write -4 and get the same result.




Are you confusing fret numbers with
fingerings?

No I DO NOT!
I have explained distictively what I expect and illustrated by an added 
example graphics.


To avoid any confusion with fret number and fingering, check this code:

%%%
\new TabStaff \relative c' {
  a,8-1  a'-2  a-1
  d,8-2 a'-3  a-2
}
%%%

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: fingerings added to tabs?

2015-12-01 Thread Thomas Morley
2015-12-01 22:44 GMT+01:00 Blöchl Bernhard :

> I have explained distictively what I expect and illustrated by an added
> example graphics.
>
> To avoid any confusion with fret number and fingering, check this code:
>
> %%%
> \new TabStaff \relative c' {
>   a,8-1  a'-2  a-1
>   d,8-2 a'-3  a-2
> }
> %%%



Maybe you mean something like:

\new TabStaff
\new TabVoice \with {
\consists "New_fingering_engraver"
\consists "Fingering_engraver"
fingeringOrientations = #'(up)
\override Fingering.side-axis = #Y
\override Fingering.outside-staff-priority = #200
} \relative c' {
  a,8-1  a'-2  a-1
  d,8-2 a'-3  a-2
}


If so, you're explanations could have been better:
Ok, the image helped, but "check this code" without adding what you
have expected will not likely get you many helpful answers.
Usually, a TabStaff _is_ the fingering, thus the confusion.

Cheers,
  Harm

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: aligning melisma and non-melisma lyrics across staves in the same system

2015-12-01 Thread Thomas Morley
Hi Kieren,

2015-12-01 16:13 GMT+01:00 Kieren MacMillan :

>> The problem is how to test equality?
>> For strings it's trivial
>
> Is that already implemented?

No

>> but LyricText also allows for markup.
>
> Is there a markup->string function?

Yep, though look at the output of:

#(write-me "markup->string "
  (markup->string
  #{
\markup
  \with-dimensions #'(-1 . 1) #'(-1 . 1)
  \with-color #blue
  "xy"
  #}))

It returns an empty string.
with-color-markup is not considered by markup->string, worth a
bug-report, I'd say, and quite easily to fix
Though, for with-dimensions-markup some more work would be needed.
Markup-commands with more than two arguments are not considered at
all.

At any rate markup->string feels more than a workaround, which may
give results in a large amount of cases, but not for all.


Continuing coding/thinking,
  Harm

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: aligning melisma and non-melisma lyrics across staves in the same system

2015-12-01 Thread Thomas Morley
Hi Kieren,

2015-12-01 21:18 GMT+01:00 Thomas Morley :
[...]
> Continuing coding/thinking,
>   Harm

here the last version. Several comments inline.
The syllables are compared via the length of their stencil-extents.
Ofcourse this has disadvantages as said before and even some more.

However, please test, to tired to continue...

Cheers,
  Harm
\version "2.19.32"

%
%% CUSTOM-GROB-PROPERTY
%

#(define (define-grob-property symbol type? description)
  (if (not (equal? (object-property symbol 'backend-doc) #f))
  (ly:error (_ "symbol ~S redefined") symbol))

  (set-object-property! symbol 'backend-type? type?)
  (set-object-property! symbol 'backend-doc description)
  symbol)
  
#(define my-custom-grob-properties
  `(
(align-to-melisma ,boolean? "Should LyricText be aligned to other LyricText
being in melisma?")
   ))
   
#(define (acknowledge-my-grob-properties lst)
  (for-each (lambda (x) (apply define-grob-property x)) lst))

#(acknowledge-my-grob-properties my-custom-grob-properties)

%
%% ENGRAVER
%

#(define (align-to-melisma-engraver ctx)
"
To be put in Score-context.
Collects all Voices, gets knowledge whether a melisma is active.
If a melisma is active, every selected LyricText's `self-alignment-X' is set to 
the value of `lyricMelismaAlignment' unless `align-to-melisma' is set #f.
Selection is done comparing the stencil-lengths.
"
   (let ((voices '())
 ;; currently not needed:
 ;(lyrics '())
 (lyric-texts '())
 (melisma? #f))
 `(
   (acknowledgers
 (lyric-syllable-interface
  . ,(lambda (engraver grob source-engraver)
   (let* (;; get `lyricMelismaAlignment', this value is used later
  ;; to set all selected grob's 'self-alignment-X to it
  (lyric-melisma-alignment 
(ly:context-property ctx 'lyricMelismaAlignment))
  ;; `align-to-melisma?' may be set false, for manual
  ;; settings 
  (align-to-melisma? 
(ly:grob-property grob 'align-to-melisma #t))
 here the problem starts
 a bunch of stencils is created just to compare their lengths to the actual 
 one, then thrown away :((
 TODO: how to do it different?
   comparing strings, will fail for markups, markup->string is not 
   sufficient.
   But, comparing the stencil-length, as done here, will probably 
   return false-true for some cases.
  
   However, manual inserting other values for`self-alignment-X' is 
   still possible in combination with `align-to-melisma' set #f
  (lyric-texts-stencil-x-lengths
(sort
  (map
(lambda (e)
  (interval-length 
(ly:stencil-extent 
  (grob-interpret-markup grob e) 
  X)))
lyric-texts)
<))
  (actual-stencil-length
(interval-length 
  (ly:stencil-extent 
(ly:grob-property grob 'stencil) 
X)))
  ;; align, when the actual stencil-length is present
  ;; more than once in `lyric-texts-stencil-x-lengths'
  ;; TODO find a less clumsy method
  (should-be-aligned
(let ((sub-lst
(member 
  actual-stencil-length 
  lyric-texts-stencil-x-lengths)))
  (and (not (null? sub-lst))
   (not (null? (cdr sub-lst)))
   (= (car sub-lst) (cadr sub-lst))
   
 ;; align selected grobs
 (if (and melisma? align-to-melisma? should-be-aligned)
 (ly:grob-set-property! 
   grob 'self-alignment-X lyric-melisma-alignment))
  
   (listeners
 ;; get all syllables at current time-step, so `acknowledgers' can work
 ;; on the complete(!) list, which is called `lyric-texts'
 ;; `lyric-texts' will be cleared before moving on to next time-step
 ;; see `stop-translation-timestep'
 (lyric-event
   .
   ,(lambda (engraver event)
  (let ((syllable-text (ly:event-property event 'text)))
(set! lyric-texts (cons syllable-text lyric-texts)
 ;; get all Voices:
 ;; collect all contexts, filter for Voices, 
 ;;(re-)set local variable `voices'
 

Re: fingerings added to tabs?

2015-12-01 Thread BB
Thank you for the links and help. I think I caused some misunderstanding 
with my original question text.


To demonstrate what I want I send a graphic as an attachement as an 
example. (I do not own the rights!)


Usually with guitar as a rule it is sayed a finger per fret. So the fret 
numbers mostly are similar to the fret numbers. With bass that is 
different because of the larger scale. There the fret number is not 
similar to the fingering. (Well, there are exeptions with guitar as 
well.) As an example, there are three fingering patterns for a scale 
with bass. That patterns repeat because of the symmetric tuning. (c 
scale -> root with 1st finger, 2nd finger, 4th finger).


I would argue that this is true for double bass as well and fingering 
numbers could make sense, at least in some cases.

(double bass scale length 109 cm, bass long scale 86 cm)

For some beginner bass tabs I would like to add (left hand) fingerings 
not to the notes, but to the tabs and omit the notes completely. The 
tabs should mostly demonstrate the fingering patterns (without notes) to 
examplify the repeating patterns (beside the notes).


How can I do fingering to tabs (notes ommited)?

Kind regards



On 01.12.2015 17:22, David Kastrup wrote:

BB  writes:


>How can I add fingerings to tabs?
>(Not found in the manual)


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: fingerings added to tabs?

2015-12-01 Thread David Kastrup
BB  writes:

> Thank you for the links and help. I think I caused some
> misunderstanding with my original question text.
>
> To demonstrate what I want I send a graphic as an attachement as an
> example. (I do not own the rights!)
>
> Usually with guitar as a rule it is sayed a finger per fret. So the
> fret numbers mostly are similar to the fret numbers. With bass that is
> different because of the larger scale. There the fret number is not
> similar to the fingering. (Well, there are exeptions with guitar as
> well.) As an example, there are three fingering patterns for a scale
> with bass. That patterns repeat because of the symmetric tuning. (c
> scale -> root with 1st finger, 2nd finger, 4th finger).
>
> I would argue that this is true for double bass as well and fingering
> numbers could make sense, at least in some cases.
> (double bass scale length 109 cm, bass long scale 86 cm)
>
> For some beginner bass tabs I would like to add (left hand) fingerings
> not to the notes, but to the tabs and omit the notes completely. The
> tabs should mostly demonstrate the fingering patterns (without notes)
> to examplify the repeating patterns (beside the notes).
>
> How can I do fingering to tabs (notes ommited)?

Exactly like the manual describes adding fingerings.

It is irritating that they are not printed by default.  I'm not sure
what the rationale for that is.

\relative
\new TabStaff \with {
  stringTunings = #bass-tuning
}
\new TabVoice \with {
  \consists "Fingering_engraver"
  \consists "New_fingering_engraver"
}
{
  \set minimumFret = 5
  \set restrainOpenStrings = ##t
  a,,4-1 c8-4 d-1 e-3 g-1 a4-3
  a4-3 g8-1 e-3 d-1 c-4 a4-1
}



-- 
David Kastrup
___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: fingerings added to tabs?

2015-12-01 Thread Blöchl Bernhard

Thanks for the code.
Just now I am on a PC with LP version 16.2 only. I am on a PC with 
version 19 some hours later. With version 16 I get errors with the 3 
lines, red in


\override Fingering.side-axis = #Y
\override Fingering.outside-staff-priority = #200
\relative c' {

Messages (sorry, in German)

/tmp/frescobaldi-xjZ9Dx/tmpiOk7H4/document.ly:10:23: Fehler: syntax 
error, unexpected '.', expecting SCM_FUNCTION or SCM_IDENTIFIER or 
SCM_TOKEN

\override Fingering
   .side-axis = #Y
/tmp/frescobaldi-xjZ9Dx/tmpiOk7H4/document.ly:11:4: Fehler: syntax 
error, unexpected \override


\override Fingering.outside-staff-priority = #200
/tmp/frescobaldi-xjZ9Dx/tmpiOk7H4/document.ly:12:10: Fehler: falscher 
Typ für Argument 2; music erwartet, "c" gefunden

\relative
  c' {
/tmp/frescobaldi-xjZ9Dx/tmpiOk7H4/document.ly:12:11: Fehler: syntax 
error, unexpected '\''

\relative c
   ' {
/tmp/frescobaldi-xjZ9Dx/tmpiOk7H4/document.ly:12:13: Fehler: Fehler 
gefunden, musikalischer Ausdruck wird ignoriert

\relative c'
 {
schwerer Fehler: gescheiterte Dateien: 
"/tmp/frescobaldi-xjZ9Dx/tmpiOk7H4/document.ly"

Wurde mit dem Return-Code 1 beendet

Thanks anyway.




\override Fingering.side-axis = #Y
\override Fingering.outside-staff-priority = #200
} \relative c' {


Am 01.12.2015 23:30, schrieb Thomas Morley:
2015-12-01 22:44 GMT+01:00 Blöchl Bernhard 
:


I have explained distictively what I expect and illustrated by an 
added

example graphics.

To avoid any confusion with fret number and fingering, check this 
code:


%%%
\new TabStaff \relative c' {
  a,8-1  a'-2  a-1
  d,8-2 a'-3  a-2
}
%%%




Maybe you mean something like:

\new TabStaff
\new TabVoice \with {
\consists "New_fingering_engraver"
\consists "Fingering_engraver"
fingeringOrientations = #'(up)
\override Fingering.side-axis = #Y
\override Fingering.outside-staff-priority = #200
} \relative c' {
  a,8-1  a'-2  a-1
  d,8-2 a'-3  a-2
}


If so, you're explanations could have been better:
Ok, the image helped, but "check this code" without adding what you
have expected will not likely get you many helpful answers.
Usually, a TabStaff _is_ the fingering, thus the confusion.

Cheers,
  Harm


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: fingerings added to tabs?

2015-12-01 Thread Blöchl Bernhard

Am 01.12.2015 18:55, schrieb David Kastrup:

BB  writes:

Exactly like the manual describes adding fingerings.

It is irritating that they are not printed by default.  I'm not sure
what the rationale for that is.


I tried it this way, as the manual describes:

%%%
\new TabStaff \relative c' {
  a,8 a'-2  a-2
  d,8 a'-2  a-2
}
%%%

What is wrong?

Regards

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: fingerings added to tabs?

2015-12-01 Thread David Kastrup
Blöchl Bernhard  writes:

> Am 01.12.2015 18:55, schrieb David Kastrup:
>> BB  writes:
>>
>> Exactly like the manual describes adding fingerings.
>>
>> It is irritating that they are not printed by default.  I'm not sure
>> what the rationale for that is.
>
> I tried it this way, as the manual describes:
>
> %%%
> \new TabStaff \relative c' {
>   a,8 a'-2  a-2
>   d,8 a'-2  a-2
> }
> %%%
>
> What is wrong?

Uh, the fingerings are not printed?  Are you confusing fret numbers with
fingerings?  The fret numbers are calculated as 2 for your a' notes, but
that has nothing whatsoever to do with the -2 fingering you add to the
notes.  You could write -4 and get the same result.

-- 
David Kastrup

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


brainstorming a way to temporarily flip direction of lyrics

2015-12-01 Thread Kieren MacMillan
Hello all,

We can temporarily change the direction of many grobs — Scripts, TextScripts, 
etc. — such that the usual effect is that they flip from being (e.g.,) beneath 
a context (e.g., the Staff that the Voice is a child of) to being above that 
context.

I’m wondering — brainstorming mode now — if there’s an easy way to extend that 
concept to contexts which ARE NOT contained by another context (as in the Voice 
∈ Staff example, above), but rather are adjacent to a second context. One 
obvious example is:

<<
\new Staff \someNotes
\new Lyrics \someWords
>>

If there were a small number of words that needed to be above the Staff, the 
current workaround is to add a whole new context, e.g.,

<<
\new Lyrics \someWordsAbove
\new Staff \someNotes
\new Lyrics \someWordsBelow
>>

adjust staff-affinity/ies and add spacer rests as/if necessary, etc. Why 
[technically] can we not say, “\once \override LyricText.alignAboveContext = …” 
to move the attachment of that grob to “the other side” of the Staff context it 
is normally associated with and adjacent to.

A logical extension of this feature would be in a centered context like

\new PianoStaff <<
\new Staff \rhMusic
\new Dynamics \dynamics
\new Staff \lhMusic
>>

allowing the “flipping” of dynamics above the upper Staff or below the lower 
Staff [without resorting to two extra Dynamics contexts].

Thanks,
Kieren.


Kieren MacMillan, composer
‣ website: www.kierenmacmillan.info
‣ email: i...@kierenmacmillan.info


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: brainstorming a way to temporarily flip direction of lyrics

2015-12-01 Thread David Kastrup
Kieren MacMillan  writes:

> Hello all,
>
> We can temporarily change the direction of many grobs — Scripts, TextScripts, 
> etc. — such that the usual effect is that they flip from being (e.g.,) 
> beneath a context (e.g., the Staff that the Voice is a child of) to being 
> above that context.
>
> I’m wondering — brainstorming mode now — if there’s an easy way to extend 
> that concept to contexts which ARE NOT contained by another context (as in 
> the Voice ∈ Staff example, above), but rather are adjacent to a second 
> context. One obvious example is:
>
> <<
> \new Staff \someNotes
> \new Lyrics \someWords
> >>
>
> If there were a small number of words that needed to be above the Staff, the 
> current workaround is to add a whole new context, e.g.,
>
> <<
> \new Lyrics \someWordsAbove
> \new Staff \someNotes
> \new Lyrics \someWordsBelow
> >>
>
> adjust staff-affinity/ies and add spacer rests as/if necessary,
> etc. Why [technically] can we not say, “\once \override
> LyricText.alignAboveContext = …” to move the attachment of that grob
> to “the other side” of the Staff context it is normally associated
> with and adjacent to.

Because there is only one VerticalAxisGroup associated with the
context.  You can try creating a SubLyrics context and then to a
\change Lyrics = ... command for moving it into another Lyrics context.

-- 
David Kastrup

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Slap tongue for flute

2015-12-01 Thread Luca Danieli
Hello,
the flute slap notation snippet at the following page doesn't work anymore I 
guess, as in my Lilypond 2.18.2 does 
nothing.http://www.lilypond.org/doc/v2.19/Documentation/snippets/winds
Can someone help me in achieving this notehead?
Luca  ___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Slap tongue for flute

2015-12-01 Thread David Kastrup
Luca Danieli  writes:

> Hello,
> the flute slap notation snippet at the following page doesn't work
> anymore I guess, as in my Lilypond 2.18.2 does
> nothing.http://www.lilypond.org/doc/v2.19/Documentation/snippets/winds
> Can someone help me in achieving this notehead?

Using the documentation for version 2.19.32 is not likely to always work
with version 2.18.2.  Try consulting the documentation coming with your
version of LilyPond, or substitute the v2.19 in that link with v2.18 in
order to get a version suitable for your setup from the online
documentation.

-- 
David Kastrup

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Slap tongue for flute

2015-12-01 Thread Thomas Morley
2015-12-01 20:16 GMT+01:00 David Kastrup :
> Luca Danieli  writes:
>
>> Hello,
>> the flute slap notation snippet at the following page doesn't work
>> anymore I guess, as in my Lilypond 2.18.2 does
>> nothing.http://www.lilypond.org/doc/v2.19/Documentation/snippets/winds
>> Can someone help me in achieving this notehead?
>
> Using the documentation for version 2.19.32 is not likely to always work
> with version 2.18.2.  Try consulting the documentation coming with your
> version of LilyPond, or substitute the v2.19 in that link with v2.18 in
> order to get a version suitable for your setup from the online
> documentation.
>
> --
> David Kastrup
>


Or use the one from LSR (the LSR runs 2.18.2)
http://lsr.di.unimi.it/LSR/Item?id=518

Cheers,
  Harm

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


printing individual parts causes the whole score to print too

2015-12-01 Thread Ryan Michael
So I have the following seperate .ly file:

\include "eiertanz-1.ly"

\header {
  instrument = "Violin"
}

{
 \violinOne
}

Which prints the variable which points to the *Voice* violinOne defined in "
eiertanz-1.ly"

however the whole score prints and then the single voice is printed. How
Can I only print the violin part?

Here is the skeleton of eiertanz-1.ly


global= {

  \key c \major
}

\header{
title = "My thing piece"
composer = ""
   }



violinOne = \new Voice {


}
cello = \new Voice {
  % etc%
}


\score {
  \new StaffGroup <<
\new Staff << \global \violinOne >>
\new Staff << \global \cello >>
  >>
  \layout { }
  \midi { }
}

-- 
ॐ नमः शिवाय
___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: printing individual parts causes the whole score to print too

2015-12-01 Thread Richard Shann
On Tue, 2015-12-01 at 00:38 -0800, Ryan Michael wrote:
> So I have the following seperate .ly file: 
> 
> 
> \include "eiertanz-1.ly"
> 
> 
> \header {
>   instrument = "Violin"
> }
> 
> 
> {
>  \violinOne
> }
> 
> 
> Which prints the variable which points to the Voice violinOne defined
> in "eiertanz-1.ly"
> 
> 
> however the whole score prints and then the single voice is printed.
> How Can I only print the violin part? 

You would need to take the \score {} out of eirertanz-1.ly as that is
telling LilyPond to typeset the score.

Richard
> 
> 
> Here is the skeleton of eiertanz-1.ly
> 
> 
> 
> 
> global= {
>  
>   \key c \major
> }
> 
> 
> \header{
> title = "My thing piece"
> composer = ""
>}
> 
> 
> 
> 
> 
> 
> violinOne = \new Voice {
> 
> 
> 
> 
> }
> cello = \new Voice {
>   % etc%
> }
> 
> 
> 
> 
> \score {
>   \new StaffGroup <<
> \new Staff << \global \violinOne >>
> \new Staff << \global \cello >>
>   >>
>   \layout { }
>   \midi { }
> }
> 
> 
> -- 
> ॐ नमः शिवाय
> ___
> lilypond-user mailing list
> lilypond-user@gnu.org
> https://lists.gnu.org/mailman/listinfo/lilypond-user



___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


accidentals for just intonation

2015-12-01 Thread N. Andrew Walsh
Hi List,

this is a somewhat specialist request, and more of a long-term project, but
I'm hoping you nice people can help me with something I'd like to do with
Lily someday.

If you've been watching the OpenLilyLib repository, you'll see that Urs has
been working on a set of tools for rendering music in just intonation. He
(quite modestly) says that it isn't ready for production, but there are
already some impressive things it can do: for one, the interface allows to
input a fraction and get back a nearest-semitone pitch with a deviation in
cents *automatically*, which is something the commercial programs don't
offer in any way (every composer I know who works with JI just inputs text
entries manually for every note, with no change in, for example, MIDI
output for ability to handle transpositions).

There's something I'd very much like to do with this, largely out of my own
(admittedly rather opinionated) view on the best means of producing
accidentals for just intonation. I'm going to assume some familiarity with
just intonation concepts, but (in short) it works like this: the
relationship between two pitches is defined in terms of the frequency
relationship, given usually as a fraction. For example, the interval of a
perfect fifth may be rendered as 3/2: that is, if I play notes with base
frequencies of 200 and 300Hz, we hear them as a (very purely tuned) fifth.
The equal-tempered one you have on a piano (ie, 7 semitones) is about two
1/100th of a semitone (called "cents" logically enough) too narrow to be
pure (ie, a 3/2 fifth is about 702 cents).

Here's my thing: I believe that the most appropriate type of accidental for
such a system is one that reflects the harmonic ratio, not the number of
steps on a scale. Flats and sharps tell us whether a pitch is lowered or
raised from its "natural" position in the scale, and just intonation
doesn't have those positions. So, I designed accidentals that graphically
reflect the harmonic ratio between a note and the tonic.

I'd like to be able to put these into Lily, and Urs tells me it can be done
by calling a draw function to draw a path. I can relatively easily make up
some paths with Inkscape and save them as SVGs, but is there a better way
to do this? The NR describes (here:
http://lilypond.org/doc/v2.19/Documentation/notation/formatting-text#graphic-notation-inside-markup)
the means to include eps files into a markup, which presumably could be
used to replace the accidental.

There are some potential complicating factors here. First, the accidentals
I use change depending on the prime factorization of the ratio involved:
for example, the ratio 9/8 (a type of whole tone) would comprise two of the
symbol for 3 (because "9/8" is really "(3*3)/8" ), which means that Urs'
interface for JI ratios would need an add-on to do prime factorization of
the ratios (which is also computationally intensive, even for relatively
simple numbers) or a means to encode ratios as lists of primes that are
then calculated to return the value in cents (that is, do the process in
reverse, starting from "(3*3)/8" and getting 9/8, which might be easier to
do).

The advantage here, though, would be this: one of the interesting things
about just intonation is that there is no theoretical limit to what kinds
of ratios you use. You could theoretically have unique signs for all the
primes you want, and then the draw function could build them on the fly.
The accidentals become modular, scaling to whatever level of complexity the
composer wants. Harry Partch writes music that tops out at the 13th
overtone, but La Monte Young has pieces with primes in the upper 300s.

So, List: this is, as I said, a somewhat long-term project, but would any
of you be willing to help me learn/do the programming necessary to develop
a system like this? I also have in mind a more general add-on to the OLL
just-intonation library: I'd like to see a set of different .ily files,
each with different sets of accidentals, which a composer could \include
into the score as needed. For example, I could write the ratios using my
system, or use a system that shows accidentals approximated to the nearest
12th-tone, with cents deviation for more exact tuning (which might be of
more relevance to keyed instruments).

I can send a few hand-drawn mock-ups of the accidentals to show what I
mean; I've been doing them by hand, but I'd really like to see them
engraved.

Thanks for the help.

Cheers,

A
___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: accidentals for just intonation

2015-12-01 Thread Urs Liska


Am 01.12.2015 um 10:10 schrieb N. Andrew Walsh:
> Hi List,
>
> this is a somewhat specialist request, and more of a long-term
> project, but I'm hoping you nice people can help me with something I'd
> like to do with Lily someday.
>
> If you've been watching the OpenLilyLib repository, you'll see that
> Urs has been working on a set of tools for rendering music in just
> intonation. He (quite modestly) says that it isn't ready for production,

Well, it isn't ...

> but there are already some impressive things it can do: for one, the
> interface allows to input a fraction and get back a nearest-semitone
> pitch with a deviation in cents *automatically*, which is something
> the commercial programs don't offer in any way (every composer I know
> who works with JI just inputs text entries manually for every note,
> with no change in, for example, MIDI output for ability to handle
> transpositions). 
>

Yes, I also find this exciting prospects, and I don't expect the
limitations there are so far to be really problematic. But basically you
can now use the functionality to produce individual notes, in a
monophonic context.
Probably it will be more clear once the second and third part of my
latest blog post are out.

> There's something I'd very much like to do with this, largely out of
> my own (admittedly rather opinionated) view on the best means of
> producing accidentals for just intonation. I'm going to assume some
> familiarity with just intonation concepts, but (in short) it works
> like this: the relationship between two pitches is defined in terms of
> the frequency relationship, given usually as a fraction. For example,
> the interval of a perfect fifth may be rendered as 3/2: that is, if I
> play notes with base frequencies of 200 and 300Hz, we hear them as a
> (very purely tuned) fifth. The equal-tempered one you have on a piano
> (ie, 7 semitones) is about two 1/100th of a semitone (called "cents"
> logically enough) too narrow to be pure (ie, a 3/2 fifth is about 702
> cents). 
>
> Here's my thing: I believe that the most appropriate type of
> accidental for such a system is one that reflects the harmonic ratio,
> not the number of steps on a scale. Flats and sharps tell us whether a
> pitch is lowered or raised from its "natural" position in the scale,
> and just intonation doesn't have those positions. So, I designed
> accidentals that graphically reflect the harmonic ratio between a note
> and the tonic. 
>
> I'd like to be able to put these into Lily, and Urs tells me it can be
> done by calling a draw function to draw a path. I can relatively
> easily make up some paths with Inkscape and save them as SVGs, but is
> there a better way to do this? The NR describes
> (here: 
> http://lilypond.org/doc/v2.19/Documentation/notation/formatting-text#graphic-notation-inside-markup)
> the means to include eps files into a markup, which presumably could
> be used to replace the accidental.

That's not exactly what I meant. I was rather thinking of the \path
command on http://lilypond.org/doc/v2.19/Documentation/notation/graphic
and have LilyPond *generate* the paths on-the-fly. This will make the
modularity of your accidentals pretty straightforward to achieve.

But I don't have significant experience with paths (although I'd be very
interested in learning), others have done more on the topic, and I think
there are quite some helper tools and functionality already availabe
that I can't point you to.

>
> There are some potential complicating factors here. First, the
> accidentals I use change depending on the prime factorization of the
> ratio involved: for example, the ratio 9/8 (a type of whole tone)
> would comprise two of the symbol for 3 (because "9/8" is really
> "(3*3)/8" ), which means that Urs' interface for JI ratios would need
> an add-on to do prime factorization of the ratios (which is also
> computationally intensive, even for relatively simple numbers) or a
> means to encode ratios as lists of primes that are then calculated to
> return the value in cents (that is, do the process in reverse,
> starting from "(3*3)/8" and getting 9/8, which might be easier to do).
>
> The advantage here, though, would be this: one of the interesting
> things about just intonation is that there is no theoretical limit to
> what kinds of ratios you use. You could theoretically have unique
> signs for all the primes you want, and then the draw function could
> build them on the fly. The accidentals become modular, scaling to
> whatever level of complexity the composer wants. Harry Partch writes
> music that tops out at the 13th overtone, but La Monte Young has
> pieces with primes in the upper 300s. 
>
> So, List: this is, as I said, a somewhat long-term project, but would
> any of you be willing to help me learn/do the programming necessary to
> develop a system like this? I also have in mind a more general add-on
> to the OLL just-intonation library: I'd like to see a set of different
> .ily files, each 

Re: printing individual parts causes the whole score to print too

2015-12-01 Thread Xavier Scheuer
On 1 December 2015 at 09:38, Ryan Michael  wrote:
>
> So I have the following seperate .ly file:
>
> \include "eiertanz-1.ly"
>
> \header {
>   instrument = "Violin"
> }
>
> {
>  \violinOne
> }
>
> Which prints the variable which points to the Voice violinOne defined
> in "eiertanz-1.ly"
>
> however the whole score prints and then the single voice is printed.
> How Can I only print the violin part?
>
> Here is the skeleton of eiertanz-1.ly
>
> (snip)
>

Hi,

Don't put the \score bloc in "eiertanz-1.ly".

Instead put only your variables "global", "violinOne", "cello" and then
use for instance a file named "eiertanz-1-score.ly" that includes
"eiertanz-1.ily" and contains the \score block for the whole score.
And another file "eiertanz-1-violin1.ly" that also includes
"eiertanz-1.ily" and the \score block for violinOne only.

Cheers,
Xavier

-- 
Xavier Scheuer 
___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: accidentals for just intonation

2015-12-01 Thread Phil Holmes
I have quite an interest in intonation, and my degree dissertation was based on 
the study of musician's reaction to just and equal tempered music, and was 
created using LilyPond.  However, I'm not clear why you believe that 
accidentals in non-equal temperaments require different signs (I think that's 
what you're proposing here).  It's said that early music was based on one or 
other form of just temperament, and used normal accidental signs.  To me, they 
indicate that the music is altered to the next higher or lower semitone in the 
key and temperament being employed: so why are other signs needed?

The only extra indication that I would use would be rather like a tempo sign, 
but instead a temperament sign: "Quarter comma meantone" at the top, for 
example.

--
Phil Holmes


  - Original Message - 
  From: N. Andrew Walsh 
  To: lilypond-user 
  Sent: Tuesday, December 01, 2015 9:10 AM
  Subject: accidentals for just intonation


  Hi List,


  this is a somewhat specialist request, and more of a long-term project, but 
I'm hoping you nice people can help me with something I'd like to do with Lily 
someday.


  If you've been watching the OpenLilyLib repository, you'll see that Urs has 
been working on a set of tools for rendering music in just intonation. He 
(quite modestly) says that it isn't ready for production, but there are already 
some impressive things it can do: for one, the interface allows to input a 
fraction and get back a nearest-semitone pitch with a deviation in cents 
*automatically*, which is something the commercial programs don't offer in any 
way (every composer I know who works with JI just inputs text entries manually 
for every note, with no change in, for example, MIDI output for ability to 
handle transpositions). 


  There's something I'd very much like to do with this, largely out of my own 
(admittedly rather opinionated) view on the best means of producing accidentals 
for just intonation. I'm going to assume some familiarity with just intonation 
concepts, but (in short) it works like this: the relationship between two 
pitches is defined in terms of the frequency relationship, given usually as a 
fraction. For example, the interval of a perfect fifth may be rendered as 3/2: 
that is, if I play notes with base frequencies of 200 and 300Hz, we hear them 
as a (very purely tuned) fifth. The equal-tempered one you have on a piano (ie, 
7 semitones) is about two 1/100th of a semitone (called "cents" logically 
enough) too narrow to be pure (ie, a 3/2 fifth is about 702 cents). 


  Here's my thing: I believe that the most appropriate type of accidental for 
such a system is one that reflects the harmonic ratio, not the number of steps 
on a scale. Flats and sharps tell us whether a pitch is lowered or raised from 
its "natural" position in the scale, and just intonation doesn't have those 
positions. So, I designed accidentals that graphically reflect the harmonic 
ratio between a note and the tonic. 


  I'd like to be able to put these into Lily, and Urs tells me it can be done 
by calling a draw function to draw a path. I can relatively easily make up some 
paths with Inkscape and save them as SVGs, but is there a better way to do 
this? The NR describes (here: 
http://lilypond.org/doc/v2.19/Documentation/notation/formatting-text#graphic-notation-inside-markup)
 the means to include eps files into a markup, which presumably could be used 
to replace the accidental.


  There are some potential complicating factors here. First, the accidentals I 
use change depending on the prime factorization of the ratio involved: for 
example, the ratio 9/8 (a type of whole tone) would comprise two of the symbol 
for 3 (because "9/8" is really "(3*3)/8" ), which means that Urs' interface for 
JI ratios would need an add-on to do prime factorization of the ratios (which 
is also computationally intensive, even for relatively simple numbers) or a 
means to encode ratios as lists of primes that are then calculated to return 
the value in cents (that is, do the process in reverse, starting from "(3*3)/8" 
and getting 9/8, which might be easier to do).


  The advantage here, though, would be this: one of the interesting things 
about just intonation is that there is no theoretical limit to what kinds of 
ratios you use. You could theoretically have unique signs for all the primes 
you want, and then the draw function could build them on the fly. The 
accidentals become modular, scaling to whatever level of complexity the 
composer wants. Harry Partch writes music that tops out at the 13th overtone, 
but La Monte Young has pieces with primes in the upper 300s. 


  So, List: this is, as I said, a somewhat long-term project, but would any of 
you be willing to help me learn/do the programming necessary to develop a 
system like this? I also have in mind a more general add-on to the OLL 
just-intonation library: I'd like to see a set of different .ily files, each 
with different 

Re: accidentals for just intonation

2015-12-01 Thread N. Andrew Walsh
Right then. Let me include a few files to show what I mean.

The basic principle is this: the fraction that makes up a ratio in just
intonation can be broken down to its prime factors, as I said in the
previous message. In just intonation, this is what matters for determining
harmonic relationships. So, the accidentals are graphic representations of
these primes. The basic concept of an accidental is a thin vertical line,
with different parts attached to it: say, a one-quarter-sharp sign is
usually a single vertical line, with two thick angled lines; the others
follow similar principles (see here:
http://www.rpmseattle.com/of_note/wp-content/uploads/2012/06/03_QT_Symbols.png).
So I want to preserve that basic "thin vertical line with stuff attached"
design principle in my own set. For brevity, let's call that thin vertical
line the scaffold, and everything attached to it a "module."

Second, I want the simplest ratios to have the simplest visual design. This
makes them visually uncluttered. Third, they should (roughly) resemble
corresponding relationships with which we are already familiar.

So, the relationship "3" attaches a single thick horizontal line to the
"scaffold", since ascending by pure fifth (remember, a perfect fifth in
just intonation is a 3/2 relationship) usually results in sharps (thus a
rough visual similarity to the basic idea of what a sharp sign looks like).
Each additional upward fifth adds another horizontal line. It is also
possible to go downward by fifth, but here's the difference relative to
normal accidentals: a downward leap uses the same symbol, flipped
vertically and placed at the bottom of the "scaffold." See the attached
files for 3/2 and 9/8. The next prime is 5, and gets the next simplest
symbol: also a thick line, but now angled. See the attached file for 5/4.
You can combine both in various ways: the ratio 6/5 (a minor third) is the
symbol for 3 over the (flipped) symbol for 5; the ratio 15/8 is really
(5*3)/8, so both 5 and 3 appear at the top.

I'm not going to include any more files, but you get the idea. These are
really low-grade scans of stuff I did by hand; obviously a path I draw in
Inkscape or whatever would be much cleaner.

So, the just-intonation accidental engraver would be able to break down the
ratio given for a pitch into its prime factors (or expect that they are
already thus formatted), and then place the paths on the accidental in the
correct positions, and then typeset the resultant accidental into music
notation in place of regular accidentals.

I hope that clarifies a bit what I'm going after. Thanks again for the help.

Cheers,

A

On Tue, Dec 1, 2015 at 10:20 AM, Urs Liska  wrote:

>
>
> Am 01.12.2015 um 10:10 schrieb N. Andrew Walsh:
>
> Hi List,
>
> this is a somewhat specialist request, and more of a long-term project,
> but I'm hoping you nice people can help me with something I'd like to do
> with Lily someday.
>
> If you've been watching the OpenLilyLib repository, you'll see that Urs
> has been working on a set of tools for rendering music in just intonation.
> He (quite modestly) says that it isn't ready for production,
>
>
> Well, it isn't ...
>
> but there are already some impressive things it can do: for one, the
> interface allows to input a fraction and get back a nearest-semitone pitch
> with a deviation in cents *automatically*, which is something the
> commercial programs don't offer in any way (every composer I know who works
> with JI just inputs text entries manually for every note, with no change
> in, for example, MIDI output for ability to handle transpositions).
>
>
> Yes, I also find this exciting prospects, and I don't expect the
> limitations there are so far to be really problematic. But basically you
> can now use the functionality to produce individual notes, in a monophonic
> context.
> Probably it will be more clear once the second and third part of my latest
> blog post are out.
>
> There's something I'd very much like to do with this, largely out of my
> own (admittedly rather opinionated) view on the best means of producing
> accidentals for just intonation. I'm going to assume some familiarity with
> just intonation concepts, but (in short) it works like this: the
> relationship between two pitches is defined in terms of the frequency
> relationship, given usually as a fraction. For example, the interval of a
> perfect fifth may be rendered as 3/2: that is, if I play notes with base
> frequencies of 200 and 300Hz, we hear them as a (very purely tuned) fifth.
> The equal-tempered one you have on a piano (ie, 7 semitones) is about two
> 1/100th of a semitone (called "cents" logically enough) too narrow to be
> pure (ie, a 3/2 fifth is about 702 cents).
>
> Here's my thing: I believe that the most appropriate type of accidental
> for such a system is one that reflects the harmonic ratio, not the number
> of steps on a scale. Flats and sharps tell us whether a pitch is lowered or
> raised from 

Re: accidentals for just intonation

2015-12-01 Thread Urs Liska


Am 01.12.2015 um 10:45 schrieb Phil Holmes:
> I have quite an interest in intonation, and my degree dissertation was
> based on the study of musician's reaction to just and equal tempered
> music, and was created using LilyPond.  However, I'm not clear why you
> believe that accidentals in non-equal temperaments require different
> signs (I think that's what you're proposing here).

This is because Andrew is not talking about music that uses a scale of
notes that just deviates from the well-tempered scale through a tuning
system. Instead he's (and of course a number of composers) conceiving
pitches as ratios over fundamental frequencies. So you may have two
consecutive notes that are very similar in frequency but stem from
completely different contexts: for example a 5/1 ratio (major third
flageolet) over b, resulting in a pitch that is 14 cent below d',
followed by a pitch that is 2 cent above d' because it is the 3/1 ratio
over g.

You can notate that as

d' -\markup "(-14)" d' -\markup "(-2)"

but what Andrew suggests (and does himself by hand so far IIUC) is a
notation that indicates the same as (pseudo-code):

b,{5:1] g{3:1}

Depending on the instrument that will create those pitches different
notations may be appropriate. I clarinetist who is bending will prefer
the indication of the cent detuning, while when I have to play them as
piano flageolets I don't really care about that and have to know the key
to press (fundamental note) and the ratio or node of the string - the
resulting pitch with its cent deviation will only be there as a courtesy.

>   It's said that early music was based on one or other form of just
> temperament, and used normal accidental signs.  To me, they indicate
> that the music is altered to the next higher or lower semitone in the
> key and temperament being employed: so why are other signs needed?

I don't know how Andrew "thinks" as a composer, but music in just
intonation (in it's modern conception) is a very different thing from
ancient music in different tunings.

Urs

>  
> The only extra indication that I would use would be rather like a
> tempo sign, but instead a temperament sign: "Quarter comma meantone"
> at the top, for example.
>
> --
> Phil Holmes
>  
>  
>
> - Original Message -
> *From:* N. Andrew Walsh 
> *To:* lilypond-user 
> *Sent:* Tuesday, December 01, 2015 9:10 AM
> *Subject:* accidentals for just intonation
>
> Hi List,
>
> this is a somewhat specialist request, and more of a long-term
> project, but I'm hoping you nice people can help me with something
> I'd like to do with Lily someday.
>
> If you've been watching the OpenLilyLib repository, you'll see
> that Urs has been working on a set of tools for rendering music in
> just intonation. He (quite modestly) says that it isn't ready for
> production, but there are already some impressive things it can
> do: for one, the interface allows to input a fraction and get back
> a nearest-semitone pitch with a deviation in cents
> *automatically*, which is something the commercial programs don't
> offer in any way (every composer I know who works with JI just
> inputs text entries manually for every note, with no change in,
> for example, MIDI output for ability to handle transpositions). 
>
> There's something I'd very much like to do with this, largely out
> of my own (admittedly rather opinionated) view on the best means
> of producing accidentals for just intonation. I'm going to assume
> some familiarity with just intonation concepts, but (in short) it
> works like this: the relationship between two pitches is defined
> in terms of the frequency relationship, given usually as a
> fraction. For example, the interval of a perfect fifth may be
> rendered as 3/2: that is, if I play notes with base frequencies of
> 200 and 300Hz, we hear them as a (very purely tuned) fifth. The
> equal-tempered one you have on a piano (ie, 7 semitones) is about
> two 1/100th of a semitone (called "cents" logically enough) too
> narrow to be pure (ie, a 3/2 fifth is about 702 cents). 
>
> Here's my thing: I believe that the most appropriate type of
> accidental for such a system is one that reflects the harmonic
> ratio, not the number of steps on a scale. Flats and sharps tell
> us whether a pitch is lowered or raised from its "natural"
> position in the scale, and just intonation doesn't have those
> positions. So, I designed accidentals that graphically reflect the
> harmonic ratio between a note and the tonic. 
>
> I'd like to be able to put these into Lily, and Urs tells me it
> can be done by calling a draw function to draw a path. I can
> relatively easily make up some paths with Inkscape and save them
> as SVGs, but is there a better way to do this? The NR describes
> (here: 
> 

Re: accidentals for just intonation

2015-12-01 Thread N. Andrew Walsh
Well, this is a much longer and different discussion, but in short: I don't
intend these for non-equal temperaments, but rather music in an open system
of justly-tuned ratios. So, for example, you might certainly wish to define
your basic scale that way (a major scale thus being 1/1, 9/8, 5/4, 4/3,
3/2, 5/3, 15/8, 2/1), but you could also go *much* further up the harmonic
series. How would you describe an 11th? A 13th? Those are primes that have
no representation in music of the common practice, and a ratio like 13/9 is
on the relatively low end of what's possible (like I said, La Monte Young
uses primes up to the low 300s, I think).

I don't like using symbols from tempered music because they are visually
and semiotically confusing: after a while, you have so many very similar
looking signs that telling them apart becomes difficult (is the sign for a
13th a sharp sign with an arrow, or with a minus?). If you're using a
system with 50 or 60 different pitches to the octave, it very quickly gets
difficult to tell the signs apart. They also don't convey the information
that is actually important to just intonation: the harmonic ratio.

Obviously, this is also very much a matter of taste. I tend to think in
terms of wanting to convey the essential information of the musical
material, and nothing more. Efficiency of visual information comes at the
cost of it being based on different principles, and thus being rather
unfamiliar, relative to the usual systems. You could very certainly use
modified quartertone accidentals for extended meantone temperaments (such
as the 24-pitch meantone temperament Johannes Keller is playing in here:
https://www.youtube.com/channel/UCFG2Y__ODlxuIwcdzMM5zrQ), and that might
even be the appropriate system to use. But for an open system of just
intonation, I feel that those accidentals convey too much of the wrong
information, and not enough of the important information.

But that's a bit of a different discussion, as I said. There are probably
more different systems for notating music in non-standard tunings than
there are composers using them, and I certainly don't expect everybody to
use *this* system (though it'd be nice to see it get more use).

Hope that makes sense.

A

On Tue, Dec 1, 2015 at 10:45 AM, Phil Holmes  wrote:

> I have quite an interest in intonation, and my degree dissertation was
> based on the study of musician's reaction to just and equal tempered music,
> and was created using LilyPond.  However, I'm not clear why you believe
> that accidentals in non-equal temperaments require different signs (I think
> that's what you're proposing here).  It's said that early music was based
> on one or other form of just temperament, and used normal accidental
> signs.  To me, they indicate that the music is altered to the next higher
> or lower semitone in the key and temperament being employed: so why are
> other signs needed?
>
> The only extra indication that I would use would be rather like a tempo
> sign, but instead a temperament sign: "Quarter comma meantone" at the top,
> for example.
>
> --
> Phil Holmes
>
>
>
> - Original Message -
> *From:* N. Andrew Walsh 
> *To:* lilypond-user 
> *Sent:* Tuesday, December 01, 2015 9:10 AM
> *Subject:* accidentals for just intonation
>
> Hi List,
>
> this is a somewhat specialist request, and more of a long-term project,
> but I'm hoping you nice people can help me with something I'd like to do
> with Lily someday.
>
> If you've been watching the OpenLilyLib repository, you'll see that Urs
> has been working on a set of tools for rendering music in just intonation.
> He (quite modestly) says that it isn't ready for production, but there are
> already some impressive things it can do: for one, the interface allows to
> input a fraction and get back a nearest-semitone pitch with a deviation in
> cents *automatically*, which is something the commercial programs don't
> offer in any way (every composer I know who works with JI just inputs text
> entries manually for every note, with no change in, for example, MIDI
> output for ability to handle transpositions).
>
> There's something I'd very much like to do with this, largely out of my
> own (admittedly rather opinionated) view on the best means of producing
> accidentals for just intonation. I'm going to assume some familiarity with
> just intonation concepts, but (in short) it works like this: the
> relationship between two pitches is defined in terms of the frequency
> relationship, given usually as a fraction. For example, the interval of a
> perfect fifth may be rendered as 3/2: that is, if I play notes with base
> frequencies of 200 and 300Hz, we hear them as a (very purely tuned) fifth.
> The equal-tempered one you have on a piano (ie, 7 semitones) is about two
> 1/100th of a semitone (called "cents" logically enough) too narrow to be
> pure (ie, a 3/2 fifth is about 702 cents).
>
> Here's my 

Re: accidentals for just intonation

2015-12-01 Thread N. Andrew Walsh
Let me give another example of what I mean, just so you have an idea. I'm
in a singing ensemble that performs music in just intonation. We have a
soprano who is *terrifyingly* good at it. One of the things she does is
sing a scale comprising the following harmonic ratios relative to the
tonic: 14/8, 16/9, 18/10, 20/11, 22/12, 24/13, 26/14, 28/15, 30/16. The
first and last pitches reduce to 7/4 and 15/8, respectively: a minor and
major seventh. So, she can sing a total of *nine* pitches within the space
of a semitone and, because she can hear the harmonic ratios they each
represent, tune them all correctly. She can do this without accompaniment
(like I said, she's scary!).

Now, you *could* just give those pitches as flats and sharps, with their
respective deviations in cents, but it would be much harder to tune by ear.
Even then, it would be guesswork. The last two pitches are less than 8
cents apart; it would be extremely difficult to get them both tuned
accurately, even with feedback from a tuner. Knowing the ratios, though,
makes it possible to hear, and thus to perform.

But, as I said, whether that's a music that others might find æsthetically
interesting is an entirely different discussion. My question is: if I were
to use such a system, how would I engrave it?

Cheers,

A

On Tue, Dec 1, 2015 at 11:01 AM, Urs Liska  wrote:

>
>
> Am 01.12.2015 um 10:45 schrieb Phil Holmes:
>
> I have quite an interest in intonation, and my degree dissertation was
> based on the study of musician's reaction to just and equal tempered music,
> and was created using LilyPond.  However, I'm not clear why you believe
> that accidentals in non-equal temperaments require different signs (I think
> that's what you're proposing here).
>
>
> This is because Andrew is not talking about music that uses a scale of
> notes that just deviates from the well-tempered scale through a tuning
> system. Instead he's (and of course a number of composers) conceiving
> pitches as ratios over fundamental frequencies. So you may have two
> consecutive notes that are very similar in frequency but stem from
> completely different contexts: for example a 5/1 ratio (major third
> flageolet) over b, resulting in a pitch that is 14 cent below d', followed
> by a pitch that is 2 cent above d' because it is the 3/1 ratio over g.
>
> You can notate that as
>
> d' -\markup "(-14)" d' -\markup "(-2)"
>
> but what Andrew suggests (and does himself by hand so far IIUC) is a
> notation that indicates the same as (pseudo-code):
>
> b,{5:1] g{3:1}
>
> Depending on the instrument that will create those pitches different
> notations may be appropriate. I clarinetist who is bending will prefer the
> indication of the cent detuning, while when I have to play them as piano
> flageolets I don't really care about that and have to know the key to press
> (fundamental note) and the ratio or node of the string - the resulting
> pitch with its cent deviation will only be there as a courtesy.
>
>   It's said that early music was based on one or other form of just
> temperament, and used normal accidental signs.  To me, they indicate that
> the music is altered to the next higher or lower semitone in the key and
> temperament being employed: so why are other signs needed?
>
>
> I don't know how Andrew "thinks" as a composer, but music in just
> intonation (in it's modern conception) is a very different thing from
> ancient music in different tunings.
>
> Urs
>
>
>
> The only extra indication that I would use would be rather like a tempo
> sign, but instead a temperament sign: "Quarter comma meantone" at the top,
> for example.
>
> --
> Phil Holmes
>
>
>
> - Original Message -
> *From:* N. Andrew Walsh 
> *To:* lilypond-user 
> *Sent:* Tuesday, December 01, 2015 9:10 AM
> *Subject:* accidentals for just intonation
>
> Hi List,
>
> this is a somewhat specialist request, and more of a long-term project,
> but I'm hoping you nice people can help me with something I'd like to do
> with Lily someday.
>
> If you've been watching the OpenLilyLib repository, you'll see that Urs
> has been working on a set of tools for rendering music in just intonation.
> He (quite modestly) says that it isn't ready for production, but there are
> already some impressive things it can do: for one, the interface allows to
> input a fraction and get back a nearest-semitone pitch with a deviation in
> cents *automatically*, which is something the commercial programs don't
> offer in any way (every composer I know who works with JI just inputs text
> entries manually for every note, with no change in, for example, MIDI
> output for ability to handle transpositions).
>
> There's something I'd very much like to do with this, largely out of my
> own (admittedly rather opinionated) view on the best means of producing
> accidentals for just intonation. I'm going to assume some familiarity with
> just intonation concepts, but 

Re: accidentals for just intonation

2015-12-01 Thread Urs Liska


Am 01.12.2015 um 10:47 schrieb N. Andrew Walsh:
> So, the just-intonation accidental engraver would be able to break
> down the ratio given for a pitch into its prime factors (or expect
> that they are already thus formatted), and then place the paths on the
> accidental in the correct positions, and then typeset the resultant
> accidental into music notation in place of regular accidentals. 
>
> I hope that clarifies a bit what I'm going after. Thanks again for the
> help.
>

I have to admit it would need more mental capacity than I have available
right now to really get through this, but I think my basic approach
should be the right one:

You have a rather small number of individual components (vertical,
horizontal and diagonal elements) that can all represented by a
postscript path. A function should be able to determine from the input
ratio which of these elements have to be combined and then generate the
appropriate path and eventually use that to replace Accidental.stencil.

How these paths can be created is something I won't be of much help, but
if you get to the point where you have very concrete necessities you'll
surely be able to get help by others with more experience in that.

Urs

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: accidentals for just intonation

2015-12-01 Thread David Kastrup
"N. Andrew Walsh"  writes:

> There's something I'd very much like to do with this, largely out of
> my own (admittedly rather opinionated) view on the best means of
> producing accidentals for just intonation.

It seems like with notational systems that everyone has an opinion and a
plan for that.  The best that LilyPond can reasonably hope for is
providing the tools for making it easy to implement your own schemes.

-- 
David Kastrup

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: accidentals for just intonation

2015-12-01 Thread David Kastrup
"Phil Holmes"  writes:

> I have quite an interest in intonation, and my degree dissertation was
> based on the study of musician's reaction to just and equal tempered
> music, and was created using LilyPond.  However, I'm not clear why you
> believe that accidentals in non-equal temperaments require different
> signs (I think that's what you're proposing here).  It's said that
> early music was based on one or other form of just temperament, and
> used normal accidental signs.  To me, they indicate that the music is
> altered to the next higher or lower semitone in the key and
> temperament being employed: so why are other signs needed?

Well, Urs' printing of the cents does have educational purpose.  For
example, I can spell out the tuning of a guitar done by pure harmonics
(the highest-sounding two strings in relation to harmonics of the
lowest-sounding one):

e, as a, * 3/4 (e, +2)
a, as a,   (a, +0)
d as a, * 4/3  (d  -2)
g as d * 4/3   (g  -4)
b as e, * 3(b  +4)
e' as e, * 4   (e' +2)

And if that kind of information is spelled in a scale, it becomes
obvious why G major and E minor chords have a problem sounding good out
of the box if you tune to perfect harmonics.  Because the interval g-b
should end up as -14 (!) in order to be a pure third, but actually ends
up as +8, a discrepancy of 22 cent.

Which explains why my default manner of tuning a guitar, namely just
tuning each string to sound as I think it should in relation to the
sequence of previous strings, has a good chance to end up more playable
than the followup work of a "serious" guitar player believing in tuning
by using harmonics.

In the scheme of talking about tunings or ad-hoc modifications, a scheme
like Urs' that can accommodate basically a continuity of values
certainly has some merit.  As a continuous notation for the sake of
playing, I think it would end up a nuisance.

-- 
David Kastrup

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: transpose pitch by semitones

2015-12-01 Thread David Kastrup
Gilles THIBAULT  writes:

>> OK, this one is more straightforward...
> ...but your idea was probably the best :
>
> 
> #(define (semitones->pitch semitone)
>(let ((index (modulo semitone 12))
>  (octave (quotient semitone 12)))
>  (apply ly:make-pitch (cons
>   octave
>   (list-ref
>'((0 0)   ; c
>   (0 1/2) ; cis
>   (1 0)   ; d
>   (1 1/2) ; dis
>   (2 0)   ; e
>   (3 0)   ; f
>   (3 1/2) ; fis %  \jiPitch 2 1
>  
>   (4 0)   ; g
>   (4 1/2) ; gis
>   (5 0)   ; a
>   (5 1/2) ; ais
>   (6 0))   ; b 
>index)

Well, that could be

(apply ly:make-pitch octave
  (vector-ref #((0 0) (0 1/2) (1 1/2) ...) index)

There is no need to use the inefficient `list-ref' here since a vector
works just fine.  And there is no point in putting `octave' into a list
just to have `apply' unpack it again.

At any rate, this scheme does not choose harmonically useful notes: it's
very straightforward.

My Emacs input mode does the pitch assignment from MIDI a bit more
versatily (this is Elisp, so it would need some amendment for working in
GUILE, but that should not be too hard to do).

;; default notenames and modifications:
;;
;; The assignment to Midi names is done using the following table that
;; tries to accomodate some common chords in the C major scale but
;; also melodic A minor.  This does not behave all that robustly under
;; modulation.
;;
;; TODO: should we have a more complete picture of the signature or
;; current mode?  Conversion to notenames may depend on lead tones and
;; lead harmonies, and those are different for c \major and a \minor,
;; for example.

(defconst lily-defaultmidi-names
  [0 0 1 2 2 3 3 4 4 5 6 6]
  "Default assignment of notenames to semitones.")

(defconst lily-defaultmidi-scale
  [0 2 4 5 7 9 11]
  "Semitone offsets for the various notenames.")

(defun lily-midi-to-note (note  sharps)
  "Convert NOTE under key SHARPS to an (octave note accidental) triple."
  ;; the trick here with regard to sharps is that we transpose the
  ;; index into `lily-defaultmidi-names' by `sharps' chromatic
  ;; fourths, and transpose the result down again by `sharps' diatonic
  ;; fourths.  We ignore the octaves and accidentals and fix them up
  ;; at the end.
  (let* ((sharps (or sharps lily-midi-keysig 0))
 (inkey (aref lily-defaultmidi-names
  (mod (+ note (* sharps 5)) 12)))
 (name (mod (+ inkey (* sharps 4)) 7))
 (nameoff (aref lily-defaultmidi-scale name))
 (acc (- (mod (- note nameoff 6) 12) 6))
 (oct (/ (- note nameoff acc 60) 12)))
(list oct name (* acc 0.5


One thing to note here is that the resulting octave depends on the key
of conversion: bis'' and c' can represent the same semitone in different
keys and have a different octave.

This works by first figuring out the proper note name to arrive at.
Then the normal semitone associated with that is looked up, and the
difference makes up both octave and resulting accidental.

The same sequence of semitones can thus lead to different notes
depending on the key of conversion.

lily-defaultmidi-names codifies when to use a flat and when to use a
sharp in C major.  Maybe it should not be a defconst.

-- 
David Kastrup

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: aligning melisma and non-melisma lyrics across staves in the same system

2015-12-01 Thread Kieren MacMillan
Hi Harm,

> Yes, parts of it works already. Look at the attached image.
> In first bar the lyrics are aligned correctly I'd say.

Agreed.

> Though not in 3rd bar. "three" is offsetted as well, it shouldn’t.

Agreed.

> The problem is how to test equality?
> For strings it's trivial

Is that already implemented?

> but LyricText also allows for markup.

Is there a markup->string function?

> Likely I'll go for 'self-alignment-X only …

That sounds like the right approach.

Thanks,
Kieren.


Kieren MacMillan, composer
‣ website: www.kierenmacmillan.info
‣ email: i...@kierenmacmillan.info


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Kneed beams and changes of staff

2015-12-01 Thread Kieren MacMillan
Hi Gilberto,

> I would need one of those automagical ways

Even if you weren’t dealing with algorithmic music, an automagic way would be 
much better…

> What surprises me about the default look is how confusing it actually is!

True! If you look at the following [even simpler] snippet, it’s clear that 
things are fine when un-kneed, but go wonky when kneed. It looks like the 
algorithm says “keep all beams at their highest possible position” instead of 
[what you want, which is:] “beam the 32nds together across the whole group, and 
then add the 64th beam(s) where most appropriate”.

I’m in no way certain (a) what the current algorithm actually is/does, and (b) 
whether improving it is possible/reasonable/feasible. I’m just “+1”-ing you 
here, having noticed this for the first time because of your post.

Here’s hoping you find a good solution!
Kieren.


Kieren MacMillan, composer
‣ website: www.kierenmacmillan.info
‣ email: i...@kierenmacmillan.info


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: transpose pitch by semitones

2015-12-01 Thread David Kastrup
Urs Liska  writes:

> Am 01.12.2015 um 15:48 schrieb Gilles THIBAULT:
>>> OK, this one is more straightforward...
>> ...but your idea was probably the best :
>
> :-)
>
> Thank you for your input and sorry I didn't have time to reply earlier.
> Maybe "best" is also a matter of use case here, but I have the
> impression that in this case a simple lookup *is* the most
> straightforward solution. In the light of your suggestions I would add a
> second lis producing flats instead of sharps, though.
>
> Still I think there should be a built-in solution. When LilyPond does
> transpositions and similar operations doesn't it work on semitones
> either, converting to and from?

Not really.  \transpose c bis' is a non-trivial transposition whereas it
does not change the semitone.

LilyPond does transposition by strictly maintaining the scale steps,
then fixing up accidentals and octaves to match.

-- 
David Kastrup

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Kneed beams and changes of staff

2015-12-01 Thread Gilberto Agostinho
Hi Kieren,


Kieren MacMillan wrote
> There are almost certainly other [more automagic] ways…
> But have you looked at stemLeftBeamCount and stemRightBeamCount?

I have looked at them, but unfortunately I would need one of those
automagical ways (I am dealing with algorithmic music and I manually
tweaking isn't an option for me).

What surprises me about the default look is how confusing it actually is! At
a glance it's very difficult to tell how many beams a note actually have. On
top of that, I also never seen that kind of notation before, to be frank. 

Below is a one more example of a complex kneed beam division. Note how the
main beam (in this case the bottom one, as the first note has a stem down)
is always in the bottom of the group:

 



--
View this message in context: 
http://lilypond.1069038.n5.nabble.com/Kneed-beams-and-changes-of-staff-tp184339p184345.html
Sent from the User mailing list archive at Nabble.com.

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


fingerings added to tabs?

2015-12-01 Thread BB

How can I add fingerings to tabs?
(Not found in the manual)

Regards

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Kneed beams and changes of staff

2015-12-01 Thread Kieren MacMillan
arg… Here’s the snippet:

%%%  SNIPPET BEGINS
\version "2.19"
\language "english"

examples = {
  \tuplet 5/4 { c''32[ 32 64 64 32 32] }
  \tuplet 5/4 { e'''32[ 32 64 g64 32 32] }
}

\score {
  \examples
}
%%%  SNIPPET ENDS

On Dec 1, 2015, at 10:34 AM, Kieren MacMillan  
wrote:

> Hi Gilberto,
> 
>> I would need one of those automagical ways
> 
> Even if you weren’t dealing with algorithmic music, an automagic way would be 
> much better…
> 
>> What surprises me about the default look is how confusing it actually is!
> 
> True! If you look at the following [even simpler] snippet, it’s clear that 
> things are fine when un-kneed, but go wonky when kneed. It looks like the 
> algorithm says “keep all beams at their highest possible position” instead of 
> [what you want, which is:] “beam the 32nds together across the whole group, 
> and then add the 64th beam(s) where most appropriate”.
> 
> I’m in no way certain (a) what the current algorithm actually is/does, and 
> (b) whether improving it is possible/reasonable/feasible. I’m just “+1”-ing 
> you here, having noticed this for the first time because of your post.
> 
> Here’s hoping you find a good solution!
> Kieren.


Kieren MacMillan, composer
‣ website: www.kierenmacmillan.info
‣ email: i...@kierenmacmillan.info


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Kneed beams and changes of staff

2015-12-01 Thread Gilberto Agostinho
Hi Kieren,


Kieren MacMillan wrote
> True! If you look at the following [even simpler] snippet, it’s clear that
> things are fine when un-kneed, but go wonky when kneed.

Your example shows the problem very clearly indeed.


> I’m in no way certain (a) what the current algorithm actually is/does, and
> (b) whether improving it is possible/reasonable/feasible. I’m just
> “+1”-ing you here, having noticed this for the first time because of your
> post.
> 
> Here’s hoping you find a good solution!

Thanks a lot!



--
View this message in context: 
http://lilypond.1069038.n5.nabble.com/Kneed-beams-and-changes-of-staff-tp184339p184349.html
Sent from the User mailing list archive at Nabble.com.

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


RE: Kneed beams and changes of staff

2015-12-01 Thread Mark Stephen Mrotek
Gilberto,

A rather tedious, yet precise method, is:

\once \set stemRightBeamCount = #x
\once \set stemLeftBeamCount = #x

Mark

-Original Message-
From: lilypond-user-bounces+carsonmark=ca.rr@gnu.org
[mailto:lilypond-user-bounces+carsonmark=ca.rr@gnu.org] On Behalf Of
Gilberto Agostinho
Sent: Tuesday, December 01, 2015 6:56 AM
To: lilypond-user@gnu.org
Subject: Kneed beams and changes of staff

Hi all,

Does anyone here know how can I achieve the look of the red beams in the
image below? (the black beams are the LilyPond's default, and the red I
drawn on a graphics application):

 

It makes so much easier to read subdivisions IMO.

Cheers,
Gilberto



--
View this message in context:
http://lilypond.1069038.n5.nabble.com/Kneed-beams-and-changes-of-staff-tp184
339.html
Sent from the User mailing list archive at Nabble.com.

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


RE: Kneed beams and changes of staff

2015-12-01 Thread Gilberto Agostinho
Hi Mark,


Mark Stephen Mrotek wrote
> A rather tedious, yet precise method, is:
> 
> \once \set stemRightBeamCount = #x
> \once \set stemLeftBeamCount = #x

This is what Kieren already recommended me in this thread, but it's
unfortunately not really possible in my case (and even if I could, I would
not be willing to go through 80 pages of music manually correcting strange
beams which in this particular case are all over the place). Anyway, for
this particular composition of mine, in the worst case scenario I will
simply force the auto-knee-gap to +inf and that's it, but I do believe
LilyPond's default output should be reconsidered.

Cheers,
Gilberto



--
View this message in context: 
http://lilypond.1069038.n5.nabble.com/Kneed-beams-and-changes-of-staff-tp184339p184351.html
Sent from the User mailing list archive at Nabble.com.

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: accidentals for just intonation

2015-12-01 Thread Stephan Neuhaus

On 2015-12-01 11:27, David Kastrup wrote:

[...]

Which explains why my default manner of tuning a guitar, namely just
tuning each string to sound as I think it should in relation to the
sequence of previous strings, has a good chance to end up more playable
than the followup work of a "serious" guitar player believing in tuning
by using harmonics.


This may be off-topic, but this is *exactly* how I do it. For a while I 
was worried that this might be too slapdash, but then I thought, "if it 
sounds good, who am I to argue?" :-)


Fun,

Stephan

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: transpose pitch by semitones

2015-12-01 Thread Gilles THIBAULT
> OK, this one is more straightforward...
...but your idea was probably the best :


#(define (semitones->pitch semitone)
   (let ((index (modulo semitone 12))
 (octave (quotient semitone 12)))
 (apply ly:make-pitch (cons
  octave
  (list-ref
   '((0 0)   ; c
  (0 1/2) ; cis
  (1 0)   ; d
  (1 1/2) ; dis
  (2 0)   ; e
  (3 0)   ; f
  (3 1/2) ; fis %  \jiPitch 2 1
 
  (4 0)   ; g
  (4 1/2) ; gis
  (5 0)   ; a
  (5 1/2) ; ais
  (6 0))   ; b 
   index)

%%test

#(for-each 
   (lambda(n)(format #t "~2,' d - ~a\n" n (semitones->pitch n)))
   '(-5 -4 -3 -2 -1 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15))
%%

-- The End ---

-- 
Gilles

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: accidentals for just intonation

2015-12-01 Thread Paul Morris
> On Dec 1, 2015, at 5:38 AM, Urs Liska  wrote:
> 
> You have a rather small number of individual components (vertical,
> horizontal and diagonal elements) that can all represented by a
> postscript path. A function should be able to determine from the input
> ratio which of these elements have to be combined and then generate the
> appropriate path and eventually use that to replace Accidental.stencil.

Yep, sounds like a matter of creating path stencils for each component part, as 
static unchanging building blocks, and then have a function that dynamically 
combines these stencils to produce the accidental needed for a given note.  
Combining stencils in different ways is simpler than producing a path on the 
fly, so that will make things easier.

I have done this kind of thing by creating an SVG with Inkscape and then 
opening the SVG file in a text editor where I can copy the path coordinates.  
Then I can paste those coordinates into a LilyPond include file, in a procedure 
that produces a path stencil.  (With some tedious back and forth to get the 
scaling right.)  Then that stencil is available to use by LilyPond.  

For Clairnote music notation I have code that replaces accidental signs with 
custom accidentals[0] that might be helpful to look at.  It combines a dot 
stencil with a line stencil, so no paths are needed.  However, I also use path 
coordinates to create whole note glyphs, so there’s an example of that as well. 
 That code is available here:

http://clairnote.org/software/

[0] http://clairnote.org/accidental-signs/

> How these paths can be created is something I won't be of much help, but
> if you get to the point where you have very concrete necessities you'll
> surely be able to get help by others with more experience in that.

There are several ways to create a stencil from a path.  Search the LSR for 
“path” for two different ways in addition to the \path markup command.  The 
most recent development version of LilyPond (2.19.x) also has a 
make-path-stencil function that combines the benefits of the two ways 
documented on the LSR without their drawbacks, so I prefer to use that unless 
I’m supporting LilyPond 2.18. 

-Paul


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Kneed beams and changes of staff

2015-12-01 Thread Gilberto Agostinho
Hi all,

Does anyone here know how can I achieve the look of the red beams in the
image below? (the black beams are the LilyPond's default, and the red I
drawn on a graphics application):

 

It makes so much easier to read subdivisions IMO.

Cheers,
Gilberto



--
View this message in context: 
http://lilypond.1069038.n5.nabble.com/Kneed-beams-and-changes-of-staff-tp184339.html
Sent from the User mailing list archive at Nabble.com.

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: transpose pitch by semitones

2015-12-01 Thread Urs Liska


Am 01.12.2015 um 15:48 schrieb Gilles THIBAULT:
>> OK, this one is more straightforward...
> ...but your idea was probably the best :

:-)

Thank you for your input and sorry I didn't have time to reply earlier.
Maybe "best" is also a matter of use case here, but I have the
impression that in this case a simple lookup *is* the most
straightforward solution. In the light of your suggestions I would add a
second lis producing flats instead of sharps, though.

Still I think there should be a built-in solution. When LilyPond does
transpositions and similar operations doesn't it work on semitones
either, converting to and from?

Urs

>
> 
> #(define (semitones->pitch semitone)
>(let ((index (modulo semitone 12))
>  (octave (quotient semitone 12)))
>  (apply ly:make-pitch (cons
>   octave
>   (list-ref
>'((0 0)   ; c
>   (0 1/2) ; cis
>   (1 0)   ; d
>   (1 1/2) ; dis
>   (2 0)   ; e
>   (3 0)   ; f
>   (3 1/2) ; fis %  \jiPitch 2 1
>  
>   (4 0)   ; g
>   (4 1/2) ; gis
>   (5 0)   ; a
>   (5 1/2) ; ais
>   (6 0))   ; b 
>index)
>
> %%test
>
> #(for-each 
>(lambda(n)(format #t "~2,' d - ~a\n" n (semitones->pitch n)))
>'(-5 -4 -3 -2 -1 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15))
> %%
>
> -- The End ---
>


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Kneed beams and changes of staff

2015-12-01 Thread Kieren MacMillan
Hi Gilberto,

> Does anyone here know how can I achieve the look of the red beams

There are almost certainly other [more automagic] ways…
But have you looked at stemLeftBeamCount and stemRightBeamCount?

Hope this helps!
Kieren.


Kieren MacMillan, composer
‣ website: www.kierenmacmillan.info
‣ email: i...@kierenmacmillan.info


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: accidentals for just intonation

2015-12-01 Thread N. Andrew Walsh
These sorts of conflicts in tuning arise, as Urs pointed out, from using
one note to designate two different harmonic contexts. The whole field of
temperament is largely an effort to reconcile them, with varying solutions
in various time periods, depending on what kind of sound was preferred (for
example, in some meantone temperaments you hear much purer thirds, at the
expense of fifths being too low. In others, you have exactly the opposite).
In just intonation, I would describe the two kinds of D -- a fifth over G
and a major third over Bb -- in the key of F as 27/16 and 5/3, respectively
(and they have, as you note, a difference between them of about 20 cents).

There's reasonable benefit to giving cents values, beyond educational: one
of the conventions in just intonation -- one which a colleague of mine
really wants to see -- is to approximate the accidentals to 12th-tones (so,
12 steps to the whole tone), and then give a markup above indicating the
nearest semitone with cents deviation. In the case of our 5/4 third, that
would show "D -13.7" above, but the accidental would be a D 2/12th
flattened. Other instruments, which maybe can't use 12th-tones, might use
other kinds of accidentals, which behave according to different rules (for
example, there are common fingering charts for flute and oboe that give
8th-tones, but clarinet just has quartertones). Being able to specify an
exact harmonic ratio, and then have Lily output different accidentals, each
behaving according to different rules as needed, would be a big advantage
over other software (and would open it up to systems like mine, which
behave according to totally different rules which can nevertheless be
extracted from the information given).

Cheers,

A

On Tue, Dec 1, 2015 at 1:50 PM, Stephan Neuhaus  wrote:

> On 2015-12-01 11:27, David Kastrup wrote:
>
>> [...]
>>
>> Which explains why my default manner of tuning a guitar, namely just
>> tuning each string to sound as I think it should in relation to the
>> sequence of previous strings, has a good chance to end up more playable
>> than the followup work of a "serious" guitar player believing in tuning
>> by using harmonics.
>>
>
> This may be off-topic, but this is *exactly* how I do it. For a while I
> was worried that this might be too slapdash, but then I thought, "if it
> sounds good, who am I to argue?" :-)
>
> Fun,
>
> Stephan
>
>
> ___
> lilypond-user mailing list
> lilypond-user@gnu.org
> https://lists.gnu.org/mailman/listinfo/lilypond-user
>
___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: transpose pitch by semitones

2015-12-01 Thread Gilles THIBAULT

> I made this function some times ago, but don't know if is enough
> straightforward :-)
OK, this one is more straightforward... 


%% sharp
#(define (semitones->pitch n)
(let ((a (quotient n 12))
  (b 0)
  (c (modulo n 12)))
  (cond ;; 2 semitones in a tone but not between E and F (c=5)
   ((< c 5) (ly:make-pitch a (quotient c 2) (* 1/2 (modulo c 2
   (else (ly:make-pitch a (quotient (1+ c) 2) (* 1/2 (modulo (1+ c) 2)))

%% flat
%{ %comment this line if you want notes with flats instead sharps
#(define (semitones->pitch n)
(let ((a (quotient n 12))
  (b 0)
  (c (modulo n 12)))
  (cond 
   ((< c 5) (ly:make-pitch a (+ (quotient c 2) (modulo c 2))
 (* -1/2 (modulo c 2
   (else (ly:make-pitch a (+ (quotient (1+ c) 2) (modulo (1+ c) 2))
  (* -1/2 (modulo (1+ c) 2)))
%}

%%test

#(for-each 
   (lambda(n)(format #t "~2,' d - ~a\n" n (semitones->pitch n)))
   '(-5 -4 -3 -2 -1 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15))



-- 
Gilles

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: fingerings added to tabs?

2015-12-01 Thread Jacques Menu
Hello BB,


\version "2.19.15"

RH = #rightHandFinger

upper = \relative c' {
  \set fingeringOrientations = #'(left)
  \set strokeFingerOrientations = #'(up)
  \set stringNumberOrientations = #'(down)
  \override StringNumber.transparent = ##t

  8
  
  
  
}

lower = \relative c {
  \set fingeringOrientations = #'(left)
  \set strokeFingerOrientations = #'(down)
  \set stringNumberOrientations = #'(up)
  \override StringNumber.transparent = ##t

  2
}


\new StaffGroup
<<

  \new Staff {
\clef "G_8"
\key e \minor
<<
  \upper \\ \lower
>>
  }

  \new TabStaff
  <<
\upper \\ \lower
  >>
>>



upper = \relative c' {
  \set fingeringOrientations = #'(left)
  \set strokeFingerOrientations = #'(up)
  \set stringNumberOrientations = #'(down)
  \override StringNumber.transparent = ##t

  8
  % 
  
  
  
}


\new StaffGroup
<<

  \new Staff {
\clef "G_8"
\key e \minor
<<
  \upper \\ \lower
>>
  }

  \new TabStaff
  <<
\upper \\ \lower
  >>
>>



JM

> Le 1 déc. 2015 à 16:25, BB  a écrit :
> 
> How can I add fingerings to tabs?
> (Not found in the manual)
> 
> Regards
> 
> ___
> lilypond-user mailing list
> lilypond-user@gnu.org
> https://lists.gnu.org/mailman/listinfo/lilypond-user


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: fingerings added to tabs?

2015-12-01 Thread David Kastrup
BB  writes:

> How can I add fingerings to tabs?
> (Not found in the manual)

They are in mine.



References for fretted strings
..

Music for fretted string instruments is normally notated on a single
staff, either in traditional music notation or in tablature.  Sometimes
the two types are combined, and it is especially common in popular music
to use chord diagrams above a staff of traditional notation.  The guitar
and the banjo are transposing instruments, sounding an octave lower than
written.  Scores for these instruments should use the ‘"treble_8"’ clef
(or ‘\transposition c’ to get correct MIDI output).  Some other elements
pertinent to fretted string instruments are covered elsewhere:

   • Fingerings are indicated as shown in *note Fingering
 instructions::.
^^

Also


So since the respective references are listed right at the top of the
node

2. Specialist notation
2.4 Fretted string instruments
2.4.1 Common notation for fretted strings

the question is just where you looked in the manual.  It is also worth
noting that the index of the notation manual contains entries like

fingering chords
fingering instructions for chords
fingering vs. string numbers
[...]
fingerings, right hand for fretted instruments

And it's not like a web search for

How can I add fingerings to tabs with LilyPond?

would not also turn up the respective page as the first hit in either
Google, Yahoo, or DuckDuckGo.

So where did you look in the manual?

-- 
David Kastrup

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user