summaryrefslogtreecommitdiff
path: root/Master/texmf-dist
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2018-06-18 21:01:37 +0000
committerKarl Berry <karl@freefriends.org>2018-06-18 21:01:37 +0000
commit1011cbf2d4d612c1af27e0b40507dac7cb40308c (patch)
tree63da68783d84f7fc66dfd783083de7b2ff98d230 /Master/texmf-dist
parent683c92e5313906003d77d51a5d3b41a16c7ce438 (diff)
mcf2graph (18jun18)
git-svn-id: svn://tug.org/texlive/trunk@48046 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist')
-rw-r--r--Master/texmf-dist/doc/metapost/mcf2graph/CHANGELOG8
-rw-r--r--Master/texmf-dist/doc/metapost/mcf2graph/README2
-rw-r--r--Master/texmf-dist/doc/metapost/mcf2graph/mcf_exa_soc.mf34
-rw-r--r--Master/texmf-dist/doc/metapost/mcf2graph/mcf_example.pdfbin235065 -> 235044 bytes
-rw-r--r--Master/texmf-dist/doc/metapost/mcf2graph/mcf_example.tex2
-rw-r--r--Master/texmf-dist/doc/metapost/mcf2graph/mcf_man_soc-064.eps2
-rw-r--r--Master/texmf-dist/doc/metapost/mcf2graph/mcf_man_soc.mf20
-rw-r--r--Master/texmf-dist/doc/metapost/mcf2graph/mcf_manual.pdfbin475648 -> 476093 bytes
-rw-r--r--Master/texmf-dist/doc/metapost/mcf2graph/mcf_manual.tex33
-rw-r--r--Master/texmf-dist/doc/metapost/mcf2graph/mcf_mplib_exa.pdfbin179634 -> 179526 bytes
-rw-r--r--Master/texmf-dist/doc/metapost/mcf2graph/mcf_mplib_exa.tex48
-rw-r--r--Master/texmf-dist/metapost/mcf2graph/mcf2graph.mf150
12 files changed, 181 insertions, 118 deletions
diff --git a/Master/texmf-dist/doc/metapost/mcf2graph/CHANGELOG b/Master/texmf-dist/doc/metapost/mcf2graph/CHANGELOG
index a103f960870..51a7cac05e6 100644
--- a/Master/texmf-dist/doc/metapost/mcf2graph/CHANGELOG
+++ b/Master/texmf-dist/doc/metapost/mcf2graph/CHANGELOG
@@ -1,6 +1,12 @@
*******************************************************************************
- Changelog of mcf2graph software package by Akira Yamaji 2018-06-03
+ Changelog of mcf2graph software package by Akira Yamaji 2018-06-18
*******************************************************************************
+[ver. 4.33 / 2018-06-18]
+ -change syntax n:&
+ n:& => n:#
+ -add command &"c"
+ -update MCF manual and examples
+
[ver. 4.32 / 2018-06-03]
-add commands C[],N[],O[],S[]
X[1] : "{X^+^}"
diff --git a/Master/texmf-dist/doc/metapost/mcf2graph/README b/Master/texmf-dist/doc/metapost/mcf2graph/README
index 53e803731d3..02d15fa1245 100644
--- a/Master/texmf-dist/doc/metapost/mcf2graph/README
+++ b/Master/texmf-dist/doc/metapost/mcf2graph/README
@@ -1,7 +1,7 @@
********************************************************************************
mcf2graph : Convert Molecular Coding Format to graphics with METAFONT/METAPOST
Author : Akira Yamaji
- version : 4.32 2018-06-03
+ version : 4.33 2018-06-18
E-mail : mcf2graph@gmail.com
Located at : http://www.ctan.org/pkg/mcf2graph
********************************************************************************
diff --git a/Master/texmf-dist/doc/metapost/mcf2graph/mcf_exa_soc.mf b/Master/texmf-dist/doc/metapost/mcf2graph/mcf_exa_soc.mf
index c510dcc2e47..b97f73ae3f4 100644
--- a/Master/texmf-dist/doc/metapost/mcf2graph/mcf_exa_soc.mf
+++ b/Master/texmf-dist/doc/metapost/mcf2graph/mcf_exa_soc.mf
@@ -1,7 +1,7 @@
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-% Molecular Coding Format for mcf_example.tex by Akira Yamaji 2018.06.03
+% Molecular Coding Format for mcf_example.tex by Akira Yamaji 2018.06.18
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-input mcf2graph.mf; %%% it must be version 4.32 or later
+input mcf2graph.mf; %%% it must be version 4.33 or later
%-------------------------------------------------------------------------
font_wd:=33mm;
font_ht:=24mm;
@@ -74,7 +74,7 @@ endfont
%***************************************************************************
beginfont("EN:Oxine-Copper","MW:351.852")
MCf(Ph,4:N,5=Ph,-4:\,O,-60,<90,Cu,-90,O,60,|,Ph,5=Ph,10:N,
- ||,4:@,12~vf:&,23:@,12~vf:&)
+ ||,4:@,12~vf:#,23:@,12~vf:#)
endfont
%***************************************************************************
beginfont("EN:Captan","MW:300.578")
@@ -92,7 +92,7 @@ beginfont("EN:Tetraconazole","MW:372.145")
endfont
%***************************************************************************
beginfont("EN:Endosulfan","MW:406.904");
- MCf(<26,?7,7=?6[13],11:@,208~wf`1.45,8~wb:&,10=d,{3,5}:O,4:S,4://O,
+ MCf(<26,?7,7=?6[13],11:@,208~wf`1.45,8~wb:#,10=d,{3,5}:O,4:S,4://O,
{8,9,10,11,12^-210,12^-150}:/Cl)
endfont;
%***************************************************************************
@@ -179,7 +179,7 @@ beginfont("EN:Rifampicin","MW:822.94")
|,-8=?6,{2,4}=dl,{1,4}:/OH,
|<=1,-2:\,NH,60,//O,-60,/_,60~dl,60,60~dl,-60,
*/_,60,/*OH,-60,/*_,60,/*OH,60,*/_^30,-60,
- 60,/*_^30,-53,66,-53~dl,66`1.2,O,>|,$8:&,
+ 60,/*_^30,-53,66,-53~dl,66`1.2,O,>|,$8:#,
-4:/*O!,-6:@,-30,O,!,//O,!,$11:\,!!,N,!,|,?6,{1,4}:N,4:/_)
endfont
%***************************************************************************
@@ -212,16 +212,16 @@ endfont
%***************************************************************************
beginfont("EN:Chlorophyll a","MW:893.509")
MCf(<54,|<=1,?5,{2,5}=dl,4:N,3:\,54~dl,|,?5,{2,4}=dl,5:N,
- -2:\,54~dl,|,?5,2=d,5:N,-2:\~dl,54,|,?5,5=d,5:N,-2:\~dl,$5:&,
- -1:@,24,/*COO!^15,72,//O,$1:&,>|,
+ -2:\,54~dl,|,?5,2=d,5:N,-2:\~dl,54,|,?5,5=d,5:N,-2:\~dl,$5:#,
+ -1:@,24,/*COO!^15,72,//O,$1:#,>|,
{2,9,15,20~zf}:/_,8:/!,14:\,!!,
- $4:\`1.45,Mg,17:&,-1:@,11~vb:&,-1:@,23~vb:&,
+ $4:\`1.45,Mg,17:#,-1:@,11~vb:#,-1:@,23~vb:#,
$21:@,-6~wf,!2,//O,!,O,!2,!!,|,!13,{1,5,9,13}:/_)
endfont
%**************************************************************************
beginfont("EN:Gibberellin A3","MW:346.379");
- MCf(<18,?5,3=?7,5=?6[12],8:@,160`1.3,3:&,13=dl,6=wf,8=wb,
- 5:@,40~zf`1,O,50,//O^180,14~zb:&,
+ MCf(<18,?5,3=?7,5=?6[12],8:@,160`1.3,3:#,13=dl,6=wf,8=wb,
+ 5:@,40~zf`1,O,50,//O^180,14~zb:#,
2:/COOH,7://_,13:*/OH,8:/*OH,14:*/_,{1,4}:*/H^60)
endfont;
%**************************************************************************
@@ -237,8 +237,8 @@ beginfont("EN:Lycorine","MW:287.315")
endfont
%**************************************************************************
beginfont("EN:Tetrodotoxine","MW:319.27")
- MCf(|<=1,<60,-90,60,-30`1.15,150,60,$1:&,$3:@,-135,60,-30`1.15,150,$4:&,
- $10:\,O,60`1.33,60,$3~si_:&,$8:@,-15~si_,O,$12:&,>|,
+ MCf(|<=1,<60,-90,60,-30`1.15,150,60,$1:#,$3:@,-135,60,-30`1.15,150,$4:#,
+ $10:\,O,60`1.33,60,$3~si_:#,$8:@,-15~si_,O,$12:#,>|,
$9:@,45,-60,OH,1^120://NH,
{5~zf^-15,7,9^-75,12,13~zf}:/OH,{2,6^180}:NH)
endfont
@@ -346,7 +346,7 @@ beginfont("EN:Pyrethrin I","MW:328.452");
endfont;
%***************************************************************************
beginfont("EN:Erythromycin","MW:733.937");
-MCf(<30,|<=1,<-120,60,60,60,-60,60,60,-60,60,60,60,-60,60,60,>|,1:&,
+MCf(<30,|<=1,<-120,60,60,60,-60,60,60,-60,60,60,60,-60,60,60,>|,1:#,
14:O,13:/*!,{1,9}://O,{2,10}:*/_,{4,6^-35,8,12^35}:/*_,
{6^35,11,12^-35}:*/OH,
$3:\*,O,30,|,?6`.7,2:O,{3,5^35}:/_,4:/OH,5^-35:/O!,
@@ -354,7 +354,7 @@ MCf(<30,|<=1,<-120,60,60,60,-60,60,60,-60,60,60,60,-60,60,60,>|,1:&,
endfont;
%**************************************************************************
beginfont("EN:Paclitaxel","MW:853.918")
- MCf(?6,5=d,3:@,|<=1,36,45,45,45,45,>|,$5:&,-4=?6,-4=?4,||,-1=wb,-3=wf,-1:O,
+ MCf(?6,5=d,3:@,|<=1,36,45,45,45,45,>|,$5:#,-4=?6,-4=?4,||,-1=wb,-3=wf,-1:O,
{4^35,4^-35,6}:/_,{3^-60,15}:*/OH,8:/*H^-60,9:*/_^60,10://O,
$1:\,O,!,//O,!,*/OH,!,/Ph,60~wf,NH,-60,//O,60,Ph,
$7:\*,O,-45,//O,60,Ph,$11:*\,O,-60,//O,60,$12:\*^-15,O,60,//O,-60)
@@ -372,7 +372,7 @@ endfont
%**************************************************************************
beginfont("EN:Morphine","MW:285.343")
MCf(<30,Ph,2=?6,-4=?6,(1,12)=?5[2],-1:O,-1=zb,
- 7:@,60~wf`0.75,70~si_`1.3,45,N,/_,9~wb:&,
+ 7:@,60~wf`0.75,70~si_`1.3,45,N,/_,9~wb:#,
15=d,6:/OH,8^180:*/H,12:/*OH)
endfont
%**************************************************************************
@@ -382,12 +382,12 @@ endfont
%***************************************************************************
beginfont("EN:Quinine","MW:324.424")
MCf(<30,Ph,3=Ph,7:N,6:/O!,
- 10:\,*/OH,/H~zf^-60,!,|,?6,2:N,1:*/H^60,4:*\,!!,2:@,165~zf,60,5~zb:&)
+ 10:\,*/OH,/H~zf^-60,!,|,?6,2:N,1:*/H^60,4:*\,!!,2:@,165~zf,60,5~zb:#)
endfont
%***************************************************************************
beginfont("EN:Atoropin","MW:289.375")
MCf(<-30,O,!,//O,!,!,Ph,
- $1:\~zb^-120,|,?7`1.1,6:*\^190`1.25,N,/_,3~wb:&,$3:/!OH~wv)
+ $1:\~zb^-120,|,?7`1.1,6:*\^190`1.25,N,/_,3~wb:#,$3:/!OH~wv)
endfont
%***************************************************************************
bye
diff --git a/Master/texmf-dist/doc/metapost/mcf2graph/mcf_example.pdf b/Master/texmf-dist/doc/metapost/mcf2graph/mcf_example.pdf
index ea64258787c..c050d3b9fe7 100644
--- a/Master/texmf-dist/doc/metapost/mcf2graph/mcf_example.pdf
+++ b/Master/texmf-dist/doc/metapost/mcf2graph/mcf_example.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/metapost/mcf2graph/mcf_example.tex b/Master/texmf-dist/doc/metapost/mcf2graph/mcf_example.tex
index 9c078593201..460e6b14c1a 100644
--- a/Master/texmf-dist/doc/metapost/mcf2graph/mcf_example.tex
+++ b/Master/texmf-dist/doc/metapost/mcf2graph/mcf_example.tex
@@ -1,5 +1,5 @@
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-% Example of MCF typeset by LaTeX mcf_examples.tex by A.Yamaji 2018.04.16
+% Example of MCF typeset by LaTeX mcf_examples.tex by A.Yamaji 2018.06.18
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\documentclass[a4paper]{article}
\usepackage{graphicx}
diff --git a/Master/texmf-dist/doc/metapost/mcf2graph/mcf_man_soc-064.eps b/Master/texmf-dist/doc/metapost/mcf2graph/mcf_man_soc-064.eps
index 6e3f08e73da..38a5af157e0 100644
--- a/Master/texmf-dist/doc/metapost/mcf2graph/mcf_man_soc-064.eps
+++ b/Master/texmf-dist/doc/metapost/mcf2graph/mcf_man_soc-064.eps
@@ -2,7 +2,7 @@
%%BoundingBox: -1 -1 212 60
%%HiResBoundingBox: -0.09962 -0.09962 211.90288 59.64348
%%Creator: MetaPost 2.00
-%%CreationDate: 2018.06.03:2010
+%%CreationDate: 2018.06.18:0626
%%Pages: 1
%%DocumentResources: procset mpost-minimal
%%+ font NJFVSO-NimbusSanL-Regu ICXWUR-CMR8
diff --git a/Master/texmf-dist/doc/metapost/mcf2graph/mcf_man_soc.mf b/Master/texmf-dist/doc/metapost/mcf2graph/mcf_man_soc.mf
index bae2cbb6d62..2c171b5cb80 100644
--- a/Master/texmf-dist/doc/metapost/mcf2graph/mcf_man_soc.mf
+++ b/Master/texmf-dist/doc/metapost/mcf2graph/mcf_man_soc.mf
@@ -1,7 +1,7 @@
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-% Molecular Coding Format file for mcf_manual.tex by Akira.Yamaji 2018.06.03
+% Molecular Coding Format file for mcf_manual.tex by Akira.Yamaji 2018.06.18
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-input mcf2graph.mf; %% it must be version 4.32 or later
+input mcf2graph.mf; %% it must be version 4.33 or later
%------------------------------------------------------------------------
sw_aux_out:=0;
sw_mol_frame:=0;
@@ -208,7 +208,7 @@ beginfont("EN:Connect atom")
sw_numberA:=1;
ratio_chain_ring:=1;
%----------------------------------------------------------------------
- MCf(<30,!6,3:\,!,5~bd:&)
+ MCf(<30,!6,3:\,!,5~bd:#)
endfont
%***********************************************************************
beginfont("EN:ring")
@@ -362,7 +362,7 @@ beginfont("EN:Charged atom")
sw_clip:=1;
font_wd:=60mm;
font_ht:=15mm;
- MCf(<-30,!2,N[1],!2,O[-1])
+ MCf(<-30,!2,N[1],!2,O[-1],!2,&"-",!2,N,&"+"^180,!)
endfont
%***********************************************************************
beginfont("EN:fused ring")
@@ -1010,7 +1010,7 @@ endfont
%***************************************************************************
beginfont("EN:Endosulfan","MW:406.904");
font_ht:=25mm;
- MCf(<26,?7,7=?6[13],11:@,208~wf`1.45,8~wb:&,10=d,{3,5}:O,4:S,4://O,
+ MCf(<26,?7,7=?6[13],11:@,208~wf`1.45,8~wb:#,10=d,{3,5}:O,4:S,4://O,
{8,9,10,11,12^-210,12^-150}:/Cl)
endfont;
%***************************************************************************
@@ -1055,21 +1055,21 @@ endfont
%***********************************************************************
beginfont("EN:Gibberellin A3","CAS:77-06-5","FM:C19H22O6","MW:346.37");
font_ht:=20mm;
- MCf(<18,?5,3=?7,5=?6[12],8:@,160`1.3,3:&,13=dl,6=wf,8=wb,
- 5:@,40~zf`1,O,50,//O^180,14~zb:&,
+ MCf(<18,?5,3=?7,5=?6[12],8:@,160`1.3,3:#,13=dl,6=wf,8=wb,
+ 5:@,40~zf`1,O,50,//O^180,14~zb:#,
2:/COOH,7://_,13:*/OH,8:/*OH,14:*/_,{1,4}:*/H^60)
endfont
%***************************************************************************
beginfont("EN:Quinine","CAS:130-95-0","FM:C20H24N2O2","MW:324.42")
font_ht:=25mm;
MCf(<30,Ph,3=Ph,7:N,6:/O!,
- 10:\,*/OH,/H~zf^-60,!,|,?6,2:N,1:*/H^60,4:*\,!!,2:@,165~zf,60,5~zb:&)
+ 10:\,*/OH,/H~zf^-60,!,|,?6,2:N,1:*/H^60,4:*\,!!,2:@,165~zf,60,5~zb:#)
endfont
%***************************************************************************
beginfont("EN:Atoropin","CAS:51-55-8","FM:C17H23NO3","MW:289.37")
font_ht:=25mm;
MCf(<-30,O,!,//O,!,!,Ph,
- $1:@,-120~zb,|,?7,6:*\^190`1.12,N,/_,3~wb:&,$3:*\*,!,OH)
+ $1:@,-120~zb,|,?7,6:*\^190`1.12,N,/_,3~wb:#,$3:*\*,!,OH)
endfont
%***************************************************************************
beginfont("EN:Rotenone");
@@ -1092,7 +1092,7 @@ endfont
%***************************************************************************
beginfont("EN:Paclitaxel","CAS:33069-62-4","FM:C47H51NO14","MW:853.91")
MCf(?6,5=dl,3:@,|<,``1,36,45,45,45,45,>|,
- $5:&,-4=?6,-4=?4,-1=wb,-3=wf,-1:O,||,
+ $5:#,-4=?6,-4=?4,-1=wb,-3=wf,-1:O,||,
{4^35,4^-35,6}:/_,{3^-60,15}:*/OH,8:/*H^-60,9:*/_^60,10://O,
1:\,O,!,//O,!,*/OH,!,/Ph,60~wf,NH,-60,//O,60,Ph,
7:\*,O,-45,//O,60,Ph,11:*\,O,-60,//O,60,12:\*^-15,O,60,//O,-60)
diff --git a/Master/texmf-dist/doc/metapost/mcf2graph/mcf_manual.pdf b/Master/texmf-dist/doc/metapost/mcf2graph/mcf_manual.pdf
index c976c47ff4a..638d03bcdd0 100644
--- a/Master/texmf-dist/doc/metapost/mcf2graph/mcf_manual.pdf
+++ b/Master/texmf-dist/doc/metapost/mcf2graph/mcf_manual.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/metapost/mcf2graph/mcf_manual.tex b/Master/texmf-dist/doc/metapost/mcf2graph/mcf_manual.tex
index f39d7cbf80c..7697177abfc 100644
--- a/Master/texmf-dist/doc/metapost/mcf2graph/mcf_manual.tex
+++ b/Master/texmf-dist/doc/metapost/mcf2graph/mcf_manual.tex
@@ -1,5 +1,5 @@
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-% Molecular Coding Format manual by Akira Yamaji 2018.06.03
+% Molecular Coding Format manual by Akira Yamaji 2018.06.18
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\documentclass[a4paper]{article}
%%%%\documentclass[a4paper,twoside]{article}
@@ -154,16 +154,16 @@ pk font,PNG,SVG,EPS or MDL MOL file.\\
%-----------------------------------------------------------------------------
\subsubsection{Connect atom}
\begin{verbatim}
- n:& : Connect to An
+ n:# : Connect to An
- <30,!6,3:\,!,5~bd:&
+ <30,!6,3:\,!,5~bd:#
\end{verbatim}
\MCFstructure
%-----------------------------------------------------------------------------
\subsubsection{Ring}
\begin{verbatim}
?n : n membered ring(3<=n<=20)
- ?6 : <-120,60,60,60,60,60,1:&
+ ?6 : <-120,60,60,60,60,60,1:#
?6
\end{verbatim}
\MCFstructure
@@ -335,9 +335,10 @@ pk font,PNG,SVG,EPS or MDL MOL file.\\
%-----------------------------------------------------------------------------
\subsubsection{Charged atom}
\begin{verbatim}
- N[1]:N+ / O[-1]:O-
+ N[1]:N+ / O[-1]:O- / A,&"c":A+c
- <-30,!2,N[1],!2,O[-1]
+ <-30,!2,N[1],!2,O[-1],
+ !2,&"-",!2,N,&"+"^180,!
\end{verbatim}
\MCFstructure
%-----------------------------------------------------------------------------
@@ -1170,7 +1171,7 @@ drawarrow & drawdblarrow:
%-----------------------------------------------------------------------------
\subsection{Endosulfan}
\begin{verbatim}
- <26,?7,7=?6[13],11:@,208~wf`1.45,8~wb:&,
+ <26,?7,7=?6[13],11:@,208~wf`1.45,8~wb:#,
10=d,{3,5}:O,4:S,4://O,
{8,9,10,11,12^-210,12^-150}:/Cl
\end{verbatim}
@@ -1235,9 +1236,9 @@ drawarrow & drawdblarrow:
\subsection{Gibberellin}
\begin{verbatim}
<18,?5,3=?7,5=?6[12],
- 8:@,160`1.3,3:&,
+ 8:@,160`1.3,3:#,
13=dl,6=wf,8=wb,
- 5:@,40~zf`1,O,60,//O^180,14~zb:&,
+ 5:@,40~zf`1,O,60,//O^180,14~zb:#,
2:/COOH,7://_,13:*/OH,8:/*OH,
14:*/_,{1,4}:*/H^60
\end{verbatim}
@@ -1249,7 +1250,7 @@ drawarrow & drawdblarrow:
10:\,*/OH,/H~zf^-60,!,
|,?6,2:N,1:*/H^60,
4:*\,!!,
- 2:@,165~zf,60,5~zb:&
+ 2:@,165~zf,60,5~zb:#
\end{verbatim}
\MCFstructure
%-----------------------------------------------------------------------------
@@ -1257,7 +1258,7 @@ drawarrow & drawdblarrow:
\begin{verbatim}
<-30,O,!,//O,!,!,Ph,
$1:@,-120~zb,
- |,?7,6:*\^190`1.02,N,/_,3~wb:&,
+ |,?7,6:*\^190`1.02,N,/_,3~wb:#,
$3:*\*,!,OH
\end{verbatim}
\MCFstructure
@@ -1289,7 +1290,7 @@ drawarrow & drawdblarrow:
%-----------------------------------------------------------------------------
\subsection{Paclitaxel}
\begin{verbatim}
- ?6,5=d,3:@,|<=1,36,45,45,45,45,>|,$5:&,
+ ?6,5=d,3:@,|<=1,36,45,45,45,45,>|,$5:#,
-4=?6,-4=?4,-1=wb,-3=wf,-1:O,||,
{4^35,4^-35,6}:/_,{3^-60,15}:*/OH,
8:/*H^-60,9:*/_^60,10://O,
@@ -1349,8 +1350,8 @@ endfont > end font
%------------------------------------------------------------------------
beginfont("NO:5","EN:Gibberellin A3"); > begin font(information)
MCf(<18,?5,3=?7,5=?6[12], > begin MCF (5)
- 8:@,160`1.3,3:&,13=dl,6=wf,8=wb, >
- 5:@,40~zf`1,O,60,//O^180,14~zb:&, >
+ 8:@,160`1.3,3:#,13=dl,6=wf,8=wb, >
+ 5:@,40~zf`1,O,60,//O^180,14~zb:#, >
2:/COOH,7://_,13:*/OH,8:/*OH, >
14:*/_,{1^60,4^60}:*/H) > end MCF
endfont; > end font
@@ -1587,8 +1588,8 @@ M END
font_wd:=50mm; font_ht:=50mm;
beginfont("NO:4","EN:Gibberellin A3","MW:346.37");
MCf(<18,?5,3=?7,5=?6[12],
- 8:@,160`1.3,3:&,13=dl,6=wf,8=wb,
- 5:@,40~zf`1,O,60,//O^180,14~zb:&,
+ 8:@,160`1.3,3:#,13=dl,6=wf,8=wb,
+ 5:@,40~zf`1,O,60,//O^180,14~zb:#,
2:/COOH,7://_,13:*/OH,8:/*OH,
14:*/_,{1^60,4^60}:*/H
)
diff --git a/Master/texmf-dist/doc/metapost/mcf2graph/mcf_mplib_exa.pdf b/Master/texmf-dist/doc/metapost/mcf2graph/mcf_mplib_exa.pdf
index e7c1fd164ab..ede67444775 100644
--- a/Master/texmf-dist/doc/metapost/mcf2graph/mcf_mplib_exa.pdf
+++ b/Master/texmf-dist/doc/metapost/mcf2graph/mcf_mplib_exa.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/metapost/mcf2graph/mcf_mplib_exa.tex b/Master/texmf-dist/doc/metapost/mcf2graph/mcf_mplib_exa.tex
index 98a89ef5d1b..9d8b2e2c4f4 100644
--- a/Master/texmf-dist/doc/metapost/mcf2graph/mcf_mplib_exa.tex
+++ b/Master/texmf-dist/doc/metapost/mcf2graph/mcf_mplib_exa.tex
@@ -1,7 +1,7 @@
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-% Example of MCF typest with LuaLaTeX(luamplib) by A.Yamaji 2018.06.03
+% Example of MCF typest with LuaLaTeX(luamplib) by A.Yamaji 2018.06.18
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-%%% mcf2graph.mf it must be version 4.32 or later
+%%% mcf2graph.mf it must be version 4.33 or later
\documentclass{article}
%------------------------------------------------------------------------------
\usepackage{luamplib}%
@@ -42,9 +42,9 @@
beginfont("NO:1","EN:Chlorophyll a","MW:893.49")
MCd(.9,.9)(0,0.5)(<54,
|<=1,?5,{2,5}=dl,4:N,3:\,54~dl,|,?5,{2,4}=dl,5:N,
- -2:\,54~dl,|,?5,2=dl,5:N,-2:\~dl,54,|,?5,5=dl,5:N,-2:\~dl,$5:&,
- -1:@,24,/*COO!^15,72,//O,$1:&,>|,
- 4:\`1.45,Mg,17:&,-1:@,11~vb:&,-1:@,23~vb:&,
+ -2:\,54~dl,|,?5,2=dl,5:N,-2:\~dl,54,|,?5,5=dl,5:N,-2:\~dl,$5:#,
+ -1:@,24,/*COO!^15,72,//O,$1:#,>|,
+ 4:\`1.45,Mg,17:#,-1:@,11~vb:#,-1:@,23~vb:#,
{2,9,15,20~zf}:/_,8:/!,14:\,!!,
21:@,-6~wf,!2,//O,!,O,!2,!!,|,!13,{1,5,9,13}:/_,
)
@@ -62,9 +62,9 @@
|<=1,?5,{2,5}=dl,4:N,3:\,54~dl,
|,?5,{2,4}=dl,5:N,
-2:\,54~dl,|,?5,2=dl,5:N,
--2:\~dl,54,|,?5,5=dl,5:N,-2:\~dl,$5:&,
--1:@,24,/*COO!^15,72,//O,$1:&,>|,
-4:\`1.45,Mg,17:&,-1:@,11~vb:&,-1:@,23~vb:&,
+-2:\~dl,54,|,?5,5=dl,5:N,-2:\~dl,$5:#,
+-1:@,24,/*COO!^15,72,//O,$1:#,>|,
+4:\`1.45,Mg,17:#,-1:@,11~vb:#,-1:@,23~vb:#,
{2,9,15,20~zf}:/_,8:/!,14:\,!!,
21:@,-6~wf,!2,//O,!,O,!2,!!,
|,!13,{1,5,9,13}:/_,
@@ -136,8 +136,8 @@ endfont
font_wd:=80mm; font_ht:=20mm;
beginfont("NO:4","EN:Gibberellin A3","MW:346.37");
MCa(0.8,0.5)(
- <18,?5,3=?7,5=?6[12],8:@,160`1.3,3:&,13=dl,6=wf,8=wb,
- 5:@,40~zf`1,O,60,//O^180,14~zb:&,
+ <18,?5,3=?7,5=?6[12],8:@,160`1.3,3:#,13=dl,6=wf,8=wb,
+ 5:@,40~zf`1,O,60,//O^180,14~zb:#,
2:/COOH,7://_,13:*/OH,8:/*OH,14:*/_,{1,4}:*/H^60)
EXT(
label.lrt("("&inf_EN&")",(0,h));
@@ -150,9 +150,9 @@ endfont;
\end{mplibcode}
\begin{minipage}[b]{85mm}
\begin{verbatim}
-<18,?5,3=?7,5=?6[12],8:@,160`1.3,3:&,
+<18,?5,3=?7,5=?6[12],8:@,160`1.3,3:#,
13=dl,6=wf,8=wb,
-5:@,40~zf`1,O,60,//O^180,14~zb:&,
+5:@,40~zf`1,O,60,//O^180,14~zb:#,
2:/COOH,7://_,13:*/OH,8:/*OH,
14:*/_,{1,4}:*/H^60)
\end{verbatim}
@@ -164,7 +164,7 @@ font_wd:=80mm; font_ht:=25mm;
beginfont("EN:Morphine","MW:285.343")
MCa(0.7,0.5)(
<30,Ph,2=?6,-4=?6,(1,12)=?5[2],-1:O,-1=zb,
- 7:@,60~wf`0.75,70~si_`1.3,45,N,/_,9~wb:&,
+ 7:@,60~wf`0.75,70~si_`1.3,45,N,/_,9~wb:#,
15=d,6:/OH,8^180:*/H,12:/*OH
)
EXT(
@@ -181,7 +181,7 @@ endfont
<30,Ph,2=?6,-4=?6,(1,12)=?5[2],
-1:O,-1=zb,
7:@,60~wf`0.75,70~si_`1.3,
-45,N,/_,9~wb:&,
+45,N,/_,9~wb:#,
15=dl,
6:/OH,8^180:*/H,12:/*OH
\end{verbatim}
@@ -192,7 +192,7 @@ endfont
font_wd:=80mm; font_ht:=35mm;
beginfont("NO:5","EN:Erythromycin","MW:733.93");
MCa(0.8,0.5)(
- <30,|<=1,<-120,60,60,60,-60,60,60,-60,60,60,60,-60,60,60,>|,1:&,
+ <30,|<=1,<-120,60,60,60,-60,60,60,-60,60,60,60,-60,60,60,>|,1:#,
14:O,13:/*Et,{1,9}://O,{2,10}:*/_,{4,6^-35,8,12^35}:/*_,
{6^35,11,12^-35}:*/OH,
$3:\*,O,30,|,?6`.7,2:O,{3,5^35}:/_,4:/OH,5^-35:/O!,
@@ -210,7 +210,7 @@ beginfont("NO:5","EN:Erythromycin","MW:733.93");
\begin{minipage}[b]{85mm}
\begin{verbatim}
<30,|<=1,<-120,60,60,60,-60,60,
-60,-60,60,60,60,-60,60,60,>|,1:&,
+60,-60,60,60,60,-60,60,60,>|,1:#,
14:O,13:/*Et,{1,9}://O,{2,10}:*/_,
{4,6^-35,8,12^35}:/*_,
{6^35,11,12^-35}:*/OH,
@@ -226,7 +226,7 @@ $5:\*^30`1.7,O,!,|,?6`.7,6:O,
font_wd:=80mm; font_ht:=35mm;
beginfont("EN:Paclitaxel","MW:853.918")
MCa(0.8,0.5)(
- ?6,5=d,3:@,|<=1,36,45,45,45,45,>|,$5:&,-4=?6,-4=?4,||,-1=wb,-3=wf,-1:O,
+ ?6,5=d,3:@,|<=1,36,45,45,45,45,>|,$5:#,-4=?6,-4=?4,||,-1=wb,-3=wf,-1:O,
{4^35,4^-35,6}:/_,{3^-60,15}:*/OH,8:/*H^-60,9:*/_^60,10://O,
$1:\,O,!,//O,!,*/OH,!,/Ph,60~wf,NH,-60,//O,60,Ph,
$7:\*,O,-45,//O,60,Ph,$11:*\,O,-60,//O,60,$12:\*^-15,O,60,//O,-60
@@ -242,7 +242,7 @@ endfont
\end{mplibcode}
\begin{minipage}[b]{85mm}
\begin{verbatim}
-?6,5=d,3:@,|<=1,36,45,45,45,45,>|,$5:&,
+?6,5=d,3:@,|<=1,36,45,45,45,45,>|,$5:#,
-4=?6,-4=?4,||,-1=wb,-3=wf,-1:O,
{4^35,4^-35,6}:/_,{3^-60,15}:*/OH,
8:/*H^-60,9:*/_^60,10://O,
@@ -261,9 +261,9 @@ beginfont("NO:6","EN:Vancomycin","MW:1449.25");
MCa(0.9,0)(
<30,
|<=1,!12,{1,3,12}=zf,7=wf,/H^-60,60,*/OH,60,
- Ph,-4:/Cl,-3:\,O,!,Ph,-4:\,O,!,Ph,-1^15:/Cl,-3:\,/*OH,*/H^-60,$1:&,
- $7:@,$26:&,$1:@,120,//O,60,NH,60,/*H,*/COOH^180,-60,
- Ph,{-2,-4}:/OH,-1:\,Ph,-5:/OH,-2:@,$4:&,>|,
+ Ph,-4:/Cl,-3:\,O,!,Ph,-4:\,O,!,Ph,-1^15:/Cl,-3:\,/*OH,*/H^-60,$1:#,
+ $7:@,$26:#,$1:@,120,//O,60,NH,60,/*H,*/COOH^180,-60,
+ Ph,{-2,-4}:/OH,-1:\,Ph,-5:/OH,-2:@,$4:#,>|,
{3^40,6,9,12}://O,{2,5,8,11}:NH,
{1^180,4^180}:*/H,{7^-60,10^60,14^60}:/*H,
$10:*\^-60,60,//O,!,NH2,
@@ -285,10 +285,10 @@ endfont;
<30,|<=1,!12,{1,3,12}=zf,7=wf,
/H^-60,60,*/OH,60,Ph,-4:/Cl,
-3:\,O,!,Ph,-4:\,O,!,Ph,-1^15:/Cl,
--3:\,/*OH,*/H^-60,$1:&,
-$7:@,$26:&,$1:@,120,//O,60,NH,60,
+-3:\,/*OH,*/H^-60,$1:#,
+$7:@,$26:#,$1:@,120,//O,60,NH,60,
/*H,*/COOH^180,-60,
-Ph,{-2,-4}:/OH,-1:\,Ph,-5:/OH,-2:@,$4:&,>|,
+Ph,{-2,-4}:/OH,-1:\,Ph,-5:/OH,-2:@,$4:#,>|,
{3^40,6,9,12}://O,{2,5,8,11}:NH,
{1^180,4^180}:*/H,
{7^-60,10^60,14^60}:/*H,
diff --git a/Master/texmf-dist/metapost/mcf2graph/mcf2graph.mf b/Master/texmf-dist/metapost/mcf2graph/mcf2graph.mf
index f553da1e7dc..e2f44387b1d 100644
--- a/Master/texmf-dist/metapost/mcf2graph/mcf2graph.mf
+++ b/Master/texmf-dist/metapost/mcf2graph/mcf2graph.mf
@@ -1,5 +1,5 @@
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-% mcf2graph ver 4.32 Copyright (c) 2013-2018 Akira Yamaji
+% mcf2graph ver 4.33 Copyright (c) 2013-2018 Akira Yamaji
%
% Permission is hereby granted, free of charge, to any person obtaining a copy of this software
% and associated documentation files (the "Software"), to deal in the Software without restriction,
@@ -34,9 +34,9 @@
tracingstats:=1;
message " This is mcf2graph ver 4.3 2018.06";
%-------------------------------------------------------------------------------------------------
-newinternal nA,nB,nC,nD,nE,nF,char_num,str_cnt,sub_usr,sub_int,tbl_cnt;
+newinternal nA,nB,nC,nD,nE,nF,char_num,str_cnt,sub_usr,sub_int,tbl_cnt,sharp_char;
numeric save_para[],comD[][],parD[][],cntD[],tbl_str_wd[],tbl_atom[],tbl_subst[][],tbl_atom_wt[],
- tbl_atom_mi[],tbl_char_wd[],tbl_char_ht[],chgA[];
+ tbl_atom_mi[],tbl_char_wd[],tbl_char_ht[],andA[],and_rot[],chargeA[];
string tbl_atom_str[],strD[],var[],tag[],mp_log_name,aux_delimiter,atomfont,
save_atomfont,save_defaultfont;
picture mol_stru[];
@@ -119,7 +119,7 @@ def_com(-4000)(_term,_jp_atom,_jp_atom_abs,_jp_bond,_cyc,_cyc_sB,_cyc_eB,_set_li
_dl,_mb,_N,_O,_S,_tmp_line,_chg_len,_get_len,_ring_len,_tmp_len,_rot_ang,_adj_ang,_chg_env,
_tmp_env,_set_colorA,_set_colorB,_postA,_postB,_postC,_postD,_postE,_postF,_postG,_postH,
_set_clr,_set_adr,_mk_bond,_set_atom,_arg_ang,_chg_atom,_tmp_rot,_fuse,_push,_pop,
- _size_a,_numeric,_jump_at,_connect_at);
+ _size_a,_numeric,_jump_at,_connect_at,_set_and,_chg_charge);
def_com(1)(si,dl,dr,db,dm,tm,wf,wb,bd,bz,zf,zb,dt,wv,nl,vf,vb,si_,wf_,wb_,bd_);
%--------------------------------------------------------------------------------------------------
def parameter_list=
@@ -199,13 +199,14 @@ def endfont=
enddef;
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
def set_def_MC=
- save /,//,/*,*/,**,*/*,~,~~,^,^^,`,'`,<,>,>>,:>,&,:,=,\,\\,*\,\*,*\*,@,$,{,},
+ save /,//,/*,*/,**,*/*,~,~~,^,^^,`,'`,<,>,>>,:>,&,:,=,\,\\,*\,\*,*\*,@,$,{,},#,
|,||,|<,>|,|<=,|:,:|,_,d,w,z,inside_def_MC;
inside_def_MC:=1;
_:=Me; d:=db; w:=wf; z:=zf;
tertiarydef a=b == change_bond(a,b) enddef;
tertiarydef a:b == change_atom(a,b) enddef;
def { == '''( enddef; let } == );
+ def &primary s == (_set_and,ASCII(s)) enddef;
vardef $primary a == a-4095 enddef;
def ^^primary n == (_tmp_rot,n) enddef; def ~~primary n == (_tmp_line,n) enddef;
def '`primary n == (_tmp_len,n) enddef; def :>primary n == (_tmp_env,n) enddef;
@@ -213,8 +214,7 @@ def set_def_MC=
def <primary n == (_rot_ang,n) enddef;
tertiarydef a^b == ^^b,a enddef; tertiarydef a`b == '`b,a enddef;
tertiarydef a~b == ~~b,a enddef; tertiarydef a>b == :>b,a enddef;
- def & == _connect_at enddef;
- def @ == _jump_at enddef; def \ == @,0 enddef;
+ def # == _connect_at enddef; def @ == _jump_at enddef; def \ == @,0 enddef;
def \\ == \~dm enddef; def *\ == \~wf enddef; def \* == \~zf enddef; def *\* == \~wv enddef;
def |: == (_push,0) enddef; def :| == (_pop,0) enddef;
def |< == (_push,1) enddef; def >| == (_pop,1) enddef;
@@ -319,12 +319,17 @@ vardef change_atom(expr a,b)=
if (b>=H)and(b<=U):: if b==N:: PP(a,_N) elseif b==O:: PP(a,_O) elseif b==S:: PP(a,_S)
else:: PX(a)(_chg_atom,b)
fi
- elseif b==NH:: PA(_set_clr,1) PP(a,_N) PX(a)(_postH,H) PA(_set_clr,0)
- elseif b==_jump_at:: PA(_jp_atom,a)
- elseif b==_connect_at:: PA(_cyc,a)
+ ef b==NH:: PA(_set_clr,1) PP(a,_N) PX(a)(_postH,H) PA(_set_clr,0)
+ ef b==_jump_at:: PA(_jp_atom,a)
+ ef b==_connect_at:: PA(_cyc,a)
fi
- elseif pair b:: PA(_set_clr,1) PX(a)(xpart(b),ypart(b)) PA(_set_clr,0)
- elseif color b:: color_list[incr cntC]:=b; PX(a)(_set_colorA,cntC)
+ ef pair b::
+ if xpart(b)==_set_and::
+ PA(_set_and,ypart(b)) PA(_chg_charge,a)
+ else::
+ PA(_set_clr,1) PX(a)(xpart(b),ypart(b)) PA(_set_clr,0)
+ fi
+ ef color b:: color_list[incr cntC]:=b; PX(a)(_set_colorA,cntC)
fi fi
sub_int %------- Retern value -------
enddef;
@@ -465,7 +470,7 @@ def draw_dblarrow text t =
draw arrow_path t
enddef;
%-------------------------------------------------------------------------------------------------
-arrow_head:=(ahlength,-(sind 0.5ahangle)*ahlength)--(0,0)--
+arrow_head:=(0,0)--(ahlength,-(sind 0.5ahangle)*ahlength)--
(ahlength, (sind 0.5ahangle)*ahlength)--cycle;
%-------------------------------------------------------------------------------------------------
def ahead_angle(expr p) =
@@ -502,7 +507,7 @@ def MCd(expr RW,RH)(expr FW,FH)(text TX)=
begingroup
save com,par,adrA,adrB,f_bra,envT,envB,lenT,lineT,strAT,stkA,stkB,stkL,stkM,cntP,bondL,temp_len,
temp_cntB,f_end,f_term,rotT,adrS,f_at,f_lineT,f_rotT,f_lenT,f_envT,angT,tempB,tempA,
- glu,xpos,ypos,str_len,max_x,max_y,par_s,par_e,score_u,hat,f_char,ps_adr,ps_com,sA,
+ glu,xpos,ypos,str_len,max_x,max_y,par_s,par_e,score_u,hat,f_char,ps_adr,ps_com,sA,sC,sD,pA,
op_com,op_par,op_cnt,crR,colorA,colorB,PA,PO,PP,PX;
%-----------------------------------------------------------------------------------------------
def PA= sub_add enddef;
@@ -512,7 +517,8 @@ def MCd(expr RW,RH)(expr FW,FH)(text TX)=
%-----------------------------------------------------------------------------------------------
numeric stkB[],stkA[],stkL[],stkM[],f_char[],ps_adr[],ps_com[],colorA[],colorB[],
op_com[][],op_par[][],op_cnt[];
- string sA;
+ string sA,sC,sD;
+ pair pA;
%-----------------------------------------------------------------------------------------------
if (sw_numberA>=1)or(sw_numberB>=1): ratio_atom_bond:=0.25; fi
if (sw_expand=1)or(sw_mol_out>=1): expand_set; fi
@@ -543,18 +549,8 @@ def MCd(expr RW,RH)(expr FW,FH)(text TX)=
for i=1 upto cntB: if lineB[i]<si_ : draw_bond(i,sB[i],eB[i],angB[i],lineB[i]); fi endfor
for i=1 upto cntB: if lineB[i]>=si_: draw_bond(i,sB[i],eB[i],angB[i],lineB[i]); fi endfor
%-----------------------------------------------------------------------------------------------
- for i=1 upto cntA:
- sA:=substring(3,4) of strD[numS[i]];
- if sA="+": chgA[i]:=1; ef sA="-": chgA[i]:=-1; else: chgA[i]:=0; fi
- if (sw_numberA>=1)and(i>=numberA_start)and(i<=numberA_end):
- if sw_numberA=2: nA:=i-numberA_start+1;
- elseif sw_numberA=3: if numberA_end<cntA: nA:=numberA_end-i+1; else: nA:=cntA-i+1; fi
- else: nA:=i; fi
- if i<10: draw_atom(i,posA[i],0,decimal(nA),1);
- else: draw_atom(i,posA[i]+(-.2atom_wd,0),0,decimal(nA),1); fi
- elseif sw_numberB>=1:
- else: draw_atom(i,posA[i],ang_br[i],strD[numS[i]],tbl_str_wd[numS[i]]); fi
- endfor
+ proc_draw_atom;
+ proc_draw_charge;
%-----------------------------------------------------------------------------------------------
sftX:=margin_left_right-minX+(font_wd-mol_wd-2margin_left_right)*FW;
sftY:=margin_top_bottom-minY+(font_ht-mol_ht-2margin_top_bottom)*FH;
@@ -656,10 +652,48 @@ def char_use_check=
endfor
fi
enddef;
+%-----------------------------------------------------------------------------------------------
+def proc_draw_atom=
+ for i=1 upto cntA:
+ if (sw_numberA>=1)and(i>=numberA_start)and(i<=numberA_end):
+ if sw_numberA=2: nA:=i-numberA_start+1;
+ elseif sw_numberA=3: if numberA_end<cntA: nA:=numberA_end-i+1; else: nA:=cntA-i+1; fi
+ else: nA:=i; fi
+ if i<10: draw_atom(i,posA[i],0,decimal(nA),1);
+ else: draw_atom(i,posA[i]+(-.2atom_wd,0),0,decimal(nA),1); fi
+ elseif sw_numberB>=1:
+ else: draw_atom(i,posA[i],ang_br[i],strD[numS[i]],tbl_str_wd[numS[i]]); fi
+ endfor
+enddef;
+%-------------------------------------------------------------------------------------------------
+def proc_draw_charge=
+ for i=1 upto cntA:
+ if andA[i]<>0:
+ sA:=char(andA[i]);
+ nA:=ang_br[i]+and_rot[i];
+ nC:=nA mod 90;
+ if strD[numS[i]]="": nB:=.5atom_wd;
+ else:
+ if nC<45: nB:=.85atom_wd+sind(nC)*.5atom_wd;
+ else: nB:=.85atom_wd+cosd(nC)*.5atom_wd;
+ fi
+ fi
+ pA:=sfB(posA[i]-(.35atom_wd,.35atom_wd),nB,nA);
+ draw_char(sA,pA,atom_wd,bond_pen_wd*ratio_char_bond,0);
+ else: sA:="";
+ fi
+ nA:=length(strD[numS[i]]);
+ sC:=substring(nA-3,nA-2) of strD[numS[i]];
+ if (sA="+")or(sC="+"): chargeA[i]:=1;
+ ef (sA="-")or(sC="-"): chargeA[i]:=-1;
+ else: chargeA[i]:=0;
+ fi
+ endfor
+enddef;
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
def proc_bond_atom(expr n)=
f_bra:=f_end:=f_term:=rotT:=adrS:=f_lineT:=f_rotT:=f_lenT:=f_envT:=envT:=envB:=strAT:=f_at:=0;
- stkL[0]:=bondL:=crR; lenT:=crR; sB[0]:=0; eB[0]:=1; lineT:=si;
+ stkL[0]:=bondL:=crR; lenT:=crR; sB[0]:=0; eB[0]:=1; lineT:=si; andAT:=0;
for i=0 upto 5: stkA[i]:=stkB[i]:=0; endfor
%-----------------------------------------------------------------------------------------------
for i=n upto cntD[0]:
@@ -700,7 +734,7 @@ def proc_bond_atom(expr n)=
ef nC=_dl: lineB[getB(par)]:=dl;
ef nC=_mb: lineB[getB(-1)]:=par;
ef (nC=_chg_line)or(nC=_tmp_line): lineT:=par;
- ef nC=_tmp_rot: rotT:=par;
+ ef nC=_tmp_rot: rotT:=par;
ef nC=_cyc: f_end:=getA(par); check_adrA(f_end); add_atom;
ef nC=_cyc_eB: f_end:=eB[getB(par)]; add_atom;
ef nC=_cyc_sB: f_end:=sB[getB(par)]; add_atom;
@@ -715,6 +749,9 @@ def proc_bond_atom(expr n)=
ef nC=_term: termA;
ef nC=_set_colorA: colorA[getA(adrT)]:=par;
ef nC=_set_colorB: colorB[getB(adrT)]:=par;
+ ef nC=_set_and: andAT:=par;
+ ef nC=_chg_charge: andA[getA(par)]:=andAT; andAT:=0;
+ if rotT<>0: and_rot[getA(par)]:=rotT; fi
fi
endfor
enddef;
@@ -723,8 +760,10 @@ def add_atom=
lineB[incr cntB]:=lineT;
lineT:=si;
if lenT=crR: lenB[cntB]:=bondL; else: lenB[cntB]:=lenT; lenT:=crR; fi
- if f_bra=0: cntA:=cntA+1; sB[cntB]:=cntA; numS[cntA]:=strAT; strAT:=0;
- if f_MP=1: colorA[cntA]:=colorB[cntA]:=0; fi else: f_bra:=0; fi
+ if f_bra=0: cntA:=cntA+1; sB[cntB]:=cntA; numS[cntA]:=strAT;
+ andA[cntA]:=andAT; andAT:=strAT:=and_rot[cntA]:=0;
+ if rotT<>0: and_rot[cntA]:=rotT; rotT:=0; fi
+ if f_MP=1: colorA[cntA]:=colorB[cntA]:=0; fi else: f_bra:=0; fi
if f_end=0: eB[cntB]:=cntA+1; f_term:=0; else: eB[cntB]:=f_end; f_end:=0; f_term:=1; fi
enddef;
%-------------------------------------------------------------------------------------------------
@@ -802,15 +841,30 @@ vardef getB(expr n)=
if n>=1: stkB[adrS+1]+n ef n=0: tempB ef n>=-999: cntB+n+1 else: stkB[adrS]+n+4095 fi
enddef;
%--------------------------------------------------------------------------------------------------
-def termA= if f_term=0: if f_bra=0: numS[incr cntA]:=strAT; strAT:=0;
- if f_MP=1: colorA[cntA]:=0; fi else: f_bra:=0; fi f_term:=1; fi enddef;
-def termB= if f_term=0: if f_bra=0:ang_br[incr cntA]:=angT; else:f_bra:=0; fi f_term:=1; fi enddef;
+def termA=
+ if f_term=0:
+ if f_bra=0:
+ cntA:=cntA+1; numS[cntA]:=strAT; andAT:=strAT:=and_rot[cntA]:=andA[cntA]:=0;
+ if rotT<>0: and_rot[cntA]:=rotT; rotT:=0; fi
+ if f_MP=1: colorA[cntA]:=0; fi
+ else: f_bra:=0;
+ fi
+ f_term:=1;
+ fi
+enddef;
+%--------------------------------------------------------------------------------------------------
+def termB=
+ if f_term=0:
+ if f_bra=0: cntA:=cntA+1; ang_br[cntA]:=angT; else:f_bra:=0; fi
+ f_term:=1;
+ fi
+enddef;
%--------------------------------------------------------------------------------------------------
def proc_cyc(expr n)= add_bond(angle(posA[n]-posBs)-angT); enddef;
%--------------------------------------------------------------------------------------------------
-def glu_c(expr n)= if numS[n]<>0: nB:=angT mod 180; nC:=.5tbl_str_wd[numS[n]]*atom_wd;
- if (nB<45)or(nB>135):glu:=glu+((sind(nB)*nC)++nC);
- else :glu:=glu+((cosd(nB)*.5atom_wd)++.5atom_wd) fi fi enddef;
+def glu_c(expr n)= if numS[n]<>0: nB:=angT mod 90; nC:=.5tbl_str_wd[numS[n]]*atom_wd;
+ if nB<45: glu:=glu+((sind(nB)*nC)++nC);
+ else: glu:=glu+((cosd(nB)*.5atom_wd)++.5atom_wd) fi fi enddef;
%--------------------------------------------------------------------------------------------------
vardef proc_env(expr n,m,a,b)= r:=(n mod 360);
if m>=sub_emb_start: parD[m][cntB-temp_cntB] else:
@@ -962,14 +1016,14 @@ Me:='(); Et:='(!); Pr:=!x2:='(!,!); Bu:=!x3:='(!,!,!);
for i=4,5,6: for j=2 upto i-2: ?[i][j]:='((_fuse,i),(j,0)); endfor endfor
for i=5,6,7,8: for j=11 upto 15: ?[i][j]:='((_fuse,i),(j,0)); endfor endfor
%=================================================================================================
-H :='("H");C:='("C");N:='("N");O:='("O");S:='("S");P:='("P");
-H[1]:='("{H^+^}");H[-1]:='("{H^-^}");C[1]:='("{C^+^}");C[-1]:='("{C^-^}");
-O[1]:='("{O^+^}");O[-1]:='("{O^-^}");N[1]:='("{N^+^}");N[-1]:='("{N^-^}");
-S[1]:='("{S^+^}");S[-1]:='("{S^-^}");P[1]:='("{P^+^}");P[-1]:='("{P^-^}");
-F:='("F");I:='("I");
+H :='("H");C:='("C");N:='("N");O:='("O");S:='("S");P:='("P");F:='("F");I:='("I");
Si:='("{Si}");Al:='("{Al}");Mg:='("{Mg}");Zn:='("{Zn}");As:='("{As}");Cu:='("{Cu}");
Ag:='("{Ag}");Au:='("{Au}");Sn:='("{Sn}");Cl:='("{Cl}");Br:='("{Br}");Li:='("{Li}");
Na:='("{Na}");Ca:='("{Ca}");Hg:='("{Hg}");Ni:='("{Ni}");Ti:='("{Ti}");U:='("U");
+H[1]:='("{H^+^}");H[-1]:='("{H^-^}");C[1]:='("{C^+^}");C[-1]:='("{C^-^}");
+O[1]:='("{O^+^}");O[-1]:='("{O^-^}");N[1]:='("{N^+^}");N[-1]:='("{N^-^}");
+S[1]:='("{S^+^}");S[-1]:='("{S^-^}");P[1]:='("{P^+^}");P[-1]:='("{P^-^}");
+Li[1]:='("{Li^+^}"); Na[1]:='("{Na^+^}"); Cl[-1]:='("{Cl^-^}"); Br[-1]:='("{Br^-^}");
%-------------------------------------------------------------------------------------------------
R:='("R"); R1:='("{R^1^}"); R2:='("{R^2^}"); R3:='("{R^3^}"); R4:='("R^4^"); R5:='("{R^5^}");
%-------------------------------------------------------------------------------------------------
@@ -1017,7 +1071,7 @@ char_size_set(.35)(.9)("i");
char_size_set(.4)( 1)(".,:;'`^");
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
def draw_char(expr CHR,POS,WD,PEN,NUM)=
-save Z,aW,aH,fW,fH,hW,hW,hH,fP,hP,pathO,pathOh,pos,dw,dwh,dwv,cdw,ppcs,sbp;
+save Z,aW,aH,fW,fH,hW,hW,hH,fP,hP,pathO,pathOh,pos,dw,dwh,dwv,cdw,ppcs,sbp,sC;
path pathO,pathOh;
string sC;
pair Z[],pos;
@@ -1127,7 +1181,7 @@ ef sC="_": dwh Z03--Z21;
ef sC="=": dwh (hP,.3aH)--(fW,.3aH); dwh (hP,.6aH)--(fW,.6aH);
ef sC="/": dw (fW,fH)..Z01;
ef sC="+": dwv Z19--Z14; dwh Z09--Z10;
-ef sC="*": dw Z19--Z14; dw Z09--Z10; dw (fW,fH)--Z01; dw Z13--Z21;
+ef sC="*": dw Z19--Z14; dw Z09--Z10; dw (.2aW,.2aH)--(.8aW,.8aH); dw (.2aW,.8aH)--(.8aW,.2aH);
else:
fi
enddef;
@@ -1138,12 +1192,14 @@ vardef fixed_l(expr n)(expr s)= s&(substring(0,n-length(s)) of blank_str) enddef
vardef fdr(expr n)(expr s)=fixed_r(n)(decimal(s)) enddef;
vardef fdl(expr n)(expr s)=fixed_l(n)(decimal(s)) enddef;
def warning(expr s)= message "% "&decimal(char_num)&fdr(3)(incr warning_cnt)&")"&s; enddef;
+%--------------------------------------------------------------------------------------------------
def bond_check(expr a)(text s)=
nF:=0; for list=s: if list=bond_cnt: nF:=1; fi endfor
if nF=0:
warning("A"&decimal(a)&" ( "&fixed_l(8)(strD[numS[a]])&") has"&fdr(2)(bond_cnt)&" bonds");
fi
enddef;
+%--------------------------------------------------------------------------------------------------
vardef stripP(expr a)=
if length(a)=4: substring (1,3) of a
elseif length(a)=6: substring (1,2) of a
@@ -1298,7 +1354,7 @@ def proc_report_out=
fdr(10)(round_auto(ypart(posA[i])/bond_len))&" ) "&fixed_l(8)(strD[numS[i]])&
" "&fdr(3)(Bcnt[i])
if hideH[i]>0: &fdr(8)(hideH[i]) else: &" " fi
- if chgA[i]<>0: &fdr(8)(chgA[i]) fi;
+ if chargeA[i]<>0: &fdr(8)(chargeA[i]) fi;
endfor
message "------------------------------------------------------------------";
message "< NO. >< bond (sdt)><angle + ( +- )><length ( pt )>";
@@ -1350,7 +1406,7 @@ def proc_mol_out=
for i=1 upto cntA:
printf fdr(10)(xpart(posA[i])/bond_len)& fdr(10)(ypart(posA[i])/bond_len)&
fdr(10)(0)&" "&fixed_l(2)(stripP(strD[numS[i]]))&" 0 0 0 0";
- if chgA[i]<>0: chg_atm[incr chg_cnt]:=i; chg_chg[chg_cnt]:=chgA[i]; fi
+ if chargeA[i]<>0: chg_atm[incr chg_cnt]:=i; chg_chg[chg_cnt]:=chargeA[i]; fi
endfor
for i=1 upto cntB: if lineB[i]<>0:
if (lineB[i]=dl)or(lineB[i]=dr)or(lineB[i]=dm): nA:=2;
@@ -1377,7 +1433,7 @@ def proc_mol_out=
for i=1 upto cntA:
printf "M V30 "&decimal(i)&" "&stripP(strD[numS[i]])&" "&
decimal(xpart(posA[i])/bond_len)&" "&decimal(ypart(posA[i])/bond_len)&" 0 0"
- if chgA[i]<>0: &" CHG="&decimal(chgA[i]) fi;
+ if chargeA[i]<>0: &" CHG="&decimal(chargeA[i]) fi;
endfor
printf "M V30 END ATOM";
printf "M V30 BEGIN BOND";