From cd80a5bcb9cc333e0a1a3f93f259fbd185d262bb Mon Sep 17 00:00:00 2001
From: Karl Berry <karl@freefriends.org>
Date: Sun, 23 Aug 2009 23:34:03 +0000
Subject: tablor 4.05 (23aug09)

git-svn-id: svn://tug.org/texlive/trunk@14831 c570f23f-e606-0410-a88d-b1316a301751
---
 .../texmf-dist/tex/latex/tablor/tablor-xetex.sty   | 149 ++++++++++++++++++++-
 1 file changed, 148 insertions(+), 1 deletion(-)

(limited to 'Master/texmf-dist/tex/latex/tablor/tablor-xetex.sty')

diff --git a/Master/texmf-dist/tex/latex/tablor/tablor-xetex.sty b/Master/texmf-dist/tex/latex/tablor/tablor-xetex.sty
index 7f4c17d6592..5cc263c7cdd 100644
--- a/Master/texmf-dist/tex/latex/tablor/tablor-xetex.sty
+++ b/Master/texmf-dist/tex/latex/tablor/tablor-xetex.sty
@@ -1,5 +1,5 @@
 \NeedsTeXFormat{LaTeX2e}[1995/12/01]
-\ProvidesPackage{tablor-xetex}[21/08/2009 v4.04-h  la machine a  creer des
+\ProvidesPackage{tablor-xetex}[23/08/2009 v4.05  la machine a  creer des
 tableaux de signes et variations compatible xetex]
 
 % \copyleft Connan le Barbare (aka Guillaume Connan) \copyright
@@ -38,6 +38,11 @@ tableaux de signes et variations compatible xetex]
 % TV([0,+infinity],[0],"h","x",ln(x)-(ln(x))^2,1,n,\tv)
 % \end{TV}
 %
+% tableau de variation avec liste de valeurs
+% \begin{TVS}
+% TVS([1,2,3,4],[-1,-infinity,+infinity,2,9],[2],"f","x",\tv)
+% \end{TVS}
+%
 % tableau de variation avec zones interdites
 %
 % \begin{TVZ}
@@ -2679,6 +2684,127 @@ fclose(sortie);
 
 
 %%$
+
+
+
+
+
+
+
+
+%%%%
+%%%
+%%% Pour des tableaux de variations simples sans fonctions
+%%%
+%%%
+
+
+
+\begin{VerbatimOut}{XcasTVS.cxx}
+TVS(La,Lo,F,nomf,nomv,nmr):={
+
+na:=size(La);
+f:=F;
+if(member(La[0],F)){f:=f[1..size(f)-1]};
+if(member(La[na-1],F)){f:=f[0..size(f)-2]};
+Z:=sort(concat(La,f));
+Zo:=sort([op(set[op(Z)])]);
+nz:=size(Z);
+nzo:=size(Zo);
+
+
+k0:= evalf(Lo[0])> evalf(Lo[1]);
+kz:=evalf(Lo[nz-1])> evalf(Lo[nz-2]);
+
+
+l0:=" newLigneVariables(btex $"+nomv+"$ etex);";lp:=" "; lf:=" ";
+  for(m:=0;m<=nzo-1;m++){l0:=l0+"val(btex $"+latex(Zo[m])+"$ etex);"}
+
+li:=lvic+nomf+"}$ etex);"+
+    if(member(Z[0],F)==0){"valPos(btex $"+latex(Lo[0])+"$ etex,"}
+    else{"nonDefBarre;limDroite(btex $"+latex(Lo[0])+"$ etex,"}+                               
+           if(k0==1){"1"}else{"0"}+
+                         ");";
+            
+    if(nz>2){ for(r:=1; r<=nz-2;r++){ 
+         krm:=evalf(Lo[r-1])< evalf(Lo[r]);
+         krp:=evalf(Lo[r])> evalf(Lo[r+1]) ;  
+         
+      lp:=lp+if(Z[r]==Z[r+1]){
+         "limGauche(btex$"+latex(Lo[r])+"$etex,"+
+              if(krm==1){"1);"}
+              else{"0);"}
+             }// fin if zr=zr+1
+             else{
+              if(Z[r]==Z[r-1]){
+         "nonDefBarre;limDroite(btex$"+latex(Lo[r])+"$etex,"+
+              if(krm==1){"1);"}
+              else{"0);"}
+             }//fin if zr=zr-1
+              else{
+              "valPos(btex $"+latex(Lo[r])+"$etex,"+
+              if(krp==1){"1);"}else{"0);"}
+}//fin else zr=zr-1
+}//fin else zr=zr+1
+}//fin for 
+}//fin de if nz>2
+                                                                      
+
+
+lf:=if(member(Z[nz-1],F)==0){"valPos(btex $"+latex(Lo[nz-1])+"$ etex,"+
+             if(kz==1){"1);"}else{"0);"}}
+    else{"limGauche(btex $"+latex(Lo[nz-1])+"$ etex,"+ 
+             if(kz==1){"1);nonDefBarre;"}else{"0);nonDefBarre;"}};    
+    
+
+MetaLfc:=
+
+ if(nz>2){"beginTableau("+nmr+")"+
+        l0+
+li+
+lp+
+lf
++"
+endTableau;
+
+";}else{"beginTableau("+nmr+")"+
+        l0+
+li+
+lf
++"
+endTableau;
+
+";}
+
+//return(MetaLfc);
+
+sortie:=fopen("XCasmpfc.mp");
+fprint(sortie,Unquoted,MetaLfc);
+fclose(sortie);
+
+
+}:;
+
+\end{VerbatimOut}
+
+%%$
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
 %%
 %% traitement des fichiers produits par giac/xcas
 %%
@@ -3128,6 +3254,27 @@ read("XCasTVPC.user");
 
 
 
+\begin{VerbatimOut}{XCasTVS.giac}
+maple_mode(0);
+read("config.cxx");
+read("XcasTVS.cxx");
+read("XCasTVS.user");
+\end{VerbatimOut}
+
+\newenvironment{TVS}%
+{\VerbatimEnvironment\begin{VerbatimOut}[commandchars=\\??]{XCasTVS.user}}%
+{\end{VerbatimOut}
+\dresse{TVS}}
+
+\newenvironment{TVS*}[1]{%
+\setcounter{TVnbis}{\theTVn}
+\setcounter{TVn}{#1}
+\VerbatimEnvironment\begin{VerbatimOut}[commandchars=\\??]{XCasTVS.user}}%
+{\end{VerbatimOut}\dressetoile{TVS}}
+
+
+
+
 
 %% pour nettoyer les fichiers auxiliaires
 
-- 
cgit v1.2.3

