Search found 108 matches

by eds01
Thu Mar 18, 2010 12:11 am UTC
Forum: Mathematics
Topic: Factoring algorithms
Replies: 3
Views: 941

Factoring algorithms

I've been working on project euler problems in Haskell, and have come across one that's giving me problems(mostly finding an a way to do it that's fast). Basically, it requires finding phi(n) (where phi is Euler's Totient Function) for a large number of values up to 40,000,000. From what I can find ...
by eds01
Mon Nov 16, 2009 3:32 pm UTC
Forum: Coding
Topic: Which language?
Replies: 36
Views: 4540

Re: Which language?

I'd suggest working through a text book, TBH. The language for the textbook matters less than it's contents. There are a number of them out there which are freely available. The Structure and Interpretation of Computer Programming is fairly good, although it's very mathy (It was used at MIT for thei...
by eds01
Wed Nov 11, 2009 8:52 pm UTC
Forum: Coding
Topic: Concurrent programming
Replies: 13
Views: 1756

Re: Concurrent programming

Is it Go ? Just guessing based on your description and avatar. Yeah, it's a Go AI. A professor I know wrote a couple of heuristic functions which can do things like calculate influence to rule out stupid moves, but does no reading of a position. They have the advantage of being really fast, but the...
by eds01
Tue Nov 10, 2009 11:32 pm UTC
Forum: Coding
Topic: Concurrent programming
Replies: 13
Views: 1756

Re: Concurrent programming

Is there support for bit vectors or something like that in Haskell? The representation of the board should ideally be small and fast. The game is played on an n-by-n board (generally 19 by 19, although 9 by 9 and 13 by 13 boards are also used), and each intersection can have 3 states: empty, black o...
by eds01
Tue Nov 10, 2009 7:42 pm UTC
Forum: Coding
Topic: Concurrent programming
Replies: 13
Views: 1756

Concurrent programming

So I'm going to be writing a program for an embarrassingly parallel problem. I'd like it to scale linearly with the number of cores, so the program will get much better when we start to get computers with dozens of cores. The one thing is that it should be running tens of thousands of the computatio...
by eds01
Sun Oct 25, 2009 7:09 pm UTC
Forum: Serious Business
Topic: Meat. Eating it. Is it alright to?
Replies: 413
Views: 46523

Re: Meat. Eating it. Is it alright to?

Wait, what? "increased fat levels due to excess carbs"? Vegetarians seem to be, on the population level, thinner and with a lower body fat percentage than omnivores, although cause/effect is hard to get at. I did google and google scholar searches, and while the articles I found were most...
by eds01
Sat Oct 24, 2009 11:08 pm UTC
Forum: Food
Topic: Worst Food Decisions, or WHY DID I EAT THAT URGRGRBLEH
Replies: 79
Views: 16203

Re: Worst Food Decisions, or WHY DID I EAT THAT URGRGRBLEH

Slivovitz.

Worst thing I've ever tried to drink.
by eds01
Fri Oct 23, 2009 10:22 pm UTC
Forum: Food
Topic: Cooking Quinoa Properly
Replies: 12
Views: 3298

Re: Cooking Quinoa Properly

Well, the Quinoa needs to be rinsed at some point to get rid of the bitter flavor. Some Quinoa comes pre-rinsed is all.
by eds01
Sat Oct 10, 2009 3:29 pm UTC
Forum: Serious Business
Topic: Bullfighting, Animal Rights & Eating Meat
Replies: 68
Views: 6914

Re: Bullfighting, Animal Rights & Eating Meat

On the contrary, I think this is related. You're accusing meat-eaters of hypocrisy, while vegetarians are in fact guilty of the same hypocrisy. You said its wrong to kill animals. However, millions of animals are killed every year to produce food for vegetarians. Vegetarians/Vegans that choose that...
by eds01
Mon Oct 05, 2009 9:18 pm UTC
Forum: Coding
Topic: Finding subpatterns of a game board.
Replies: 12
Views: 1142

Re: Finding subpatterns of a game board.

This will be for devloping an AI afaik, I've been asked to write the program, it's done, I want to make it faster. I haven't looked much at Sensei's Library but I'll browse through it more now :) You might also want to think about putting a Joseki library into it. Also, if you're going to turn it i...
by eds01
Mon Oct 05, 2009 12:24 am UTC
Forum: Coding
Topic: Finding subpatterns of a game board.
Replies: 12
Views: 1142

Re: Finding subpatterns of a game board.

