## where is _LatexSmallFractionConstant documented?...

I am trying to find what the meaning of the values that _LatexSmallFractionConstant accepts and what they do.

For example

mu:=1/((4*t+1)^(8/5)*(t-1)^(7/5));
_LatexSmallFractionConstant:=34:
latex(simplify(mu))

{1 \left( 4\,t+1 \right) ^{-{\frac{8}{5}}} \left( t-1 \right) ^{-{
\frac{7}{5}}}}



Which renders wrong as follows

But when I set _LatexSmallFractionConstant to 35 instead of 34 this is what happens

restart;
mu:=1/((4*t+1)^(8/5)*(t-1)^(7/5));
_LatexSmallFractionConstant:=35:
latex(simplify(mu))

{\frac {1}{ \left( t-1 \right) ^{{\frac{7}{5}}}} \left( 4\,t+1
\right) ^{-{\frac{8}{5}}}}


which renders as a little better as

And when I set it to _LatexSmallFractionConstant:=100 it becomes good

However, no settings value will make latex render this fraction correctly

restart;
mu:=1/(x+y);
_LatexSmallFractionConstant:=2000000000:
latex(mu)

\left( x+y \right) ^{-1}


But if I set it to 35 again now it fails to handle fraction right

restart;
mu:=1/2;
_LatexSmallFractionConstant:=35:
latex(mu)

1/2


but changing to  either zero or 1 or 2 makes it generate the correct latex

restart;
mu:=1/2;
_LatexSmallFractionConstant:=0:  #1 and 2 also works. By anything larger it goes back to 1/2
latex(mu)

{\frac{1}{2}}  #but why extra {} ??


So it seems some values makes it work OK (35 for top example) but same value makes it not work well for another example.

It seems like random settings to me.

Where is all of this documented?  I can't find it in help. Which file to print to see what this option does?

Maple 2019.1  on windows.

 > restart; mu:=1/((4*t+1)^(8/5)*(t-1)^(7/5)); _LatexSmallFractionConstant:=34: latex(mu)

{1 \left( 4\,t+1 \right) ^{-{\frac{8}{5}}} \left( t-1 \right) ^{-{
\frac{7}{5}}}}

 > restart; mu:=1/((4*t+1)^(8/5)*(t-1)^(7/5)); _LatexSmallFractionConstant:=35: latex(mu)

{\frac {1}{ \left( t-1 \right) ^{{\frac{7}{5}}}} \left( 4\,t+1
\right) ^{-{\frac{8}{5}}}}

 > restart; mu:=1/((4*t+1)^(8/5)*(t-1)^(7/5)); _LatexSmallFractionConstant:=100: latex(mu)

{\frac {1}{ \left( 4\,t+1 \right) ^{8/5} \left( t-1 \right) ^{7/5}}}

 > restart; mu:=1/(x+y); _LatexSmallFractionConstant:=2000000000: latex(mu)

\left( x+y \right) ^{-1}

 > restart; mu:=1/2; _LatexSmallFractionConstant:=3: latex(mu)

1/2

 > restart; mu:=1/2; _LatexSmallFractionConstant:=0: latex(mu)

{\frac{1}{2}}

 >

## too many problems using algolib latex in Maple...

This is really a FYI more than a question, since I do not expect any more to be able to fix these since they are part of old Maple code called algolib, downloaded from  http://algo.inria.fr/libraries/

I was trying to see if the latex command included in the above will work better than Maple own latex command.  I downloaded the tar file from the above http://algo.inria.fr/libraries/17.0/algolib.tar    and extracted it.

At first I could not find where the latex command is, since it is not part of the .mla. After some struggle, I found I can get their latex command to work if I read the following 6 .mpl files (in this order) that show up after opening the above tar file

read "C:/MAPLE/algolib/mad/CommonLib.mpl";


Once I did the above, now I could do the command

MADLaTeX:-latex(sol);

#or

MADLaTeX:-latex(sol,'string')

And these work now. For example

MADLaTeX:-latex(1/2)

\frac{1}{2}

