# Should I cite or quote?

I seem to be in a dilemma when it comes to citation and references. I am implementing and improving an algorithm, and therefore I must state the steps of the algorithm. I would also like to use the definitions they used and there is not much room for paraphrasing. If I paraphrase it, it would be weird since the formulation is very specific. This is a general question: when implementing some algorithm in a paper, would I cite the definitions or should I quote?

The standard dichotomy of quoting vs. paraphrasing makes sense for prose (where an idea can be expressed in many ways), but generally not for mathematical equations: F = ma cannot be meaningfully paraphrased. An algorithm straddles the boundary (which is a source of much intellectual property difficulty): in some ways, after all, an algorithm can be thought of as a rather extensive equation.

A prose-style block quote is not appropriate for an equation, and I would argue that it is likewise not appropriate for an equation. What I instead tend to do in this circumstance is say something like, "Here is the definition of Algorithm X, as reproduced from [citation]:" and then state the definition. If I am adjusting notation or making other such presentation changes, then I will replace "reproduced" with "adapted." This gives the citation and makes it clear that you are using somebody else's formulation, without breaking into a prose-style quote (even better is to place it in a figure or table).

The explanation of the algorithm, on the other hand, is prose, and that you should write yourself, paraphrasing and adapting for the context in which you are discussing the algorithm, which is no doubt different than its original presentation.

• Thank you for the answer, the problem with me is the method section, I am trying to define the algorithm as it goes and then I branch into my own optimization. Should I also use the statement "here is the definition of algorithm x...." each time I want to go back to the algorithm. I imagine it will be a hassle to read. Commented Feb 10, 2015 at 6:47
• @Engin007 you only need to explain it once. If the reader forgot, they can always turn back the page. Commented Feb 10, 2015 at 7:43
• @Engin007, go read a bunch of ACM TOMS articles until you find a style you like and replicate it for your paper. Commented Feb 10, 2015 at 13:36
• Thank you @BillBath you have got me on the right path. I am still confused but this is only due to not knowing how to put the formulation together. Commented Feb 10, 2015 at 21:34