Ch3QA: Chapter 3 Problem and Solution Generation

View source: R/control.R

Ch3QAR Documentation

Chapter 3 Problem and Solution Generation

Description

Randomly generates and typesets problems of 6 specified types from Chapter 3 of ALMCR3e. All problems use the Standard Ultimate Life Table (SULT) a.k.a. Standard Ultimate Survival Model (SUSM). This function generates two PDF files, one listing the problems, and another with the step-by-step solutions.

Usage

Ch3QA(probspertype = 5, probspec = NULL, randomize = FALSE, probsummary = FALSE,
  qfile = "qfilech3", afile = "afilech3", keeptex = FALSE)

Arguments

probspertype

Number of problems of each type to generate. Use this argument (instead of probspec) to generate the same number of problems for each of the 6 types of Chapter 3 SULT problems.

probspec

Vector of length 6 giving the number of each of the 6 types of Chapter 3 SULT problems to generate. Use this argument (instead of probspertype) to generate different numbers of problems for the 6 types of Chapter 3 SULT problems.

randomize

Boolean variable controlling whether the problems will be randomized (TRUE), or appear in problem type order (FALSE).

probsummary

Boolean variable controlling whether a summary of the problem types generated will be placed at the end of the question file.

qfile

Name (and path) to write question PDF file.

afile

Name (and path) to write solution PDF file.

keeptex

Boolean variable controlling whether the .tex files compiled to produce the PDFs are kept (TRUE) or deleted (FALSE) after the PDF is rendered.

Details

Specify the types of problems generated using either the (scalar) probspertype parameter or the (vector) probspec parameter. See package vignette for further information.

Value

Invoked for the side effect of producing the two PDF files.

Author(s)

Chris Groendyke groendyke@rmu.edu

References

Dickson, D.C.M., Hardy, M.R., Waters, H.R., 2020 Actuarial Mathematics for Life Contingent Risks, Third Edition, Cambridge, UK: Cambridge University Press.

See Also

Ch4QA, Ch5QA, and Ch10QA for analogous functions for generating problems and solutions for material in chapters 4, 5 and 10, respectively.

Examples

# Generate 4 problems of each type.
Ch3QA(probspertype = 4)

# Generate 15 problems total (1 of type 1, 4 of type 2, etc.)
Ch3QA(probspec = c(1, 4, 2, 0, 3, 5))

ChrisGroendyke/AutoSULT documentation built on June 12, 2024, 9:28 a.m.