update

2 views
Skip to first unread message

Martin Albrecht

unread,
Apr 5, 2013, 2:09:30 PM4/5/13
to lwe-chall...@googlegroups.com
Hi,

I just pushed two changessets, they contain clean ups of the Ring LWE code and
the addition of the matrix_repr() code.

I did not actually add a matrix_repr() function. Instead I added a wrapper
class which turns RingLWE instances into LWE instances. This allows to use it
in functions like samples() transparently.

As far as I can see this needs doing:

- Please read the source code and check it. Is it correct? Is it well
documented?
- Daniel needs to document the Linder Peikert generator
- We have to decide whether to include the uniform secret stuff.
- Write up the report.

I'd also suggest that you take a look at the changesets I checked in because a
fair part of it was me cleaning up stuff that's easily avoidable (missing
documentation and tests)

Cheers,
Martin

--
name: Martin Albrecht
_pgp: http://pgp.mit.edu:11371/pks/lookup?op=get&search=0x8EF0DC99
_otr: 47F43D1A 5D68C36F 468BAEBA 640E8856 D7951CCF
_www: http://martinralbrecht.wordpress.com/
_jab: martinr...@jabber.ccc.de

Daniel Cabarcas

unread,
Apr 8, 2013, 12:53:13 PM4/8/13
to lwe-chall...@googlegroups.com
Hi,

I'm back. I just added some comments to the LindnerPeikert generator and addressed the bug related to the root finding algorithm. Please let me know if there are still questions. I must say that this generator is only my personal interpretation of what the paper says. The paper doesn't provide enough details to be sure of what the authors intended.

I will check the rest of the code this week.

Cheers

Daniel

Martin Albrecht

unread,
Apr 8, 2013, 10:10:33 PM4/8/13
to lwe-chall...@googlegroups.com
Hi Daniel,

I think we can do away with your "ugly way to find a root" by simplifying the
expression slightly. In particular if we take the log2 of both sides first,
things seem to work out:

(c*exp((1-c**2)/2))**(2*n) == 2**-40

log((c*exp((1-c**2)/2))**(2*n))/log(2) == -40

-((c^2 - 1)*n - 2*log(c^n))/log(2) == -40

-((c^2 - 1)*n - 2*n*log(c))/log(2) == -40

Then, find_root seems to find the root with

find_root(-((c^2 - 1)*n - 2*n*log(c))/log(2) == -40, 1, 10)

I've checked this in, can you check?
Reply all
Reply to author
Forward
0 new messages