So I said, great, finally a Maple latex command that knows how to convert a fraction to latex the right way. Much better than Maple's latex command default output

latex(1/2)

1/2


But when I started testing it more, I found many problems. So I am posting these issues, since I do not know where to send them to, as this package is no longer being maintained. May be some Maple expert can figure how to fix them if there is an interest.  I looked at the code above, and too complicated for me to even figure where to look and how to fix these.

 > restart;
 > #EXAMPLE 1
 > V:=x->piecewise(0<=x and x<=a,0,infinity); ic:=f(x,0)=piecewise(0<=x and x<=a,A*x*(a-x),0); pde :=I*h*diff(f(x,t),t)=-h^2/(2*m)*diff(f(x,t),x$2) +V(x)*f(x,t); sol:=pdsolve([pde,ic],f(x,t)) assuming a>0; lprint(sol); f(x,t) = piecewise(0 <= x and x <= a,A*x*(a-x),0)+Sum(t^n*((U -> -I*(-1/2*h^2/m *diff(diff(U,x),x)+piecewise(0 <= x and x <= a,0,infinity)*U)/h)@@n)(piecewise( 0 <= x and x <= a,A*x*(a-x),0))/n!,n = 1 .. infinity)  > MADLaTeX:-latex(sol) Error, (in typetomath) 0 <= x and x <= a: invalid for math mode  > latex(sol) f \left( x,t \right) = \cases{Ax \left( a-x \right) &$0\leq x$\ and \$x\leq a$\cr 0&otherwise\cr} +\sum _{n=1}^{\infty }{\frac {{t}^{n} \left( U\mapsto {\frac {-i \cases{0&$0\leq x$\ and \$x\leq a$\cr \infty &otherwise\cr}U}{h}}^{ \left( n \right) } \right) \left( \cases{Ax \left( a-x \right) &$0\leq x$\ and \$x\leq a$\cr 0&otherwise\cr} \right) }{n!}}  > #EXAMPLE 2  > pde := diff(v(t, s), t) +s^2*(diff(v(t, s), s, s))/(2*sigma^2)+(r-q)*s*(diff(v(t, s), s))-r*v(t, s) = 0; ic:=v(T, s) = psi(s); sol:=pdsolve([pde,ic],v(t,s)); lprint(sol); v(t,s) = psi(s)+Sum((t-T)^n*((U -> -1/2*diff(diff(U,s),s)*s^2/sigma^2+s*(-r+q)* diff(U,s)+r*U)@@n)(psi(s))/n!,n = 1 .. infinity)  > MADLaTeX:-latex(sol) Error, (in symbol/string) only ANSI-C compliant symbols are handled  > latex(sol) v \left( t,s \right) =\psi \left( s \right) +\sum _{n=1}^{\infty }{ \frac { \left( t-T \right) ^{n} \left( U\mapsto rU^{ \left( n \right) } \right) \left( \psi \left( s \right) \right) }{n!}}  > #EXAMPLE 3  > interface(showassumed=0); pde := diff(u(x,t),t)=k*diff(u(x,t),x$2)- u(x,t)*x; ic  := u(x,0)=sin(x); bc  := u(0,t)=0,u(Pi,t)=0; sol:=pdsolve([pde,ic,bc],u(x,t)) assuming k>0; lprint(sol)

