Is it OK for someone to put answers from stackoverflow into research? For example, if I'm doing research on something and I don't know how to get through a math equation, is it considered acceptable if I ask the question on this website and then put the answer as part of my research and say that it's my own? Otherwise, how should I quote that answer in my research: would I have to quote the person who answered my question or the entire stackoverflow website?
All content on the Stack Exchange network is licensed under the CC:Wiki license, which means you can use it for whatever purpose you want, so long as you provide attribution. That means you must give credit to the original author for his work.
If, however, you are just getting help for a math assignment, then do the actual homework yourself, using hints from the answer provided. This is partly why homework assignments should always be disclosed and the community discouraged from giving you a complete answer; it reduces the possibility of plagiarism, or being accused of someone else doing your work for you.
You can read more about the CC:Wiki license here: http://creativecommons.org/licenses/by-sa/3.0/
You can find out how to properly attribute a Stack Overflow post here: http://blog.stackoverflow.com/2009/06/attribution-required/
You can claim that you found it in your research - you did ask, and someone answered, but it would certainly be considered bad ettiquete to say that that it was yours as such.
Depending on the type of paper that you are writing, there are different ways to attribute the original author.
My suggestion would be to quote the users name, provide a link to the question and throw in a link to stackoverflow itself - having said that, it would also be polite to ask the author of the answer if they mind their answer being used in this way - I don't think many people would object, but it is polite and does cover your bases nicely.
Edit: Harvey has provided a link to the CC license. Guess that puts a nice firm set of conditions on the general gist of my answer.
There are non-written rules that govern the reuse of ideas in academic circles. Individual institutions might have written rules, too, and you should consult these. But even if your institution does not have them in writing, some rules apply universally.
If you can identify the source of an idea, you must acknowledge the source. This is true at every level, whether you're a student or a researcher. You don't need to provide a source for what everybody in your specialty knows — that's called “folklore”. If you found out something purely by yourself, you don't need to say anything in a student paper; but in a research publication, you are supposed to make a bibliographic search, and to try to determine the original source for an idea.
If you found something because someone else wrote it (on Stack Exchange or elsewhere), you must cite them. Depending on how instrumental their help was, it may be appropriate to mention it either in your acknowledgements or in your bibliography. A bibliographic reference is a precise indication — you'd reference a particular answer or a particular thread, by one or more authors. If the help you received is more diffuse, if it got you over the background problems but the breakthrough is yours, you might acknowledge “user X, Y and Z on Math Stack Exchange” (or “the many fine folks who answered my questions of Math Stack Exchange”, if the individual contributions aren't important enough to list).