Items tagged with integer integer Tagged Items Feed

I have a fairly easy question but I am new to Maple and can't seem to figure it out w/ Maple help or anyone online resources.  The problem is list all pairs of integers between 100 and 110 that are relatively prime.  (I think) I can make it work by doing:

for k from 100 by 1 to 110 do gcd(k, 100), gcd(k, 101) . . . ; end do

but what if the problem had said pairs of integers from 100 to 1000? I don't understand how to iterate this function for more than one variable.  Any help would be appreciated.

AUTHOR: Fereydoon Shekofte v := ImportMatrix("F:\\xyz.txt", source = delimited, delimiter = " ", format = rectangular, datatype = float[4], transpose = false, skiplines = 0) c := ImportMatrix("F:\\face.txt", source = delimited, delimiter = " ", format = rectangular, datatype = integer[4], transpose = false, skiplines = 0) MatrixOptions(mi("format"), 'order = C_order'); mi("format") f := Array(ArrayTools[Reshape](c[1 .. 3864], 1288, 3), order = C_order) plots[pointplot3d](v) p := Array([seq(geom3d[point](p || i, v[i, 1], v[i, 2], v[i, 3]), i = 1 .. 1063)])

I have been working on a problem related to and using the famous Hadamard-Weierstrass Factorization Theorem (HWFT) for representing an entire function, E(z), with pre-defined zeroes, a(n), which go off to infinity. From HWFT one can represent any meromorphic function with pre-defined poles and zeroes as the ratio of two entire functions.

I am not interested in creating an entire function, but a function F(z) analytic on a disk centered at a pre-defined point such that the analytic continuation, A(z), of F(z) equals pre-defined values



I was reading the manual for Maple 13 and playing with some commands.

There is an equation: sin(x)=cos(x) and you can solve it by the solve command.

If you want all solutions, you just put there AllSolutions attribute and you get




I wonder why there is a tilde (~) behind "_Z1", because each integer satisfies

the equation (there is no need for an assumption).


Is it possible to compute possible addition chains for an integer in maple ??

If not, is there ANY software that will do it ??

It looks like, choosing a public key exponent with a smaller addition chain makes  RSA decryption more efficient .. but how to know whether or not your exponent has a small addition chain!

Call me stupid but I still wasn't able to run the simple example in the maple help (see ) regarding calling external, precompiled Code (in my Case: c++).

How can I write a Maple program (using if..else) to find the first positive integer n (between 1 and 355)such that 355 can divide n*m (m is an integer, say 199) ? Thanks for your help. 

I am trying to do the following sum


But I get this error message

"Error, invalid input: numtheory:-bigomega expects its 1st argument, x, to be of type integer, but received j."

I have tried


but this has no effect. I'm a bit puzzled why Bigomega doesn't work in summations as  other Numtheory functions I've used have all worked.

I have an Nx3 Matrix A and each row looks like [integer,integer,*]. Matrix A acts like a function of two variables in the sense that the ordered pairs that you get be selecting the first two entries of each row are all distinct.

I would like a slick way to convert A to a Matrix B for which B[i,j]=* where * is the third entry in the unique row of A that looks like [i,j,*]. We can insert 0 for "blanks."

For example, if


1 3 a
1 4 d
1 1 b



I have a problem in maple with conversion to the binary writing system.  I would like to convert integers into a binary string of fixed length.


So 7 should become [0,0,0,1,1,1] while 22 should become [0,1,0,1,1,0].

Is that possible? (it would save me quite some time).  I know there are methods to do binary conversion in maple but it's not really what I want.


Many thanks!

Is there a way to specify a user-supplied routine when using the define_external command?

Here is a simple Fortran program to show what I want.


This question comes from a math forum, somebody wanted to solve the following system with maple, but he didn't find a way for it:

eqs:={20<=a,a<=60, 20<=b,b<=60, 20<=c,c<=60, 20<=d,d<=60, a+b+c+d=160, 4*a+6*b+8*c+12*d=1200};

where a,b,c,d are integers.

A possible workaround to try each a,b,c,d, numbers in the given ranges to find the solutions, but it would be good from maple to solve it directly.

Can Maple solve these kinds of problems directly?

Hello everybody,


I have a list of 8 integers and I want to extract all the possible sublists of this list.

For example if the list is L:=[1,2,3,4,5,6,7,8] I want to extract





Is there a simple way to do that? Since there are 2^8=256 of such sublists, my idea was to

write a for i  from 1 to 256 and convert i to a binary number on each iteration, e.g, i =123

is the binary number 1111011, which would correspond to sub list


I'm currently doing some proof of concept implementation of what comes closest to be described as "network flow" problem inside Maple. The current applicability is limited to one source and one sink, flows are not interesting, meaning the edge-costs are all equally set to 1. The chosen vector-based representation for a simple network (adjacency matrix)


  S 1 2 E
S 0 1 1 0
1 0 0 0 1
2 0 0 0 1
E 0 0 0 0

is as follows:

MM := [[2], S, [[1, 2], [[], 1], [[], 2]], E]

5 6 7 8 9 10 11 Last Page 7 of 22