Search Engine www.edaboard.com

# Generate Random Numbers

41 Threads found on edaboard.com: Generate Random Numbers

## Generate random numbers between two numbers in ocean script

most random number generators either give a result between 0-1 or give a result that is based on some limit, i.e. random(10) would give a result that is in the range 0-9. If you want 2 significant digits then you can do something like 2.5+random(11)/10 (i.e. 2.5-3.5 inclusive). Though I'm not sure if Ocean script allows for math to be (...)

## How to generate AWGN.??

AWGN - Add White Gausian Noise. to generate white gaussian noise u need function that generates random numbers with gaussian distribution (example randn in matlab) If your enviroment doesnt have gaussian distributed random generator you have to make one using standard random generator ( (...)

## Problems with random number generation

random number system function has a argument called seed. The seed parameter controls the numbers that \$random returns such that different seeds generate different random streams. The seed parameter shall be either a reg, an integer, or a time variable. The seed value should be assigned to this variable (...)

## Weighting a random number in systemverilog

Take a look at you are using systemverilog you should download the free LRM while it's still free. ht

## Generatng random number in Keil C51 Compiler

it's true. from keil documentation The rand function generates a pseudo-random number between 0 and 32767 it's mean every time you restart your program it's generate the same sequence of numbers. You can use srand() function for each value it generate different sequence. Show this link

## generating random bits on verilog

Do a for loop to generate N times 32-bit random numbers, and concatenate it to get your 10000 random bits. And obviously \$random only works in simulation, not in real hardware.

## Random Numbers at particular rate in fix time interval

You could use an LFSR to generate your random numbers. Keep in mind that as usual this is pseudo random, but for an application like this that should be sufficient. All you need t

## 16F877A serial communication

Use Rand() function to generate random numbers convert the value to string and send the string to USART.

## Help!Simulate a uniform quantizer ?

simulate a uniform quantizer that takes as an input a vector of numbers and returns as an output the quantized vector. 1-generate a random input vector of 10000 samples randomly in the range from . 2-Simulate your quantizer three times with number of levels that are equal to 2 , 4 and 8. 3-The m-file output should (...)

## Random number generator

I have a problem with the random number generator function with MPLAB c programming. We use rand() to generate 2 numbers, but the 1st number is generated randomly in odd sequence and the other number is generated randomly in even sequence. The number is from 0-7. This is (...)

## 2D and 3D arrays initialization and working with them

hi i am working on a vhdl project where i need to initialise 2d array which is 10*10 matrix actually of real values can ypu plz tell me how to do it? also i need to generate a 10*10 array of random numbers which are 100 in number.... i thought of 3D arrays but output of lfsr is not being taken due to size mismatch plz respond asap since i (...)

## regarding random number generation in matlab

i wanted to use normrnd(mu,sigma,m,n) in order to generate random numbers from normal distribution with mean mu =0 and some standard deviation say sigma. this sigma will be used to study the effect of Kt/C noise but my matlab doesnt support statistical toolbox. Another possibilty i look is to use randn(m,n) which has mean =0 and standard (...)

## How to modify a 4 bit counter to generate truly random numbers

A counter justs counts, for it to stop at a random number, you have to stop the counter, but randomly. Can you do this without setting or clearing its count?. What you have to do is to generate a random number of pulses in a block that the counter counts. So a revesed biassed diode feeding an opamp (or two) with open loop (...)

## randomly generate node sensor data(matlab)

Hi, thanks for the reply I am using the (rand(1,noNodes)>=0.8) formula that generates 0 and 1 with the prob I have chosen. I want if zero to generate randomly specific abnormal values if 1 random normal values then another case if fire detection happens generate other set of data my prob how to (...)

## How to generate random numbers in "C" with AVR Studio?

uxmanz, If I understood correctly, what you posted don´t work. Note that the built-in uC timer is colcked by same source than core. It is necessary an external assincronous event to feed input of random funcion. I performed something like what you said and generated everytime the same value. +++

## Generation of noise using random numbers

I am generating normally distributed random numbers using Box-Muller Algorithm.Now I want to generate noise using the random numbers obtained from this worry is how do you map noise( something that is measurable in say volts) from the random number generated.

## to generate Captble for encounter by itf files

u can generate Captbl from encounter by using generateCapTbl command in Encounter..

## How to simulate OFDM model in matlab....plz reply

any help so far?:D it is very simple: just *generate random numbers *use one of the digital modulation types (QAM , PSK, .....) *IFFT *parallel to serial *and channel (now do the reverse as a receiver) this is a very basic type :) regards

## non repeated random number generator??

Using \$random() you can do it. But you need to write a small code to it. In the below link Search for "generate random numbers without repetition"

## Needed help (16 bit LEDs on the VHDL)

Hi yurchec, I understand that you want to flash the leds in random manner... However, in vhdl there is no ready-to-use random function that generate random numbers.. You may write a function that functions random alike. Or you can find a library that has random (...)

## PIC generate random number using feedback shift register

