Re: [NTG-context] Context logo

2009-03-15 Thread Mojca Miklavec
On Sat, Mar 14, 2009 at 21:52, Xan wrote:

 So it has transparent background, but why gimp says that eps does not
 support transparency? Strange. Really strange.

At least in older versions of (E)PS you cannot use transparent blue
or transparent red to fill shapes for example. But the background is
always transparent even in PostScript in the sense that unless you
explicitely paint the background with white, you can include your
image in another document and you won't see any white white
rectangular border around it.

GIMP doesn't really support EPS. I don't know what you need GIMP for,
but when I need to convert some EPS or PDF image into transparent PNG,
I do:

gs -dSAFER -dBATCH -dNOPAUSE \
  -sDEVICE=pngalpha \
  -dTextAlphaBits=4 \
  -dGraphicsAlphaBits=4 \
  -sOutputFile=converted_file.png \
  -r100.0 \ (put here whatever number you want)
  original_file.pdf

You can try that with the logo and you'll notice the transparent
background with GIMP.

Mojca
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] XeTeX font feature selection

2009-03-15 Thread Mojca Miklavec
On Sat, Mar 14, 2009 at 15:33, John Hughes wrote:
 What is the correct way of selecting a font and using OpenType
 features? I have tried

 \definetypeface[linlib][rm][Xserif][Linux Libertine][features=oldstyle]
 \setupbodyfont[linlib, 12pt]

 but the output prints Computer Modern (and not with old-style
 numerals). The font seems to work without the features=oldstyle, but
 I am not sure how to select the font and some OpenType features. I
 don't seem to be able to find any documentation.

Hello,

the only documentation is type-xtx.tex source code. The Xserif hack
that has originally been written by Adam Lindsey now reads as:

\starttypescript[Xserif][all][name]

\definefontsynonym[Dummy]  [name:\typescripttwo]
[features=default]
\definefontsynonym[Serif]   [Dummy]

This means that [features=default] is hardcoded into the syntax. I
didn't try it, but to make something work the way you would like it,
one would need to modify the hack into something like this:

\definefontsynonym[Dummy] [name:\typescripttwo] [\typescriptthree]

(but this would need some thinking, I do not suggest doing this
modification right away even if it works).

Else you can use classical typescripts as those in pdftex and luatex
(see type-otf.tex, type-tmf.tex etc.) - numerous examples spread
around.

A kind-of-dirty, but most simple trick is to just redefine default features:

From font-ini.mkii:

\definefontfeature
  [default]
  [liga=yes,kern=yes,tlig=yes,trep=yes]
\definefontfeature
  [oldstyle]
  [liga=yes,kern=yes,tlig=yes,trep=yes,onum=yes]

Just put the following definition on top of your document:

\definefontfeature
  [default]
  [liga=yes,kern=yes,tlig=yes,trep=yes,onum=yes]

Mojca
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] Context logo

2009-03-15 Thread Xan

En/na Aditya Mahajan ha escrit:

On Sat, 14 Mar 2009, Xan wrote:




Yes, Wolfgang. Now I understand it.
The actually process is:
texexec prova.tex -- prova.pdf and prova-mpgraph.1 (eps file) 
generated.


and I see what you said.
So it has transparent background, but why gimp says that eps does not 
support transparency? Strange. Really strange.


AFAIU, trasparency is implemented using specials in mp code, so the 
eps (the .1 file) does not contain transparency, but the pdf does. Did 
you open the pdf or the eps file in gimp?
Aditya, when I open pdf or eps file in gimp, gimp pop-up a windows of 
convert the file. When the conversion is completed, it puts white 
background in the image. So I can't see if pdf has _really_ transparent 
background.


Xan.
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] Context logo

2009-03-15 Thread Xan

En/na Mojca Miklavec ha escrit:

On Sat, Mar 14, 2009 at 21:52, Xan wrote:
  

So it has transparent background, but why gimp says that eps does not
support transparency? Strange. Really strange.



At least in older versions of (E)PS you cannot use transparent blue
or transparent red to fill shapes for example. But the background is
always transparent even in PostScript in the sense that unless you
explicitely paint the background with white, you can include your
image in another document and you won't see any white white
rectangular border around it.
  

Okay Mojca.
Anyone knows if newest version of eps support it?

GIMP doesn't really support EPS. I don't know what you need GIMP for,
but when I need to convert some EPS or PDF image into transparent PNG,
I do:

