The NGS (Next Generation Sequencing) involves fragmenting the DNA to be sequenced. This is followed by attachment to beads or flow cells and then a localized PCR is conducted. Modified bases are added and with addition of each base, a detection is made (by fluorescence for instance) for the type of base bonded. After complete sequencing of all the fragments, how are these reads of fragments assembled in the way they were in the original non-fragmented DNA? (in short: How sequence assembly works?)
Assembly and alignment are generally used to refer to two different algorithms that work in two different ways.
Alignment takes your sequence fragments, and compares them to a reference genome, and tells you where that read aligns and how closely it aligns. For a while, popular aligners used Burrows-Wheeler transform algorithms to make special indexed versions of the genome, this made alignment to the index far faster.
Assembly is when you have no reference, and use the overlap of the reads to build large contigs. For a while De Brujin graphs were a popular algorithm for that.