## 4 linear factors...

Hi all,

I am hoping to use Maple to develop a list of 4 distinct linear factors with the following conditions...

1)  each individual factor does not have a common integer factor...  ie...  3x+9 is not permitted

2)  the coefficients in each individual factor has an integer between (-9 and 9) without the possibility of zero...  ie x + 0 and 0*x +3 are not permitted

3) each seperate factor is prime to one-another.  ie.  factor1=3x+4  and factor2=-3x-4 is not permitted.

I was hoping to use something short and sweet, using a sequence (if possible), but continue to run into problems.

Any help out there would be fantastic

Thanks,

Mark

## prime notation setup changed in Maple 2017...

Not sure if this is documented explicitly to Maple users, but normally (prior to Maple 2017) interface(typesetting=extended) was all that was required to output display diff(y(x),x) as y'(x)

With Maple 2017 typesetting=extended is default and one must use with(Typesetting)  Settings(typesetprime=true) in order to output the display of diff(y(x),x) as y'(x).

Perhaps this is well documented somewhere, however I was unable to find the change.

## make latex() generate y'(x) for diff(y(x),x) ?...

I know the latex() command in Maple have many issues and I have no hope of what I will ask having a solution, but thought to ask any way.

Is there a way to make maple generate the latex for all the derivatives to use ' instead of d/dx ?

for example, given this

ode:=diff(y(x),x)=x;
latex(ode,output=string);


The Latex generated (which is correct) is

{\frac {\rm d}{{\rm d}x}}y \left( x \right) =x

but sometines I find it more readable if the latex was

y'(x)=x

which is more common in textbooks and other places. The problem also is that I am using worksheet so can't use  y'(x) as input.

But even switching to document mode, and writing it 2D math as input, the Latex output still does not match the input

So if there is a solution to this, would it require changing the latex() command itself? or can it be done at user level?

I'd like all orders of derivatives anywhere in the equation to come out as y'' etc.. so diff(y(x),x\$3) should generate the latex y'''(x) and so on.

Is there a trick to do this?

Maple 2017.2

## Prime number subset code using set and list conversion...

by: Maple

hello i was just looking back on some stuff i did a few months back and although im aware there is a function for generating the prime subset up to a given number already featured in a package in mape im just curious to know how this one measures up in terms of computational efficiency etc.

anyway, this is code, if anyone has the time to give it a try and let me know what they think ie faster more logical way about it any feed back is appreciated cheers.

restart;
interface(showassumed = 0, rtablesize = infinity);
with(plots); with(numtheory); with(Statistics); with(LinearAlgebra); with(RandomTools); with(codegen, makeproc); with(combinat); with(Maplets[Elements]);
unprotect(real, rational, integer, complex);
alias(P[In] = CurveFitting[PolynomialInterpolation]); alias(L[In] = CurveFitting[LeastSquares]); alias(R[In] = CurveFitting[RationalInterpolation]); alias(S[In] = CurveFitting[Spline]); alias(B[In] = CurveFitting[BSplineCurve]); alias(L[In] = CurveFitting[ThieleInterpolation], rho = frac); alias(&Nscr; = Count); alias(&Dopf; = numtheory:-divisors); alias(sigma = numtheory:-sigma); alias(&Fscr; = ListTools['Flatten']); alias(&Sopf; = seq);
delta := proc (x, y) options operator, arrow; piecewise(x = y, 1, x <> y, 0) end proc;
&Mopf; := proc (X, Y) options operator, arrow; map(X, Y) end proc;
&Cscr;[S, L] := proc (X) options operator, arrow; convert(X, 'list') end proc;
&Cscr;[L, S] := proc (X) options operator, arrow; convert(X, 'set') end proc;
&Popf; := proc (N) options operator, arrow; minus({&Sopf;(k*delta(&Nscr;(&Fscr;(&Cscr;[S, L](&Mopf;(&Cscr;[S, L], &Mopf;(&Dopf;, &Dopf;(k)))))), 3), k = 1 .. N)}, {0}) end proc;
N -> minus({(k delta(&Nscr;(&Fscr;(&Cscr;[S, L]((&Cscr;[S, L])

&Mopf; (&Dopf; &Mopf; (&Dopf;(k)))))), 3)) &Sopf; (k = 1 .. N)},

{0})
n[P] := proc (N) options operator, arrow; &Nscr;(&Cscr;[S, L](&Popf;(N)))-1 end proc;

