trirnd Matlab script

SPONSORED LINKS

    Specification

  • Version:
  • File size: 0 KB
  • File name: trirnd.m
  • Last update:
  • Platform: Windows / Linux / Mac OS / BSD / Solaris
  • Language: Matlab
  • Price:Freeware
  • Company: Laurent Cavin (View more)

trirnd script description:




Publisher review:
trirnd generates discrete random numbers from a triangular distribution. randomValue = TRIRND(minVal, topVal, maxVal);The distribution is defined by:
- a minimum and a maximum value
- a "top" value, with the highest probability.
The distribution is defined with zero probability at minVal-1 and maxVal 1, and with highest probability at topVal. Hence every value in the range (including the maximum and minimum values) have a non-zero probability to be included, whatever topValue is.The output is a random integer.randomMatrix = TRIRND(minVal, topVal, maxVal, nrow, ncolumns)returns a (nrow x ncolumns) matrix of random integers.NOTES:
- This is a numeric approximation, so use with care in "serious" statistical applications!
- Two different algorithms are implemented. One is efficient for large number of random points within a small range (maxVal-minVal), while the other is efficient for large range for reasonable number of points. For large ranges, there is a O(n^2) relation with regard to the product of range*number_of_points. When this product reach about a billion, the runtime reach several minutes.
- To inspect the resulting distribution, plot a histogram of the resulting random numbers, e.g. "hist(trirnd(1,87,100,10000,1),100)".
trirnd is a Matlab script for Mathematics scripts design by Laurent Cavin. It runs on following operating system: Windows / Linux / Mac OS / BSD / Solaris.

Operating system:
Windows / Linux / Mac OS / BSD / Solaris

Latest script and internet news

222

222

22

Posted on: 18 Jul 2023 22:27 by A. Brown

111

111

111

Posted on: 18 Jul 2023 22:24 by A. Brown

The permanently active Push system offered by the new Google Chrome 42

The permanently active Push system offered by the new Google Chrome 42

Hacked By !Sc-sT

Posted on: 17 Mar 2015 07:57 by A. Brown

SPREAD THE WORD

User Rating


Rating: 2.2 out of 5
Based on 13 ratings. 13 user reviews.

  • Currently 2.15 out of 5
  • 1
  • 2
  • 3
  • 4
  • 5