u(x,t) = casesplit/ans(Sum(-(AiryBi(-1/k^(1/3)*lambda[n])*AiryAi((-lambda[n]+
x)/k^(1/3))-AiryBi((-lambda[n]+x)/k^(1/3))*AiryAi(-1/k^(1/3)*lambda[n]))*(Int(
sin(x)*AiryBi((-lambda[n]+x)/k^(1/3)),x = 0 .. Pi)*AiryAi(-1/k^(1/3)*lambda[n])
-AiryBi(-1/k^(1/3)*lambda[n])*Int(sin(x)*AiryAi((-lambda[n]+x)/k^(1/3)),x = 0
.. Pi))*(-sinh(lambda[n]*t)+cosh(lambda[n]*t))/(Int(AiryBi((-lambda[n]+x)/k^(1/
3))^2,x = 0 .. Pi)*AiryAi(-1/k^(1/3)*lambda[n])^2-2*AiryBi(-1/k^(1/3)*lambda[n]
)*Int(AiryBi((-lambda[n]+x)/k^(1/3))*AiryAi((-lambda[n]+x)/k^(1/3)),x = 0 .. Pi
)*AiryAi(-1/k^(1/3)*lambda[n])+AiryBi(-1/k^(1/3)*lambda[n])^2*Int(AiryAi((-
lambda[n]+x)/k^(1/3))^2,x = 0 .. Pi)),n = 0 .. infinity),{And(AiryAi(1/k^(1/3)*
(-lambda[n]+Pi))*AiryBi(-1/k^(1/3)*lambda[n])-AiryBi(1/k^(1/3)*(-lambda[n]+Pi))
*AiryAi(-1/k^(1/3)*lambda[n]) = 0,-infinity <= lambda[n] and lambda[n] <=
infinity)})

Error, (in typetomath) -infinity <= lambda[n] and lambda[n] <= infinity: invalid for math mode

 > latex(sol)

u \left( x,t \right) =\mbox {{\tt casesplit/ans}} \left( \sum _{n=0
}^{\infty } \left( {(-\sinh \left( \lambda_{{n}}t \right) +\cosh
\left( \lambda_{{n}}t \right) ) \left( {{\rm Bi}\left({\frac {-
\lambda_{{n}}+x}{\sqrt [3]{k}}}\right)}{{\rm Ai}\left(-{\frac {\lambda
_{{n}}}{\sqrt [3]{k}}}\right)}-{{\rm Bi}\left(-{\frac {\lambda_{{n}}}{

\sqrt [3]{k}}}\right)}{{\rm Ai}\left({\frac {-\lambda_{{n}}+x}{\sqrt [
3]{k}}}\right)} \right)  \left( \int_{0}^{\pi}\!\sin \left( x \right)
{{\rm Bi}\left({\frac {-\lambda_{{n}}+x}{\sqrt [3]{k}}}\right)}
\,{\rm d}x{{\rm Ai}\left(-{\frac {\lambda_{{n}}}{\sqrt [3]{k}}}
\right)}-{{\rm Bi}\left(-{\frac {\lambda_{{n}}}{\sqrt [3]{k}}}\right)}
\int_{0}^{\pi}\!\sin \left( x \right) {{\rm Ai}\left({\frac {-\lambda_
{{n}}+x}{\sqrt [3]{k}}}\right)}\,{\rm d}x \right)  \left( \int_{0}^{
\pi}\! \left( {{\rm Bi}\left({\frac {-\lambda_{{n}}+x}{\sqrt [3]{k}}}
\right)} \right) ^{2}\,{\rm d}x \left( {{\rm Ai}\left(-{\frac {\lambda
_{{n}}}{\sqrt [3]{k}}}\right)} \right) ^{2}-2\,{{\rm Bi}\left(-{\frac
{\lambda_{{n}}}{\sqrt [3]{k}}}\right)}\int_{0}^{\pi}\!{{\rm Bi}\left({
\frac {-\lambda_{{n}}+x}{\sqrt [3]{k}}}\right)}{{\rm Ai}\left({\frac {
-\lambda_{{n}}+x}{\sqrt [3]{k}}}\right)}\,{\rm d}x{{\rm Ai}\left(-{
\frac {\lambda_{{n}}}{\sqrt [3]{k}}}\right)}+ \left( {{\rm Bi}\left(-{
\frac {\lambda_{{n}}}{\sqrt [3]{k}}}\right)} \right) ^{2}\int_{0}^{\pi
}\! \left( {{\rm Ai}\left({\frac {-\lambda_{{n}}+x}{\sqrt [3]{k}}}
\right)} \right) ^{2}\,{\rm d}x \right) ^{-1}} \right) , \left\{ {\it
And} \left( {{\rm Ai}\left({\frac {-\lambda_{{n}}+\pi}{\sqrt [3]{k}}}
\right)}{{\rm Bi}\left(-{\frac {\lambda_{{n}}}{\sqrt [3]{k}}}\right)}-
{{\rm Bi}\left({\frac {-\lambda_{{n}}+\pi}{\sqrt [3]{k}}}\right)}{
{\rm Ai}\left(-{\frac {\lambda_{{n}}}{\sqrt [3]{k}}}\right)}=0,-
\infty \leq \lambda_{{n}} \land \lambda_{{n}}\leq \infty  \right)
\right\}  \right)

 >
 >