Maple Worksheet - Error

Failed to load the worksheet /maplenet/convert/prime_subset_up_to_N.mw .

## Loop for composites...

I have a homework ask you to find the first string of (at least)10, 50, 100 consecutive composites. I have no idea how to use maple. HELP

all i can think of is

>ithprime(i+1) - ithprime(i) = 10

>print(i+1, i)

and combine it with some loop

i dont know how to set up a loop

need a lot of help

## Strong Primality Test in Maple?...

Maple's isprime is not a definitive primality test. The input has to pass a "strong pseudo-primality test" and "one Lucas test". This is well documented. I thought I remembered that there is also a way to get Maple to perform a true primality test, but I don't remember how and don't see anything about this in the Maple help system.

Is my memory faulty, or is there no definitive primality test in Maple?

Doug

---------------------------------------------------------------------
Math, USC, Columbia, SC 29208  E-mail: mailto:meade@math.sc.edu
Phone:  (803) 777-6183         URL:    http://www.math.sc.edu


## Making a plot for CPUtime of algorithms...

Dear mapleprimes users,

I have a problem with this function:

B is the length of my array

A := Array(1..B,0);

for i from 1 to B do
p = nextprime(i)

a = primroot(p)

A[i] := A[i] + convert((Usage(mlog(b,a,p,method=indcalc), output=[cputime,output],quiet)[1],decimal,15))
end do;

A;

My idea is to create an array A with all the CPUtimes from the 1st prime til the Bth prime, and then plot it.

But my problem is that I get an error; Illegal use of an object as a name.

I dont know what to do could you help me?

Thanks!

## is it possible to find back the ideal which given ...

if given a prime ideal p, is it possible to find back possible ideal A which output this prime ideal

such that p*A = 0

## Number Theory-FactorSet...

Nm= p1. p2 ...pm + 1, for m more than or equals 1.

So N1 = p1 + 1 = 2 + 1 = 3, N2 = p1 p2 + 1 = 2  3 + 1 = 7, etc.

We prove that Nm is not divisible by any of p1, p2, . . . , pm, so that Nm is either a prime or it is divisible by a prime larger than pm.

(c) Use Maple to find out which of these numbers Nm, for m = 1, 2, . . . , 15, is actually prime.

Use Maple to compare pm with the smallest prime number that divides Nm, for m =1, 2, . . . , 15.

## Extremely annoying problem...

Ive written this program:

It determines the power of the Ithfactor, only one problem. When I try to compute the factor of 512 I get 2_2 (subscript) which is extremly stupid. I want to know how I can change my program so that it can give the power of every ith factor. Thanks!

## Weird problem with largest prime factorisation fun...

Hi,

I`m using this program to find the largest prime factor:

Problem: If I insert largest_prime(p^n), where p is prime, it returns n. Which I dont want! I want p to be returned.

## What is the command to get a sequence of the first...

What is the command to get a sequence of the first twenty prime numbers

## Warning, expecting Range variable k blablabla... w...

I dont know what to do any further...

I have some function containing HeunG as a function

it is of the following form

f(k)=argument(functions containing HeunG) - ln(2)*k

now plotting this works...

But when differentiating with respect to k and then plotting it gives me the following message:

Warning, expecting only range variable k in expression (I*((1/2)^(1/2*I*k))^2*HeunG(3,-9/2+3/4*I*k-3/4*k^2,-1+1/2*I*k,-1/2+1/2*I*k,1/2,1+I*k,1/2...

## Maple 13 student crashes after 18 hour calculation...

Hi,

I have enjoyed Maple computer algebra system as a platform for some work on prime constellations.  A summary of my work is here -