Just out of curiosity, what are you going to be doing with these patterns? Are you just doing this for the hack value, to link into a database, for an AI, &c, &c? From what it sounds like, you're searching for shapes in the game. Is this right? Also, are you testing all directions for a give...
by eds01
Sun Oct 04, 2009 5:52 pm UTC
Forum: Coding
Topic: First "actual" java program, and it's... strange.
Replies: 17
Views: 1798

Re: First "actual" java program, and it's... strange.

One of the problems (in my mind) with Java is that it refuses to work unless you explicitly catch or throw exceptions. Sure, I can understand that most of the time you want to catch or throw them, but in some situations, it greatly increases boilerplate: Imagine that there's no sensible way to recov...
by eds01
Sun Oct 04, 2009 12:18 am UTC
Forum: Coding
Topic: Should I learn Python or Scheme first?
Replies: 7
Views: 5711

Re: Should I learn Python or Scheme first?

Well, what do you want to do? Python is a great language for easily being able to do useful stuff. Scheme is a great language for learning computer science. Most textbooks on Scheme will teach you how to go about solving problems. Scheme's syntax is very, very, simple and regular. Everything is in p...
by eds01
Fri Aug 14, 2009 12:21 am UTC
Forum: Individual XKCD Comic Threads
Topic: 0622: "Haiku Proof"
Replies: 126
Views: 42681

Re: "Haiku Proof" discussion

moras make no sense in languages like english so redefine it... Really, since there can only be japanese mora-definition haikus, why wouldn't we redefine it to work with languages we can understand? Of course, the above is still a bad haiku because line 1&2 are more like 12 syllables with a ran...
by eds01
Wed Aug 12, 2009 4:00 pm UTC
Forum: Individual XKCD Comic Threads
Topic: 0622: "Haiku Proof"
Replies: 126
Views: 42681

Re: "Haiku Proof" discussion

A haiku isn't 5-7-5 syllables, but 5-7-5 morae. The form of a haiku doesn't translate into english. For example, a japanese haiku: furu ike ya kawazu tobikomu mizu no oto compare that to: Three things are certain: Death, taxes and lost data. Guess which has occurred. In particular, a mora is at most...
by eds01
Sat Aug 08, 2009 7:36 pm UTC
Forum: Coding
Topic: Is Java worth learning?
Replies: 24
Views: 4655

Re: Is Java worth learning?

I'm somewhat biased, as Java has always been my primary language, but I've always found Java code a lot more clear than a lot of C/C++/Ruby/etc code. Python comes the closest, but I think Java still wins here, typed variables really improve clarity. Its good for prototyping or just jotting ideas do...
by eds01
Sat Aug 08, 2009 5:58 pm UTC
Forum: Coding
Topic: The "IT DOESN'T WORK!" thread
Replies: 1963
Views: 572121

Re: The "IT DOESN'T WORK!" thread

So I'm finally working on my board game AI again (I posted a question here almost a yer ago now ^_^;;;), and I've changed the fundamental representation of the game board. So I'm running into the following problem: *** - (SETF FUNCALL) is only defined for functions of the form #'symbol. ;;; defines...
by eds01
Thu Aug 06, 2009 7:23 am UTC
Forum: Computer Science
Topic: If you could make your own CS curriculum, how would it work?
Replies: 10
Views: 2708

Re: If you could make your own CS curriculum, how would it work?

Java isn't anywhere near a bad language, and you're not fighting it nearly as much as you would with scheme, lisp derivatives are kind of counter intuitive. Ocaml looks interesting, but it completely seems to ignore a lot of memory management and doesn't give you a nice enough grasp on how things l...
by eds01
Mon Aug 03, 2009 2:16 am UTC
Forum: Coding
Topic: The "IT DOESN'T WORK!" thread
Replies: 1963
Views: 572121

Re: The "IT DOESN'T WORK!" thread

fermatTest :: Int -> Int -> Bool fermatTest p a = a**(p-1) `mod` p == 1 fac :: Int -> Int fac n = foldr (*) 1 [1..n] I'm getting some issues with types here. Namely, No instance for (Floating Int) arising from a use of `**' at project3.hs:33:17-24 Can anyone help me understand haskells types as it ...
by eds01
Wed Jul 29, 2009 2:38 am UTC
Forum: Computer Science
Topic: Generating lists of prime numbers
Replies: 8
Views: 3563

Re: Generating lists of prime numbers

