[TeX-music] MusiXTeX and TeX register limitation [was: I want your tests]

2003-01-08 Thread Rainer Dunker
On Mon, Jan 06, 2003 at 11:57:37PM +0100, taupin (wanadoo-lps) wrote:
  Is there somebody who observes difficulties or slowing down when \including
  musixadd? Otherwise it could IMO also be incorporated in musixtex.
 
 I'm really reluctant, once more, because of the problem of register
 consumption.
 This make musixadd and musixmadd not compatible with other register
 consuming packages, especially in LaTeX. Otherwise, MusiXTeX would
 become reserved for Omega users.

Just an idea: What about having MusiXTeX use macros instead of
registers? Sure, this would make musixtex.tex's coding somewhat more
complicated, especially where calculations are to be performed, but in
many situations, macros behave just like allocated registers. I've done
this change with musixlyr, and in the end I was surprised how little the
necessary code changes actually were.

vision Having overcome the register limitation, MusiXTeX could easily
be made capable of handling arbitrary numbers of instruments, slurs,
beams, etc. /vision

Best regards,

Rainer
___
TeX-music mailing list
[EMAIL PROTECTED]
http://sunsite.dk/mailman/listinfo/tex-music



Re: [TeX-music] MusiXTeX and TeX register limitation [was: I want your tests]

2003-01-08 Thread Rainer Dunker
On Wed, Jan 08, 2003 at 01:58:41PM +0100, Bernhard Lang wrote:
  Just an idea: What about having MusiXTeX use macros instead of
  registers? Sure, this would make musixtex.tex's coding somewhat more
  complicated, especially where calculations are to be performed, but in
  many situations, macros behave just like allocated registers. I've done
  this change with musixlyr, and in the end I was surprised how little the
  necessary code changes actually were.
  [...]
 Wouldn't changing from registers to macros dramatically affect the speed?

I've got no evidence, but I don't expect any considerable performance
loss. TeX's macro mechanism is highly performant, thus expanding a short
macro shouldn't be much slower than looking up a register content.
(Perhaps it's even faster? I don't know ...)

 For typing short pieces this shouldn't be a problem. But for rather big
 scores? I remarked already that adding lyrics to a piece using musixlyr
 considerably slows down PMXing and TeXing.

That's regrettably true, but it has nothing to do with the
register/macro choice. It's a rather general property of musixlyr, based
on the fact that the necessary lyrics analysis (i.e. the splitting into
syllables) can be accomplished with TeX data structures only in
squared-degree, not linear, execution time (related to the length of
the lyrics input).

It shouldn't have any significance on PMXing, though.

Best regards,

Rainer
___
TeX-music mailing list
[EMAIL PROTECTED]
http://sunsite.dk/mailman/listinfo/tex-music



Re: [TeX-music] MusiXTeX and TeX register limitation [was: I want your tests]

2003-01-08 Thread Rainer Dunker
On Wed, Jan 08, 2003 at 03:59:26PM +0100, Bernhard Lang wrote:
  It's a rather general property of musixlyr, based on the fact that the
  necessary lyrics analysis (i.e. the splitting into syllables) can be
  accomplished with TeX data structures only in squared-degree, not
  linear, execution time (related to the length of the lyrics input).
 
 Thus, n bytes of lyrics, cut into some small pieces and put at the proper
 position, will win over n bytes at one shot at the beginning?

Principally yes. Nevertheless, I've never tried at which amount of
lyrics you'll really notice a speed difference.

Best regards,

Rainer
___
TeX-music mailing list
[EMAIL PROTECTED]
http://sunsite.dk/mailman/listinfo/tex-music