gs -dSAFER -dBATCH -dNOPAUSE \
  -sDEVICE=pngalpha \
  -dTextAlphaBits=4 \
  -dGraphicsAlphaBits=4 \
  -sOutputFile=converted_file.png \
  -r100.0 \ (put here whatever number you want)
  original_file.pdf

You can try that with the logo and you'll notice the transparent
background with GIMP.
  
Thanks Mojca for this script. I did the same with gimp with more more 
effort (open eps file, gimp says that it should convert, then a file 
with white background appears and then I substitute white background 
with transparent background, and save as png file. Uf!!).


Mojca, how is this script for converting pdf file to (newest) eps? For 
seeing if newest eps supports transparency.

Mojca
  

Regards,
Xan.
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] Context logo

2009-03-15 Thread Taco Hoekwater

Xan wrote:


Mojca, how is this script for converting pdf file to (newest) eps? For 
seeing if newest eps supports transparency.


This has nothing to do with 'newest eps'. It is to do with the appalling
support for the eps format in the gimp. Eps has had transparant
backgrounds since day one (a whole quarter-century ago).

Best wishes,
Taco
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] Context logo

2009-03-15 Thread Xan

En/na Taco Hoekwater ha escrit:

Xan wrote:


Mojca, how is this script for converting pdf file to (newest) eps? 
For seeing if newest eps supports transparency.


This has nothing to do with 'newest eps'. It is to do with the appalling
support for the eps format in the gimp. Eps has had transparant
backgrounds since day one (a whole quarter-century ago).

Best wishes,
Taco 

Clear, now.

Thanks for all (all of you),
Xan.
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] What does \c! means?

2009-03-15 Thread Wei-Wei Guo

Hi Taco,

