// create replacement durand that might be replaced later by
// a compiled mechanism (nmodl mod file) for speed
objref seed_vec, output_vec
objref randobj
randobj = new Random()
{randobj.uniform(0, 1)}
if (!serial) {
//	randobj.Isaac64(ranseedbase)
	randobj.MCellRan4(ranseedbase)
}

// arguments are Vector seed, double size_of_return_vector, Vector output
// both the seed and the output are unused for now and only seed has the
// potential to be used since the function is called output=durand(...)

obfunc durand() { // sent a vector whose first element is seed
		// the number of random elements to return
		// in the third argument which was a vector
	objref output_vec
	seed_vec = $o1 // unused for now - could feed into randobj
	vec_size = $2
	output_vec = $o3
	output_vec = new Vector()
	for i=1, vec_size {
		output_vec.append( randobj.repick() )
	}
	return output_vec
}