Microsimulation API: ssim::RngStream Class Reference

Microsimulation API

Public Member Functions | Static Public Member Functions | Private Member Functions | Private Attributes | Static Private Attributes | List of all members
ssim::RngStream Class Reference

`#include <RngStream.h>`

Inheritance diagram for ssim::RngStream:
[legend]
Collaboration diagram for ssim::RngStream:
[legend]

## Public Member Functions
| RngStream (const char *name="")
void | ResetStartStream ()
void | ResetStartSubstream ()
void | ResetNextSubstream ()
void | SetAntithetic (bool a)
void | IncreasedPrecis (bool incp)
bool | SetSeed (const double seed[6])
void | GenAdvanceState (int32_t e, int32_t c, const double A1[3][3], const double A2[3][3], const double InvA1[3][3], const double InvA2[3][3])
void | AdvanceState (int32_t e, int32_t c)
void | AdvanceSubstream (int32_t e, int32_t c)
void | AdvanceStream (int32_t e, int32_t c)
void | CalcMatrix (int32_t e, int32_t c, double C1[3][3], double C2[3][3])
void | GetState (double seed[6]) const
double | RandU01 ()
int | RandInt (int i, int j)

## Static Public Member Functions
static bool | SetPackageSeed (const double seed[6])

## Private Member Functions
double | U01 ()
double | U01d ()

## Private Attributes
double | Cg [6]
double | Bg [6]
double | Ig [6]
bool | anti
bool | incPrec
std::string | name

## Static Private Attributes
static double | nextSeed [6]

## Detailed Description

Definition at line 30 of file RngStream.h.

## Constructor & Destructor Documentation

## ◆ RngStream()

ssim::RngStream::RngStream | ( | const char * | name = `""` | ) |

Definition at line 337 of file RngStream.cpp.

## Member Function Documentation

## ◆ AdvanceState()

void ssim::RngStream::AdvanceState | ( | int32_t | e,
|  | int32_t | c
| ) |  |

Definition at line 450 of file RngStream.cpp.

## ◆ AdvanceStream()

void ssim::RngStream::AdvanceStream | ( | int32_t | e,
|  | int32_t | c
| ) |  |

Definition at line 460 of file RngStream.cpp.

## ◆ AdvanceSubstream()

void ssim::RngStream::AdvanceSubstream | ( | int32_t | e,
|  | int32_t | c
| ) |  |

Definition at line 454 of file RngStream.cpp.

## ◆ CalcMatrix()

void ssim::RngStream::CalcMatrix | ( | int32_t | e,
|  | int32_t | c,
|  | double | C1[3][3],
|  | double | C2[3][3]
| ) |  |

Definition at line 467 of file RngStream.cpp.

## ◆ GenAdvanceState()

void ssim::RngStream::GenAdvanceState | ( | int32_t | e,
|  | int32_t | c,
|  | const double | A1[3][3],
|  | const double | A2[3][3],
|  | const double | InvA1[3][3],
|  | const double | InvA2[3][3]
| ) |  |

Definition at line 418 of file RngStream.cpp.

## ◆ GetState()

void ssim::RngStream::GetState | ( | double | seed[6] | ) | const

Definition at line 496 of file RngStream.cpp.

## ◆ IncreasedPrecis()

void ssim::RngStream::IncreasedPrecis | ( | bool | incp | ) |

Definition at line 550 of file RngStream.cpp.

## ◆ RandInt()

int ssim::RngStream::RandInt | ( | int | i,
|  | int | j
| ) |  |

Definition at line 578 of file RngStream.cpp.

## ◆ RandU01()

double ssim::RngStream::RandU01 | ( |  | ) |

Definition at line 566 of file RngStream.cpp.

## ◆ ResetNextSubstream()

void ssim::RngStream::ResetNextSubstream | ( |  | ) |

Definition at line 381 of file RngStream.cpp.

## ◆ ResetStartStream()

void ssim::RngStream::ResetStartStream | ( |  | ) |

Definition at line 361 of file RngStream.cpp.

## ◆ ResetStartSubstream()

void ssim::RngStream::ResetStartSubstream | ( |  | ) |

Definition at line 371 of file RngStream.cpp.

## ◆ SetAntithetic()

void ssim::RngStream::SetAntithetic | ( | bool | a | ) |

Definition at line 557 of file RngStream.cpp.

## ◆ SetPackageSeed()

bool ssim::RngStream::SetPackageSeed | ( | const double | seed[6] | ) |
| static

Definition at line 391 of file RngStream.cpp.

## ◆ SetSeed()

bool ssim::RngStream::SetSeed | ( | const double | seed[6] | ) |

Definition at line 402 of file RngStream.cpp.

## ◆ U01()

double ssim::RngStream::U01 | ( |  | ) |
| private

Definition at line 276 of file RngStream.cpp.

## ◆ U01d()

double ssim::RngStream::U01d | ( |  | ) |
| private

Definition at line 305 of file RngStream.cpp.

## Member Data Documentation

## ◆ anti

bool ssim::RngStream::anti
| private

Definition at line 96 of file RngStream.h.

## ◆ Bg

double ssim::RngStream::Bg[6]
| private

Definition at line 93 of file RngStream.h.

## ◆ Cg

double ssim::RngStream::Cg[6]
| private

Definition at line 93 of file RngStream.h.

## ◆ Ig

double ssim::RngStream::Ig[6]
| private

Definition at line 93 of file RngStream.h.

## ◆ incPrec

bool ssim::RngStream::incPrec
| private

Definition at line 96 of file RngStream.h.

## ◆ name

std::string ssim::RngStream::name
| private

Definition at line 99 of file RngStream.h.

## ◆ nextSeed

double ssim::RngStream::nextSeed
| staticprivate

Initial value:
=
{
12345.0, 12345.0, 12345.0, 12345.0, 12345.0, 12345.0
}

Definition at line 102 of file RngStream.h.

The documentation for this class was generated from the following files:

- /home/marcle/src/R/microsimulation/inst/include/RngStream.h
- /home/marcle/src/R/microsimulation/src/RngStream.cpp