I'm interesting in generating some random numbers for one of my projects. I have stumbled across the following code snippet: It appears to use feedback shift registers to generate a pseudo random sequence. Does anyone have any thoughts / comments / better examples? Many thanks in adva

## Random Integer Generator - Simulink

Hi, How do i generate random numbers between given limits in simulink. For ex: between 25 - 30. At every sample time one of the value between 25 to 30 should be given out. (could be25, 26 , 30, 28, 25, 29, etc.,) Thanks, Ashwini

## how to generate random numbers using C-langugae?

OK. Take into account that the above code generates uniformly distributed numbers in the range (14 bits). Regards Z

## \$random & \$urandon - systemVerilong

function int unsigned \$random ; function int unsigned \$urandom ; The seed is an optional argument. Use the same seed to generate the same sequence of random numbers every time. A common practice is to use a plusarg at the command line and read it in the testbench (\$value\$plusargs) and use it as a (...)

## Generating random nos in verilogA for simulation in Finesim

I am currently modeling jitter in verilogA. For this i need to generate random numbers. This model is to be run with finesim as the simulator. Can anyone suggest any way to do this as finesim does not support \$random function unlike spectre?

## How To Generate a Random Process ??

Any one help me how to generate a random Process, with using any MATLAB functions. I want to know that what logic behind it if I want to generate 1000 points random numbers, Pdf is also given with mean and Variance. But question is same How to generate the random (...)

## Simulation with VHDL: How to create stimulus with Jitter?

Hello! I`m need to create clock stimulus with jitter. I think that need to generate random numbers in desired range and add/substract from constant for period. What you think about this? Can anyone share examples of VHDL code? -- Regards, Jack

## help on vhdl (designWorks4) generate 4 random numbers(4bits)

I need some help on a little project, and the objective is to design a sequencial machine simulating a lottery machine or lotto (I don't really know the exact word in english). the point is that I need to generate 4 numbers (4-bits each(hex)) and register them on four 8_digit_segments. I don't really know how can I generate (...)

## random number generator

i want to generate random number from 0,1,2,3.but all this numbers are in binary.that is ,00,01,10,11.i want the vhdl code for this task.pleae help on this.

## What are the functions of PRF64?

Hi guys, Can anybody tell me about PRF64 function. I know that we are using this to generate psuedo random numbers. Please put more information regrding this....... Regards, PPPPPP

## RANDOM PRIME NUMBER GENERATION USING C LANGUAGE

I WANT TO generate randomLY OCCURRING PRIME numbers FOR MY PROJECT WHICH IS BASED ON RSA ALGORITHM. PLZ GIVE ME HINTS OR SOME LINKS ABOUT THE SAME. THANX IN ADVANCE !!!!!!

## How to generate pesudo random sequence other than LFSR?

can anybody plz tell me how to generate pesudo random sequence others then LFSR:?:

## Help me implement RSA encryption algorithm on FPGA

hi guys i am trying to implement RSA encryption algo on FPGA. my idea is to first generate random numbers and then check them for being prime numbers or not... i am using linear feedback shift registers for random number generation. but now i am stuck in primality testing.....can anyone help me on this!!!please

## How to generate pseudo random numbers on 8-bit micor?

I have generated Pseudo Noise using a PIC 12c672 .Basically is having arrays . You can tap the array and exor it with a value. The sequence will repeat atfer some time, but looking it into an spectrum analizer it was enough for my purposes (apply this noise to a laser) .

## How can I generate random numbers using combo/sequential logic?

Some random number generates are sensitive to seed value, but an LFSR repeats the exact same sequence no matter what seed value you use (excluding that one lock-up value). The seed simply changes the sequence starting point. However, an LFSR is still very useful because it is easy to build one with an extremely long sequence. It's true that you

## How to generate random number in C++?

Here is what i use to generate a random numder within a given range #include #include using namespace std; int main(){ int rannum; // define variables bool found = 1; long sec; time( &sec); // use time function to get number of seconds from 1/1/1970 srand((unsigned)s

## Frequency Spectrum in Matlab

1. sin((1:1000)/10) is axample code to generate a fixed frequency wave. 2. First generate random serial numbers, then filter it using the filter desiganted by yoursefl.

## Looking for scrambler algorithm for wireless system

typically, the scrambler is a LFSR, just as what people use to generate pseudo-random numbers. for a specific startand, like 802.11g, you should read the spec.

## Need a good random generator for matlab

Does anybody know where to get a Matlab file that generates very close to independent random samples? If you look at the higher order statistics of rand or randn, they are not as independent as I would like them to be. Any suggestions?

## How to generate random number in PIC?

Hi. Anyone knows how to generate random number in PIC? I am thinking of using timer to increase a counter and from the counter value, I do few operations to scramble up the value in counter. Does it cause the number to be random? Or someone got better ways or ideas to do it? Thanks.

## Pseudo Random Number Generator using 8bit MCU ?

There is a lot of implementation to generate pseudorandom numbers implementin a cellular automata. I want to help you but i donot remmeber how to make it.