## problem with maple 2019...

so i just went from a really old version of maple to a the newest one maple 2019 and at first glance it doesn't seem to work correctly please take a look at the picture maybe there is a toggle i missed or something of the sorts thanks you for your time

## Inconsistent results when integrating by parts...

I have a tough integral I'm trying to solve (see attatched code). Maple seems to be able to compute it if I instruct it to integrate by parts, however the solutions don't make sense. For example, if I differentiate the result I expect to get my original integrand, but I do not. Furthermore, depending on which function you choose as 'u' and which as 'dv' when integrating by parts yields different results.

071319_Integral.mw

The attatched code has four examples:

1) Definite integration by parts

2) Indefinite integration by parts

3) Indefinite integration by parts, alternate choice of 'u'

4) Definite integration by parts, alternate choice of 'u'

and after each indefinite integration, I differentiate the result to compare with the orginal integrand.

What is going on here?

## Periodic plot with Maple 2019?...

Hi,
I would like to trace periodic functions. I saw that this was possible with the old 'FourierSeries' package with the "Rept" command. How to reproduce the same thing in the Maple 19 environment? Thank you

fs_examples.mw

## Maple gives solution to PDE which gives 1/0 for fi...

fyi, there seems to be a problem here. Maple 2019, Physics version 395 on windows 10.