Would it be better (i.e. quicker) to simply test if there were any prime factors, instead of generating the full prime factorization? You only need to test up to sqrt (n) that way. Something like: isPrime :: Integer -> Bool isPrime n = noFactorsp n ns where ns = takeWhile (< (truncate (sqrt n))) pri...
by eds01
Wed Jul 29, 2009 12:19 am UTC
Forum: Computer Science
Topic: Generating lists of prime numbers
Replies: 8
Views: 3563

Generating lists of prime numbers

One of the homework assignments in my Programming Language Concepts course is to make a function in Haskell to generate the primes less than n (also about a half dozen other easy things, like taking two lists and computing their union recursively). The teacher sketched out what a factoring function ...
by eds01
Tue Jul 28, 2009 2:45 pm UTC
Forum: Serious Business
Topic: Meat. Eating it. Is it alright to?
Replies: 413
Views: 46523

Re: Meat. Eating it. Is it alright to?

I don't make any moral distinction between an animal or a plant. Animals being in a form that is easier to empathize with doesn't really make any difference to me, I don't see why I'd draw some moral line between ending the life of a Cow, Plant or Bacteria. I'd really only be concerned with ending ...
by eds01
Tue Jul 14, 2009 5:52 pm UTC
Forum: Coding
Topic: The "IT DOESN'T WORK!" thread
Replies: 1963
Views: 572121

Re: The "IT DOESN'T WORK!" thread

So I'm finally working on my board game AI again (I posted a question here almost a yer ago now ^_^;;;), and I've changed the fundamental representation of the game board. So I'm running into the following problem: *** - (SETF FUNCALL) is only defined for functions of the form #'symbol. ;;; defines ...
by eds01
Sun May 10, 2009 7:14 pm UTC
Forum: Serious Business
Topic: Personal Utilitarianism
Replies: 30
Views: 4610

Re: Personal Utilitarianism

The one assumption in this thread is that suicide is negative, which is not necessarily true. Your death can generate utility for people, although usually indirectly. To various degrees of success suicide has been used for political reasons, mostly to protest things. For example, although Gandhi did...
by eds01
Mon Apr 20, 2009 3:17 pm UTC
Forum: Food
Topic: 18-25 yo males, please look here.
Replies: 29
Views: 5329

Re: 18-25 yo males, please look here.

19. Last night, I had some sauted zuchinni, brown rice and soy sauce, and snacked on some cheese before that (the grocery stores close early on sunday, and it's what was in the apartment). Around 5 hours ago, at noon, I had a "proper meal". As for junk food, my roommate made some french fr...
by eds01
Wed Apr 15, 2009 2:41 pm UTC
Forum: Serious Business
Topic: Philosophy of Religion [Philosophy]
Replies: 132
Views: 13193

Re: Aquinas' proofs of God

Does a circular list need to have a final element? No, of course not. It's an infinite chain of things in a finite amount of space. What's to stop the universe from being like a circular list? Assuming this paper here is correct, nothing - http://arxiv.org/abs/astro-ph/9712344 . This answer just pu...
by eds01
Sun Apr 12, 2009 10:59 am UTC
Forum: Serious Business
Topic: Philosophy of Religion [Philosophy]
Replies: 132
Views: 13193

Re: Aquinas' proofs of God

Does a circular list need to have a final element? No, of course not. It's an infinite chain of things in a finite amount of space. What's to stop the universe from being like a circular list? Assuming this paper here is correct, nothing - http://arxiv.org/abs/astro-ph/9712344 . The question of firs...
by eds01
Sat Apr 04, 2009 7:58 am UTC
Forum: Serious Business
Topic: Was the world a better place back then?
Replies: 32
Views: 5227

Re: Was the world a better place back then?

Or to put it another way, until recently there where as many people currently alive as there had died in the entire prior history of mankind. We are still over 40% I believe. http://www.prb.org/Articles/2002/HowManyPeopleHaveEverLivedonEarth.aspx More than that, think about the claim - that in gene...
by eds01
Thu Mar 19, 2009 11:41 pm UTC
Forum: Serious Business
Topic: Existence of the Patriarchy
Replies: 202
Views: 50115

Re: Existence of the Patriarchy

In some countries (i.e. Sweden), paternal leave is mandatory, just like maternity leave. Currently, both parents in Sweden have 16 months of leave to split up among themselves, and the least amount that one parent can take off is 2 months (so the other takes off 14 months). Source: http://en.wikiped...
by eds01
Tue Feb 10, 2009 4:37 pm UTC
Forum: Serious Business
Topic: The value of music
Replies: 67
Views: 8608

Re: The value of music

Anything that produces something that is not readily digitalizable (like artists) will be ok. Probably writers will have it worst - they do not produce anything that cannot be copied flawlessly. Writers do produce something that is not easily digitalizable, at least for now: People just don't like ...
by eds01
Mon Dec 22, 2008 7:37 pm UTC
Forum: Hardware
Topic: suggestions for CPU
Replies: 8
Views: 1270

Re: suggestions for CPU

So the case has space for 2 80mm fans: 1 for the PSU, and one for everything else. How worried should I be about overheating?
by eds01
Sat Dec 13, 2008 5:59 pm UTC
Forum: Hardware
Topic: suggestions for CPU
Replies: 8
Views: 1270

Re: suggestions for CPU

I'm not going to be doing much gaming on the machine - It'll just be a linux box, so I'll only play things like dwarf fortress and nethack. I won't really be doing anything graphics intensive - I've still got my laptop, I can do a little gaming on it if I want.
by eds01
Sat Dec 13, 2008 5:20 am UTC
Forum: Food
Topic: What is your favourite animal to eat?
Replies: 95
Views: 11739

Re: What is your favourite animal to eat?

Duck. I haven't really had all that much meat in the past number of years. I gave up red meat a while ago, and at this point, I'll eat anything if I know it had a good life and a humane death, which kind of restricts me, particularly living in a dorm. I don't eat meat just because it's kosher, free-...
by eds01
Sat Dec 13, 2008 2:41 am UTC
Forum: Hardware
Topic: suggestions for CPU
Replies: 8
Views: 1270

suggestions for CPU

So I'm building a desktop computer, which will act as both a server and a user machine for me (the original impetus for the machine was building a disk server, then I decided that I might as well just make it a general server, and of course I want to use it when I'm in my room). I've got a case from...
by eds01
Mon Dec 08, 2008 9:37 pm UTC
Forum: The Help Desk
Topic: OSX and Java
Replies: 8
Views: 1699

