x[0],min=1)
p.add_constraint(x[1],min=1)
print p.show()
print p.solve()
A=p.get_values(x)
print A
On Mon, Jul 6, 2020 at 11:06 PM chandra chowdhury
wrote:
> Hi,
> I am trying to solve MILP using Sage. Problem is if there is no solution
> it gives an error. Instead of an error
Hi,
I am trying to solve MILP using Sage. Problem is if there is no solution
it gives an error. Instead of an error, I want to change constraints
(like if initial max=100 which does not give solution, new max=101 which
may give solution)
and run the solver automatically.
p = MixedIntegerLinearP
I have matrices B and C of size (m,n) over integer with m>n.
I know there is matrix A of size (m,m) such that
AB=C. How to find A efficiently in Sage?
--
You received this message because you are subscribed to the Google Groups
"sage-support" group.
To unsubscribe from this group and stop receiv
Hi,
I have multi variable polynomial over integers say f(x,y,z).
I want to define it over GF(5) efficiently.
For that I am doing this:
R=PolynomialRing(GF(5), 3, 'X')
Z = list(R.gens())
But g=R(f(Z)) is not working.
--
You received this message because you are subscribed to the Google Group
Dear all,
I have written the following code:
K. = FunctionField(GF(2));
R. = K[]
L. = K.extension(y^2 +y+x+1/x)
print L.places(2)
p = L.places(2)[1]
print p
G=p.divisor()
LG=G.basis_function_space()
print LG
Output is as follows:
[Place (x^2 + x + 1, x*y + 1), Place (x^2 + x + 1, x*y +
Hi,
I take two vectors as follows:
R=[(1, 3), (1, 0)]
Then I span it over integers like
R=(ZZ^2).span(R)
It is clear that vector([0,3]) is in R.
I want to find corresponding coordinates i.e,
(1,-1). How can I find this using Sage?
Instead of integers, is it possible to span over the ring
Inte
I have a sequence which I stored in an array.
I want to find the period of the sequence.
But the following code gives error.
S=[1,2,3,1,2,3]
S=Sequence(S)
print S.period()
--
You received this message because you are subscribed to the Google Groups
"sage-support" group.
To unsubscribe from this
How can I pass the value of Python variable to C? I compile
by this:
gcc -I/usr/include/python2.7 ABC.c -lpython2.7 -lm -lutil -lpthread -ldl
#include
#include
#include
#include
#include
int main()
{
PyObject *pValue, *c, *d;
Py_Initialize();
long *b;
printf("1+1:\n");
PyRun_S
I have a ring like this
R1 = IntegerModRing(5)
R=R1.cartesian_product(R1)
How to define variables x,y,z over R?
R2.=R[] is not working.
--
You received this message because you are subscribed to the Google Groups
"sage-support" group.
To unsubscribe from this group and stop receiving emails f
I want to calculate the determinant of a large matrix
with large entries. So it is taking time. In my machine,
I have 32 CPUs. Is it possible in Sage to use all CPUs
parallelly to find the determinant?
--
You received this message because you are subscribed to the Google Groups
"sage-support" gr
Initial version of Sage this worked perfectly
*V=BooleanPolynomialRing(GF(2),49,['x%d'%(i) for i in range(1,49)]+['Z'])*
But now I am getting error. My version is 7.4
Error is as follows:
Traceback (click to the left of this block for traceback)
...
TypeError: 'FiniteField_prime_modn_with_categ
I am trying to find the basis of Riemann Roch space.
But I am getting following error.
1
33
(x, y - 1) + (x, y + 1) + (x - 2, y - 21) + (x - 3, y - 17) + (x - 3, y
+ 17) + (x - 20, y + 18) + (x + 17, y + 4) + (x + 14, y - 9) + (x + 11,
y + 11) + (x + 8, y + 13) + (x + 7, y + 9)
Traceback (click to
Is it possible to factor polynomials completely over modular ring?
Like
x = var('x')
factor(x^5-x, IntegerModRing(25)['x'])
gives
(x-1)*(x+1)*(x^2+1)*x
but the actual factorization is x*(x-1)*(x+1)*(x-7)*(x+7)
--
You received this message because you are subscribed to the Google Groups
"sage
Dear all,
How to find the cardinality of an ideal ?
For example, consider the ideal I generated by over
the ring Z_8[x]/(x^6+3*x^5+1). I want to find the cardinality of I.
--
You received this message because you are subscribed to the Google Groups
"sage-support" group.
To unsubscribe from th
Hi,
when I am running BKZ algorithm for Lattice dimension more than 200
I am getting RuntimeError: Aborted. Entries are 4000 bits integers.
I am using the following code M=M.BKZ(block_size=20,fp="ld" ).
--
You received this message because you are subscribed to the Google Groups
"sage-support"
Hi,
I have sequence like
{57, 44, 40, 57, 50, 53, 17, 24, 20, 3, 8, 51, 62, 56, 2,
..}, where
each value is between 0 to 63. I want to check its randomness. Is there
any function in Sage for this?
--
You received this message because you are subscribed to the Google Groups
"sage
Hi,
I have lattice L generated by row vectors
(1,1,2), (1,2,1) & (4,5,1) over Z_7. It is clear
that (4,5,1)-3*(1,1,2)-(1,2,1)= (0,0,1) over Z_7.
So (0,0,1) is on the Lattice L. Is it possible
to find the shortest vector of L in Sage? Norm is
normal Euclidean norm.
Is there any concept of LLL al
17 matches
Mail list logo