We help IT Professionals succeed at work.
Get Started

solve the problem by using serial code (Normal code c/c++) and by using  parallezim (Open MP C/C++ Library)

mjs2011 asked
Last Modified: 2020-03-13
I need help to on my home work to write code by using open MP  (Parallel Computer ) in C/C++

The genetic code is the set of rules used by living cells to translate information encoded within genetic material (DNA or mRNA sequences of nucleotide triplets, or codons) into proteins. The genetic code is highly similar among all organisms and can be expressed in a simple table with 64 entries.
A three-nucleotide codon in a nucleic acid sequence specifies a single amino acid. The vast majority of genes are encoded with a single scheme often referred to as the genetic code (refer to the codon table).
Attached to this assignment, you will find a text file named “mouse.dat” that contains the complete genome of a mouse. Write a program to read in the DNA sequence from the file, calculate the frequency of each codon in the codon table, and print out the result as a number and a percentage.
(a) Write a serial code for the solution "Normal Code by using C++ Language".
(b) Use OpenMP to perform the calculation in parallel and verify the result. You should provide two versions of your parallel solution (By using OPEN MP C/C++)
i. using loop-level parallelism
ii.using functional decomposition (sections).
(c) For the two parallel versions of your code, calculate the wall clock time using 2, 4, 8, and 16 threads. Compare them with the sequential time. Show your results in a tabulated form for easy comparison. Comment on the results (By using OPEN MP C/C++)
Watch Question
Application Development and Automation Management
This problem has been solved!
Unlock 7 Answers and 41 Comments.
See Answers
Why Experts Exchange?

Experts Exchange always has the answer, or at the least points me in the correct direction! It is like having another employee that is extremely experienced.

Jim Murphy
Programmer at Smart IT Solutions

When asked, what has been your best career decision?

Deciding to stick with EE.

Mohamed Asif
Technical Department Head

Being involved with EE helped me to grow personally and professionally.

Carl Webster
CTP, Sr Infrastructure Consultant

An Experts Exchange subscription includes unlimited access to online courses.

Get Started
Ask ANY Question

Connect with Certified Experts to gain insight and support on specific technology challenges including:

  • Troubleshooting
  • Research
  • Professional Opinions
Did You Know?

We've partnered with two important charities to provide clean water and computer science education to those who need it most. READ MORE