Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

1. Class 'lfsr' contains the following properties: a) An unsigned integer called the 'seed': (the seed value will range between 0 to 255) b) A

1. Class 'lfsr' contains the following properties:

a) An unsigned integer called the 'seed': (the seed value will range between 0 to 255)

b) A reciprocal characteristic/feedback polynomial function: (the user will set the characteristic polynomial. Basically, the user will specify the bit-positions which your class will use to generate the random numbers. The bits in the LFSR state that influence the input are called taps. An example of such function is given at page #04)

Add appropriate member-functions such as,

a) Constructor(s)

b) A function to print the seed and generated numbers (both in integer and binary number system).

c) A function (named as random_number_generator) to create 20 consecutive random numbers from the given seed and the characteristic polynomial.

d) Based on the requirements of the class, you might have to convert any given decimal number to a binary number and store it. So, you need to implement a function that converts a given decimal number to a corresponding binary number.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

MySQL/PHP Database Applications

Authors: Brad Bulger, Jay Greenspan, David Wall

2nd Edition

0764549634, 9780764549632

More Books

Students also viewed these Databases questions

Question

Collect a small sample of about

Answered: 1 week ago

Question

13-1 How does building new systems produce organizational change?

Answered: 1 week ago