Thanks for help

## DBsubject(Trigonometry)

## DBchapter(Trigonometric functions)

## DBsection(Sine & cosine functions - definitions, graphs, & properties)

## Institution(Univeristy of Utah)

## Author(Utah ww group)

## MLT(Amp_per_shift_formula)

## Level(2)

## TitleText1('Precalculus')

## AuthorText1('Ron Larson and Robert Hostetler')

## EditionText1('7')

## Section1('.')

## Problem1('')

## KEYWORDS('algebra')

DOCUMENT(); # This should be the first executable line in the problem.

loadMacros(

"PGstandard.pl", # Standard macros for PG language

"MathObjects.pl",

"PGcourse.pl", # Customization file for the course

"PGchoicemacros.pl",

"PGanswermacros.pl",

"AnswerFormatHelp.pl",

);

TEXT(beginproblem());

Context("Numeric");

Context()->variables->add(t=>'Real');

$showPartialCorrectAnswers = 1;

$a=random(2,1,9); # amplitude

$b=random(100,50,900); # frequency

$c=non_zero_random(-3.13,0.1,3.13); # phase shift

$d=non_zero_random(-9,1,9); # offset

$pi=2.0*acos(0.0);

Context()->texStrings;

BEGIN_TEXT

Knowledge of sinusoidal functions

$BR

Let

\[f(x)=$a \cos(2 \pi $b t + $c) + $d.\]

The amplitude of this function is

\{ ans_rule(12) \},

$BR

its period is

\{ ans_rule(12) \},

$BR

its phase shift is

\{ ans_rule(12) \},

$BR

and its offset is

\{ ans_rule(12) \},

END_TEXT

ANS(num_cmp( $a));

ANS(num_cmp( 1/$b));

ANS(num_cmp( $c));

ANS(num_cmp( $d));

ENDDOCUMENT(); # This should be the last executable line in the problem.