Re: [NTG-context] \triangledown placed too low in Palatino

2014-04-15 Thread Hans Hagen

On 4/14/2014 11:30 AM, Sanjoy Mahajan wrote:

I can change things but will only do that when all you mathematicians
have some agreement about it ...


Otared points out that the distinction between \triangle and
\bigtriangleup comes from plain TeX.  plain.tex has these definitions:

\mathchardef\triangle=0234
\mathchardef\bigtriangleup=2234

So \triangle is a math ord and \bigtriangleup a math bin.

For compatibility, that should probably stay true in ConTeXt too---even
the low placement of \bigtriangledown, which I don't understand but
which does reproduce plain TeX's placement.


why? if compatibility means 'not useable' we should fix it


Btw, it is still on my agenda to provide a mechanism for switching
between math dictionaries (i.e. group symbols in group switch if needed
different properties) so that one can switch between logic,
statistics, streetfighting or whatever math.


Hm, like different dialects of a language.  Plain TeX definitely speaks
a pure-mathematician dialect.  It would be interesting to see what
symbol groups are useful in other dialects.


http://www.openmath.org/cdindex.html

it would be interesting to come up with a reasonable list of math languages

Hans

-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com
 | www.pragma-pod.nl
-
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] \triangledown placed too low in Palatino

2014-04-15 Thread Sanjoy Mahajan
Hans Hagen pra...@wxs.nl writes:

 So \triangle is a math ord and \bigtriangleup a math bin.

 For compatibility, that should probably stay true in ConTeXt too---even
 the low placement of \bigtriangledown, which I don't understand but
 which does reproduce plain TeX's placement.

 why? if compatibility means 'not useable' we should fix it

Thus, a question for the purer mathematicians on the list: Are there
uses for the lower placement of \bigtriangledown?  As a physicists, I
have used that shape only for the gradient operator (for which one has
\nabla).  But maybe it is used in, say, category theory with a lower
placement?

-Sanjoy
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] \triangledown placed too low in Palatino

2014-04-14 Thread Sanjoy Mahajan
 I can change things but will only do that when all you mathematicians 
 have some agreement about it ...

Otared points out that the distinction between \triangle and
\bigtriangleup comes from plain TeX.  plain.tex has these definitions:

\mathchardef\triangle=0234
\mathchardef\bigtriangleup=2234

So \triangle is a math ord and \bigtriangleup a math bin.

For compatibility, that should probably stay true in ConTeXt too---even
the low placement of \bigtriangledown, which I don't understand but
which does reproduce plain TeX's placement.

 Btw, it is still on my agenda to provide a mechanism for switching
 between math dictionaries (i.e. group symbols in group switch if needed
 different properties) so that one can switch between logic,
 statistics, streetfighting or whatever math.

Hm, like different dialects of a language.  Plain TeX definitely speaks
a pure-mathematician dialect.  It would be interesting to see what
symbol groups are useful in other dialects.

-Sanjoy
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] \triangledown placed too low in Palatino

2014-04-13 Thread Hans Hagen

On 4/13/2014 4:44 AM, Sanjoy Mahajan wrote:

Otared Kavian ota...@gmail.com writes:


The \triangle operator is used for instance in the « symmetric
difference » of two subsets


Ah, good to learn something about pure mathematics.  In my mathematics
degree, my tutor said, You are very good at the applied material,
which was not meant as a compliment.

So \triangle should be a \mathop rather than a \mathord?  Right now, as
Aditya pointed out, it's a \mathord (ordinary), in contrast to
\bigtriangleup, which is the same character but typeset as a binary
operator (binary). From char-def.lua :

  [0x25B3]={
   adobename=whiteuppointingtriangle,
   category=so,
   cjkwd=a,
   description=WHITE UP-POINTING TRIANGLE,
   direction=on,
   linebreak=ai,
   mathspec={
{
 class=ordinary,
 name=triangle,
},
{
 class=binary,
 name=bigtriangleup,
},
   },
   unicodeslot=0x25B3,
  },


I can change things but will only do that when all you mathematicians 
have some agreement about it ...


Btw, it is still on my agenda to provide a mechanism for switching 
between math dictionaries (i.e. group symbols in group swith i fneeded 
different properties) so that one can switch between logic, statistics, 
streetfighting or whatever math.


Hans

-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com
 | www.pragma-pod.nl
-
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] \triangledown placed too low in Palatino

2014-04-12 Thread Sanjoy Mahajan
Otared Kavian ota...@gmail.com writes:

 The \triangle operator is used for instance in the « symmetric
 difference » of two subsets

Ah, good to learn something about pure mathematics.  In my mathematics
degree, my tutor said, You are very good at the applied material,
which was not meant as a compliment.

