oggiemc
asked on
Linear feedback shift register
Hi People,
Ive bee given an assignment to check out two simple pseudorandom number generators
and compare them in terms of the statistical properties of their outputs. One of them is a Linear feedback shift register. We've been given the code implemented in C (please see attached file) but im prety new to programming and would greatly appreciate if somone could perhaps explain to me whats going on line per line. I prety much understand the theory behind LFSRs, its the actual implementation that has me confused..
Thanks in advance
LFSR.txt
Ive bee given an assignment to check out two simple pseudorandom number generators
and compare them in terms of the statistical properties of their outputs. One of them is a Linear feedback shift register. We've been given the code implemented in C (please see attached file) but im prety new to programming and would greatly appreciate if somone could perhaps explain to me whats going on line per line. I prety much understand the theory behind LFSRs, its the actual implementation that has me confused..
Thanks in advance
LFSR.txt
ASKER
Many thanks indeed ReedNewman for the quick and detailed response..Ill have a read over this and hopefully it will become clear to me!! One quick question for now though:
Can you explain to me why we use uint32_t / uint16_t types?? Ive read some online material but i dont really understand..Does it mean that the integer returned takes up 32/16 bits of memory??Like the way individual characters take up a byte??
Once again,
Many thanks!!
Can you explain to me why we use uint32_t / uint16_t types?? Ive read some online material but i dont really understand..Does it mean that the integer returned takes up 32/16 bits of memory??Like the way individual characters take up a byte??
Once again,
Many thanks!!
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Open in new window