Re: OSX and Java

I hope that bumping this thread and double posting by doing so is acceptable (I didn't see anything against it in this forum's rules, at any rate). anyways, I still have not managed to get this problem fixed, so help in getting it fixed would be much appreciated, especially because I need to run Ecl...
by eds01
Mon Dec 08, 2008 1:34 am UTC
Forum: Serious Business
Topic: Religion
Replies: 2000
Views: 189713

Re: Religion

This is a major error. You won't find this kind of error in the histories of the greeks for instance. Especially not for such an important character. And it would be a particularly major error except, as I just noted, there's a fairly simple and widely accepted explanation. Does it say anywhere in ...
by eds01
Sat Nov 29, 2008 4:40 pm UTC
Forum: Food
Topic: Raw Milk
Replies: 55
Views: 5785

Re: Raw Milk

Cooking the milk yourself might not be that great a solution. It will be safe after that, but it might also lose more taste than store-bought pasteurized milk, so you gain nothing. Milk factories have done a lot of research to find the combination of temperature and heating time that keeps the tast...
by eds01
Sat Nov 22, 2008 3:44 pm UTC
Forum: Coding
Topic: The "IT DOESN'T WORK!" thread
Replies: 1963
Views: 572121

Re: The "IT DOESN'T WORK!" thread

So I'm teaching myself some common lisp (using CLISP, if it makes a difference). Anyways, I'm writing a AI for a game (The game is go and the AI is just a naive monte-carlo method), and I'm holding points on the board in some places in lists of (x,y) pairs. The ability to take list A and list B and ...
by eds01
Mon Nov 17, 2008 9:35 pm UTC
Forum: XKCD Meetups
Topic: Toronto Meet up
Replies: 6
Views: 3599

Re: Toronto Meet up

I'm currently in Rochester (or Buffalo, if school's out) - getting to toronto isn't very difficult, and I've got some family there I can stay at. If I'm not on vacation or studying abroad (which I will be in the spring), I'll be there.
by eds01
Fri Nov 07, 2008 1:34 am UTC
Forum: Food
Topic: Raw Milk
Replies: 55
Views: 5785

Re: Raw Milk

Getting rid of too many bacteria is bad for you - it can help lower your immune system by lack of use (i.e. if you don't use it, you lose it), but there are some genuinely nasty bugs pasteurization can get rid of. Raw milk generally tastes better than pasteurized, because they're 2 general ways to d...

Go to advanced search