So \triangle should be a \mathop rather than a \mathord?  Right now, as
Aditya pointed out, it's a \mathord (ordinary), in contrast to
\bigtriangleup, which is the same character but typeset as a binary
operator (binary). From char-def.lua :

 [0x25B3]={
  adobename=whiteuppointingtriangle,
  category=so,
  cjkwd=a,
  description=WHITE UP-POINTING TRIANGLE,
  direction=on,
  linebreak=ai,
  mathspec={
   {
class=ordinary,
name=triangle,
   },
   {
class=binary,
name=bigtriangleup,
   },
  },
  unicodeslot=0x25B3,
 },

-Sanjoy
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] \triangledown placed too low in Palatino

2014-04-11 Thread Otared Kavian
Hi,

The \triangle operator is used for instance in the « symmetric difference » of 
two subsets: if $E$ is a set and $A \subset E$, and $B \susbet E$, then one 
defines
\startformula
A \triangle B := (A \cup B) \setminus (A \cap B).
\stopformula
Then the mapping $(A,B) \mapsto A \triangle B$ is a commutative, associative 
binary operator on the subsets of $E$.

Some people use instead $A \Delta B$, but this is not the traditional, nor the 
correct way, to write this « symmetric difference » of two sets. This is why, I 
guess, in TeX \triangle is an operator.
I have seen also \triangledown as an operator, but I don’t recall the context 
in which it was used…

Regarding the notation \nabla to denote the gradient, and \Delta, to denote the 
Laplace operator (which by the way can be defined as $\Delta u := \nabla \cdot 
(\nabla u)$), Mikael Sundqvist gave the correct observations.

Best regards: OK

On 11 avr. 2014, at 05:48, Aditya Mahajan adit...@umich.edu wrote:

 On Thu, 10 Apr 2014, Sanjoy Mahajan wrote:
 
 Jannik,
 
 You are right.  \nabla looks much nicer and is placed correctly.  (I
 still think the \triangledown placement is slightly off.)
 
 My environment files from MkII days have \def\nabla{\triangledown}, so I
 never tried the true \nabla until your suggestion.
 
 In MkIV: \triangledown is mapped to 0x25BD while nabla is mapped to 0x2207. 
 These are different glyphs.
 
 IIUC, the difference in placement is because \triangledown is defined as a 
 mathop (and hence centered on the math-axis) while \nabla is defined as a 
 mathord. Compare:
 
 \startformula
  \nabla T
  \quad
  \triangledown T
  \quad
  \mathop{\nabla} T
 \stopformula
 
 From what I remember, I was the one who added the mappings for triangledown 
 as a mathop based on, I believe, unicode-math package in LaTeX. I don't 
 understand what all the triangle operators are supposed to do. As such, I 
 cannot say whether the wrong placement is due to the wrong font metrics or 
 the wrong mapping (mathop vs mathord) by ConTeXt.
 
 Aditya
 ___
 If your question is of interest to others as well, please add an entry to the 
 Wiki!
 
 maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
 webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
 archive  : http://foundry.supelec.fr/projects/contextrev/
 wiki : http://contextgarden.net
 ___

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


[NTG-context] \triangledown placed too low in Palatino

2014-04-10 Thread Sanjoy Mahajan
I just noticed that the gradient operator (\triangledown) ends up too
low when using Palatino:

\setupbodyfont[palatino]
\starttext
$\triangledown T$
\stoptext

It seems about 3pt too low.  Without the \setupbodyfont[palatino], the
placement is fine.

(tested with 2013.05.28 and 2014.03.27 betas)

-Sanjoy
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] \triangledown placed too low in Palatino

2014-04-10 Thread Jannik Voges
I think you are using the wrong symbol. Or at least I would prefer \nabla as 
gradient operator.


Jannik


Am 10.04.2014 um 23:49 schrieb Sanjoy Mahajan san...@mit.edu:

 I just noticed that the gradient operator (\triangledown) ends up too
 low when using Palatino:
 
 \setupbodyfont[palatino]
 \starttext
 $\triangledown T$
 \stoptext
 
 It seems about 3pt too low.  Without the \setupbodyfont[palatino], the
 placement is fine.
 
 (tested with 2013.05.28 and 2014.03.27 betas)
 
 -Sanjoy
 ___
 If your question is of interest to others as well, please add an entry to the 
 Wiki!
 
 maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
 webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
 archive  : http://foundry.supelec.fr/projects/contextrev/
 wiki : http://contextgarden.net
 ___

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] \triangledown placed too low in Palatino

2014-04-10 Thread Sanjoy Mahajan
Jannik,

You are right.  \nabla looks much nicer and is placed correctly.  (I
still think the \triangledown placement is slightly off.)

My environment files from MkII days have \def\nabla{\triangledown}, so I
never tried the true \nabla until your suggestion.

Thank you.

-Sanjoy

Jannik Voges researchj...@icloud.com writes:

 I think you are using the wrong symbol. Or at least I would prefer
 \nabla as gradient operator.


 Jannik
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] \triangledown placed too low in Palatino

