Re: [sage-support] Size reduced of a basis

2021-04-20 Thread Santanu Sarkar
Hi Martin, Thank you so much for your kind help. It works! Kind regards, Santanu On Mon, 22 Mar 2021 at 19:49, 'Martin R. Albrecht' via sage-support < sage-support@googlegroups.com> wrote: > Hi Santanu, > > With very high precision it goes through: > > #+b

Re: [sage-support] Size reduced of a basis

2021-03-19 Thread Santanu Sarkar
", line 379, in fpylll.fplll.lll.LLLReduction.size_reduction fpylll.util.ReductionError: b'success' Kind regards, Santanu On Wed, 17 Mar 2021 at 15:47, 'Martin R. Albrecht' via sage-support < sage-support@googlegroups.com> wrote: > Hi there, > > You can do it by calling down to FPyLLL

[sage-support] Size reduced of a basis

2021-03-16 Thread Santanu Sarkar
Dear all, In Sagemath, is it possible to change a basis of a lattice which is size reduced? That is my interest is only on 1st condition of LLL basis. Kind regards, Santanu -- You received this message because you are subscribed to the Google Groups "sage-support" group. To u

[sage-support] Linear complexity profile of a binary sequence

2020-11-11 Thread Santanu Sarkar
Dear all, I have a binary sequence {0,1,1,1,1,0,0,0,1,1,0,1,0,1,0,0,1,0,1,1,1,0,0,0,1,1,0,1,0,1}. I want to find its Linear complexity profile using SageMath. Any idea? Regards, Santanu -- You received this message because you are subscribed to the Google Groups "sage-support"

[sage-support] Unimodular transformation matrix of LLL algorithm

2020-09-26 Thread Santanu Sarkar
determinant of T becomes 0 i.e., T.det()=0. I want T.det()=1. Best regards, Santanu -- You received this message because you are subscribed to the Google Groups "sage-support" group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-suppor

[sage-support] Reduction over Ideal

2020-08-05 Thread Santanu Sarkar
Dear all, Consider ideal I= over the binary field GF(2). Then (x2).reduce(I) gives x2. I want it to be x0*x1. In fact , I want this kind of reduction always should give quadratic polynomial (I know that this is possible for my problems). -- You received this message because you are subscribed

[sage-support] Installation problem