The solution given to this wave PDE by Maple as sum that starts from zero, has "n" in the denominator. When n=0, this gives division by zero.  Is this a bug?

 > restart; L:=3: c:=4: h:=1/10: b:=Pi*c/L: f:=piecewise(0<=x and x<=L/3,3*h/L*x,L/3

Error, numeric exception: division by zero

 >

## Why can't Maple perform this integral?...

I'm confused as to why Maple can't perform a certain integral for me. Please see my attached code - it get's stuck on the last step.

070919_ThetaIntegral.mw

## Collecting specific coefficient from problematic...

Does anyone know how collect zero epsilon coefficient from follow expression?

coeff_test.mw

Is it possible?

Thank you!

## How to create the set of all possible rational zer...

I am able to generate random polynomials with non-zero coefficents, and define sets of all the positive divisors of the leading coefficient and the constant terms. My question is this, how may I apply the rational zeros theorem to generate the set of all possible rational zeros of the polynomial. I basically need to form all the possible quotients (positive and negative) with numerator in one set and denominator in the other set, ignoring duplicates. The attached worksheet has what I've done so far.rational_zeros.mw

 (1)

 (2)

 (3)

## eval and subexpressions...

The command eval allows to simplify a complicated expression

in a more compact form for a later output in LATEX

In the example which follows I was able to insert A and B but non C in the expression.

There is already a post on this kind of topic but I failed to understand the details.

Perhaps a Maple worksheet of answer on this topic  would be useful !

bye Lorenzo

 > restart;
 > expression:=exp(-b*x^c/2)*((x^(-(3*c)/2 + a/2 + 1/2)*(c + a + 1)*b^(-(3*c + a + 1)/(2*c)) + c*x^(a/2 + 1/2 - c/2)*b^(-(c + a + 1)/(2*c)))*c*WhittakerM((-c + a + 1)/(2*c), (2*c + a + 1)/(2*c), b*x^c) + b^(-(3*c + a + 1)/(2*c))*x^(-(3*c)/2 + a/2 + 1/2)*WhittakerM((c + a + 1)/(2*c), (2*c + a + 1)/(2*c), b*x^c)*(c + a + 1)^2)/((a + 1)*(c + a + 1)*(2*c + a + 1));
 (1)
 (2)
 > expression_ABC:=eval(expression,[x^(-(3*c)/2 + a/2 + 1/2)*(c + a + 1)*b^(-(3*c + a + 1)/(2*c))=A,c*x^(a/2 + 1/2 - c/2)*b^(-(c + a + 1)/(2*c))=B,((a + 1)*(c + a + 1)*(2*c + a + 1))=C]);
 (3)
 >
 >
 >
 >

## Maple 2019.1 on Windows 10 1903 - Context menu mis...

Hi

I've just installed Maple latest + MapleSim with the license provided by my university (I use VPN with a secure key to remotely access server license. Everything works fine, except for the context menu. It seems that the context menu module is missing! I tried uninstalling and reinstalling, but did not help.

I went back to the campus and checked Maple installation on computers there, and this problem is absent (context menu is working fine).

I can only use the context menu toolbar on the right... but this is not very convenient.

What could be the problem? See the attached image.

Thanks

---------------------

## Bug in n-th derivative of the Zeta function ?...

Hi!

How to calculate  a value in MAPLE:

My code:

evalf(eval(diff(n*Zeta(n, 3), n), n = 3)); give me:

#-0.3740436824 + 3.*eval(diff(Zeta(n, 3), n), {n = 3}) ,it should be only:-0.3740436824

OR:

fdiff(n*Zeta(n, 3), [n], n = 3);

#fdiff(n -> n*Zeta(n, 3), [1], [3]) ???

It's a Bug  or (As Designed / Not a Bug) ?

Mathematica code:

D[n*Derivative[n][Zeta][3], n] /. n -> 3 // N;

(* -0.374044*)

## imaginary to real...

I just used Maple for the first time to find the roots of an equation, the problem they give me imaginary solutions every time I put a (ln); even for ln (1) it proposes me -265.745524189222 + 0.785398163397448 * I as a solution. Could you help me to solve this problem?

## Simplification using a polylog(2,*) identity...

Why doesn't

f:=ln(s + 2)^2 + 2*polylog(2, -1 - s) + 2*polylog(2, (1 + s)/(s + 2))

simplify to zero assuming s>0?

## possible wrong solution by pdsolve...

I solved this PDE by hand to verify Maple's solution. I think Maple solution is wrong. This PDE is the heat PDE on a bar (1D) with boundary coditions on both ends are function of time and zero initial conditions.

unassign('A,B,x,t,L,k,f');
pde := diff(u(x,t),t)= diff(u(x,t),x$2): bc := u(0, t) = A(t), u(1, t) = B(t): ic := u(x, 0) = 0: sol1:=pdsolve([pde, ic, bc], u(x, t)); #now try when A(t)=sin(t),B(t)=t, use 20 terms for the sum sol2:=simplify(subs([infinity=20,B(tau)=tau,A(tau)=sin(tau),A(0)=0,B(0)=0,A(t)=sin(t),B(t)=t],sol1)): sol3:=simplify(value(subs(t=1,sol2))): evalf(subs(x=0.5,sol3))  Also doing pdetest(sol1,pde); on the above solution does ot return zero as expected. To verify more, I solved the same PDE again, but now using an explicit values for the boundary conditions A(t), B(t). Using A(t)=sin(t), B(t)=t. Then found the value again of the solution u at x=0.5 and t=1 like in the above, and it gives different value: unassign('A,B,x,t,L,k,f'); pde := diff(u(x,t),t)= diff(u(x,t),x$2):
bc := u(0, t) = sin(t), u(1, t) = t:
ic := u(x, 0) = 0:
sol4:=pdsolve([pde, ic, bc], u(x, t));
sol5:=simplify(subs(infinity=20,sol4)):
sol6:=simplify(value(subs(t=1,sol5))):
evalf(subs(x=0.5,sol6))


Then I typed my hand solution into Maple and for the same values x=0.5, t=1 and same number of terms, I also get the same value 0.819.

I do not see at all where the function sin integral should come into play in this solution.

Could some Maple expert please check to see what is going on with this solution to Maple?

Using Maple 2019.1 and Physics version 370

 1 2 3 4 5 6 Page 1 of 6
﻿