arand()

P

Pierre McCann

Howdy:

I am working on some code (written by someone else), and this line cropped
up:

newParameters.row = currentParameters.row + (temp *
step.row * arand());

My questions are:
1. What is the arand() function?
2. How is it different from the rand() function?
3. Is there a reference on the web that can be consulted for this
information?
Note on question #3: I'm not just asking without looking. I did have a
quick look around, but no searches on "arand" or "arand()" seemed to give me
what I was looking for.

Thanks in advance for any help.

Regards,

pdm
 
A

Alan Balmer

I am working on some code (written by someone else), and this line cropped
up:

newParameters.row = currentParameters.row + (temp *
step.row * arand());

My questions are:
1. What is the arand() function?

It's not standard C. Try asking on a newsgroup which discusses
whatever platform this came from.
 
I

Irrwahn Grausewitz

Pierre McCann said:
I am working on some code (written by someone else), and this line cropped
up:

newParameters.row = currentParameters.row + (temp *
step.row * arand());

My questions are:
1. What is the arand() function?

It is not a standard C function, and therefore unfortunately off-topic
in c.l.c. Furthermore, I never came across it, AFAICT.
2. How is it different from the rand() function?

It has an 'a' prepended. :) No, seriously: I don't have a clue.
3. Is there a reference on the web that can be consulted for this
information?

If it's part of a known extension library, a Google search should help.
Note on question #3: I'm not just asking without looking. I did have a
quick look around, but no searches on "arand" or "arand()" seemed to give me
what I was looking for.

Well, in that case you should search the code you are working on and the
libraries it uses (read: inspect the header files it includes). If this
doesn't reveal any useful information, asking in a newsgroup dedicated
to your implementation/OS/platform might help.
Thanks in advance for any help.

Sorry for being unable to help any further, good luck to you.

Regards
 
D

Darrell Grainger

Howdy:

I am working on some code (written by someone else), and this line cropped
up:

newParameters.row = currentParameters.row + (temp *
step.row * arand());

My questions are:
1. What is the arand() function?
2. How is it different from the rand() function?
3. Is there a reference on the web that can be consulted for this
information?
Note on question #3: I'm not just asking without looking. I did have a
quick look around, but no searches on "arand" or "arand()" seemed to give me
what I was looking for.

You need to work on your googling skills. Try searching for "random number
generator arand" and see what it get s you. Regardless, it is not part of
the C standard and there appears to be more than one answer.
 
C

CBFalconer

Pierre said:
.... snip ...

My questions are:
1. What is the arand() function?
.... snip ...

It is the rand() function called by a dyslectic Canadian, eh.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,769
Messages
2,569,582
Members
45,057
Latest member
KetoBeezACVGummies

Latest Threads

Top