2021-05-12 23:32:02 +0200 commented question A certain polyhedron-related computation: any way to get it quicker? See https://doc.sagemath.org/html/en/thematic_tutorials/profiling.html and https://doc.sagemath.org/html/en/reference/mi 2021-05-12 23:29:48 +0200 marked best answer solver parameter not available in Mixed Integer Linear Programming I'm getting the following error, while trying to set up IntegralityFocus for Gurobi backend in Sage 9.2: sage: from sage_numerical_backends_gurobi.gurobi_backend import GurobiBackend as mysolver sage: milp = MixedIntegerLinearProgram(solver=mysolver) sage: milp.solver_parameter("IntegralityFocus", 1) --------------------------------------------------------------------------- KeyError Traceback (most recent call last) sage_numerical_backends_gurobi/gurobi_backend.pyx in sage_numerical_backends_gurobi.gurobi_backend.GurobiBackend.solver_parameter() KeyError: 'IntegralityFocus' During handling of the above exception, another exception occurred: ValueError Traceback (most recent call last) in ----> 1 milp.solver_parameter("IntegralityFocus", Integer(1)) /usr/local/SageMath.92/local/lib/python3.8/site-packages/sage/numerical/mip.pyx in sage.numerical.mip.MixedIntegerLinearProgram.solver_parameter (build/cythonized/sage/numerical/mip.c:16597)() 2470 return self._backend.solver_parameter(name) 2471 else: -> 2472 self._backend.solver_parameter(name, value) 2473 2474 cpdef sum(self, L): sage_numerical_backends_gurobi/gurobi_backend.pyx in sage_numerical_backends_gurobi.gurobi_backend.GurobiBackend.solver_parameter() ValueError: This parameter is not available. Enabling it may not be so hard, though.  Ok, it says "Enabling it may not be so hard, though." but HOW? 2021-05-12 23:29:48 +0200 commented answer solver parameter not available in Mixed Integer Linear Programming @Emmanuel Charpentier I submitted a ticket https://trac.sagemath.org/ticket/31782 but nobody seems to care. 2021-05-12 21:41:33 +0200 commented question A certain polyhedron-related computation: any way to get it quicker? Did you profile your code? Which function / block is a bottleneck? 2021-05-12 19:57:05 +0200 commented answer Reduction of the coefficients of a polynomial in sage You may find description of methods available in Sage at https://doc.sagemath.org/html/en/reference/modules/sage/modules 2021-05-11 19:18:27 +0200 commented answer Reduction of the coefficients of a polynomial in sage LLL has polynomial time - see https://en.wikipedia.org/wiki/Lenstra%E2%80%93Lenstra%E2%80%93Lov%C3%A1sz_lattice_basis_re 2021-05-11 17:58:57 +0200 commented answer Reduction of the coefficients of a polynomial in sage It looks like CVP implementation in Sage uses a different approach than SVP (which is based on LLL) and is more time con 2021-05-11 17:55:28 +0200 commented answer Reduction of the coefficients of a polynomial in sage It looks like CVP implementation in Sage uses a different approach than SVP (which is based on LLL) and is more time con 2021-05-11 16:11:38 +0200 commented answer Reduction of the coefficients of a polynomial in sage It looks OK to me. 2021-05-11 01:35:34 +0200 commented answer Reduction of the coefficients of a polynomial in sage In this case you need to take $C \approx \frac{\sqrt{N}}{64(j-1)}$ and use closest_vector(t) instead of shortest_vector( 2021-05-11 01:35:04 +0200 commented answer Reduction of the coefficients of a polynomial in sage In this case you need to take $C \approx \frac{\sqrt{N}}{64(j-1)}$ and use closest_vector(t) instead of shortest_vector( 2021-05-11 00:58:56 +0200 commented answer Reduction of the coefficients of a polynomial in sage In this case you need to take $C \approx \frac{\sqrt{N}}{64(j-1)}$ and use closest_vector(t) instead of shortest_vector( 2021-05-10 01:45:34 +0200 commented question RSA encryption and decryption Can you illustrate this discrepancy with an actual example? 2021-05-10 01:44:43 +0200 answered a question Reduction of the coefficients of a polynomial in sage If we understand "smaller" by absolute value, then the problem can be posed as finding a short vector in the lattice gen 2021-05-06 16:14:10 +0200 commented answer Bivariate Coppersmith method Is depends on the size of RSA modulus. Say, there is negligible chance with a 2048-bit, let along 4096-bit, modulus. 2021-05-06 16:11:09 +0200 commented question Groebner basis step by step At least 3 polynomials can be removed so that the Grobner basis will still remain trivial. 2021-05-05 21:55:42 +0200 commented answer Bivariate Coppersmith method No, as we see that (25*a+11)*(27*b+1) is reducible (product of 2 factors). 2021-05-05 19:58:24 +0200 commented answer Bivariate Coppersmith method I do not follow this question since it's about two polynomials, while Coppersmith method applies to a single polynomial. 2021-05-05 19:26:25 +0200 commented answer Bivariate Coppersmith method Yes, Coppersmith method is applicable to (65-8 * b) * (67-8 * a) -1763 = 0, but not to 64*a^2*b^2-840*a^2*b+2600*a^2-856 2021-05-05 19:26:05 +0200 commented answer Bivariate Coppersmith method Yes, Coppersmith method is applicable to (65-8 * b) * (67-8 * a) -1763 = 0, but not to 64*a^2*b^2-840*a^2*b+2600*a^2-856 2021-05-04 16:41:47 +0200 answered a question Bivariate Coppersmith method I'm not sure what is exactly your concern about the bivariate Coppersmith method -- if it's about the theory, you'd bett 2021-05-04 16:11:49 +0200 commented question RSA encryption and decryption The code works fine for me. What is your concern? 2021-05-04 16:09:58 +0200 answered a question quotient ring in Sage If under Z2 you understand $\mathbb Z/2\mathbb Z$ (or $\mathrm{GF}(2)$), then the even coefficients in the ideal generat 2021-05-03 20:11:50 +0200 answered a question How to find difference table of DES S box in sage math? Try: S.difference_distribution_table().str() 2021-05-02 04:33:11 +0200 commented question Bivariate Coppersmith method Some implementation is available at https://github.com/ubuntor/coppersmith-algorithm 2021-04-30 22:23:39 +0200 received badge ● Nice Answer (source) 2021-04-28 05:51:19 +0200 edited answer How to define function We can create a random function as a substitution table (over arbitrary Cartesian power d of a finite object K, also doi 2021-04-28 04:17:46 +0200 edited answer How to define function We can create a random function as a substitution table (over arbitrary Cartesian power d of a finite object K, also doi 2021-04-28 04:15:53 +0200 edited answer How to define function We can create a random function as a substitution table (over arbitrary Cartesian power d of a finite object K, also doi 2021-04-28 04:12:47 +0200 answered a question How to define function We can a random function as a substitution table (over arbitrary Cartesian power d of a finite object K, also doing some 2021-04-28 00:31:04 +0200 edited answer AttributeError: '...FunctionFieldElement_rational' object has no attribute 'series' Besides the reported problem of series not being defined, there is one more: z is declared in multiple places as var('z' 2021-04-28 00:28:35 +0200 edited answer AttributeError: '...FunctionFieldElement_rational' object has no attribute 'series' Besides the reported problem of series not being defined, there is one more: z is declared in multiple places as var('z' 2021-04-28 00:28:07 +0200 edited answer AttributeError: '...FunctionFieldElement_rational' object has no attribute 'series' Besides the reported problem of series not being defined, there is one more: z is declared in multiple places as var('z' 2021-04-28 00:27:21 +0200 answered a question AttributeError: '...FunctionFieldElement_rational' object has no attribute 'series' Besides the reported problem of series not being defined, there is one more: z is declared in multiple places as var('z' 2021-04-28 00:03:31 +0200 commented question Eliptic Curves - How to check that substract points cross/exceeds the order of curve n? There is no such thing as "negative y1" since the point coordinates are elements of the field $\mathbb F_p$, and as such 2021-04-28 00:03:11 +0200 commented question Eliptic Curves - How to check that substract points cross/exceeds the order of curve n? There is no such thing as "negative y1" since the point coordinates are elements of $F_p$, and as such they do not have 2021-04-26 15:31:58 +0200 received badge ● Nice Answer (source) 2021-04-25 18:30:58 +0200 commented answer factor symbolic expression I'm not sure what problem you are talking about as your code runs without an issue at Sagecell: https://sagecell.sagemat 2021-04-25 17:33:02 +0200 answered a question factor symbolic expression Adding parentheses does the job: EGe0 = (pp*A*qq).collect(p) 2021-04-25 17:27:49 +0200 answered a question how to get value without e? We can control how many decimal digits to print with formatted floating point output - for example, here we get 50 decim 2021-04-24 16:34:57 +0200 commented answer Rounding up to the nearest integer that’s congruent to k mod N The multiples of P, that is $\{O,P,2P,\dots,(n-1)P\}$ forms a cyclic group. Since $n$ is odd, you can also define half_m 2021-04-24 16:34:18 +0200 commented answer Rounding up to the nearest integer that’s congruent to k mod N The multiples of P, that is $\{O,P,2P,\dots,(n-1)P\}$ forms a cyclic group. Since $n$ is odd, you can also define half_m 2021-04-24 16:33:36 +0200 commented answer Rounding up to the nearest integer that’s congruent to k mod N ${O,P,2P,\dots,(n-1)P}$ forms a cyclic group. Since $n$ is odd, you can also define half_mod_n = (n+1) /2, and it is an 2021-04-23 15:58:23 +0200 commented answer Rounding up to the nearest integer that’s congruent to k mod N It's not possible unless you know what multiple of P a given point is, which in general amounts to computing the discret 2021-04-23 03:49:05 +0200 answered a question Rounding up to the nearest integer that’s congruent to k mod N "Rounding" in this case means simply adding P_05 like P_9_half_rounded = P_9_half + P_05 print(P_9_half_rounded == P * 2021-04-22 20:55:10 +0200 received badge ● Good Answer (source) 2021-04-22 17:58:25 +0200 commented question How to combine bin packing with graph theory? This may be better suited for https://math.stackexchange.com/ as your question is not Sage specific. 2021-04-22 06:09:19 +0200 edited answer How to create lists of n-tuples efficiently? Each half of x can be viewed as a subset of size q of the corresponding set: {0,1,...,pq-1} and {pq,pq+1,...,2pq-1}, res 2021-04-22 06:02:31 +0200 answered a question How to create lists of n-tuples efficiently? Each half of x can be viewed as a subset of size q of the corresponding set: {0,1,...,pq-1} and {pq,pq+1,...,2pq-1}, res 2021-04-12 06:42:25 +0200 commented answer list of all prime powers -1 For example: for q in PP: if q>=100: break print(q)