Kitonum

21530 Reputation

26 Badges

17 years, 91 days

MaplePrimes Activity


These are replies submitted by Kitonum

@Chouette  Use  rationalize(simplify(...))  for algebraic numbers:

Sol1 := {solve( R^2-sqrt(2)*R-1 )};
Sol2 := {solve( (sqrt(3)+1)*R^2 = sqrt(3)-1 )};
rationalize(simplify(Sol1));
rationalize(simplify(Sol2));

 

@JSalisbury  Should be  Point[i] := ...

@vv  I did not understand why it happened. Now I did  restart;  and got the same result as sand's one:

`-`(a, b);
                           a - b

@sand15  In Maple 2018.3 (worksheet mode, Standard GUI)  I get  that  Matrix(3, 3, `.`) = Matrix(3, 3, `*`)

Matrix(3, 3, `.`);
Matrix(3, 3, `*`);

                            

 

 

@Teep  You can do this automatically as follows

MaplePrimes_network_labels_new.mw

@Teep   See help on the  GraphTheory:-RelabelVertices  command.

@radaar  Unfortunately, I am not familiar with books on Maple in English. Maybe someone else will give such advice. I have long been using only the Maple help system if I forgot something. For example, in the aswer to your initial question, I simply opened the help for  Student:-MultivariateCalculus:-ApproximateInt  command and found the  partition  option for it.

 

@colin12345678  From your original code it is not clear of which expression the derivative is taken. I suggested that of  k(T)/2/Pi*Int(sin(theta)^2/delta(T)/(1+delta(T)), theta=0..Pi)) . In the code below, the derivative is taken only of  k(T)/2/Pi :


 

restart;
k:=T->2/cosh(2/T)/coth(2/T);
delta:=T->sqrt(1-k(T)^2*sin(theta)^2);
e:=T->-2*tanh(2/T)+D(T->k(T)/2/Pi)(T)*Int(sin(theta)^2/delta(T)/(1+delta(T)), theta=0..Pi);

proc (T) options operator, arrow; 2/(cosh(2/T)*coth(2/T)) end proc

 

proc (T) options operator, arrow; sqrt(1-k(T)^2*sin(theta)^2) end proc

 

proc (T) options operator, arrow; -2*tanh(2/T)+(D(proc (T) options operator, arrow; (1/2)*k(T)/Pi end proc))(T)*(Int(sin(theta)^2/(delta(T)*(1+delta(T))), theta = 0 .. Pi)) end proc

(1)

evalf(e(1));

-1.793211145

(2)

evalf(e(4));

-.9522166642

(3)

 


And the last option corresponds to the code in your last comment. Here, the derivative is taken only from the integral:


 

restart;
b:=T->1/T;
k:=T->2/cosh(2*b(T))/coth(2*b(T));
delta:=T->sqrt(1-k(T)^2*sin(theta)^2);
e:=T->-2*tanh(2/T)+k(T)/(2*Pi)*D(T->2/Pi*Int(sin(theta)^2/delta(T)/(1+delta(T)), theta=0..Pi))(T);

proc (T) options operator, arrow; 1/T end proc

 

proc (T) options operator, arrow; 2/(cosh(2*b(T))*coth(2*b(T))) end proc

 

proc (T) options operator, arrow; sqrt(1-k(T)^2*sin(theta)^2) end proc

 

proc (T) options operator, arrow; -2*tanh(2/T)+(1/2)*k(T)*(D(proc (T) options operator, arrow; 2*(Int(sin(theta)^2/(delta(T)*(1+delta(T))), theta = 0 .. Pi))/Pi end proc))(T)/Pi end proc

(1)

evalf(e(1));
evalf(e(4));

-1.895473238

 

-.9574874368

(2)

 


 

Download 1111.mw

Download 111.mw

@David Sycamore  The procedure code needs a minimal change so that it does not check all positive integers  k , but only numbers of the type  k=6*n  (n is positive integer):

Wrapped_prime:=proc(p::prime, N::posint:=5000)
local n, k, m0, m;
n:=length(p);
for k from 6 by 6 to N do
m0:=add(10^i, i=0..k-1);
m:=m0+10^k*p+10^(k+n)*m0;
if isprime(m) then return k fi;
od;
end proc:

Using this procedure, I checked all к (multiples of 6) up to N=10000 . The computer worked for more than an hour, but could not find a prime number.

Wrapped_prime(397, 10000);
 

@mmcdara In original code after  -2*tanh(2/T)  the sign  "+"  stands.

@David Sycamore  You do not need to do anything with the code of this procedure. You just have to copy this code as plain text into your worksheet. Then you press the enter key and after that you can use the procedure as shown in the examples above. You type (or copy) the procedure name and type the desired prime number in parentheses.

@JAMET   I did not understand the meaning of the question.

@Carl Love   for this useful clarification.

@Carl Love  I know. Of course, if for OP is necessary to select the smallest elements, the sum of which does not exceed a bound, then we can use a set. Otherwise, we should use a list.

@Rouben Rostamian   If you take   large enough, (n-5)/6^6  will be greater than 1.

First 34 35 36 37 38 39 40 Last Page 36 of 133