2014-04-10 Thread Aditya Mahajan

On Thu, 10 Apr 2014, Sanjoy Mahajan wrote:


Jannik,

You are right.  \nabla looks much nicer and is placed correctly.  (I
still think the \triangledown placement is slightly off.)

My environment files from MkII days have \def\nabla{\triangledown}, so I
never tried the true \nabla until your suggestion.


In MkIV: \triangledown is mapped to 0x25BD while nabla is mapped to 
0x2207. These are different glyphs.


IIUC, the difference in placement is because \triangledown is defined as a 
mathop (and hence centered on the math-axis) while \nabla is defined as a 
mathord. Compare:


\startformula
  \nabla T
  \quad
  \triangledown T
  \quad
  \mathop{\nabla} T
\stopformula

From what I remember, I was the one who added the mappings for 
triangledown as a mathop based on, I believe, unicode-math package in 
LaTeX. I don't understand what all the triangle operators are supposed 
to do. As such, I cannot say whether the wrong placement is due to the 
wrong font metrics or the wrong mapping (mathop vs mathord) by ConTeXt.


Aditya
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] \triangledown placed too low in Palatino

2014-04-10 Thread Sanjoy Mahajan
 I cannot say whether the wrong placement is due to the wrong font
 metrics or the wrong mapping (mathop vs mathord) by ConTeXt.

I tried '\triangle T' (often used as the Laplacian operator, instead of
writing it out as \nabla^2).  That one comes out fine, even though
\triangledown does not.  But they seem to have similar kinds of
defintions/mappings:

From luatex-math.tex :

\def\triangle  {\Umathchar  25B3 }
\def\triangledown  {\Umathchar  200025BD }

So it must be a wrong font metric?

-Sanjoy
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] \triangledown placed too low in Palatino

2014-04-10 Thread Aditya Mahajan

On Fri, 11 Apr 2014, Sanjoy Mahajan wrote:


I cannot say whether the wrong placement is due to the wrong font
metrics or the wrong mapping (mathop vs mathord) by ConTeXt.


I tried '\triangle T' (often used as the Laplacian operator, instead of
writing it out as \nabla^2).  That one comes out fine, even though
\triangledown does not.  But they seem to have similar kinds of
defintions/mappings:

From luatex-math.tex :

\def\triangle  {\Umathchar  25B3 }
\def\triangledown  {\Umathchar  200025BD }

So it must be a wrong font metric?


AFAIU, ConTeXt does not use luatex-math.tex. The mappings are defined in 
char-def.lua.


triangle is defined as a mathord (like nabla) while bigtriangleup is a 
mathop (like triangledown).


Aditya
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] \triangledown placed too low in Palatino

2014-04-10 Thread Aditya Mahajan

On Fri, 11 Apr 2014, Aditya Mahajan wrote:


On Fri, 11 Apr 2014, Sanjoy Mahajan wrote:


I cannot say whether the wrong placement is due to the wrong font
metrics or the wrong mapping (mathop vs mathord) by ConTeXt.


I tried '\triangle T' (often used as the Laplacian operator, instead of
writing it out as \nabla^2).  That one comes out fine, even though
\triangledown does not.  But they seem to have similar kinds of
defintions/mappings:

From luatex-math.tex :

\def\triangle  {\Umathchar  25B3 }
\def\triangledown  {\Umathchar  200025BD }

So it must be a wrong font metric?


AFAIU, ConTeXt does not use luatex-math.tex. The mappings are defined in 
char-def.lua.


triangle is defined as a mathord (like nabla) while bigtriangleup is a mathop 
(like triangledown).


Sorry, bigtriangleup is a mathbin. (As I said, I don't understand how the 
mathclass of different triangle operators is determined).


Aditya
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] \triangledown placed too low in Palatino

2014-04-10 Thread Mikael P. Sundqvist
Instead of \triangle you should use \Delta for the laplacian (as you
should use \nabla for the gradient).

Mikael

On Fri, Apr 11, 2014 at 6:06 AM, Sanjoy Mahajan san...@mit.edu wrote:
 I cannot say whether the wrong placement is due to the wrong font
 metrics or the wrong mapping (mathop vs mathord) by ConTeXt.

 I tried '\triangle T' (often used as the Laplacian operator, instead of
 writing it out as \nabla^2).  That one comes out fine, even though
 \triangledown does not.  But they seem to have similar kinds of
 defintions/mappings:

 From luatex-math.tex :

 \def\triangle  {\Umathchar  25B3 }
 \def\triangledown  {\Umathchar  200025BD }

 So it must be a wrong font metric?

 -Sanjoy
 ___
 If your question is of interest to others as well, please add an entry to the 
 Wiki!

 maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
 webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
 archive  : http://foundry.supelec.fr/projects/contextrev/
 wiki : http://contextgarden.net
 ___
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___