diff options
Diffstat (limited to 'Master/texmf-dist/scripts/ketcindy/ketlib/ketcindylibbasic1r.cs')
-rw-r--r-- | Master/texmf-dist/scripts/ketcindy/ketlib/ketcindylibbasic1r.cs | 886 |
1 files changed, 501 insertions, 385 deletions
diff --git a/Master/texmf-dist/scripts/ketcindy/ketlib/ketcindylibbasic1r.cs b/Master/texmf-dist/scripts/ketcindy/ketlib/ketcindylibbasic1r.cs index a3376741a8d..e473027def3 100644 --- a/Master/texmf-dist/scripts/ketcindy/ketlib/ketcindylibbasic1r.cs +++ b/Master/texmf-dist/scripts/ketcindy/ketlib/ketcindylibbasic1r.cs @@ -9,14 +9,14 @@ // but WITHOUT ANY WARRANTY; without even the implied warranty of // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the // GNU General Public License for more details. -// f +// // You should have received a copy of the GNU General Public License // along with this program. If not, see <http://www.gnu.org/licenses/> // -println("KeTCindy V.3.2.3(20181216)"); +println("KeTCindy V.3.2.5"); println(ketjavaversion()); -println("ketcindylibbasic1(20181125) loaded"); +println("ketcindylibbasic1[20190131] loaded"); //help:start(); @@ -71,7 +71,7 @@ Ketinit(work,sy,rangex,rangey):=(//181001to KCOLOR=[0,0,0]; GLIST=[]; GCLIST=[]; -// GDATALIST=[]; +// GDATALIST=[]; //no ketjs GOUTLIST=[]; POUTLIST=[]; VLIST=[]; @@ -97,6 +97,8 @@ Ketinit(work,sy,rangex,rangey):=(//181001to ADDPACK=[]; // 16.05.16 GPACK="tpic"; //180817 ErrFlag=0; + KETJSOP=[]; //190129 + // no ketjs on 190122 setdirectory(Dirwork); if(!isstring(Fhead), // 17.10.13from, 17.11.12 Fhead=text(curkernel()); @@ -122,8 +124,8 @@ Ketinit(work,sy,rangex,rangey):=(//181001to Dircdy=substring(Dircdy,1,length(Dircdy)); ); ); - Changesetting(Homehead+pathsep()+getname()); //180913 - Changesetting(Dircdy); //181017 + Userhome=Homehead+pathsep()+getname(); //190128 + Changesetting(); //190128 Changework(Dircdy+pathsep()+work); //180329to,181001 Fnametex=Fhead+".tex"; FnameR=Fhead+".r"; @@ -139,6 +141,7 @@ Ketinit(work,sy,rangex,rangey):=(//181001to Shellparent="/kc.command"; , Shellparent="/kc.sh"; + Mackc="sh"; //190116 ); //181125to if(!isexists(Dirwork,""), println(Dirwork+" not exists"); @@ -152,6 +155,7 @@ Ketinit(work,sy,rangex,rangey):=(//181001to println(setexec(Dirwork,Shellparent)); ); ); +// no ketjs off 190122 ArrowlineNumber=1; // 15.01.05 ArrowheadNumber=1; BezierNumber=1; //15.01.03 @@ -163,6 +167,7 @@ Ketinit(work,sy,rangex,rangey):=(//181001to YMIN=rangey_1/SCALEY; YMAX=rangey_2/SCALEY; Setwindow("Msg=n"); // 16.05.31 +// no ketjs on 190122 // for Presentation letterc=[0.98,0.13,0,0.43]; boxc=[0,0.32,0.52,0]; shadowc=[0,0,0,0.5]; mboxc="yellow"; //17.03.02 regional debugged @@ -173,6 +178,7 @@ Ketinit(work,sy,rangex,rangey):=(//181001to if(indexof(PathT,"pdflatex")+indexof(PathT,"lualatex")>0, LibnameS=replace(LibnameS,"ketpic","ketpic2e"); );//17.12.03until +// no ketjs off 190122 ); ////%Ketinit end//// @@ -250,7 +256,7 @@ Readlines(path,file):=( //help:Readlines(path,file); regional(tmp,out); out=readfile2str(path,file); - out=tokenize(out,"/LF/"); + out=tokenize(out,"/L"+"F/"); //190129 tmp=out_(length(out)); if(length(tmp)==0, out=out_(1..(length(out)-1)); @@ -260,22 +266,22 @@ Readlines(path,file):=( ////%Readlines end//// ////%Changesetting start//// -Changesetting(dir):=( //181017 - regional(fname); - fname="ketcindychange.txt"; - if(!isexists(dir,fname), - if(dir==Dircdy, - fname="ketcindy.conf"; - , - fname=".ketcindy.conf"; - ); +Changesetting():=( //190128 + regional(dir,fname); + dir=Homehead+pathsep()+getname(); + fname=".ketcindy.conf"; + if(isexists(dir,fname), + println("read "+fname+" in "+dir); + setdirectory(dir); + import(fname); ); + dir=Dircdy; fname="ketcindy.conf"; if(isexists(dir,fname), println("read "+fname+" in "+dir); setdirectory(dir); import(fname); ); -); //181017to +); ////%Changesetting end//// ////%Cindyname start//// @@ -308,7 +314,7 @@ Setwindow(str):=( // createpoint("SW",Pcrd([XMIN,YMIN])); // createpoint("NE", Pcrd([XMAX,YMAX])); Putpoint("SW",Pcrd([XMIN,YMIN])); - Putpoint("NE", Pcrd([XMAX,YMAX])); + Putpoint("NE", Pcrd([XMAX,YMAX])); ); if(msg=="y", println("Setwindow(["+XMIN+","+XMAX+"],["+YMIN+","+YMAX+"])"); @@ -373,6 +379,47 @@ DqDq(str):=( ); ////%DqDq end//// +////%PPa start//// 190111 +PPa():=PPa(""); +PPa(str):="("+str+")"; +////%PPa end//// + +////%PaO start//// 190111 +PaO():=PaO(""); +PaO(Arg):=( + regional(out); + if(isstring(Arg), + out="("+Arg; + , + out=""; + repeat(Arg, + out=out+"("; + ); + ); + out; +); +////%PaO end//// + +////%PaC start//// 190111 +PaC():=PaC(""); +PaC(Arg):=( + regional(out); + if(isstring(Arg), + out=Arg+")"; + , + out=""; + repeat(Arg, + out=out+")"; + ); + ); + out; +); +////%PaC end//// + +////%PPa start//// 190111 +PPa(str):="("+str+")"; +////%PPa end//// + ////%Tab2list start//// Tab2list(dtstr):=Tab2list(dtstr,[]); Tab2list(dtstrorg,options):=( @@ -787,7 +834,7 @@ Changework(dirorg,options):=( //16.10.21 , println("Directory "+dir+" not exist, so "+Dqq(Dirwork)+" not changed"); ); //180618to -// println("Directory "+dir+" not exist, so set to "+Dircdy);//180604(2lines) +// println("Directory "+dir+" not exist, so set to "+Dircdy);//180604[2lines] // Dirwork=Dircdy; // ErrFlag=-1; , @@ -826,17 +873,17 @@ Changestyle(nameL,style):=( if(length(tmp)>0, Ltype=Ltypeorg; GCLIST=select(GCLIST,#_1!=name); - COM2ndlist=select(COM2ndlist, - (indexof(#,"("+name)==0)%(indexof(#,"Shade")>0)); // 15.05.23,16.12.13 + COM2ndlist=select(COM2ndlist, //no ketjs + (indexof(#,"("+name)==0)%(indexof(#,"Shade")>0)); // 15.05.23,16.12.13 //no ketjs if(Noflg<2, if(isstring(Ltype), - if((Noflg==0)&(color!=KCOLOR), //180904 + if((Noflg==0)&(color!=KCOLOR), //180904 //no ketjs on Texcom("{");Com2nd("Setcolor("+color+")");//180722 - ); + ); //no ketjs off Ltype=GetLinestyle(text(Noflg)+Ltype,name); - if((Noflg==0)&(color!=KCOLOR), //180904 + if((Noflg==0)&(color!=KCOLOR), //180904 //no ketjs on Texcom("}");//180722 - ); + ); //no ketjs off , if(Noflg==1,Ltype=0); ); @@ -864,7 +911,7 @@ Op(n,object):=( // 16.05.25 ////%Op end//// ////%Ptselected start//// -Ptselected():=Isptselected(allpoints());//180711(2lines) +Ptselected():=Isptselected(allpoints());//180711[2lines] Ptselected(ptlist):=Isptselected(ptlist); Isptselected():=Isptselected(allpoints()); //180706 Isptselected(ptlist):=( @@ -1117,19 +1164,15 @@ Sprintf(value,dig):=( ); ////%Sprintf end//// -Assign(str):=( // old - regional(out); - out=str; - forall(VLIST, - tmp=substring(#_1,0,length(#_1)-1); - out=replace(out,tmp,"("+#_2+")"); - ); - out; -); - ////%Assign start//// +Assign(str):=( //190125from + regional(tmp); + tmp=[]; + forall(VLIST,tmp=concat(tmp,[#_1,#_2])); + Assign(str,tmp); +); //190125to Assign(funstr,vrL):=( - regional(nn,out,tmp,tmp1); + regional(nn,out); nn=length(vrL)/2; out=funstr; forall(1..nn, @@ -1137,7 +1180,6 @@ Assign(funstr,vrL):=( ); out; ); - Assign(funstr,varname,rep):=( //help:Assign("x^2+a*x","a",1.3); //help:Assign("a*x^2+b*x",["a",1,"b",2]); @@ -1154,7 +1196,7 @@ Assign(funstr,varname,rep):=( ii=indexof(funstr,varname); if(ii>0, Flg=0; - if(ii>1, + if(ii>1, tmp=substring(funstr,ii-2,ii-1); if(contains(Notvar,tmp), tmp2=tmp2+substring(funstr,0,ii); @@ -1270,7 +1312,7 @@ Divoptions(options):=( tmp1=parse(tmp2); color=tmp1; if(length(tmp1)==4, - tmp1=colorCmyk2Rgb(tmp1); + tmp1=Colorcmyk2rgb(tmp1); ); , tmp1=Colorname2rgb(tmp2); color=tmp1; //181212 @@ -1369,6 +1411,28 @@ Crossprod(a,b):=( ); ////%Crossprod end//// +////%Mvprod start//// +Mvprod(mat,vec):=( //190127 + regional(vecL); + if(MeasureDepth(vec)==0,vecL=[vec],vecL=vec); + Mvprod(mat,vecL,length(vecL)); +); +Mvprod(mat,vecL,nn):=( +//help:Mvprod(mat,vec(list)); + regional(tmp,out); + if(nn==1, + out=mat*vecL_1; + , + out=[]; + forall(1..nn, + tmp=mat*vecL_#; + out=append(out,tmp); + ); + ); + out; +); +////%Mvprod end//// + ////%Ptstart start//// Ptstart(Fig):=( //help:Ptstart("gr1"); @@ -1427,7 +1491,7 @@ Paramoncrv(pP,Gdata):=Paramoncurve(pP,Gdata);//180723 ////%Paramoncrv end//// ////%ParamonCurve start//// ParamonCurve(point,Gdata):=( -//help:ParamonCurve(A,"gr1");//180723(3lines) +//help:ParamonCurve(A,"gr1");//180723[3lines] regional(Tmp,PtL,pP); if(ispoint(point),pP=point.xy,pP=point); // Eps=10^(-8); @@ -1631,7 +1695,7 @@ IntersectcrvsPp(Gr1,Gr2,options):=( Data1=apply(Data1,LLcrd(#)); Data2=apply(Data2,LLcrd(#)); if(length(Data1)==length(Data2), - Tmp1=Reverse(Data2); + Tmp1=reverse(Data2); Eps0=10^(-6); Tmp2=0; forall(1..(length(Data1)), @@ -2046,7 +2110,7 @@ Collectsameseg(ptdL):=( ); gL=[]; tmp=apply(tmp1md,#_4); - dst=min(tmp); + dst=min(tmp); forall(tmp1md, if(#_4<dst+Eps00, gL=append(gL,#); @@ -2194,7 +2258,7 @@ NearestptcrvPhy(point,PL):=( ////%Nearestptcrv start//// Nearestptcrv(point,plist):=( //help:Nearestptcrv(A,"gr1"); - regional(tmp,pt);//180723(3lines) + regional(tmp,pt);//180723[3lines] if(ispoint(point),pt=point.xy,pt=point); tmp=Nearestpt(pt,plist); tmp_1; @@ -2334,7 +2398,7 @@ Derivative(fun,var,value,options):=( ); ); if(method=="D", - str="d("; + str="d"+PaO(); str=str+replace(fun,var,"#")+","; str=str+value+")"; tmp=Pcrd([1,parse(str)]); // 14.11.08 @@ -2385,7 +2449,7 @@ Tangentplot(nm,pdstr,ptinfo,optionsorg):=( println(" Derivative cannot be calculated"); flg=1; , - tmp=sort(tmp,[#_3]);//1807120(3lines) + tmp=sort(tmp,[#_3]);//1807120[3lines] pt=tmp_ch_1; par=tmp_ch_2; ); @@ -2485,7 +2549,7 @@ Integratefn(fnstr,rngstr,options):=( //180708from ex=range_2; dx=(ex-sx)/Num; xn=apply(0..Num,sx+#*dx); - yn=apply(xn,parse(Assign(fnstr,[var,textformat(#,5)]))); + yn=apply(xn,parse(Assign(fnstr,[var,#]))); //181230 plt=apply(1..(Num+1),[xn_#,yn_#]); Sm=IntegrateO(plt,range); );//180708to @@ -2494,8 +2558,8 @@ Integratefn(fnstr,rngstr,options):=( //180708from forall(1..Num, Lx=range_1+(range_2-range_1)*(#-1)/Num; Rx=range_1+(range_2-range_1)*#/Num; - va1=parse(replace(fnstr,vastr,textformat(Lx,5))); - va2=parse(replace(fnstr,vastr,textformat(Rx,5))); + va1=parse(replace(fnstr,vastr,Textformat(Lx,5))); + va2=parse(replace(fnstr,vastr,Textformat(Rx,5))); Sm=Sm+(va1+va2)*(Rx-Lx)/2; ); ); @@ -2505,14 +2569,14 @@ Integratefn(fnstr,rngstr,options):=( //180708from ex=range_2; dx=(ex-sx)/Num; xn=apply(0..Num,sx+#*dx); - yn=apply(xn,parse(replace(fnstr,vastr,textformat(#,5)))); + yn=apply(xn,parse(replace(fnstr,vastr,Textformat(#,5)))); dx=dx/2; repeat(Num,s, x0=xn_s; x1=(xn_s+xn_(s+1))/2; x2=xn_(s+1); y0=yn_s; - y1=parse(replace(fnstr,vastr,textformat(x1,5))); + y1=parse(replace(fnstr,vastr,Textformat(x1,5))); y2=yn_(s+1); Sm=Sm+dx*(y0+4*y1+y2)/3; ); @@ -2701,19 +2765,19 @@ Inversefun(fnstr,rngstr,value):=( x1=range_1; x2=range_2; repeat(15, x3=(x1+x2)/2; - va1=parse(replace(fnstr,varstr,textformat(x1,5))); - va2=parse(replace(fnstr,varstr,textformat(x3,5))); + va1=parse(replace(fnstr,varstr,Textformat(x1,5))); + va2=parse(replace(fnstr,varstr,Textformat(x3,5))); if((va1>value & va2>value) % (va1<value & va2<value), x1=x3; , x2=x3; ); ); - va1=parse(replace(fnstr,varstr,textformat(x1,5)))-value; - va2=parse(replace(fnstr,varstr,textformat(x2,5)))-value; + va1=parse(replace(fnstr,varstr,Textformat(x1,5)))-value; + va2=parse(replace(fnstr,varstr,Textformat(x2,5)))-value; if(x1==range_1 % x2==range_2, - println("not found in ("+textformat(range_1,5) - +","+textformat(range_2,5)+")"); + println("not found in ("+Textformat(range_1,5) + +","+Textformat(range_2,5)+")"); ); if(abs(va1)<=abs(va2),x1,x2); ); @@ -2770,34 +2834,48 @@ Texcom(strorg):=( //17.09.22 ); ////%Texcom end//// +////%Ketcindylogo start//// Ketcindylogo():=( //help:Ketcindylogo(); Com2nd("Texcom("+Dq+"\def\ketcindy{{K\kern-.20em \lower.5ex\hbox{E}\kern-.125em{TCindy}}}"+Dq+")"); ); +////%Ketcindylogo end//// -Drwline():=Drwline(textformat(GrL,5)); +////%Drwline start//// +Drwline():=Drwline(Textformat(GrL,5)); Drwline(gstr):=( Com2nd("Drwline("+gstr+")"); ); +////%Drwline end//// + +////%Dashline start//// Dashline(gstr):=( Com2nd("Dashline("+gstr+")"); ); +////%Dashline end//// +////%Invdashline start//// Invdashline(gstr):=( Com2nd("Invdashline("+gstr+")"); ); +////%Invdashline end//// +////%Dottedline start//// Dottedline(gstr):=( Com2nd("Dottedline("+gstr+")"); ); +////%Dottedline end//// +////%SetEnglish start//// SetEnglish():=( //help:SetEnglish(); Com0th("setlanguage('en')"); ); +////%SetEnglish end//// +////%Drawlinetype start//// Drawlinetype(name,type):=( //help:Drawlinetype("gr1","da,1"); regional(Dop,tmp,tmp1,tmp2); @@ -2820,6 +2898,7 @@ Drawlinetype(name,type):=( Dottedline(name+Dop); ); ); +////%Drawlinetype end//// ////%Setunitlen start//// Setunitlen():=( @@ -2836,7 +2915,7 @@ Setunitlen(UI):=( OL="+-*/"; if(length(UI)>0, ULEN=UI; - GLIST=append(GLIST,"Setunitlen("+Dq+UI+Dq+")");//180513 + GLIST=append(GLIST,"Setunitlen("+Dq+UI+Dq+")");//180513 //no ketjs ); Is=1; VL=""; @@ -2881,14 +2960,15 @@ Setunitlen(UI):=( Setmarklen(ratio):=( //help:Setmarklen(0.2); MARKLEN=ratio*0.2;//16.11.01 - Com2nd("Setmarklen("+textformat(ratio,5)+")"); + Com2nd("Setmarklen("+Textformat(ratio,5)+")"); ); ////%Setmarklen end//// ////%Setorigin start//// Setorigin(point):=( //help:Setorigin([1,2]); - Com2nd("Setorigin("+textformat(point,5)+")"); + GENTEN=point; //181231 + Com2nd("Setorigin("+Textformat(point,5)+")"); ); ////%Setorigin end//// @@ -3065,20 +3145,20 @@ Setcolor(parorg):=( //180603renew cstr=text(par); cstr=substring(cstr,1,length(cstr)-1); if(length(par)==3, - cstr="Texcom('\\color[rgb]{"+cstr+"}')"; + cstr="Texcom('\\color[rgb]{"+cstr+"}')"; //no ketjs KCOLOR=par; ); if(length(par)==4, - cstr="Texcom('\\color[cmyk]{"+cstr+"}')"; - tmp=ColorCmyk2Rgb(par); + cstr="Texcom('\\color[cmyk]{"+cstr+"}')"; //no ketjs + tmp=Colorcmyk2rgb(par); KCOLOR=tmp; ); - Com2nd(cstr); + Com2nd(cstr); //no ketjs ); ////%Setcolor end//// -////%ColorRgb2Cmyk start//// -ColorRgb2Cmyk(clr):=( +////%Colorrgb2cmyk start//// +Colorrgb2cmyk(clr):=( // help:ColorRgb([0.2,0.5,0.1]); regional(clrnew,tmp,black); tmp=apply(clr,1-#); @@ -3091,10 +3171,10 @@ ColorRgb2Cmyk(clr):=( ); //181112to clrnew; ); -////%ColorRgb2Cmyk end//// +////%Colorrgb2cmyk end//// -////%ColorCmyk2Rgb start//// -ColorCmyk2Rgb(clr):=( +////%Colorcmyk2rgb start//// +Colorcmyk2rgb(clr):=( // help:ColorRgb([0.2,0.5,0.1,0.2]); regional(clrnew,tmp,black); black=clr_4; @@ -3102,7 +3182,7 @@ ColorCmyk2Rgb(clr):=( clrnew=tmp_(1..3); clrnew; ); -////%ColorCmyk2Rgb end//// +////%Colorcmyk2rgb end//// ////%Colorrgbhsv start//// Colorrgbhsv(rgb):=( @@ -3215,16 +3295,16 @@ Colorhslrgb(hsl):=( var2 = ( ll + ss ) - ( ss * ll ); ); var1 = 2.0 * ll - var2; - rr = hue2rgb( var1, var2, hh + ( 1.0 / 3.0 ) ); - gg = hue2rgb( var1, var2, hh ); - bb = hue2rgb( var1, var2, hh - ( 1.0 / 3.0 ) ); + rr = Hue2rgb( var1, var2, hh + ( 1.0 / 3.0 ) ); + gg = Hue2rgb( var1, var2, hh ); + bb = Hue2rgb( var1, var2, hh - ( 1.0 / 3.0 ) ); ); [rr,gg,bb]; ); ////%Colorhslrgb end//// -////%Colorhue2rgb start//// -hue2rgb(vv1,vv2,vh):=( +////%Hue2rgb start//// +Hue2rgb(vv1,vv2,vh):=( regional(out); if ( vh < 0.0 ,vh =vh+1); if ( vh > 1.0 ,vh =vh-1); @@ -3243,7 +3323,7 @@ hue2rgb(vv1,vv2,vh):=( ); out; ); -////%Colorhue2rgb end//// +////%Hue2rgb end//// ////%Colorrgbhwb start//// Colorrgbhwb(sL):=( @@ -3365,36 +3445,51 @@ GetLinestyle(str,name):=( noflg=parse(substring(str,0,1)); if(substring(name,0,3)=="sub",subflg=1,subflg=0); // 16.02.29 tmp1=substring(str,1,3); + tmp2=""; //190119from + tmp=indexof(str,","); + if(tmp>0, + tmp2=substring(str,tmp,length(str)); + ); //190119to if(tmp1=="dr" % tmp1=="Dr", - Ltype=0; +// Ltype=0; + if(length(tmp2)==0,tmp2="1"); //190125 + Ltype=[0,tmp2]; //190119 if(noflg==0 & subflg==0, // 16.02.29 Drwline(name+Dop); ); ); if(tmp1=="da" % tmp1=="Da", - Ltype=1; +// Ltype=1; + if(length(tmp2)==0,tmp2="1,1"); //190125 + Ltype=[1,tmp2]; //190119 if(noflg==0 & subflg==0, // 16.02.29 Dashline(name+Dop); ); ); if(tmp1=="id" % tmp1=="Id", - Ltype=2; // 15.11.09 +// Ltype=2; // 15.11.09 + if(length(tmp2)==0,tmp2="1,1"); //190125 + Ltype=[2,tmp2]; //190119 if(noflg==0 & subflg==0, // 16.02.29 Invdashline(name+Dop); ); ); if(tmp1=="do" % tmp1=="Do", - Ltype=3; +// Ltype=3; + if(length(tmp2)==0,tmp2="1,1"); //190125 + Ltype=[3,tmp2]; //190119 if(noflg==0 & subflg==0, // 16.02.29 Dottedline(name+Dop); ); ); if(tmp1=="dp" % tmp1=="Dp", - Ltype=0; +// Ltype=0; + if(length(tmp2)==0,tmp2="1"); //190125 + Ltype=[0,tmp2]; //190119 tmp1=parse(name); tmp2=""; forall(tmp1, - tmp2=tmp2+textformat(#_1,5)+","; + tmp2=tmp2+Textformat(#_1,5)+","; ); tmp2=substring(tmp2,0,length(tmp2)-1); if(noflg==0, @@ -3439,7 +3534,7 @@ Chunderscore(str):=( ); if(indexof(str,"]")>0, tmp1=replace(tmp1,",]",")"); - tmp1=replace(tmp1,"[","list("); + tmp1=replace(tmp1,"[","list"+PaO()); , tmp1=substring(tmp1,0,length(tmp1)-1); ); @@ -3480,11 +3575,11 @@ AddGraph(nm,pltdata,options):=( pdata=tmp1; if(Noflg<3, println("generate addgraph "+name); - tmp=name+"="+textformat(pdata,5); + tmp=name+"="+Textformat(pdata,5); parse(tmp); if(isstring(pltdata), // 16.04.04 from if(indexof(pltdata,"]")>0, - tmp1="list(Listplot("+substring(pltdata,1,length(pltdata)); + tmp1="list"+PaO()+"Listplot"+PaO()+substring(pltdata,1,length(pltdata)); tmp1=replace(tmp1,"]",",]"); , tmp1="Listplot("+substring(pltdata,0,length(pltdata))+",]"; @@ -3513,37 +3608,37 @@ AddGraph(nm,pltdata,options):=( if(indexof(pltdata,"[")>0, tmp1=tmp1+")"; ); - GLIST=append(GLIST,name+"="+tmp1); + GLIST=append(GLIST,name+"="+tmp1); //no ketjs , if(MeasureDepth(pdata)==1, - tmp1=name+"=Listplot("+textformat(pdata,5)+")"; + tmp1=name+"=Listplot("+Textformat(pdata,5)+")"; , - tmp1="list("; + tmp1="list"+PaO(); forall(1..(length(pdata)), - tmp=name+"p"+textformat(#,5)+"="; + tmp=name+"p"+Textformat(#,5)+"="; if(length(pdata_#)>1, // 15.01.22 - tmp=tmp+"Listplot("+textformat(pdata_#,5)+")"; + tmp=tmp+"Listplot("+Textformat(pdata_#,5)+")"; , - tmp=tmp+"Pointdata("+textformat(pdata_#_1,5)+")"; + tmp=tmp+"Pointdata("+Textformat(pdata_#_1,5)+")"; ); - GLIST=append(GLIST,tmp); - tmp1=tmp1+name+"p"+textformat(#,5)+","; + GLIST=append(GLIST,tmp); //no ketjs + tmp1=tmp1+name+"p"+Textformat(#,5)+","; ); tmp1=name+"="+substring(tmp1,0,length(tmp1)-1)+")"; ); - GLIST=append(GLIST,tmp1); + GLIST=append(GLIST,tmp1); //no ketjs ); ); // 16.04.04 until if(Noflg<2, if(isstring(Ltype), - if((Noflg==0)&(color!=KCOLOR), //181020 + if((Noflg==0)&(color!=KCOLOR), //181020 //no ketjs on Texcom("{");Com2nd("Setcolor("+color+")");//180722 - ); + ); //no ketjs off Ltype=GetLinestyle(text(Noflg)+Ltype,name); - if((Noflg==0)&(color!=KCOLOR), //181020 + if((Noflg==0)&(color!=KCOLOR), //181020 //no ketjs on Texcom("}");//180722 - ); - , + ); //no ketjs off + , if(Noflg==1,Ltype=0); ); GCLIST=append(GCLIST,[name,Ltype,opcindy]); @@ -3600,7 +3695,7 @@ Joincrvs(nm,plotstrL,options):=( pS=Ptstart(PtL); pQ=Ptstart(Qd); pR=Ptend(Qd); - rMN=min([|pP-pQ|,|pP-pR|,|pS-pQ|,|pS-pR|]); + rMN=min([|pP-pQ|,|pP-pR|,|pS-pQ|,|pS-pR|]); if(rMN==|pP-pR|, Qd=reverse(Qd); , @@ -3624,25 +3719,25 @@ Joincrvs(nm,plotstrL,options):=( if(Noflg<3, println("generate joincurve "+name); tmp1=apply(PtL,Pcrd(#)); - tmp=name+"="+textformat(tmp1,5); + tmp=name+"="+Textformat(tmp1,5); parse(tmp); tmp1=""; forall(plotstrL, tmp1=tmp1+#+","; ); tmp1=substring(tmp1,0,length(tmp1)-1); - GLIST=append(GLIST,name+"=Joincrvs("+tmp1+")"); + GLIST=append(GLIST,name+"=Joincrvs("+tmp1+")"); //no ketjs ); if(Noflg<2, if(isstring(Ltype), - if((Noflg==0)&(color!=KCOLOR), //181020 + if((Noflg==0)&(color!=KCOLOR), //181020 //no ketjs on Texcom("{");Com2nd("Setcolor("+color+")");//180722 - ); - Ltype=GetLinestyle(text(Noflg)+Ltype,name); - if((Noflg==0)&(color!=KCOLOR), //181020 + ); //no ketjs off + Ltype=GetLinestyle(text(Noflg)+Ltype,name); + if((Noflg==0)&(color!=KCOLOR), //181020 //no ketjs on Texcom("}");//180722 - ); - , + ); //no ketjs off + , if(Noflg==1,Ltype=0); ); GCLIST=append(GCLIST,[name,Ltype,opcindy]); @@ -3680,7 +3775,7 @@ Partcrv(nm,pA,pB,PkLstr,options):=( Out2=Partcrv("",1,pB,PkLstr,["nodata"]); tmp=Ptstart(PkL)-Ptend(PkL); if(|tmp|<Eps, - Ans=Joincrvs("",[Out1,Out2],["nodata"]); + Ans=Joincrvs("",[Out1,Out2],["nodata"]); , Ans=[apply(Out1,Pcrd(#)),apply(Out2,Pcrd(#))]; ); @@ -3688,8 +3783,8 @@ Partcrv(nm,pA,pB,PkLstr,options):=( ); if(Flg==0, nS=ceil(pA); - nE=floor(pB); - PPL=[]; + nE=floor(pB); + PPL=[]; if(pA<nS-Eps, pP=(nS-pA)*PkL_(nS-1)+(1-nS+pA)*PkL_nS; PPL=[pP]; @@ -3707,14 +3802,14 @@ Partcrv(nm,pA,pB,PkLstr,options):=( tmp=Nearestpt(LLcrd(Pcrd(pA)),PkL); Ta=tmp_2; tmp=Nearestpt(LLcrd(Pcrd(pB)),PkL); // 15.09.12 - Tb=tmp_2; + Tb=tmp_2; Ans=Partcrv("",Ta,Tb,PkL,["nodata"] ); Ans=apply(Ans,Pcrd(#)); ); if(Noflg<3, println("generate partcrv "+name); tmp1=apply(Ans,Pcrd(#)); - tmp=name+"="+textformat(tmp1,5); + tmp=name+"="+Textformat(tmp1,5); parse(tmp); // GLIST=append(GLIST, // 16.04.03 if(DepthFlg==0, @@ -3722,20 +3817,20 @@ Partcrv(nm,pA,pB,PkLstr,options):=( , tmp=PkLstr+"(1)"; ); - tmp1=name+"=Partcrv("+textformat(Lcrd(pA),5) - +","+textformat(Lcrd(pB),5)+","+tmp+")"; // 16.04.03 - GLIST=append(GLIST,tmp1); + tmp1=name+"=Partcrv("+Textformat(Lcrd(pA),5) + +","+Textformat(Lcrd(pB),5)+","+tmp+")"; // 16.04.03 + GLIST=append(GLIST,tmp1); //no ketjs ); if(Noflg<2, if(isstring(Ltype), - if((Noflg==0)&(color!=KCOLOR), //181020 + if((Noflg==0)&(color!=KCOLOR), //181020 //no ketjs on Texcom("{");Com2nd("Setcolor("+color+")");//180722 - ); - Ltype=GetLinestyle(text(Noflg)+Ltype,name); - if((Noflg==0)&(color!=KCOLOR), //181020 + ); //no ketjs off + Ltype=GetLinestyle(text(Noflg)+Ltype,name); + if((Noflg==0)&(color!=KCOLOR), //181020 //no ketjs on Texcom("}");//180722 - ); - , + ); //no ketjs off + , if(Noflg==1,Ltype=0); ); GCLIST=append(GCLIST,[name,Ltype,opcindy]); @@ -3761,8 +3856,11 @@ Pointdata(nm,list):=Pointdata(nm,list,[]); Pointdata(nm,listorg,options):=( //help:Pointdata("1",[2,4],["Size=5"]); //help:Pointdata("2",[[2,3],[4,1]]); +//help:Pointdata(options=["Size=(1)","Disp=(y)","Inside="]); +//help:Pointdata("Inside=1(def)/ratio/rgblist/colorname/-1"]); regional(list,name,nameL,ptlist,opstr,opcindy, - eqL,dispflg,size,thick,tmp,tmp1,tmp2,tmp3,Ltype,Noflg,color); + eqL,dispflg,size,thick,tmp,tmp1,tmp2,tmp3, + Ltype,Noflg,color,inside); name="pt"+nm; nameL=name+"L"; tmp=Divoptions(options); @@ -3770,65 +3868,80 @@ Pointdata(nm,listorg,options):=( Noflg=tmp_2; eqL=tmp_5; opcindy=tmp_(length(tmp)); - opstr=tmp_(length(tmp)-1); +// opstr=tmp_(length(tmp)-1); color=tmp_(length(tmp)-2); size=""; dispflg="Y"; - if(length(eqL)>0, - forall(eqL, - tmp=Strsplit(#,"="); - tmp1=Toupper(substring(tmp_1,0,1)); - tmp2=Toupper(substring(tmp_2,0,1)); - if(tmp1=="S", - size=tmp2; - opcindy=opcindy+",size->"+text(size); //181013 - ); - if(tmp1=="D", //181030from - dispflg=tmp2; - ); + inside=color; + forall(eqL, + tmp=Strsplit(#,"="); + tmp1=Toupper(substring(tmp_1,0,1)); + if(tmp1=="S", + size=Toupper(substring(tmp_2,0,1));; + opcindy=opcindy+",size->"+text(size); //181013 + ); + if(tmp1=="D", //181030from + dispflg=Toupper(substring(tmp_2,0,1)); ); + if(tmp1=="I", //181229from + if(contains(["","no"],tmp_2), + if(tmp_2=="no",inside=append(inside,-1)); + , + tmp2=substring(tmp_2,0,1); + if(contains(["-","0","1",".","["],tmp2), + tmp=parse(tmp_2); + if(length(tmp)==4,tmp=Colorcmyk2rgb(tmp)); //190115 + if(!isstring(tmp),tmp=[tmp]); + , + tmp=Colorname2rgb(tmp_2); + ); + inside=concat(inside,tmp); + ); + ); //181229to ); if(dispflg=="Y", println("generate pointdata "+name); ); //181030to - if(isstring(listorg),list=parse(listorg),list=listorg); //17.10.23 + if(isstring(listorg), + list=parse(listorg) + , + list=listorg + ); //17.10.23 if(MeasureDepth(list)==0,list=[list]);//180530 tmp=MeasureDepth(list); - if(tmp>0, // 2015.02.21 - if(tmp==1,ptlist=list,ptlist=list_1); - tmp=apply(ptlist,[textformat(Pcrd(#),5)]); - tmp1=text(tmp); - tmp2=substring(tmp1,1,length(tmp1)-1); - tmp3=tmp1; - , - ptlist=list; - tmp1=textformat(Pcrd(ptlist),5); - tmp2=tmp1; - tmp3="["+tmp1+"]"; - ); + if(tmp==1,ptlist=list,ptlist=list_1); //190126from + tmp=apply(ptlist,[Textformat(Pcrd(#),5)]); + tmp1=text(tmp); + tmp2=substring(tmp1,1,length(tmp1)-1); + tmp3=tmp1; tmp=name+"="+tmp1; parse(tmp); tmp=nameL+"="+tmp3; - parse(tmp); + parse(tmp); //190126to if(Noflg<3, if(isstring(listorg), //17.10.23 tmp2=listorg; , - tmp2="list("; //17.10.10from + tmp2="list"+PaO(); //17.10.10from forall(list, if(isstring(#), tmp=#; , - if(ispoint(#),tmp=text(#),tmp=textformat(#,6)); + if(ispoint(#), + tmp=text(#); + , + tmp=Textformat(#,6); + ); ); tmp2=tmp2+tmp+","; ); - tmp2=substring(tmp2,0,length(tmp2)-1)+")"; //17.10.10until + tmp2=substring(tmp2,0,length(tmp2)-1)+")"; + //17.10.10until ); - GLIST=append(GLIST,name+"=Pointdata("+tmp2+")"); + GLIST=append(GLIST,name+"=Pointdata("+tmp2+")"); //no ketjs ); if(Noflg<2, - tmp=[nameL,0,opcindy]; + tmp=[nameL,[0,1],opcindy]; //190126 GCLIST=append(GCLIST,tmp); if(Noflg==0, if(length(size)>0, @@ -3838,17 +3951,20 @@ Pointdata(nm,listorg,options):=( if(length(size)>0,tmp1=parse(size),tmp1=1); tmp1=max(tmp1,1)/8; Setpen(tmp1); // 16.04.09 until - if((Noflg==0)&(color!=KCOLOR), //181020 - Texcom("{");Com2nd("Setcolor("+color+")");//180711 - ); - Com2nd("Drwpt(list("+name+")"+opstr+")"); - if((Noflg==0)&(color!=KCOLOR), //181020 + if((Noflg==0)&(color!=KCOLOR), //181020 //no ketjs on + Texcom("{"); + Com2nd("Setcolor("+color+")");//180711 + ); //no ketjs off + opstr=","+Textformat(inside,2); + Com2nd("Drwpt"+PaO()+"list"+PaO()+name+")"+opstr+")"); + if((Noflg==0)&(color!=KCOLOR), //181020 //no ketjs on Texcom("}");//180711 - ); + ); //no ketjs off Setpen(thick); // 16.04.09 - if(length(size)>0, - Com2nd("Setpt("+textformat(TenSize/TenSizeInit,1)+")"); - ); + if(length(size)>0, //no ketjs on + tmp=Textformat(TenSize/TenSizeInit,1); + Com2nd("Setpt("+tmp+")"); + ); //no ketjs off ); ); ptlist; @@ -3856,6 +3972,23 @@ Pointdata(nm,listorg,options):=( ////%Pointdata end//// ////%Listplot start//// +Listplot(list):=Listplot(list,[]); +Listplot(Arg1,Arg2):=( + regional(name,list,options,str); + if(isstring(Arg1), + name=Arg1; + list=Arg2; + Listplot(name,list,[]); + , + list=Arg1; + options=Arg2; + name=""; + forall(list, // 16.10.07from + name=name+#.name; + );// 16.10.07until + Listplot(name,list,options); + ); +); Listplot(nm,list,options):=( //help:Listplot([A,B]); // help:Listplot(["A","B"]); @@ -3866,7 +3999,7 @@ Listplot(nm,list,options):=( name=substring(nm,1,length(nm)); , name="sg"+nm; - ); // until + ); // upto tmp=Divoptions(options); Ltype=tmp_1; Noflg=tmp_2; @@ -3877,7 +4010,7 @@ Listplot(nm,list,options):=( cutend=[0,0];//180719 forall(eqL, tmp=Strsplit(#,"="); - tmp1=Toupper(substring(tmp_1,0,1)); + tmp1=Toupper(substring(tmp_1,0,1)); tmp2=tmp_2; if(tmp1=="M", tmp=Toupper(substring(tmp2,0,1)); @@ -3904,19 +4037,19 @@ Listplot(nm,list,options):=( ptlist_1=ptlist_1+tmp*cutend_1; ptlist_(length(ptlist))=ptlist_(length(ptlist))-tmp*cutend_2; );//180719to - tmp=name+"="+textformat(ptlist,5); + tmp=name+"="+Textformat(ptlist,5); parse(tmp); - GLIST=append(GLIST,name+"=Listplot("+textformat(ptlist,5)+")"); // 180719 + GLIST=append(GLIST,name+"=Listplot("+Textformat(ptlist,5)+")"); // 180719 //no ketjs ); if(Noflg<2, if(isstring(Ltype), - if((Noflg==0)&(color!=KCOLOR), //181020 + if((Noflg==0)&(color!=KCOLOR), //181020 //no ketjs on Texcom("{");Com2nd("Setcolor("+color+")");//180711 - ); + ); //no ketjs off Ltype=GetLinestyle(text(Noflg)+Ltype,name); - if((Noflg==0)&(color!=KCOLOR), //181020 + if((Noflg==0)&(color!=KCOLOR), //181020 //no ketjs on Texcom("}");//180711 - ); + ); //no ketjs off , if(Noflg==1,Ltype=0); ); @@ -3925,23 +4058,6 @@ Listplot(nm,list,options):=( tmp1=apply(list,Lcrd(#)); tmp1; ); -Listplot(Arg1,Arg2):=( - regional(name,list,options,str); - if(isstring(Arg1), - name=Arg1; - list=Arg2; - Listplot(name,list,[]); - , - list=Arg1; - options=Arg2; - name=""; - forall(list, // 16.10.07from - name=name+#.name; - );// 16.10.07until - Listplot(name,list,options); - ); -); -Listplot(list):=Listplot(list,[]); ////%Listplot end//// ////%Lineplot start//// @@ -3977,20 +4093,20 @@ Lineplot(nm,list,options):=( if(Noflg<3, println("generate Lineplot "+name); tmp1=apply(Out,Pcrd(#)); - tmp=name+"="+textformat(tmp1,5); + tmp=name+"="+Textformat(tmp1,5); parse(tmp); - GLIST=append(GLIST,name+"=Lineplot("+textformat(list,5)+opstr+")"); + GLIST=append(GLIST,name+"=Lineplot("+Textformat(list,5)+opstr+")"); //no ketjs ); if(Noflg<2, if(isstring(Ltype), - if((Noflg==0)&(color!=KCOLOR), //181020 + if((Noflg==0)&(color!=KCOLOR), //181020 //no ketjs on Texcom("{");Com2nd("Setcolor("+color+")");//180722 - ); + ); //no ketjs off Ltype=GetLinestyle(text(Noflg)+Ltype,name); - if((Noflg==0)&(color!=KCOLOR), //181020 + if((Noflg==0)&(color!=KCOLOR), //181020 //no ketjs on Texcom("}");//180722 - ); - , + ); //no ketjs off + , if(Noflg==1,Ltype=0); ); GCLIST=append(GCLIST,[name,Ltype,opcindy]); @@ -4049,7 +4165,7 @@ Plotdata(name1,func,variable,options):=( if(substring(#,0,1)=="E", if(substring(tmp1,0,1)=="[", //180817from Ec=parse(tmp1); - tmp1=replace(tmp1,"[","c("); + tmp1=replace(tmp1,"[","c"+PaO()); tmp1=replace(tmp1,",",".0,"); tmp1=replace(tmp1,"]",".0)"); opstr=opstr+","+Dqq("Exc="+tmp1); //180817to @@ -4084,7 +4200,7 @@ Plotdata(name1,func,variable,options):=( PdL=[]; Ke=1; forall(0..Num, - xx=x1+#*(x2-x1)/Num; // differs from Scilab ( / Num-1) + xx=x1+#*(x2-x1)/Num; // differs from Scilab [ / Num-1] if(length(Exfun)>0, tmp=parse(Exfun); if(abs(tmp)<Eps, @@ -4103,7 +4219,7 @@ Plotdata(name1,func,variable,options):=( , PdL=concat(PdL,[["inf"],tmp]); ); - ); + ); , PdL=[tmp]; ); @@ -4172,22 +4288,22 @@ Plotdata(name1,func,variable,options):=( tmp1=append(tmp1,apply(tmp2,Pcrd(#))); ); ); - tmp=name+"="+textformat(tmp1,5); + tmp=name+"="+Textformat(tmp1,5); parse(tmp); - tmp1=replace(func,LFmark,""); + tmp1=replace(func,LFmark,""); //no ketjs on tmp2=replace(variable,LFmark,""); tmp=name+"=Plotdata('"+tmp1+"','"+tmp2+"'"+opstr+")"; - GLIST=append(GLIST,tmp); + GLIST=append(GLIST,tmp); //no ketjs off ); if(Noflg<2, if(isstring(Ltype), - if((Noflg==0)&(color!=KCOLOR), //181020 + if((Noflg==0)&(color!=KCOLOR), //181020 //no ketjs on Texcom("{");Com2nd("Setcolor("+color+")");//180722 - ); + ); //no ketjs off Ltype=GetLinestyle(text(Noflg)+Ltype,name); - if((Noflg==0)&(color!=KCOLOR), //181020 + if((Noflg==0)&(color!=KCOLOR), //181020 //no ketjs on Texcom("}");//180722 - ); + ); //no ketjs off , if(Noflg==1,Ltype=0); ); @@ -4197,13 +4313,13 @@ Plotdata(name1,func,variable,options):=( , if(Noflg<2, if(isstring(Ltype), - if((Noflg==0)&(color!=KCOLOR), //181020 + if((Noflg==0)&(color!=KCOLOR), //181020 //no ketjs on Texcom("{");Com2nd("Setcolor("+color+")");//180722 - ); + ); //no ketjs off Ltype=GetLinestyle(text(Noflg)+Ltype,name); - if((Noflg==0)&(color!=KCOLOR), //181020 + if((Noflg==0)&(color!=KCOLOR), //181020 //no ketjs on Texcom("}");//180722 - ); + ); //no ketjs off , if(Noflg==1,Ltype=0); ); @@ -4220,7 +4336,7 @@ Paramplot(nm,funstr,variable):=Paramplot(nm,funstr,variable,[]); Paramplot(nm,funstr,variable,options):=( //help:Paramplot("1","[2*cos(t),sin(t)]","t=[0,2*pi]"); regional(name,Out,tmp,tmp1,tmp2,vname,func,str,Rng,Num, - Ec,Exfun,Dc,eqL,Fntmp,Vatmp,t1,t2,dt,tt,pa,ke, + Ec,Exfun,Dc,eqL,Fntmp,Vatmp,t1,t2,dt,tt,pa,ke, pt, //190103 Ltype,Noflg,Inflg,Outflg,opstr,opcindy,color); if(substring(nm,0,1)=="-", // 180928from name=substring(nm,1,length(nm)); @@ -4251,7 +4367,7 @@ Paramplot(nm,funstr,variable,options):=( if(substring(#,0,1)=="E", if(substring(tmp1,0,1)=="[", //180817from Ec=parse(tmp1); - tmp1=replace(tmp1,"[","c("); + tmp1=replace(tmp1,"[","c"+PaO()); tmp1=replace(tmp1,",",".0,"); tmp1=replace(tmp1,"]",".0)"); opstr=opstr+","+Dqq("Exc="+tmp1); //180817to @@ -4342,22 +4458,22 @@ Paramplot(nm,funstr,variable,options):=( tmp1=append(tmp1,apply(tmp2,Pcrd(#))); ); ); - tmp=name+"="+textformat(tmp1,5); + tmp=name+"="+Textformat(tmp1,5); parse(tmp); - tmp1=replace(funstr,LFmark,""); // 15.11.13 + tmp1=replace(funstr,LFmark,""); // 15.11.13 //no ketjs on tmp2=replace(variable,LFmark,""); tmp=name+"=Paramplot('"+tmp1+"','"+tmp2+"'"+opstr+")"; - GLIST=append(GLIST,tmp); + GLIST=append(GLIST,tmp); //no ketjs off ); if(Noflg<2, if(isstring(Ltype), - if((Noflg==0)&(color!=KCOLOR), //181020 + if((Noflg==0)&(color!=KCOLOR), //181020 //no ketjs on Texcom("{");Com2nd("Setcolor("+color+")");//180722 - ); + ); //no ketjs off Ltype=GetLinestyle(text(Noflg)+Ltype,name); - if((Noflg==0)&(color!=KCOLOR), //181020 + if((Noflg==0)&(color!=KCOLOR), //181020 //no ketjs on Texcom("}");//180722 - ); + ); //no ketjs off , if(Noflg==1,Ltype=0); ); @@ -4367,14 +4483,14 @@ Paramplot(nm,funstr,variable,options):=( , if(Noflg<2, if(isstring(Ltype), - if((Noflg==0)&(color!=KCOLOR), //181020 + if((Noflg==0)&(color!=KCOLOR), //181020 //no ketjs on Texcom("{");Com2nd("Setcolor("+color+")");//180722 - ); + ); //no ketjs off Ltype=GetLinestyle(text(Noflg)+Ltype,name); - if((Noflg==0)&(color!=KCOLOR), //181020 + if((Noflg==0)&(color!=KCOLOR), //181020 //no ketjs on Texcom("}");//180722 - ); - , + ); //no ketjs off + , if(Noflg==1,Ltype=0); ); if(Inflg==1, @@ -4408,7 +4524,7 @@ Connectseg(Pdata):=( ctr=0; while((length(vL)>0)&(ctr<1000), ctr=ctr+1; - qd=PlotL_(length(PlotL)); + qd=PlotL_(length(PlotL)); ah=qd_1; ao=qd_(length(qd)); flg=0; forall(1..(length(vL)),jj, @@ -4416,7 +4532,7 @@ Connectseg(Pdata):=( tmp1=Pdata_(vL_jj); pp=tmp1_1; qq=tmp1_(length(tmp1)); if(Norm(pp-ao)<Eps, - tmp=tmp1_(2..(length(tmp1))); + tmp=tmp1_(2..(length(tmp1))); if(length(tmp)>0, qd=concat(qd,tmp); ); @@ -4560,7 +4676,7 @@ Implicitplot(name1,func,xrng,yrng,optionsorg):=( xval1=xval2; eval11=eval21; eval12=eval22; - if(length(qL)==2, + if(length(qL)==2, out=append(out,qL); ); ); @@ -4583,21 +4699,21 @@ Implicitplot(name1,func,xrng,yrng,optionsorg):=( tmp1=append(tmp1,apply(tmp2,Pcrd(#))); ); ); - tmp=name+"="+textformat(tmp1,5); + tmp=name+"="+Textformat(tmp1,5); parse(tmp); - tmp=name+"=Implicitplot('"+func+"','"+xrng+"','"+yrng+"'"+opstr+")"; - GLIST=append(GLIST,tmp); + tmp=name+"=Implicitplot('"+func+"','"+xrng+"','"+yrng+"'"+opstr+")"; //no ketjs + GLIST=append(GLIST,tmp); //no ketjs ); if(Noflg<2, if(isstring(Ltype), - if((Noflg==0)&(color!=KCOLOR), //181020 + if((Noflg==0)&(color!=KCOLOR), //181020 //no ketjs on Texcom("{");Com2nd("Setcolor("+color+")");//180722 - ); - Ltype=GetLinestyle(text(Noflg)+Ltype,name); - if((Noflg==0)&(color!=KCOLOR), //181020 + ); //no ketjs off + Ltype=GetLinestyle(text(Noflg)+Ltype,name); + if((Noflg==0)&(color!=KCOLOR), //181020 //no ketjs on Texcom("}");//180722 - ); - , + ); //no ketjs off + , if(Noflg==1,Ltype=0); ); GCLIST=append(GCLIST,[name,Ltype,opcindy]); @@ -4688,9 +4804,9 @@ Circledata(nm,cenrad,options):=( if(Noflg<3, println("generate Circledata "+name); tmp1=apply(Out,Pcrd(#)); - tmp=name+"="+textformat(tmp1,5); + tmp=name+"="+Textformat(tmp1,5); parse(tmp); - if(length(cenrad)==2, + if(length(cenrad)==2, //no ketjs on tmp=name+"=Circledata("+cenrad+opstr+")"; , if(ra>0, @@ -4699,18 +4815,18 @@ Circledata(nm,cenrad,options):=( tmp=name+"=Lineplot("+cenrad_1+","+cenrad_2+")"; ); ); - GLIST=append(GLIST,tmp); + GLIST=append(GLIST,tmp); //no ketjs off ); if(Noflg<2, if(isstring(Ltype), - if((Noflg==0)&(color!=KCOLOR), //181020 + if((Noflg==0)&(color!=KCOLOR), //181020 //no ketjs on Texcom("{");Com2nd("Setcolor("+color+")");//180722 - ); - Ltype=GetLinestyle(text(Noflg)+Ltype,name); - if((Noflg==0)&(color!=KCOLOR), //181020 + ); //no ketjs off + Ltype=GetLinestyle(text(Noflg)+Ltype,name); + if((Noflg==0)&(color!=KCOLOR), //181020 //no ketjs on Texcom("}");//180722 - ); - , + ); //no ketjs off + , if(Noflg==1,Ltype=0); ); GCLIST=append(GCLIST,[name,Ltype,opcindy]); @@ -4790,20 +4906,20 @@ Framedata(nm,list,optionsorg):=( if(Noflg<3, println("generate Framedata "+name); tmp1=apply(Out,Pcrd(#)); - tmp=name+"="+textformat(tmp1,5); + tmp=name+"="+Textformat(tmp1,5); parse(tmp); - GLIST=append(GLIST,name+"=Framedata("+pA+","+dx+","+dy+")"); + GLIST=append(GLIST,name+"=Framedata("+pA+","+dx+","+dy+")"); //no ketjs ); if(Noflg<2, if(isstring(Ltype), - if((Noflg==0)&(color!=KCOLOR), //181020 + if((Noflg==0)&(color!=KCOLOR), //181020 //no ketjs on Texcom("{");Com2nd("Setcolor("+color+")");//180722 - ); - Ltype=GetLinestyle(text(Noflg)+Ltype,name); - if((Noflg==0)&(color!=KCOLOR), //181020 + ); //no ketjs off + Ltype=GetLinestyle(text(Noflg)+Ltype,name); + if((Noflg==0)&(color!=KCOLOR), //181020 //no ketjs on Texcom("}");//180722 - ); - , + ); //no ketjs off + , if(Noflg==1,Ltype=0); ); GCLIST=append(GCLIST,[name,Ltype,opcindy]); @@ -4826,20 +4942,20 @@ Framedata(nm,cent,dx,dy,options):=( if(Noflg<3, println("generate Framedata "+name); tmp1=apply(Out,Pcrd(#)); - tmp=name+"="+textformat(tmp1,5); + tmp=name+"="+Textformat(tmp1,5); parse(tmp); - GLIST=append(GLIST,name+"=Framedata("+cent.xy+","+dx+","+dy+")"); + GLIST=append(GLIST,name+"=Framedata("+cent.xy+","+dx+","+dy+")"); //no ketjs ); if(Noflg<2, if(isstring(Ltype), - if((Noflg==0)&(color!=KCOLOR), //180904 + if((Noflg==0)&(color!=KCOLOR), //180904 //no ketjs on Texcom("{");Com2nd("Setcolor("+color+")");//180722 - ); - Ltype=GetLinestyle(text(Noflg)+Ltype,name); - if((Noflg==0)&(color!=KCOLOR), //180904 + ); //no ketjs off + Ltype=GetLinestyle(text(Noflg)+Ltype,name); + if((Noflg==0)&(color!=KCOLOR), //180904 //no ketjs on Texcom("}");//180722 - ); - , + ); //no ketjs off + , if(Noflg==1,Ltype=0); ); GCLIST=append(GCLIST,[name,Ltype,opcindy]); @@ -4906,28 +5022,28 @@ Ovaldata(nm,Pdata,options):=( if(Noflg<3, println("generate Ovaldata "+name); tmp1=apply(Graph,Pcrd(#)); - tmp=name+"="+textformat(tmp1,5); + tmp=name+"="+Textformat(tmp1,5); parse(tmp); - GLIST=append(GLIST, - name+"=Ovaldata("+Ctr+","+Dx+","+Dy+opstr+")");//16.01.30 + GLIST=append(GLIST, //no ketjs + name+"=Ovaldata("+Ctr+","+Dx+","+Dy+opstr+")");//16.01.30 //no ketjs ); if(Noflg<2, if(isstring(Ltype), - if((Noflg==0)&(color!=KCOLOR), //180904 + if((Noflg==0)&(color!=KCOLOR), //180904 //no ketjs on Texcom("{");Com2nd("Setcolor("+color+")");//180722 - ); - Ltype=GetLinestyle(text(Noflg)+Ltype,name); - if((Noflg==0)&(color!=KCOLOR), //180904 + ); //no ketjs off + Ltype=GetLinestyle(text(Noflg)+Ltype,name); + if((Noflg==0)&(color!=KCOLOR), //180904 //no ketjs on Texcom("}");//180722 - ); - , + ); //no ketjs off + , if(Noflg==1,Ltype=0); ); GCLIST=append(GCLIST,[name,Ltype,opcindy]); tmp1=apply(Graph,Pcrd(#)); - tmp=name+"="+textformat(tmp1,5); + tmp=name+"="+Textformat(tmp1,5); parse(tmp); - tmp=textformat(Ctr,5)+","+textformat(Dx,5)+","+textformat(Dy,5); + tmp=Textformat(Ctr,5)+","+Textformat(Dx,5)+","+Textformat(Dy,5); ); Graph; ); @@ -5035,7 +5151,7 @@ Parabolaplot(nm,ptlist,rng,options):=( tmp=tmp+"+("+format(tmp2,5)+")"; tmp1=parse(rng); tmp1=[pA_1-(tmp1_2-tmp1_1)/2,pA_1+(tmp1_2-tmp1_1)/2]; - tmp2="x="+textformat(tmp1,5); + tmp2="x="+Textformat(tmp1,5); Plotdata(nm+"para",tmp,tmp2,append(options,"nodisp")); Rotatedata(nm+"para","gr"+nm+"para",angle,append(options,pB)); ); @@ -5194,7 +5310,7 @@ println([4573,ptlist]); tmp=angle+#*2*pi/number; tmp1=pA+rr*[cos(tmp),sin(tmp)]; if(#>0 & #<number, - if((ispoint(ptlist_2))&(geo=="Y"), //180708(3lines) + if((ispoint(ptlist_2))&(geo=="Y"), //180708[3lines] Putpoint((ptlist_2).name+text(#),tmp1);//16.10.07 ); //Pointdata(nm,ptL); @@ -5266,7 +5382,7 @@ Setarrow(arglist):=( ); [YaSize,YaAngle,YaPosition,YaCut,YasenStyle]; ); -////%Setarrow start//// +////%Setarrow end//// ////%Arrowheaddata start//// @@ -5331,7 +5447,7 @@ Arrowheaddata(point,direction,options):=( ); ); gG=apply(0..10,pP+ookisa*cos(hiraki)*[cos(2*pi/10*#),sin(2*pi/10*#)]); - Flg=0; + Flg=0; forall(1..rF,Nj, if(Flg==0, pB=Ptcrv(rF+1-Nj,Houkou); @@ -5429,7 +5545,7 @@ Arrowhead(nm,point,direction,optionsorg):=(//181018from if(!Inwindow(LLcrd(pP)),Noflg=2);//181018 if(Noflg<3, tmp1=apply(list,LLcrd(#)); - tmp=name+"="+textformat(tmp1,5); + tmp=name+"="+Textformat(tmp1,5); parse(tmp); ); if(Noflg<2, @@ -5451,14 +5567,14 @@ Arrowhead(nm,point,direction,optionsorg):=(//181018from hostr=format(apply(Houkou,LLcrd(#)),5); ); ); - if((Noflg==0)&(color!=KCOLOR), //180904 + if((Noflg==0)&(color!=KCOLOR), //180904 //no ketjs on Texcom("{");Com2nd("Setcolor("+color+")");//180722 - ); + ); //no ketjs off Com2nd("Arrowhead("+ptstr+","+hostr+opstr+")"); - if((Noflg==0)&(color!=KCOLOR), //180904 + if((Noflg==0)&(color!=KCOLOR), //180904 //no ketjs on Texcom("}");//180722 - ); -); + ); //no ketjs off + ); ); ////%Arrowhead end//// @@ -5580,7 +5696,7 @@ Anglemark(Arg1,Arg2):=( // 2015.04.28 from , plist=Arg1; options=Arg2; - tmp=textformat(plist,5); + tmp=Textformat(plist,5); tmp=replace(tmp,",",""); nm=substring(tmp,1,length(tmp)-1); Anglemark(nm,plist,options); @@ -5642,34 +5758,34 @@ Anglemark(nm,plist,options):=( Th=Rg_1+#*(Rg_2-Rg_1)/Num; Out=append(Out,Ctr+ra*[cos(Th),sin(Th)]); ); - Th=(Rg_1+Rg_2)/2; //16.10.31from(moved) + Th=(Rg_1+Rg_2)/2; //16.10.31from[moved] tmp1=Ctr+Brat*ra*[cos(Th),sin(Th)]; tmp="Defvar("+Dq+Bpos+"="; - tmp=tmp+textformat(tmp1,5)+Dq+");"; - parse(tmp);//16.10.31until(moved) + tmp=tmp+Textformat(tmp1,5)+Dq+");"; + parse(tmp);//16.10.31to[moved] if(length(Bname)>0, parse(Bname); ); if(Noflg<3, println("generate anglemark "+name+" and "+Bpos); tmp1=apply(Out,Pcrd(#)); - tmp=name+"="+textformat(tmp1,5); + tmp=name+"="+Textformat(tmp1,5); parse(tmp); - tmp=textformat(plist,5); + tmp=Textformat(plist,5); //no ketjs on tmp1=substring(tmp,1,length(tmp)-1); tmp=name+"=Anglemark("+tmp1+opstr+")"; - GLIST=append(GLIST,tmp); + GLIST=append(GLIST,tmp); //no ketjs off ); if(Noflg<2, if(isstring(Ltype), - if((Noflg==0)&(color!=KCOLOR), //180904 + if((Noflg==0)&(color!=KCOLOR), //180904 //no ketjs on Texcom("{");Com2nd("Setcolor("+color+")");//180722 - ); - Ltype=GetLinestyle(text(Noflg)+Ltype,name); - if((Noflg==0)&(color!=KCOLOR), //180904 + ); //no ketjs off + Ltype=GetLinestyle(text(Noflg)+Ltype,name); + if((Noflg==0)&(color!=KCOLOR), //180904 //no ketjs on Texcom("}");//180722 - ); - , + ); //no ketjs off + , if(Noflg==1,Ltype=0); ); GCLIST=append(GCLIST,[name,Ltype,opcindy]); @@ -5690,7 +5806,7 @@ Paramark(Arg1,Arg2):=( // 17.03.27 from , plist=Arg1; options=Arg2; - tmp=textformat(plist,5); + tmp=Textformat(plist,5); tmp=replace(tmp,",",""); nm=substring(tmp,1,length(tmp)-1); Paramark(nm,plist,options); @@ -5738,29 +5854,29 @@ Paramark(nm,plist,options):=( Out=append(Out,pA+ra*(pC-pA)/|pC-pA|); if(length(Bname)>0, tmp1=pA+Brat*ra*(pB-pA)/|pB-pA|+Brat*ra*(pC-pA)/|pC-pA|; - tmp="Defvar("+Dq+Bpos+"="+textformat(tmp1,5)+Dq+");"; + tmp="Defvar("+Dq+Bpos+"="+Textformat(tmp1,5)+Dq+");"; parse(tmp); - parse(Bname); + parse(Bname); ); if(Noflg<3, println("generate paramark "+name); tmp1=apply(Out,Pcrd(#)); - tmp=name+"="+textformat(tmp1,5); + tmp=name+"="+Textformat(tmp1,5); parse(tmp); - tmp1=substring(textformat(plist,5),1,length(textformat(plist,5))-1); + tmp1=substring(Textformat(plist,5),1,length(Textformat(plist,5))-1); //no ketjs on tmp=name+"=Paramark("+tmp1+opstr+")"; - GLIST=append(GLIST,tmp); + GLIST=append(GLIST,tmp); //no ketjs off ); if(Noflg<2, if(isstring(Ltype), - if((Noflg==0)&(color!=KCOLOR), //180904 + if((Noflg==0)&(color!=KCOLOR), //180904 //no ketjs on Texcom("{");Com2nd("Setcolor("+color+")");//180722 - ); - Ltype=GetLinestyle(text(Noflg)+Ltype,name); - if((Noflg==0)&(color!=KCOLOR), //180904 + ); //no ketjs off + Ltype=GetLinestyle(text(Noflg)+Ltype,name); + if((Noflg==0)&(color!=KCOLOR), //180904 //no ketjs on Texcom("}");//180722 - ); - , + ); //no ketjs off + , if(Noflg==1,Ltype=0); ); GCLIST=append(GCLIST,[name,Ltype,opcindy]); @@ -5791,7 +5907,7 @@ Bowdata(plist):=Bowdata(plist,[]); Bowdata(plist,options):=( regional(nm,tmp); if(islist(plist), // 16.12.04from - tmp=textformat(plist,5); + tmp=Textformat(plist,5); tmp=replace(tmp,",",""); nm=substring(tmp,1,length(tmp)-1); Bowdata(nm,plist,options); @@ -5854,9 +5970,9 @@ Bowdata(nm,plist,options):=( ra=Ydata_2; Th=(Ydata_3+Ydata_4)*0.5; BOWMIDDLE=[pC_1+ra*cos(Th),pC_2+ra*sin(Th)]; - Bpos="md"+name; // 16.10.31from(moved) - tmp="Defvar("+Dq+Bpos+"="+textformat(BOWMIDDLE,5)+Dq+");"; - parse(tmp);// 16.10.31until(moved) + Bpos="md"+name; // 16.10.31from[moved] + tmp="Defvar("+Dq+Bpos+"="+Textformat(BOWMIDDLE,5)+Dq+");"; + parse(tmp);// 16.10.31to[moved] if(length(Bname)>0, //16.11.01from tmp=indexof(Bops,","); if(tmp>0, @@ -5892,7 +6008,7 @@ Bowdata(nm,plist,options):=( Bname=Bname+","; if(indexof(Bname,"rot")>0, if(rev==1,tmp=pB-pA,tmp=pA-pB); - Bname=Bname+textformat(tmp,5)+","; + Bname=Bname+Textformat(tmp,5)+","; , Bname=Bname+Dq+"c"+Dq+","; ); @@ -5927,27 +6043,27 @@ Bowdata(nm,plist,options):=( if(Noflg<3, println("generate bowdata "+name+" and "+Bpos);//16.10.31 if(MeasureDepth(Out)==1,Out=[Out]); - tmp1=[]; + tmp1=[]; forall(Out,tmp2, tmp=apply(tmp2,Pcrd(#)); tmp1=append(tmp1,tmp); ); - tmp=name+"="+textformat(tmp1,5); + tmp=name+"="+Textformat(tmp1,5); parse(tmp); - tmp1=substring(textformat(plist,5),1,length(textformat(plist,5))-1); + tmp1=substring(Textformat(plist,5),1,length(Textformat(plist,5))-1); //no ketjs on tmp=name+"=Bowdata("+tmp1+opstr+")"; - GLIST=append(GLIST,tmp); + GLIST=append(GLIST,tmp); //no ketjs off ); if(Noflg<2, if(isstring(Ltype), - if((Noflg==0)&(color!=KCOLOR), //180904 + if((Noflg==0)&(color!=KCOLOR), //180904 //no ketjs on Texcom("{");Com2nd("Setcolor("+color+")");//180722 - ); - Ltype=GetLinestyle(text(Noflg)+Ltype,name); - if((Noflg==0)&(color!=KCOLOR), //180904 - Texcom("}");//180722 - ); - , + ); //no ketjs off + Ltype=GetLinestyle(text(Noflg)+Ltype,name); + if((Noflg==0)&(color!=KCOLOR), //180904 //no ketjs on + Texcom("}");//180722 + ); //no ketjs off + , if(Noflg==1,Ltype=0); ); GCLIST=append(GCLIST,[name,Ltype,opcindy]); @@ -6082,7 +6198,7 @@ Deqplot(nm,deqorg,rngorg,initt,initf,options):=( //17.10.06 ); rng=rngorg; if(indexof(rng,"=")==0, - rng=rng+"="+textformat([XMIN,XMAX],6); + rng=rng+"="+Textformat([XMIN,XMAX],6); ); deq=deqorg; deq=replace(deq,"'","`"); //180527 @@ -6137,33 +6253,33 @@ Deqplot(nm,deqorg,rngorg,initt,initf,options):=( //17.10.06 deq=deq+"]"; ); if(Noflg<3, - pdL=deqdata(deq,rng,initt,initf,Num); + pdL=Deqdata(deq,rng,initt,initf,Num); if(phase==1, pdL=apply(pdL,#_(2..3)); ); tmp1=apply(pdL,Pcrd(#)); - tmp=name+"="+textformat(tmp1,5); + tmp=name+"="+Textformat(tmp1,5); parse(tmp); ); - if(Noflg<1, + if(Noflg<1, //no ketjs on tmp=Assign(deq); tmp=replace(deq,"'","`"); tmp=name+"=Deqplot('"+tmp+"','"+rng+"',"; - tmp=tmp+format(initt,6)+","+textformat(initf,6); + tmp=tmp+format(initt,6)+","+Textformat(initf,6); tmp=tmp+","+text(sel)+",'Num="+text(Num)+"')"; tmp=RSform(tmp); GLIST=append(GLIST,tmp); - ); + ); //no ketjs off if(Noflg<2, if(isstring(Ltype), - if((Noflg==0)&(color!=KCOLOR), //180904 + if((Noflg==0)&(color!=KCOLOR), //180904 //no ketjs on Texcom("{");Com2nd("Setcolor("+color+")");//180722 - ); - Ltype=GetLinestyle(text(Noflg)+Ltype,name); - if((Noflg==0)&(color!=KCOLOR), //180904 + ); //no ketjs off + Ltype=GetLinestyle(text(Noflg)+Ltype,name); + if((Noflg==0)&(color!=KCOLOR), //180904 //no ketjs on Texcom("}");//180722 - ); - , + ); //no ketjs off + , if(Noflg==1,Ltype=0); ); GCLIST=append(GCLIST,[name,Ltype,opcindy]); @@ -6194,7 +6310,7 @@ EnclosingS(nm,plist,options):=( Start=[]; Flg=0; forall(realL, - if(isList(#) % ispoint(#), + if(islist(#) % ispoint(#), Start=Lcrd(#); // 15.09.12 , Flg=Flg+1; @@ -6305,26 +6421,26 @@ EnclosingS(nm,plist,options):=( AnsL_(length(AnsL))=AnsL_1;//16.10.20 if(Noflg<3, println("generate Enclosing "+name); - tmp=name+"="+textformat(AnsL,5); + tmp=name+"="+Textformat(AnsL,5); parse(tmp); - tmp=name+"=Enclosing(";//16.11.07from - tmp1="list("; + tmp=name+"=Enclosing(";//16.11.07from //no ketjs on + tmp1="list"+PaO(); forall(plist, tmp1=tmp1+#+","; ); tmp=tmp+substring(tmp1,0,length(tmp1)-1)+")"+opstr+")"; - GLIST=append(GLIST,tmp);//16.11.07until + GLIST=append(GLIST,tmp);//16.11.07to //no ketjs off ); if(Noflg<2, if(isstring(Ltype), - if((Noflg==0)&(color!=KCOLOR), //180904 + if((Noflg==0)&(color!=KCOLOR), //180904 //no ketjs on Texcom("{");Com2nd("Setcolor("+color+")");//180722 - ); - Ltype=GetLinestyle(text(Noflg)+Ltype,name); - if((Noflg==0)&(color!=KCOLOR), //180904 + ); //no ketjs off + Ltype=GetLinestyle(text(Noflg)+Ltype,name); + if((Noflg==0)&(color!=KCOLOR), //180904 //no ketjs on Texcom("}");//180722 - ); - , + ); //no ketjs off + , if(Noflg==1,Ltype=0); ); GCLIST=append(GCLIST,[name,Ltype,opcindy]); @@ -6336,7 +6452,7 @@ EnclosingS(nm,plist,options):=( /////////// new enclosing /////////// ////%Enclosing start//// -Enclosing(nm,plist):=Enclosing2(nm,plist,[]);//180706(2lines) +Enclosing(nm,plist):=Enclosing2(nm,plist,[]);//180706[2lines] Enclosing(nm,plistorg,options):=Enclosing2(nm,plistorg,options); Enclosing2(nm,plist):=Enclosing2(nm,plist,[]); Enclosing2(nm,plistorg,options):=( @@ -6433,7 +6549,7 @@ Enclosing2(nm,plistorg,options):=( tmp2=Prepend(Op(length(tmp1),tmp),tmp2); Gdata=replace(Gdata,"(",""); Gdata=replace(Gdata,")",""); - tmp=Gdata+"="+textformat(tmp2,6); + tmp=Gdata+"="+Textformat(tmp2,6); parse(tmp); plist_nxtno=Gdata; t2=Length(tmp1); @@ -6474,28 +6590,28 @@ Enclosing2(nm,plistorg,options):=( ); if(Noflg<3, println("generate Enclosing "+name); - tmp=name+"="+textformat(AnsL,5); + tmp=name+"="+Textformat(AnsL,5); parse(tmp); tmp=name+"=Enclosing2(";//16.11.07from - tmp1="list("; + tmp1="list"+PaO(); forall(plistorg, //18.02.02 tmp1=tmp1+#+","; ); - tmp=tmp+substring(tmp1,0,length(tmp1)-1)+")";//18.0706from + tmp=tmp+substring(tmp1,0,length(tmp1)-1)+")";//18.0706from //no ketjs on if(length(Start)>0,tmp=tmp+","+Textformat(Start,6)); tmp=tmp+","+text(epspara)+")";//18.0706to,180707 - GLIST=append(GLIST,tmp);//16.11.07until + GLIST=append(GLIST,tmp);//16.11.07to //no ketjs off ); if(Noflg<2, if(isstring(Ltype), - if((Noflg==0)&(color!=KCOLOR), //180904 + if((Noflg==0)&(color!=KCOLOR), //180904 //no ketjs on Texcom("{");Com2nd("Setcolor("+color+")");//180722 - ); - Ltype=GetLinestyle(text(Noflg)+Ltype,name); - if((Noflg==0)&(color!=KCOLOR), //180904 + ); //no ketjs off + Ltype=GetLinestyle(text(Noflg)+Ltype,name); + if((Noflg==0)&(color!=KCOLOR), //180904 //no ketjs on Texcom("}");//180722 - ); - , + ); //no ketjs off + , if(Noflg==1,Ltype=0); ); GCLIST=append(GCLIST,[name,Ltype,opcindy]); @@ -6524,7 +6640,7 @@ Makehatch(iolistorg,pt,vec,bdylist):=( tmp="["+substring(tmp,0,length(tmp)-1)+"]"; iolist_#=parse(tmp); ); - Scalebkup=[SCALEX,SCALEY];//181020(2lines) + Scalebkup=[SCALEX,SCALEY];//181020[2lines] SCALEX=1; SCALEY=1; sg=Lineplot("",[pt,pt+vec],["nodata"]); @@ -6697,14 +6813,14 @@ Hatchdatacindy(nm,iostr,bdylistorg,optionsorg):=( ); );//180717to if(tmp=="s", - Listplot(name,[LLcrd(tmp2_1),[tmp2_1_1,2*YMIN-YMAX], //180717(2lines) + Listplot(name,[LLcrd(tmp2_1),[tmp2_1_1,2*YMIN-YMAX], //180717[2lines] [tmp2_(length(tmp2))_1,2*YMIN-YMAX],LLcrd(tmp2_(length(tmp2)))], ["nodisp"]); Joincrvs(text(kk)+name,[namep,"sg"+name],["nodisp"]);//180717 bname="join"+text(kk)+name; ); if(tmp=="n", - Listplot(name,[LLcrd(tmp2_1),[tmp2_1_1,2*YMAX-YMIN], //180717(2lines) + Listplot(name,[LLcrd(tmp2_1),[tmp2_1_1,2*YMAX-YMIN], //180717[2lines] [tmp2_(length(tmp2))_1,2*YMAX-YMIN],LLcrd(tmp2_(length(tmp2)))], ["nodisp"]); Joincrvs(text(kk)+name,[namep,"sg"+name],["nodisp"]); @@ -6722,8 +6838,8 @@ Hatchdatacindy(nm,iostr,bdylistorg,optionsorg):=( Joincrvs(text(kk)+name,[namep,"sg"+name],["nodisp"]);//180717 bname="join"+text(kk)+name; ); - , - Enclosing2(text(kk)+name,tmp,["nodisp"]);//180619(2lines); + , + Enclosing2(text(kk)+name,tmp,["nodisp"]);//180619[2lines] bname="en"+text(kk)+name; ); ); @@ -6851,7 +6967,7 @@ Hatchdatacindy(nm,iostr,bdylistorg,optionsorg):=( vec=[cos(angle),sin(angle)]; nvec=[-sin(angle),cos(angle)]; AnsL=[]; - ctr=0;//181005(2lines) + ctr=0;//181005[2lines] forall(0..(maxnum_1), kk, pt=startP+kk*interval*nvec; sha=Makehatch(iostr,pt,vec,bdylist); @@ -6868,41 +6984,41 @@ Hatchdatacindy(nm,iostr,bdylistorg,optionsorg):=( AnsL=concat(AnsL,sha); ); ); - tmp1=apply(AnsL,textformat(#,5)); + tmp1=apply(AnsL,Textformat(#,5)); tmp=name+"="+tmp1; parse(tmp); ); if((Noflg<3)&(mkflg>-1), if(fileflg!="Y", //181102 println("generate Hatchdata "+name); - tmp=name+"="+textformat(AnsL,5); + tmp=name+"="+Textformat(AnsL,5); parse(tmp); - if(!islist(iostr),tmp1=[iostr],tmp1=iostr); - tmp="c("; + if(!islist(iostr),tmp1=[iostr],tmp1=iostr); //no ketjs on + tmp="c"+PaO(); forall(tmp1, tmp=tmp+Dq+#+Dq+","; ); tmp=substring(tmp,0,length(tmp)-1)+")"; tmp2=name+"=Hatchdata("+tmp; forall(bdynameL, - tmp2=tmp2+",list("+#+")"; + tmp2=tmp2+",list"+PaO()+#+")"; ); tmp2=tmp2+opstr+")"; - GLIST=append(GLIST,tmp2); + GLIST=append(GLIST,tmp2); //no ketjs off , - GLIST=append(GLIST,"ReadOutData("+Dq+fname+Dq+")");//181102 + GLIST=append(GLIST,"ReadOutData("+Dq+fname+Dq+")");//181102 //no ketjs ); ); if((Noflg<2)&(mkflg>-1), if(isstring(Ltype), - if((Noflg==0)&(color!=KCOLOR), //180904 + if((Noflg==0)&(color!=KCOLOR), //180904 //no ketjs on Texcom("{");Com2nd("Setcolor("+color+")");//180722 - ); - Ltype=GetLinestyle(text(Noflg)+Ltype,name); - if((Noflg==0)&(color!=KCOLOR), //180904 + ); //no ketjs off + Ltype=GetLinestyle(text(Noflg)+Ltype,name); + if((Noflg==0)&(color!=KCOLOR), //180904 //no ketjs on Texcom("}");//180722 - ); - , + ); //no ketjs off + , if(Noflg==1,Ltype=0); ); GCLIST=append(GCLIST,[name,Ltype,opcindy]); @@ -6980,7 +7096,7 @@ Shade(nm,plistorg,options):=( //180613to ); ); //180929to if(length(color)==4, //180602from - tmp=colorCmyk2rgb(color); + tmp=Colorcmyk2rgb(color); ); flg=0; ctr=1; if(encflg==1, //180929from @@ -7004,7 +7120,7 @@ Shade(nm,plistorg,options):=( //180613to tmp2=append(tmp2,tmp); ); tmp1=Dqq("-"+name+text(ctr)); - tmp2=textformat(tmp2,6)+",["+Dqq("nodisp")+"]"; + tmp2=Textformat(tmp2,6)+",["+Dqq("nodisp")+"]"; tmp=name+text(ctr)+"=Listplot("+tmp1+","+tmp2+")"; parse(tmp); plist_jj=name+text(ctr); @@ -7018,11 +7134,11 @@ Shade(nm,plistorg,options):=( //180613to , G2=Joincrvs("1",plist,["nodata"]); G2=apply(G2,Pcrd(#)); - tmp1="fillpoly("+textformat(G2,5)+opcindy+");"; + tmp1="fillpoly("+Textformat(G2,5)+opcindy+");"; parse(tmp1); ); Str="Shade("; - tmp1="list("; + tmp1="list"+PaO(); forall(plist, if(isstring(#), // from 16.01.24 if(length(#)>1, @@ -7031,13 +7147,13 @@ Shade(nm,plistorg,options):=( //180613to tmp1=tmp1+Dq+#+Dq+","; ); , - tmp1=tmp1+"Listplot("+textformat(#,5)+"),"; + tmp1=tmp1+"Listplot("+Textformat(#,5)+"),"; ); //16.01.24to ); Str=Str+substring(tmp1,0,length(tmp1)-1)+")"+")"; //180929 - Com2nd("Texcom("+Dqq("{")+")",["before"]);Com2nd("Setcolor("+color+")",["before"]);//180722 + Com2nd("Texcom("+Dqq("{")+")",["before"]);Com2nd("Setcolor("+color+")",["before"]);//180722 //no ketjs on Com2nd(Str,["before"]); - Com2nd("Texcom("+Dqq("}")+")",["before"]);//180722 + Com2nd("Texcom("+Dqq("}")+")",["before"]);//180722 //no ketjs off ); ////%Shade end//// |