I just finished reading the 'System_Macros'. I still don't get the meaning
of '\??pb @lang@' in the following codes:

  \def\lang#1%
   {\def\biblanguage{#1}%
\ifcsname \??pb @l...@#1\endcsname
\expanded{\mainlanguage[\getvalue{\??pb @l...@#1}]}%
\expanded{\language[\getvalue{\??pb @l...@#1}]}%
 \fi \ignorespaces}

In \lang[zh], for example, '\??pb @lang@' will be expanded to \@@pblangen,
will it? Is \??pb a command? Is '\??pb @lang@' a command? Why can there be
a whitespace in '\??pb @lang@'?

Sorry for some many questions. I'm so confused and don't know what to
search in wiki, manuals, etc..


Best wishes,
Wei-Wei

Taco Hoekwater 写道:

Also generally helpful for a low-level understanding of context are
these wiki pages:

  http://wiki.contextgarden.net/System_Macros

___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] What does \c! means?

2009-03-15 Thread Wolfgang Schuster


Am 15.03.2009 um 16:15 schrieb Wei-Wei Guo:

I just finished reading the 'System_Macros'. I still don't get the  
meaning

of '\??pb @lang@' in the following codes:

 \def\lang#1%
  {\def\biblanguage{#1}%
   \ifcsname \??pb @l...@#1\endcsname
   \expanded{\mainlanguage[\getvalue{\??pb @l...@#1}]}%
   \expanded{\language[\getvalue{\??pb @l...@#1}]}%
\fi \ignorespaces}

In \lang[zh], for example, '\??pb @lang@' will be expanded to  
\@@pblangen,
will it? Is \??pb a command? Is '\??pb @lang@' a command? Why can  
there be

a whitespace in '\??pb @lang@'?


\lang{zh} forms in the \ifcsname ... \endcsname the command  
\@@p...@lang@zh

and looks if the commands is defined, if this is true the language is
switched to chinese.


Sorry for some many questions. I'm so confused and don't know what to
search in wiki, manuals, etc..


The \??bp at the begin of the macro is ConTeXt's system to create a  
namespace.


To understand I have to go a little bit away from the above macro and  
will
explain it on ConText's command to create key-val list. With the  
internal
command \getparameters is used to create key-val-lists, this is done  
with


  \getparameters[mycommand][width=1cm,height=2cm,align=right]

This creates the commands \mycommandwidth with the value 1cm,  
\mycommandheight
with the value 2cm and \mycommandalign with the value right. The text  
in the
first brace is the namespace which is used as prefix for each created  
command.
To optimize this operation and save a little bit of TeX's register we  
replace
'mycommand' with '\mycommand' which expand itself \mycommand, to make  
this
system more consystem ConTeXt use the convetion to use namespaces with  
two
question marks and two (or more) letter like the above \??bp, you can  
more

of this tricks in a article from Hans [1].

The space after '\??bp' and the \lang macro above is necessary because  
TeX
thinks otherwise '@lang@' is a part of the '\??bp' command and to  
prevent

this Taco puts the space there.

As a normal user you don't want to write macros or as beginner in  
ConTeXT
programming you don't have to care about this but it's good to know  
why are

things done in this way to understand system macros.

[1] http://www.ntg.nl/maps/22/27.pdf

Wolfgang

___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] What does \c! means?

2009-03-15 Thread Hans Hagen

Wei-Wei Guo wrote:

Hi Taco,

I just finished reading the 'System_Macros'. I still don't get the meaning
of '\??pb @lang@' in the following codes:

  \def\lang#1%
   {\def\biblanguage{#1}%
\ifcsname \??pb @l...@#1\endcsname
\expanded{\mainlanguage[\getvalue{\??pb @l...@#1}]}%
\expanded{\language[\getvalue{\??pb @l...@#1}]}%
 \fi \ignorespaces}

In \lang[zh], for example, '\??pb @lang@' will be expanded to \@@pblangen,
will it? Is \??pb a command? Is '\??pb @lang@' a command? Why can there be
a whitespace in '\??pb @lang@'?


\??pb creates a namespace so you cannot mess with it in your document 
easily


\??pb is just a macro and the ?? makes it kind of private (hidden)

there has to be a whitespace otherwise you'd call for \?...@lang@


Sorry for some many questions. I'm so confused and don't know what to
search in wiki, manuals, etc..


this is not stuff most users want to know or see; add a few 
\expandafter's, \futurelet's and \afterassignments and one wonders in 
what universe one has ended up


Hans

-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
 tel: 038 477 53 69 | fax: 038 477 53 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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] pinyin in context

2009-03-15 Thread Hans Hagen

Bill Long wrote:

so


http://picasaweb.google.com/lh/sredir?uname=weilai.longtarget=ALBUMid=5313243080349643217authkey=Gv1sRgCJLO9v__gOPr_gEfeat=email


is the result of


\ruby{静}{\jing4} \ruby{夜}{\ye4}\ruby{思}{\si1}


i.e. you want transliterations on top?

is that \jing4 a convention or something specific for tex packages

Hans

-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
 tel: 038 477 53 69 | fax: 038 477 53 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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] die if a module is missing

2009-03-15 Thread Hans Hagen

Aditya Mahajan wrote:

On Sat, 14 Mar 2009, Hans Hagen wrote:


Michael Bynum wrote:

This has burned me too.  It would be nice if the errors were more
prominent, perhaps repeated at the end of the output?


ok, i do repeat it now; aborting the run is no options as some modules 
might have been removed due to integration in the core


Then the user should know that and update the source file :-). It can be 
a normal error prompt, the one where you get a question mark and are 
asked if you want to continue or abort (rather than enter the file name 
prompt of \input).


I do feel that for user modules, there should be an error when the 
module is not found. If you do not want the above behaviour as a 
default, it could be a configurable option.


i'm thinking of something \enableoptions[...] (analogue to the mkiv 
\enabletrackers) but then we need to move more configuration options to 
this mechanisms, so it will be something mkiv only


Hans


-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
 tel: 038 477 53 69 | fax: 038 477 53 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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] \FlushStep in module s-pre-50 adds too much space

2009-03-15 Thread Hans Hagen

Curious Learn wrote:

Hello,

I tried using module s-pre-50 to get stepwise revelation of the content in my
presentation today. I noticed that the command \FlushStep adds what seems to be
too much space between successive items. Is there a way, I can prevent
\FlushStep from adding this much space.


depends on mkii vs mkiv

in mkii it's injecting nodes, so you need to keep the \FlushStep 
attached to the previous paragraph if possible like here\FlushStep


in mkiv it should not matter

-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
 tel: 038 477 53 69 | fax: 038 477 53 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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] pinyin in context

2009-03-15 Thread Wolfgang Schuster


Am 15.03.2009 um 04:23 schrieb Bill Long:


Dear Hans,

Can you help check if you can implement a new feature of pinyin
input in context?



Is a lua based method a option for you?

Here is a primitive converter, not perfect and could fail but it gives
you a first impression, the missing 'ǎ' in the output is a font  
problem.


\startluacode

function commands.convertpinyin(text,number)
local replaced
local number = tonumber(number)
if string.find(text,a) or string.find(text,e) then
if number==1 then
text = string.gsub(text,a,ā)
text = string.gsub(text,e,ē)
elseif number==2 then
text = string.gsub(text,a,á)
text = string.gsub(text,e,é)
elseif number==3 then
text = string.gsub(text,a,ǎ)
text = string.gsub(text,e,ě)
elseif number==4 then
text = string.gsub(text,a,à)
text = string.gsub(text,e,è)
end
replaced = false
else
replaced = true
end
while replaced do
if number==1 then
text = string.gsub(text,i,ī)
text = string.gsub(text,o,ō)
if string.find(text,o) then else text =  
string.gsub(text,u,ū) end

text = string.gsub(text,v,ǖ)
elseif number==2 then
text = string.gsub(text,i,í)
text = string.gsub(text,o,ó)
if string.find(text,o) then else text =  
string.gsub(text,u,ú) end

text = string.gsub(text,v,ǘ)
elseif number==3 then
text = string.gsub(text,o,ǒ)
text = string.gsub(text,i,ǐ)
if string.find(text,o) then else text =  
string.gsub(text,u,ǔ) end

text = string.gsub(text,u,ǔ)
text = string.gsub(text,v,ǚ)
elseif number==4 then
text = string.gsub(text,o,ò)
text = string.gsub(text,i,ì)
if string.find(text,o) then else text =  
string.gsub(text,u,ù) end

text = string.gsub(text,v,ǜ)
end
replaced = false
end
tex.sprint(tex.ctxcatcodes,text)
end

local letter = lpeg.R(az)
local number = lpeg.R(09)

local pinyin = lpeg.C(letter^1) * lpeg.C(number^0) /  
commands.convertpinyin


local parser = (pinyin)^0

function commands.pinyin(str)
parser:match(str)
end

\stopluacode

\def\pinyin#1{\ctxlua{commands.pinyin([[#1]])}}

\starttext

\pinyin{ni2hao3}
\pinyin{huai4}

\stoptext

Wolfgang

___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


[NTG-context] horoffset singlesided/doublesided

2009-03-15 Thread Alan Stone
Hi,

\showframe

\setuplayout[width=.65\paperwidth,hoffset=1cm,margin=0cm]
\setuphead[chapter][page=right]

%\setuppagenumbering[alternative=singlesided]  % horoffset_ss.pdf
\setuppagenumbering[alternative=doublesided]  % horoffset_ds.pdf

\starttext
\dorecurse{2}{\chapter{Chapter #1}\dorecurse{8}{\input knuth}}
\stoptext

For

- horoffset_ds.pdf and
- horoffset_ss.pdf

how do you define horoffset so that for the

- odd pages the layout |horoffset|...|text|...|   is
- even pages the layout|...|text|...|horoffset|   is

Alan


horoffset_ds.pdf
Description: Adobe PDF document


horoffset_ss.pdf
Description: Adobe PDF document
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] horoffset singlesided/doublesided

2009-03-15 Thread Wolfgang Schuster


Am 15.03.2009 um 21:49 schrieb Alan Stone:


\setuplayout[width=.65\paperwidth,hoffset=1cm,margin=0cm]


Why do you believe \setuplayout has a 'hoffset' parameter, the distance
between the left margin and the text is set with 'backspace'.


how do you define horoffset so that for the


\setuppagenumbering[alternative={singlesided,doublesided}]

Wolfgang

___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


[NTG-context] math problems

2009-03-15 Thread Mohamed Bana

hi guys,

i generally use this file to test if math is working, with the recent
update i get a lot of errors such as;

! Missing number, treated as zero.
to be read again
 $
\@@dobig ...o #1\bodyfontsize {}\right @space $
}}
\...@mt@defaultBigl ...\puremathcomm {open}{\Big {#1}
}
l.99 \pauli = \dirac^2 = \Bigl(
 \sum_{j=1}^2
\sigma_j\big(-i\PD{}{x^j}-a_j\bi...

?


with texlive 2008 it works just fine, i've attached the output of the
TL2008.  i'm certain that the same file was compiling just fine with (i
think) luatex 0.31 (or pre 0.31).

the content is from Mikael Persson's thesis.

Mohamed


\usemodule[bib]

\def\mathbb#1{{\blackboard #1}}
\def\pauli{\mathfrak{P}}
\def\mathfrak#1{{\fraktur #1}}


% Matriser av olika typ.
% Paranthesis
\definemathmatrix
[pmatrix]
[left={\left(\,},right={\,\right)}]
% Brackets
\definemathmatrix
[bmatrix]
[left={\left[\,},right={\,\right]}]
% Curly braces
\definemathmatrix
[Bmatrix]
[left={\left\{\,},right={\,\right\}}]
% vertical bars
\definemathmatrix
[vmatrix]
[left={\left\vert\,},right={\,\right\vert}]
% double vertical bars
\definemathmatrix
[Vmatrix]
[left={\left\Vert\,},right={\,\right\Vert}]

\def\PD#1#2{\frac{\partial #1}{\partial #2}}
\def\ann{\mathscr{Q}^{\vphantom{*}}}
\def\mathscr#1{{\gothic #1}}
\def\cre{\mathscr{Q}^*}
\def\dirac{{\mathfrak{D}}}
\def\pform{\mathfrak{p}}
\def\ed{\mfunction{\,d}}
\definemathcommand [dom] [nolop] {\mfunction{Dom}}
\def\bz{\bar{z}}
\def\psip{{\psi_+}}
\def\psim{{\psi_-}}

% \eqref
\definereferenceformat[eqref][left=(,right=)]

\defineenumeration[problem]
[text=Problem,
location=serried,
width=fit,
indenting=first,
distance=0.5em,
	way=bysection,
]

\subsubsection[ksec:paulitvad]{The Pauli operator in $\mathbb{R}^2$}

A charged spin $1/2$ particle is described by the Pauli Hamiltonian, which acts in $L_2(\mathbb{R}^2)\otimes \mathbb{C}^2$, and is formally defined as
\placeformula[keq:pauli]
\startformula
\pauli = 
\startpmatrix
\NC H-\frac{g}{2}B \NC 0 \NR
\NC 0 \NC H+\frac{g}{2}B\NR
\stoppmatrix.
\stopformula
Here $H$ is the two-dimensional Schrödinger Hamiltonian $H=(-i\nabla -\vec{a})^2$, $B$ is the magnetic field (In two dimensions we identify the two-form and the coefficient function), and $g$ is the {\em gyromagnetic ratio}. We identify the real point $(x^1,x^2)$ with the complex number $z=x^1+ix^2$, and denote a scalar potential of $B$ by $W$,
\startformula
-\Delta W = B.
\stopformula
We set $\Pi_j = -i\PD{}{x^j}-a_j$ and
\startformula
 \ann = \Pi_1 - i \Pi_2,\quad \cre = \Pi_1 + i\Pi_2,
\stopformula
and note that
\placeformula[keq:komm]
\startformula
\ann\cre=\cre\ann+2B,\quad H=\cre\ann+B=\ann\cre-B.
\stopformula
From~\eqref[keq:pauli] and~\eqref[keq:komm] we get
\placeformula[keq:paulig]
\startformula
\pauli = 
\startpmatrix
\NC \cre\ann-\frac{g-2}{2}B \NC 0 \NR
\NC 0 \NC \ann\cre+\frac{g-2}{2}B\NR
\stoppmatrix.
\stopformula
The number $\frac{g-2}{2}$ is called the {\em anomaly factor} of the magnetic moment. Experiments give an anomaly factor of $0.00159$ for the electron~\cite[bovo]. We assume that $g=2$, which is the simplest case. Thus, the Pauli Hamiltonian we study in this thesis is formally defined by
\placeformula[keq:pauliw]
\startformula
\pauli = 
\startpmatrix
\NC \cre\ann \NC 0 \NR
\NC 0 \NC \ann\cre\NR
\stoppmatrix.
\stopformula
The Pauli operator can be written as the square of the Dirac operator
\placeformula[keq:paulia]
\startformula
\pauli = \dirac^2 = \Bigl(\sum_{j=1}^2 \sigma_j\big(-i\PD{}{x^j}-a_j\big)\Bigr)^2 = 
\startpmatrix
\NC 0 \NC \cre \NR
\NC \ann \NC 0\NR
\stoppmatrix^2
\stopformula
from which it follows that it is a non-negative operator. Now let us be more precise about the domains. As in the case of the Schrödinger Hamiltonian there is a problem in defining the Pauli Hamiltonian if the magnetic field is too singular. The quadratic form corresponding to $\pauli$ is given by
\placeformula[keq:pform]
\startformula
\pform(\psi,\psi)= \int_{\mathbb{R}^2} \Big|\sum_{j=1}^2 \sigma_j\big(-i\PD{}{x^j}-a_j\big)\psi\Big|^2\ed m(x).
\stopformula

If $\vec{a}\in L_{2,\text{loc}}(\mathbb{R}^2)\otimes \mathbb{R}^2$ then $\pform(\psi,\psi)$ makes sense for $\psi\in C_0^\infty(\mathbb{R}^2)\otimes \mathbb{C}^2$. We define the {\em minimal} Pauli form $\pform_{\text{min}}$ as
\startformula
\startalign
\NC \dom(\pform_{\text{min}}) \NC = C_0^\infty(\mathbb{R}^2)\otimes \mathbb{C}^2;\NR
\NC \pform_{\text{min}}(\psi,\psi) \NC = \pform(\psi,\psi),\quad \psi\in\dom(\pform_{\text{min}}).\NR
\stopalign
\stopformula
It is closable and thus a self-adjoint operator $\pauli_{\text{min}}$ can be defined. We also define the {\em maximal} Pauli form $\pform_{\text{max}}$ as
\placeformula
\startformula
\startalign
\NC \dom(\pform_{\text{max}}) \NC = \bigl\{\,\psi\in L_2(\mathbb{R}^2)\otimes \mathbb{C}^2\bigm| 

Re: [NTG-context] math problems

2009-03-15 Thread Aditya Mahajan

On Sun, 15 Mar 2009, Mohamed Bana wrote:


hi guys,

i generally use this file to test if math is working, with the recent
update i get a lot of errors such as;


Add

\let\blackboard\mathblackboard
\let\fraktur\mathfraktur
\let\gothic\mathfraktur

in your preamble.

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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] \FlushStep in module s-pre-50 adds too much space

2009-03-15 Thread Curious Learn
Hans Hagen pragma at wxs.nl writes:


 in mkii it's injecting nodes, so you need to keep the \FlushStep 
 attached to the previous paragraph if possible like here\FlushStep
 
 in mkiv it should not matter

Thank you Hans. I will try to install Context Minimals in a couple of days. In
MKII it does not help even if I keep it attached to the previous paragraph. 

The reason I have not been installing Context Minimals is that I am not sure how
I will make the text editor I use (TextMate) to use it. The instructions for Mac
OS X talk about TexShop and another one, but not textmate. Also, from the
instructions (for Mac OSx) it is not clear whether it will install the latest
stable version or the latest beta. 

If anyone can clarify these things that would be great.

In any case, when will MKIV be included in the TexLive distribution.

___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] \FlushStep in module s-pre-50 adds too much space

2009-03-15 Thread Wolfgang Schuster


Am 16.03.2009 um 02:56 schrieb Curious Learn:

The reason I have not been installing Context Minimals is that I am  
not sure how
I will make the text editor I use (TextMate) to use it. The  
instructions for Mac
OS X talk about TexShop and another one, but not textmate. Also,  
from the
instructions (for Mac OSx) it is not clear whether it will install  
the latest

stable version or the latest beta.


http://wiki.contextgarden.net/TextMate

Wolfgang

___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] \FlushStep in module s-pre-50 adds too much space

2009-03-15 Thread Aditya Mahajan

On Mon, 16 Mar 2009, Curious Learn wrote:


Hans Hagen pragma at wxs.nl writes:



in mkii it's injecting nodes, so you need to keep the \FlushStep
attached to the previous paragraph if possible like here\FlushStep

in mkiv it should not matter


Thank you Hans. I will try to install Context Minimals in a couple of days. In
MKII it does not help even if I keep it attached to the previous paragraph.

The reason I have not been installing Context Minimals is that I am not sure how
I will make the text editor I use (TextMate) to use it. The instructions for Mac
OS X talk about TexShop and another one, but not textmate.


I don't know this, I have never used TextMate. Normally, if you open your 
editor from a terminal, you can just source setuptex before opening your 
editor, and everything should work fine.



Also, from the
instructions (for Mac OSx) it is not clear whether it will install the latest
stable version or the latest beta.

If anyone can clarify these things that would be great.


Mac installation is same as any other Unix like system. See details at
http://wiki.contextgarden.net/ConTeXt_Minimals. By default, beta 
installation is installed, but you can pass --context=current to get the 
stable distribution.



In any case, when will MKIV be included in the TexLive distribution.


It already is. See http://wiki.contextgarden.net/Running_Mark_IV

Bascically, you need to run luatools --generate and context --make, then 
you can you context filename to use mkiv.


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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] What does \c! means?

2009-03-15 Thread Wei-Wei Guo

Thanks, Wolfgang and Hans.


Best wishes,
Wei-Wei


Hans Hagen 写道:


this is not stuff most users want to know or see; add a few 
\expandafter's, \futurelet's and \afterassignments and one wonders in 
what universe one has ended up


Hans


___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___