freenode/#lisp - IRC Chatlog
Search
7:11:22
Marcy
How can I get slime to load something as soon as it starts? I tried editing my .emacs file and it's not working.
7:30:15
jackdaniel
then you can put anything in ~/.sbclrc (in case of sbcl), or ~/.eclrc (in case of ecl) etc
14:25:59
White_Flame
There's a pretty simple document listing all the prime numbers, but I ran out of harddrive space trying to download it
14:28:05
rtf34
sorry but i just have a problem with my lisp program, it's have to processing about totient phi of euler project
15:00:33
flip214
White_Flame: you should choose some other encoding, the Kolmogorov complexity of prime numbers is quite small.
15:03:27
flip214
White_Flame: no, the gzip format is too limited for that... but there are compression programs that try to build algorithms, perhaps one of these would succeed.
15:04:33
White_Flame
flip214: that would be amazing, because afair there's still no non-search algorithm to generate all the prime numbers, right?
15:05:17
flip214
White_Flame: well, sieve of eratosthenes wouldn't be called searching, would it? they just come out, one after another.
15:06:41
flip214
White_Flame: if you start from 2, no guessing is involved. if you have enough time and storage, that is.
15:07:27
White_Flame
or put differently, a purely mathematical function to compute the next prime given a prior, as opposed to an algorithm
15:09:01
Bike
whether an algorithm to compute the function proceeds by "testing candidates" doesn't matter
15:09:47
White_Flame
as mentioned, we can describe how to find all prime numbers, just not feasible mean
15:12:05
Bike
and i don't know why the time complexity even matters given that you're talking about computing all primes, which would obviously take forever
15:13:09
White_Flame
well, give me an algorithm to compute the Nth prime in constant time, and I'll be happy that primes are "solved" :)
15:13:22
flip214
Bike: well, if computers keep speeding up by some constant factor every year, it won't.
15:16:12
flip214
we wondered why the machines didn't accept the PCI devices, a reboot ago they were still present?
15:20:14
Bike
anyway, AKS is polynomial in number of digits, which is obviously pretty tractable asymptotically. though the useful algorithms are higher O but quicker in practice. but most of the "biggest primes" we fine are mersenne, which we describe by an exponential power, so naturally it's going to get harder and harder quickly
15:21:13
flip214
well, IMO the randomly-generated primes for cryptography are more important than some "size matters" findings
15:22:23
flip214
still, I guess you'd be generating "my" random primes much earlier than your "big" ones, at least when enumerating them ;)
15:26:19
flip214
_death: if we'd only skip the randomness part, and actually start generating them one-by-one, this wouldn't happen!
15:26:50
_death
flip214: sure.. here's a program to generate all primes: (loop for i from 2 do (output i)) ;)
16:17:33
shrdlu68
Are there documentation methods which employ some sort of graph that traces function calls and branches from the entry point to the exit point?
16:22:32
scymtym
UML sequence diagrams are mostly used to specify or document object collaboration. "entry point to exit point" sounds more like things happening within a function for which an UML activity diagram would be more suitable which is not to say that it would be very suitable
16:33:27
pjb
graphviz is perhaps too general. There are web services to draw easily from some textual description UML diagrams, including sequence diagrams.
16:43:19
shrdlu68
I've been testing cl-tls with a modified version of dex, and everything appears to work as it should. I can put the modded dex up somewhere is anyone is interested.
16:54:17
emaczen
In what ways does lisp allow you to control memory consumption? Or is this implementation specific?
16:57:11
White_Flame
there is "consing up memory" which just means allocation, vs reuse of data structures. That's generally the level of control in any GC language
16:57:39
White_Flame
in some implementations, allocating typed arrays can compact them, but they're not required to
17:00:07
emaczen
I have a data-structure which I am converting to a serialized one that I can work with on disk. I keep running out of memory. I'm serializing several of these data structures, I think that my program should finish if it would just garbage collect immediately after every serialization
17:00:25
White_Flame
in general, you can think in count of "slots" if you're going to micro-optimize how large a footprint your data structures are going to hold
17:00:52
White_Flame
you can usually force garbage collection, but the system already is doing that if you're running out
17:02:23
emaczen
White_Flame: I'm not sure why it would hold onto this data structure once it is serialized
17:03:36
White_Flame
are you successfully completing output for some of the structures, and it dies later on, or does it die processing the first one?
17:04:10
emaczen
White_Flame: It successfully completes serialization of at least one of the data structures.
17:05:16
emaczen
I have some unused slots in the data structure because they are utility classes that I use everywhere for convenience. Is there some kind of operator or declaration that will get the compiler to forget about them?
17:07:49
emaczen
What is strange about this problem in general is that it is a prefix-tree, before I was using a hash-table and so the prefix-tree I thought should be more space-efficient since it will re-use prefixes but I can't get it to work out that way...
17:09:19
emaczen
shka: I actually did convert my prefix-tree class of nodes to a pure list representation and it still used more memory than my hash-table
17:10:01
emaczen
shka: The pure list representation used WAY less than my class implementation though
17:11:44
emaczen
There is no doubt I could implement a pure-list implementation, but my hope was that I could just get around that and write some declarations or learn something about memory consumption in general.
17:14:38
emaczen
Bike: The fix would just be creating and merging some classes like "valued-node" and "named-node"
17:15:12
emaczen
It sounds all fine and simple, but I don't feel like breaking it. I think I would rather implement the pure list solution
17:15:42
emaczen
Bike: I'm not so familiar at the moment with that class hierarchy or "valued-node" and "named-node"
18:26:01
alphor
what other capabilities besides conditional evaluation does being a special form provide?
18:35:42
jackdaniel
aeth: your assertion is very harmful, because it is untrue – # is a dispatching macro character - there are #. for evaluation, #- read-time conditional, #o octal etc
18:36:12
aeth
jackdaniel: generally when it's #...(...) the elements inside the list are quoted is probably a better way of phrasing it
18:41:50
jackdaniel
I think the point is that it's not literal either, but rather undefined macro character
18:50:03
shrdlu68
Is it possible to use open with :element-type '(unsigned-byte n) and read only n-bit integers. where n is not a multiple of 8?
18:50:55
_death
shrdlu68: depends on the implementation.. offhand I think on sbcl you can use 16/32/64 as well, but not sure