LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Unique random number generation with two input value

Hi,

 

Basically I have two set of integer numbers.

Using these two input integer values I need to generate the unique number.

For example,

Input1, input2

11, 13 =>  1010 (After random generation)

13, 11 => 787 (After random generation)

 

Can someone show me how you can make this happen?

 

Thank you in advance,

 

Do

0 Kudos
Message 1 of 3
(2,174 Views)

Your question doesnt make any sense to me.

 

Unique =/ Random

 

You could simply concatenate the two integers to create unique number but if this formed part of a set then you could have the same "unique" no.

 

A random number is something else.  I'll point you the useful OpenG random number VI (even though there is a random vi native to LV).

 

OpenG_random no vi.png 

 

What is the formulation have you used (would you like to use) to generate 1010 and 787 from Input1 and Input2?  It's not random..

 

You need to explain your application a lot more clearly.

Message Edited by battler. on 05-26-2010 07:50 PM
Message 2 of 3
(2,168 Views)

Sounds like you are looking for a pseudo randum number generator.

 

Clasical theory uses prime numbers, rotational shifts and eXclusive ORs.

 

Do a google (or engine of your choice) search for Cyclic Reduncy or checksum algoritms.

iTm - Senior Systems Engineer
uses: LABVIEW 2012 SP1 x86 on Windows 7 x64. cFP, cRIO, PXI-RT
0 Kudos
Message 3 of 3
(2,155 Views)