Alec Mihailovs

Dr. Aleksandrs Mihailovs

4495 Reputation

21 Badges

20 years, 335 days
Mihailovs, Inc.
Owner, President, and CEO
Tyngsboro, Massachusetts, United States

Social Networks and Content at Maplesoft.com

Maple Application Center

I received my Ph.D. from the University of Pennsylvania in 1998 and I have been teaching since then at SUNY Oneonta for 1 year, at Shepherd University for 5 years, at Tennessee Tech for 2 years, at Lane College for 1 year, and this year I taught at the University of Massachusetts Lowell. My research interests include Representation Theory and Combinatorics.

MaplePrimes Activity


These are replies submitted by Alec Mihailovs

The line starting from if in "Sorry,I forgot to mention" looks like that, both in IE and Firefox,
if Ia iL_increase:=io+(Ue-Ua)/L*t;
I don't think that it would work in Maple.
I meant that you should use &lt; instead of < on this site - not in Maple. You right about <=, that's how it should be entered in Maple. In HTML, one can use &le; and &ge; but in Maple <= and >=. Also, <> is used in Maple for ≠. Your original procedure worked for me after assigning of IaLG_boundary_condition. The line starting from if seems to be missing some code - probably, because of that &lt; problem.
I meant that you should use &lt; instead of < on this site - not in Maple. You right about <=, that's how it should be entered in Maple. In HTML, one can use &le; and &ge; but in Maple <= and >=. Also, <> is used in Maple for ≠. Your original procedure worked for me after assigning of IaLG_boundary_condition. The line starting from if seems to be missing some code - probably, because of that &lt; problem.
I have to see the code to tell how it should be plotted. LSSolve has various forms of output. It may work with fit(t), or not - depending on the way fit was defined.
Slightly below that, in Description section, it is said that
  • To specify color for plotting 2-D plots, use predefined names or COLOR structures.
  • To specify color for plotting 3-D plots, use predefined names, COLOR structures, a procedure, or an expression.
As it is said in ?colorfunc, "In general, specifying the color using procedures or expressions works only with surfaces." To color a curve in 2 colors, it can be separated in 2 curves. For example, as follows,
plot([`if`(sin(x)>=0,sin(x),undefined),
`if`(sin(x)<0,sin(x),undefined)],x=0..13,color=[red,blue]);
P.S. A part of your code is invisible, because in HTML one has to use &lt; instead of the < sign.
Also, it is possible to draw axes and tickmarks manually. For example,
xaxis:=proc(a,b,c) plottools[line]([a,0],[b,0],thickness=c) end:
yaxis:=proc(a,b,c) plottools[line]([0,a],[0,b],thickness=c) end:
xtick:=proc(a,b,c) plottools[line]([a,-b],[a,b],thickness=c) end:
ytick:=proc(a,b,c) plottools[line]([-b,a],[b,a],thickness=c) end:
f:=plot(x^2,x=-1.05..1.05,thickness=3):
plots[display](f,xaxis(-1.1,1.08,3),yaxis(0,1.04,3),
seq(xtick(-0.2*i,0.015,2),i=1..5),seq(xtick(0.2*i,0.015,2),i=1..5),
seq(ytick(0.1*i,0.02,2),i=1..10),
plots[textplot]([seq([0.2*i,-0.02,sprintf("%.1f",0.2*i)],i=-5..5)],
      align=BELOW,font=[TIMES,BOLD,14]),
plots[textplot]([seq([-0.03,0.1*i,sprintf("%.1f",0.1*i)],i=1..10)],
      align=LEFT,font=[TIMES,BOLD,14]),
plots[arrow]([1.08,0],[0.12,0],head_width=0.03,head_length=0.12,color=black),
plots[arrow]([0,1.04],[0,0.06],head_width=0.04,head_length=0.06,color=black),
plots[textplot]([1.25,0,"x"],align=RIGHT,font=[HELVETICA,14]),
plots[textplot]([0,1.14,"y"],align=ABOVE,font=[HELVETICA,14]),
axes=none,view=[-1.1..1.25,-0.1..1.2]);
For publication, plots require a lot of additional work. The general idea is that one should use export to ps with editing of the eps file after that. It is better to avoid using any text in the plot. Also, ps export is better in earlier Maple versions. Here is an example,
plotsetup(ps, plotoutput=`parabola.eps`, 
plotoptions=`width=4in,height=3in,noborder,portrait`);
plot(x->x^2,-1..1, thickness=5);
I used x->x^2 to avoid appearing of x in the plot. Now, the produced eps file can be opened in a text editor. To increase the width of axes and tickmarks, one can go to the lines /thin 3 def and /medium 7 def and change the numbers to the desirable width - something like /thin 15 def and /medium 18 def. After that, a lot of other editing is desirable - such as changing the position of 0 at the origin, changing 1 to 1.0 etc. - that also can be done in a text editor. Still, with a lot of manual work, it is rather hard to make the quality suitable for publishing. It is much easier to use MetaPost instead, or gnuplot, for example, or other CAS.
For example, let
A:=Matrix(10,2,(i,j)->i+i^2*(j-1));

                                [ 1      2]
                                [         ]
                                [ 2      6]
                                [         ]
                                [ 3     12]
                                [         ]
                                [ 4     20]
                                [         ]
                                [ 5     30]
                           A := [         ]
                                [ 6     42]
                                [         ]
                                [ 7     56]
                                [         ]
                                [ 8     72]
                                [         ]
                                [ 9     90]
                                [         ]
                                [10    110]
Then you can plot it as follows, 
plot(convert(A,listlist));
Pointplot also can be used. For example, the following command gives the same plot,
plots[pointplot](A,connect=true,color=red);
For example,
int(diff(a(x),x),x);
                                 a(x)

int(diff(a(x),x),x=0..L,continuous);

                             -a(0) + a(L)
Your example can not be integrated, in general, so Maple returns it as it is. What answer did you expect?
That works very fast. It would be interesting to compare that with calling corresponding nag functions g05... Adding a multinormal distribution to Statistics package seems like a good idea.
That works very fast. It would be interesting to compare that with calling corresponding nag functions g05... Adding a multinormal distribution to Statistics package seems like a good idea.
I don't have environmental variable 'maple' set. Perhaps, that causes problems. You might try to delete it, uninstall java, delete all java entries in the registry and reinstall Maple 10 (with installing java back after that if it necessary for other applications). That would make certain that Maple is using its own jre and not another one.
I don't have environmental variable 'maple' set. Perhaps, that causes problems. You might try to delete it, uninstall java, delete all java entries in the registry and reinstall Maple 10 (with installing java back after that if it necessary for other applications). That would make certain that Maple is using its own jre and not another one.
Yes, in general, Cholesky decomposition gives a solution. In this example, with c[i,j] = rho for i ≠ j, it is rather cumbersome. I used a different approach. If there exist such numbers c[i] that c[i,j] =c[i]*c[j] for i ≠ j, then the samples B[i] with correlation matrix c can be constructed as
               B[i] = c[i]* W[0] + sqrt(1-c[i]^2)* W[i]
In this example, c[i] = sqrt(rho).
First 168 169 170 171 172 173 174 Last Page 170 of 180