2020-04-21 Thread Santanu Sarkar
Dear all, I am trying to install Sage 9.0. But I am getting error. I have upgraded from Ubuntu 14.04 to Ubuntu 18.04. I am getting this: (base) santanu@Santanu-Laptop:~/Documents/sage-9.0-Ubuntu_18.04-i686/SageMath$ make ... . make[1]: *** [/home/santanu/Documents/sage-9.0

[sage-support] Problem to install Cryptominisat

2020-04-19 Thread Santanu Sarkar
Hi all, When I am trying to install Cryptominisat, I am getting following error. (base) santanu@Santanu-Laptop:~/Desktop/sage-8.9-Ubuntu_18.04-i686/SageMath$ ./sage -i cryptominisat *** Error building Sage. The following package(s

[sage-support] LLL algorithm in infinity norm

2019-11-01 Thread Santanu Sarkar
Dear all, I want run LLL algorithm in infinity norm (max norm). Is it possible in Sage? My lattice is generated by row vectors of a square matrix. -- You received this message because you are subscribed to the Google Groups "sage-support" group. To unsubscribe from this group and stop receivin

[sage-support] Solve inequality in Sage

2019-10-20 Thread Santanu Sarkar
Hi, I have inequalities like these: 3 x1 + 5 x2 + 2 x3 + 5 x4 + 7 x5 <= 28 2 x1 + 0 x2 + 0 x3 + 8 x4 <= 14 4 x4 + 5 x5 <= 22 3 x2 <= 2 3 x4 >= 1 I want to get a solution. Values of x's are either 0 or 1. -- You received this message because you are subscribed to the Google Groups "sage-

Re: [sage-support] Re: How to find one element of residue field as a vector over base field

2019-05-15 Thread Santanu Sarkar
On Wed, 15 May 2019 at 17:03, Kwankyu wrote: > Hi Chandra, > > What is Place (x^2 + x + 1, x*y + 1)? Is it ideal generated by >> >> (x^2 + x + 1, x*y + 1). >> >> > No. Place (x^2 + x + 1, x*y + 1) is the unique place of the function field > > at which both functions x^2 + x +1, x*y + 1 vanish. >

Re: [sage-support] Function Field

2019-05-13 Thread Santanu Sarkar
me and I obtain > > [Place (1/x, y), Place (1/x, y + 1), Place (x, x*y)] > > Could you describe the SageMath version you are using? > > Vincent > > Le 13/05/2019 à 10:10, Santanu Sarkar a écrit : > > Hi, > >This code works well. > > > > K. = FunctionFie

[sage-support] Function Field

2019-05-13 Thread Santanu Sarkar
Hi, This code works well. K. = FunctionField(GF(2)) R. = K[] f=y^2 + y + 1/x L. = K.extension(f) print L.places(1) But if I take f=y^2 + y + 1/x, it is giving error. -- You received this message because you are subscribed to the Google Groups "sage-support" group. To unsubscribe from this g

Re: [sage-support] Re: How to define variables over integer

2019-05-09 Thread Santanu Sarkar
Dear friends, Thank you so much for your help. It is working now. Regards, Santanu On Thu, 9 May 2019 at 15:19, Simon King wrote: > Hi Santanu, > > Am Mittwoch, 8. Mai 2019 15:15:06 UTC+2 schrieb Santanu: >> >> I know how to define variables over BooleanPolynomialRing.

[sage-support] How to define variables over integer

2019-05-08 Thread Santanu Sarkar
I know how to define variables over BooleanPolynomialRing. This is as follows. n=4 V=BooleanPolynomialRing(n+1,['z%d'%(i) for i in range(n+1)] ) V.inject_variables() Can we define similar code over integers (ZZ) or rationals (QQ)? Also I want to store variables in an array like Z=[z0,z1,z2,z3] bu

Re: [sage-support] Re: How to find solution

2017-10-18 Thread Santanu Sarkar
Dear Simon, Thank you so much. Regards, Santanu On 15 October 2017 at 13:30, Simon King wrote: > On 2017-10-14, Simon King wrote: > > First, define a variable `a`. I don't know if one really needs > > to declare its domain to solve the problem, but when one does, >

[sage-support] How to find solution

2017-10-14 Thread Santanu Sarkar
In Sage, is it possible to find a such that \int_{a}^{\infty} e^(-x^2/2) dx=2^(-20) -- You received this message because you are subscribed to the Google Groups "sage-support" group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-support+unsubscr...@go

Re: [sage-support] Re: Division in non-Integral domain

2017-02-27 Thread Santanu Sarkar
Dear Simon, Thank you very much for your help. Regards, Santanu On 26 February 2017 at 00:03, Simon King wrote: > Hi Santanu, > > I am sorry that your question was unanswered for so long. > > On 2017-02-24, Santanu Sarkar wrote: > > How to check $x+4 \in <1+

[sage-support] Division in non-Integral domain

2017-02-23 Thread Santanu Sarkar
Hi, How to check $x+4 \in <1+x+x^2+2x^3>$ in the ring $\mathbb{Z}_8[x]$, where <1+x+x^2+2x^3> is the ideal generated by 1+x+x^2+2x^3? If yes, how to find $g(x)$ so that $g(x) (1+x+x^2+2x^3)=x+4$? -- You received this message because you are subscribed to the Google Groups "sage-support" group.

Re: [sage-support] Re: Lattice reduction over polynomial lattice

2017-02-23 Thread Santanu Sarkar
Dear all, Thanks a lot for your kind help. On 22 February 2017 at 13:49, Johan S. R. Nielsen wrote: > Indeed, Sage has row_reduced_form for a polynomial matrix. The row reduced > form is sufficient to find a vector in the row space which has minimal > degree. > > The method used to be called

[sage-support] Re: Lattice reduction over polynomial lattice

2017-02-20 Thread Santanu Sarkar
Dear all, I am searching lattice reduction for polynomial matrices in Sage. Kindly help me. T. Mulders and A. Storjohann. On lattice reduction for polynomial matrices. Journal of Symbolic Computation, 35(4):377 – 401, 2003 On 20 February 2017 at 21:19, Santanu Sarkar wrote: > Dear

[sage-support] Lattice reduction over polynomial lattice

2017-02-20 Thread Santanu Sarkar
Dear all, I have polynomial lattice over a finite field. So each component of the vectors v_1, v_2, v_3 are polynomials over a finite field say F_11. Hence v_1=(f_1(x), f_2(x), f_3(x)), v_2=(g_1(x), g_2(x), g_3(x)) and v_3=(h_1(x), h_2(x), h_3(x)). Here norm is the maximum degree of each compo

[sage-support] Sage Crash Report

2017-01-12 Thread Santanu Sarkar
I am getting these. Please help me. santanu@Math-Sans:~/SageMath$ ./sage ┌┐ │ SageMath Version 7.1, Release Date: 2016-03-20 │ │ Type "notebook()" for the browser-based notebook interface.

[sage-support] Save 3D plot

2015-08-29 Thread Santanu Sarkar
How to save 3D plot in eps format? L=line3d([( 3 , 2 , 1 ), ( 4 , 3 , 2 )],color='red') L=list_plot3d([[ 3 , 2 , 1 ], [ 4 , 3 , 2 ]],color='red') -- You received this message because you are subscribed to the Google Groups "sage-support" group. To unsubscribe from this group and stop receiving

[sage-support] Interpolation in Sage

2015-07-22 Thread Santanu Sarkar
Hello, I want to find a polynomial f(x_1,x_2,x_3,x_4) explicitly by interpolation. I know that the degree of f is 2. I have enough data points. How can I do this in Sage? -- You received this message because you are subscribed to the Google Groups "sage-support" group. To unsubscribe from th

[sage-support] Array

2015-02-26 Thread Santanu Sarkar
Dear all, How to define 3D array like in C language double A[10][10][10]; For 1D array I use A=[0]*10 and for 2D array I use matrix A=matrix(RR,10,10, range(10*10)) in Sage Best, Santanu -- You received this message because you are subscribed to the Google Groups "sage-support"

[sage-support] Find real root

2015-01-09 Thread Santanu Sarkar
Dear all, I have one polynomial f_x(y) =y^3 +f_1(x) y^2 +f_2(x) y + f_3(x). Since it is a cubic polynomial, it has atleast one real root. I want to find that real root as a function of x. I know that x \in [a,b]. -- You received this message because you are subscribed to the Google Groups "sa

Re: [sage-support] Re: Coefficient of Boolean Polynomial

2014-11-18 Thread Santanu Sarkar
Thank you so much. On 18 November 2014 00:02, slelievre wrote: > Santanu wrote: > > >> R.=BooleanPolynomialRing(3) >> f=v1*v2+v1*v3+v1 >> print f.coefficient(v1) >> >> I am getting >> >> Traceback (click to the left of

[sage-support] Coefficient of Boolean Polynomial

2014-11-17 Thread Santanu Sarkar
In my Sage code, R.=BooleanPolynomialRing(3) f=v1*v2+v1*v3+v1 print f.coefficient(v1) I am getting Traceback (click to the left of this block for traceback) ... AttributeError: 'sage.rings.polynomial.pbori.BooleanPolynomial' object has no attribute 'coefficient' Answer should be v2+v3+1. I do n

Re: [sage-support] How to handle file in Sage

2014-10-28 Thread Santanu Sarkar
; > > If the file name does not have an extension in that short list, > > 'load' will add the extension .sobj. > > > > Yes, use Python's builtin open command: > > A1 = open("./Documents/program21.txt").read() > > > > > Le lundi

Re: [sage-support] How to handle file in Sage

2014-10-27 Thread Santanu Sarkar
Thanks a lot. But I am getting these errors: A1=load("./Documents/program21.txt") Traceback (most recent call last): File "", line 1, in File "_sage_input_4.py", line 10, in exec compile(u'open("___code___.py","w").write("# -*- coding: utf-8 -*-\\n" + _support_.preparse_worksheet_cell(

[sage-support] How to handle file in Sage

2014-10-19 Thread Santanu Sarkar
I have a text file abc.txt in Desktop where I have written A=[1,2,3,4]. Is it possible to call this array A from Sage notebook? When I write the following in notebook, A1 = load("/Desktop/abc.txt") getting Traceback (most recent call last): File "", line 1, in File "_sage_input_49.py",

Re: [sage-support] Re: How to extract value from array

2014-02-23 Thread Santanu Sarkar
on: which value has x ? > > print x > > returns > t > > Argh...I don't want this, but I want x has the same value than t ? answer: > t has NO value, because t == 1, is not an "assignment" but an "equation" > > x = T[0].right() > > print x

[sage-support] How to extract value from array

2014-02-22 Thread Santanu Sarkar
Following code I want to assign a value. var('a,t,x') T=[t==1, a==2] Now I want to make x=t which is 1 in this case. That is x will be 1. -- You received this message because you are subscribed to the Google Groups "sage-support" group. To unsubscribe from this group and stop receiving email

[sage-support] Error

2014-01-01 Thread Santanu Sarkar
Suddenly I get the following error. sage: notebook() --- UnpicklingError Traceback (most recent call last) in () > 1 notebook() /home/drsantanu/Downloads/sage-5.13-linux-64bit-ubuntu_12.04.3_lt

[sage-support] Integration

2013-12-09 Thread Santanu Sarkar
I want to find the following integration. I=integral_{t=x}^y I_{x<=y}t, where I_{x<=y} is the indicator function whose value is 1 when x<=y, else 0. So, value of I=(y^2-x^2)/2 if x<=y =0 if x>y Does Sage provide this kind of symbolic integration? -- You receiv

[sage-support] Re: Install cryptominisat-2.9.5 in Ubuntu 13.10

2013-11-18 Thread Santanu Sarkar
Installed it. Is there any updated version of cryptominisat-2.9.5? On 18 November 2013 15:48, Santanu Sarkar wrote: > Dear all, > I am trying to install cryptominisat in my Ubuntu 13.10. But I have the > following > error. > > sage: B = BooleanPolynomialRing(10,

[sage-support] Install cryptominisat-2.9.5 in Ubuntu 13.10

2013-11-18 Thread Santanu Sarkar
lve(I.gens()) --- ImportError Traceback (most recent call last) in () > 1 sage.sat.boolean_polynomials.solve(I.gens()) /home/santanu/Downloads/sage-5.12-linux-32bit-ubuntu_13.04-i686-Linux/local/lib/p

Re: [sage-support] Re: Sage Install Matrix Problem

2013-11-14 Thread Santanu Sarkar
Thanks a lot. My version was Ubuntu 12.04. Now I can fix the problem. On 9 October 2013 15:56, Dima Pasechnik wrote: > On 2013-10-09, Santanu Sarkar wrote: > > I have installed sage 5.11 in the following way. > > > > santanu@santanu-Compaq-Presario-C700-Notebook-PC &

[sage-support] Sage Install Matrix Problem

2013-10-09 Thread Santanu Sarkar
I have installed sage 5.11 in the following way. santanu@santanu-Compaq-Presario-C700-Notebook-PC:~/Desktop/sage-5.11-linux-32bit-ubuntu_13.04-i686-Linux$ ./sage notebook() Some functions work perfectly, but when I write M=matrix(ZZ,2,2,[1,2,3,4]) I have the following: Traceback (most

Re: [sage-support] Re: Convolution Polynomial Ring

2013-08-22 Thread Santanu Sarkar
, Stefan van Zwam wrote: > On Thursday, August 22, 2013 4:06:22 PM UTC-4, Santanu wrote: > >> How to define polynomial ring like Z[x]/(x^10-1) & Z_5[x]/(x^10-1) in >> Sage? >> >> > sage: R1. = PolynomialRing(ZZ) > sage: R. = R1.quotient(a^10 - 1) > > sag

[sage-support] Re: Convolution Polynomial Ring

2013-08-22 Thread Santanu Sarkar
How to define polynomial ring like Z[x]/(x^10-1) & Z_5[x]/(x^10-1) in Sage? On 22 August 2013 12:37, Santanu Sarkar wrote: > Dear all, > Is convolution polynomial ring implemented in Sage? > I want to implement NTRU public key cryptosystem. Hence I need > modular inverse

[sage-support] Convolution Polynomial Ring

2013-08-22 Thread Santanu Sarkar
Dear all, Is convolution polynomial ring implemented in Sage? I want to implement NTRU public key cryptosystem. Hence I need modular inverse of a polynomial also in the ring. With regards, Santanu -- You received this message because you are subscribed to the Google Groups "sage-su

Re: [sage-support] Roots af a polynomial

2013-07-18 Thread Santanu Sarkar
Thank you. On 18 July 2013 16:09, William Stein wrote: > On Thu, Jul 18, 2013 at 12:53 PM, Santanu Sarkar > wrote: > > Over integer. > > I did > > R. = QQ[x] > f = x*(x^3+1)*(x-17) > > then looked at f.roots?? which says it uses f.factor. So I looked at &g

Re: [sage-support] Roots af a polynomial

2013-07-18 Thread Santanu Sarkar
Over integer. On 18 July 2013 15:50, William Stein wrote: > On Thu, Jul 18, 2013 at 11:54 AM, Santanu Sarkar > wrote: > > What algorithm is used in Sage to calculate the roots of a polynomial > f(x)? > > Corresponding Sage function is f.roots() > > What is the bas

[sage-support] Roots af a polynomial

2013-07-18 Thread Santanu Sarkar
What algorithm is used in Sage to calculate the roots of a polynomial f(x)? Corresponding Sage function is f.roots() -- You received this message because you are subscribed to the Google Groups "sage-support" group. To unsubscribe from this group and stop receiving emails from it, send an email

[sage-support] Coefficient of Boolean Polynomial

2013-05-27 Thread Santanu Sarkar
Dear all, In the following code, although the coefficient of x0 is 1+x1*x2, it returns 1. from sage.crypto.boolean_function import BooleanFunction R.=BooleanPolynomialRing(6) f=(1+x1*x2)*x0+x4*x5 print f.monomial_coefficient(x0) -- You received this message because you are subscribed to the G

[sage-support] Array in Sage

2013-05-19 Thread Santanu Sarkar
Is the any way to write four dimensional array in Sage like C int M[10][10][10][10]? For two dimensional case I use Matrix. -- You received this message because you are subscribed to the Google Groups "sage-support" group. To unsubscribe from this group and stop receiving emails from it, send a

Re: [sage-support] Conjunctive Normal Form

2013-04-21 Thread Santanu Sarkar
Dear all, Thank you very much for your help. With regards, Santanu On 21 April 2013 07:02, Martin Albrecht wrote: > sage: B. = BooleanPolynomialRing() > sage: f=a+b*c > sage: from sage.sat.converters.polybori import CNFEncoder > sage: from sage.sat.solvers.dimacs import DIMACS &g

[sage-support] Conjunctive Normal Form

2013-04-20 Thread Santanu Sarkar
Dear all, I want to convert the polynomial f into Conjunctive Normal Form (CNF) in Sage. How can I do this? B. = BooleanPolynomialRing() f=a+b*c -- You received this message because you are subscribed to the Google Groups "sage-support" group. To unsubscribe from this group and stop receivin

[sage-support] Boolean Function

2013-04-18 Thread Santanu Sarkar
Dear all, I have a Boolean polynomial f with huge degree & variables. Also it has huge number of monomials. I want to delete all monomials from f with degree greater than 20. For that I have written the following approach. V=BooleanPolynomialRing(4,['r%d'%(i) for i in range(4)]) V.inject_variab

[sage-support] Problem in Sat Solver

2013-04-04 Thread Santanu Sarkar
When I run the following code, I have Traceback (click to the left of this block for traceback) ... AssertionError from sage.crypto.boolean_function import BooleanFunction R.=BooleanPolynomialRing(6) C=[x0, x0 + x1, x1 + x2, x3, x2 + 1, x4 +x5] tt=cputime() I = Ideal(C) import sage.

[sage-support] Re: Arrays of Boolean variables

2013-02-26 Thread Santanu Sarkar
Dear all, Using R.variable(), I can solve the first problem. On 27 February 2013 07:20, Santanu Sarkar wrote: > Dear all, >I need two arrays of Boolean variables. So I have written > > R=BooleanPolynomialRing(2,['x%d'%(i+1) for i in range > (1)]+,['y%

[sage-support] Arrays of Boolean variables

2013-02-26 Thread Santanu Sarkar
Dear all, I need two arrays of Boolean variables. So I have written R=BooleanPolynomialRing(2,['x%d'%(i+1) for i in range (1)]+,['y%d'%(i+1) for i in range (1)] ) R.inject_variables() Now in one array A, I want to store x1,..,x1 and in another array B want to store y1,..y1.

Re: [sage-support] Re: Extract only some elements from a set

2013-02-26 Thread Santanu Sarkar
ot;x0"] or > L[0][x0]. > > Hoping that this will help you. > > Best regards. > Christophe. > > > 2013/2/26 Santanu Sarkar > >> Sorry, I can not understand the approach. >> >> Let I=[{x0:1, x1: 0, y0: 1}]. Suppose I want to find only x0 and x1

Re: [sage-support] Re: Extract only some elements from a set

2013-02-26 Thread Santanu Sarkar
Sorry, I can not understand the approach. Let I=[{x0:1, x1: 0, y0: 1}]. Suppose I want to find only x0 and x1. How is it possible? On 26 February 2013 16:37, akhil wrote: > > > On Tuesday, February 26, 2013 1:40:26 PM UTC+5:30, Santanu wrote: >> >> Dear all, >>

[sage-support] Extract only some elements from a set

2013-02-26 Thread Santanu Sarkar
Dear all, I have a set non linear equations over Boolean variables x_1,..., x_{1}. Sat solver gives I=[{x1: 0, x100: 1, .}]. I am interested to see only the values of x1,.., x100. Will you kindly help me ? -- You received this message because you are subscribed to the Google Groups "

Re: [sage-support] Error when type notebook()

2013-02-19 Thread Santanu Sarkar
> > > > On 19 February 2013 05:16, Santanu Sarkar > wrote: > >> Dear all, >> when I type notebook(), I get the following error. >> Will you kindly help me? >> >> >> sage: notebook() >> >>

[sage-support] Re: Error when type notebook()

2013-02-19 Thread Santanu Sarkar
My version is sage-5.6-linux-32bit-ubuntu_12.04.1_lts-i686-Linux. On 19 February 2013 08:46, Santanu Sarkar wrote: > Dear all, > when I type notebook(), I get the following error. > Will you kindly help me? > > &

[sage-support] Error when type notebook()

2013-02-18 Thread Santanu Sarkar
Dear all, when I type notebook(), I get the following error. Will you kindly help me? sage: notebook() --- EOFError Traceback (most recent call last) /home/a/.sage/ in () /home/a/Downloads

Re: [sage-support] Re: Boolean Variables

2013-02-18 Thread Santanu Sarkar
Thank you very much. On 16 February 2013 21:50, akhil wrote: > > > On Saturday, February 16, 2013 9:38:14 AM UTC+5:30, Santanu wrote: >> >> Dear all, >> I have the following problem. >> >> >> I am working with Boolean variables. So I call the follo

[sage-support] Boolean Variables

2013-02-15 Thread Santanu Sarkar
Dear all, I have the following problem. I am working with Boolean variables. So I call the following. from sage.crypto.boolean_function import BooleanFunction R.=BooleanPolynomialRing(10) Suppose during run time of my code, I get three polynomials x1*x2+x3+x4, x0+x5, x4+x5. Now I want to repl

Re: [sage-support] Solve polynomial over ring

2013-01-30 Thread Santanu Sarkar
Thank you. On 30 January 2013 10:17, Charles Bouillaguet wrote: > On Jan 30, 2013, at 3:20 PM, Santanu Sarkar wrote: > > > > > N=8 > > R.=Integers(N)[] > > f=x^2-1 > > print f.roots() > > > Try : > > sage: print f.roots(multiplicities=False)

[sage-support] Solve polynomial over ring

2013-01-30 Thread Santanu Sarkar
I want to solve a polynomial over ring. However my code does not work. N=8 R.=Integers(N)[] f=x^2-1 print f.roots() In my case, N is always a power of 2. -- You received this message because you are subscribed to the Google Groups "sage-support" group. To unsubscribe from this group and stop

[sage-support] Polynomial Ring

2013-01-23 Thread Santanu Sarkar
I have written following code: R=Integers(30)['X'] f1=X-10 f2=X-30 print f1*f2 This gives X^2-40*X+300 However I want coefficients to be modulo 30 i.e., 40 =10 , 300=0 in R. -- You received this message because you are subscribed to the Google Groups "sage-support" group. To post to this grou

Re: [sage-support] Sat Solver

2012-12-24 Thread Santanu Sarkar
* > * Warning: this is a prerelease version, and it may be unstable. * > ** > ****** > sage: from sage.sat.solvers import SatSolver > sage: > > > On Monday 24 D

[sage-support] Sat Solver

2012-12-23 Thread Santanu Sarkar
Dear all, To solve a SAT problem, when I have written the following, I got error. from sage.structure.sequence import Sequence from sage.rings.infinity import PlusInfinity from sage.sat.solvers import SatSolver from sage.sat.converters import ANF2CNFConverter Traceback (click to the left of

[sage-support] Symbolic Calculation in Sage

2012-12-14 Thread Santanu Sarkar
Is there any function in Sage by which this kind of symbolic calculation is possible? s=0 for i=1 to m if(i>a+t) s=s+2i else s=s+t m,a,t are non negative integers. -- You received this message because you are subscribed to the Google Groups "sage-support"

[sage-support] Groebner Basis over finite field

2012-12-12 Thread Santanu Sarkar
I have a set of non-linear equations over a prime field. I want to solve them using Groebner basis technique. When I want to calculate Groebner basis, I have following error. verbose 0 (3292: multi_polynomial_ideal.py, groebner_basis) Warning: falling back to very slow toy implementation. P1=

Re: [sage-support] Solve system of non linear equations

2012-12-12 Thread Santanu Sarkar
Thank you very much for your help. On 9 December 2012 12:18, Georgi Guninski wrote: > On Sat, Dec 08, 2012 at 11:44:19AM +0530, Santanu Sarkar wrote: > > Dear all, > > I have a system of non linear equations over GF(2). How to solve > > them in Sage? > > >

Re: [sage-support] Re: Solve system of non linear equations

2012-12-08 Thread Santanu Sarkar
sage: AA. = AffineSpace(GF(2),2) > > sage: S = AA.subscheme(x^2+y^2) > > sage: S.point_set().points() > > [(0, 0), (1, 1)] > > > > On Saturday, December 8, 2012 6:14:19 AM UTC, Santanu wrote: > > > I have a system of non linear equations over GF(2). How to solve

[sage-support] Solve system of non linear equations

2012-12-07 Thread Santanu Sarkar
Dear all, I have a system of non linear equations over GF(2). How to solve them in Sage? -- You received this message because you are subscribed to the Google Groups "sage-support" group. To post to this group, send email to sage-support@googlegroups.com. To unsubscribe from this group, send e

[sage-support] Array of Arrays

2012-10-01 Thread Santanu Sarkar
I have written the following: T=[0]*2 S=[] l=2 for i in range(l): T[0]=i T[1]=i+1 print T S.append(T) Now S becomes [[1, 2], [1, 2]] instead of [[0,1],[1,2]]. In my situation, length l of S is not fixed. Is there any method to solve this problem? -- You received this message bec

[sage-support] Matrix

2012-08-06 Thread Santanu Sarkar
When I want to write a matrix, I have the following error. sage: matrix(ZZ,2,2,[1,2,3,4]) --- AttributeErrorTraceback (most recent call last) /home/a/Downloads/sage-4.8-linux-32bit-ubuntu_10.04_lts

[sage-support] Double Integral

2012-05-21 Thread Santanu Sarkar
When I use the following code it returns 0. var('x y') def f1(x,y): if(x+y < 5): return x+y else: return 0 integral(integral(f1(x,y), x, 0,1), y, 0, 1) whereas integral(integral(x+y, x, 0,1), y, 0, 1) returns 1. Can any one point out the reason for this discrepancy

[sage-support] Fastest Lattice Reduction

2012-02-17 Thread Santanu Sarkar
I need to reduce a lattice of dimension 200 with its entries sizes are of size like 3000 bit. I use LLL(algorithm="fpLLL:fast") for faster lattice reduction. But it seems there is a problem in the function. Reduction is very bad. Is there any way to reduce this size of matrix efficiently? -- To

Re: [sage-support] Normal Distribution

2012-02-17 Thread Santanu Sarkar
Thanks for the help. On 17 February 2012 16:00, Vegard Lima wrote: > On Fri, Feb 17, 2012 at 10:52 AM, Santanu Sarkar > wrote: >> How to generate 1000 random integers which follow normal >> distribution with mean 0 and variance 0.1? > > You can do this with numpy: >

[sage-support] Normal Distribution

2012-02-17 Thread Santanu Sarkar
How to generate 1000 random integers which follow normal distribution with mean 0 and variance 0.1? -- To post to this group, send email to sage-support@googlegroups.com To unsubscribe from this group, send email to sage-support+unsubscr...@googlegroups.com For more options, visit this group at

Re: [sage-support]

2012-02-16 Thread Santanu Sarkar
No, that I do not know. I run my code half an hour. But still donot get result. On 16/02/2012, William Stein wrote: > On Thu, Feb 16, 2012 at 9:53 AM, Santanu Sarkar > wrote: >> M2 is a (50, 50) matrix. Its entries are large (2048 bit). >> >> On 16 February 2012 09:

Re: [sage-support]

2012-02-16 Thread Santanu Sarkar
M2 is a (50, 50) matrix. Its entries are large (2048 bit). On 16 February 2012 09:32, William Stein wrote: > On Thu, Feb 16, 2012 at 9:23 AM, Santanu Sarkar > wrote: >> Hi all, >>  I have used the function  E,N1=M2.hermite_form(transformation=True) >> to compute the

[sage-support]

2012-02-16 Thread Santanu Sarkar
Hi all, I have used the function E,N1=M2.hermite_form(transformation=True) to compute the Hermite Normal Form and observed that it is very slow. Is there any better function? -- To post to this group, send email to sage-support@googlegroups.com To unsubscribe from this group, send email to

[sage-support] Area of a plot

2012-02-12 Thread Santanu Sarkar
Daer all, Is there any function in Sage by which we can calculate the area of a plot? Actually I have many intersecting circles. I want to find the area covered by them. Note that here total area is not sum of area of each circle. -- To post to this group, send email to sage-support@googlegroups

Re: [sage-support] Order of a cyclic group

2012-01-21 Thread Santanu Sarkar
Thanks for the help. On 21 January 2012 07:27, Maarten Derickx wrote: > Well the way I first tried is as follows: > > age: F.=GF(2)[] > sage: G.=F.quotient(x^6 + x^4 + x^2 + x + 1) > sage: a.multiplicative_order() > --- > Not

Re: [sage-support] Period of a sequence

2012-01-20 Thread Santanu Sarkar
Thank you very much. On 20 January 2012 20:57, David Joyner wrote: > On Fri, Jan 20, 2012 at 9:56 AM, Santanu Sarkar > wrote: >> I have a sequence of 0 and 1. I know that period is small. Is there >> any function in Sage by which >> I can find the period? Or, can we fin

[sage-support] Period of a sequence

2012-01-20 Thread Santanu Sarkar
I have a sequence of 0 and 1. I know that period is small. Is there any function in Sage by which I can find the period? Or, can we find the period efficiently? For example {0,1,0,1,0,1} has period of length 2. -- To post to this group, send email to sage-support@googlegroups.com To unsubscribe f

Re: [sage-support] Order of a cyclic group

2012-01-20 Thread Santanu Sarkar
Yes, exactly that we mean. On 19 January 2012 20:13, John Cremona wrote: > On 19 January 2012 15:39, Santanu Sarkar wrote: >> Consider a polynomial f(x) over GF(2)[x]. How is it possible >> to find the order of the cyclic group generated by f(x)? > > What do you mean by t

[sage-support] Order of a cyclic group

2012-01-19 Thread Santanu Sarkar
Consider a polynomial f(x) over GF(2)[x]. How is it possible to find the order of the cyclic group generated by f(x)? -- To post to this group, send email to sage-support@googlegroups.com To unsubscribe from this group, send email to sage-support+unsubscr...@googlegroups.com For more options, vi

Re: [sage-support] Factors of an integer

2012-01-17 Thread Santanu Sarkar
Sorry. I get the function. On 17 January 2012 18:58, Santanu Sarkar wrote: > Thanks. But this function gives only prime factors. Is there any > function which gives > all divisor? > > On 17 January 2012 00:39, Renan Birck Pinheiro > wrote: >> >> >> 2012/1

Re: [sage-support] Factors of an integer

2012-01-17 Thread Santanu Sarkar
Thanks. But this function gives only prime factors. Is there any function which gives all divisor? On 17 January 2012 00:39, Renan Birck Pinheiro wrote: > > > 2012/1/16 Santanu Sarkar >> >> Is there any function in Sage by which I can get the >> number of prime facto

[sage-support] Factors of an integer

2012-01-16 Thread Santanu Sarkar
Is there any function in Sage by which I can get the number of prime factors, number of factors of a positive ineger? -- To post to this group, send email to sage-support@googlegroups.com To unsubscribe from this group, send email to sage-support+unsubscr...@googlegroups.com For more options, v

[sage-support] Probability of a Boolean Function

2011-12-15 Thread Santanu Sarkar
I have a Boolean Function f which I know is not balanced. In fact f=0 with probability 1/4. If I use the function f.is_balanced() it tells me that the function is not balanced, which is fine. But is there a function which will tell me the what the probability of a Boolean function being zero is ? I

[sage-support] Re: Boolean function

2011-12-11 Thread Santanu Sarkar
Sorry I meant to write " But it does not work" apologies for the typo On 12 December 2011 07:49, Santanu Sarkar wrote: > I have a set of Boolean functions like > A[0]=x1*x2+x3*x4 > A[1]=x3+x7+x10 > A[2]=x19*x36+x43*x45*x50 > over variables x_1,.. x_50. > But each

[sage-support] Boolean function

2011-12-11 Thread Santanu Sarkar
I have a set of Boolean functions like A[0]=x1*x2+x3*x4 A[1]=x3+x7+x10 A[2]=x19*x36+x43*x45*x50 over variables x_1,.. x_50. But each function contains at most 10 variables. I want to calculate the balancedness of each function. I have done the following: from sage.crypto.boolean_function import B

Re: [sage-support] Dependence set of a symbolic expression

2011-12-03 Thread Santanu Sarkar
Thankx a lot. On 2 December 2011 02:18, Laurent wrote: >> sage: x0,x1,x2,x3,x4,x5,x6,x7,x8,x9 = var('x0,x1,x2,x3,x4,x5,x6,x7,x8,x9') >> sage: S = 1*x1 + 2*x3 + 3*x4 + 4*x5 + 5*x7 + 6*x9 >> sage: S.variables() >> (x1, x3, x4, x5, x7, x9) > > > By the way : > > sage: x=var('x') > sage: S=sin(x)**2+

[sage-support] Dependence set of a symbolic expression

2011-12-01 Thread Santanu Sarkar
Hello, Let S be a symbolic expression of a certain number of variables taken from a particular set of variables. How do I find out the list of the distinct variables that S depends on? Suppose {x0,x1,x2,x3,x4,x5,x6,x7,x8,x9} is a set of unknowns and S = x1 + x3*x4 + x5*x7*x9. I need to find the sub

Re: [sage-support] Chinese Remainder Theorem

2011-09-22 Thread Santanu Sarkar
Thank you. On 23 September 2011 10:38, D. S. McNeil wrote: > On Fri, Sep 23, 2011 at 12:39 AM, Santanu Sarkar > wrote: > > I want to find integer such that > > x= 1 mod 3 > > x=2 mod 5 > > x=3 mod 7 > > like this system of congruences using Chinese

[sage-support] Chinese Remainder Theorem

2011-09-22 Thread Santanu Sarkar
I want to find integer such that x= 1 mod 3 x=2 mod 5 x=3 mod 7 like this system of congruences using Chinese Remainder Theorem. In Sage, crt() function takes only 4 argument. -- To post to this group, send email to sage-support@googlegroups.com To unsubscribe from this group, send email to sa

Re: [sage-support] How to write Sage code to cython code

2011-09-17 Thread Santanu Sarkar
Thank you. Is there any function in Python for inverse modulo of an integer? Corresponding Sage function is A=15.inverse_mod(17). Also is there any function like ''.join(str(i) for i in A) in Python for an array A? On 17 September 2011 19:36, D. S. McNeil wrote: > > It always returns 101, no

Re: [sage-support] How to write Sage code to cython code

2011-09-17 Thread Santanu Sarkar
It always returns 101, not a random prime of 100 bit integer. On 17 September 2011 18:04, Rajeev Singh wrote: > On Sat, Sep 17, 2011 at 5:46 PM, Santanu Sarkar > wrote: > > Hi all, > > > > I want to use cython. > > > > The following code does not work >

[sage-support] How to write Sage code to cython code

2011-09-17 Thread Santanu Sarkar
Hi all, I want to use cython. The following code does not work %cython cdef P P = next_prime(ZZ.random_element(2^(100-1),2^100)) -- To post to this group, send email to sage-support@googlegroups.com To unsubscribe from this group, send email to sage-support+unsubscr...@googlegroups.com For mor

  1   2   3   >