Drexel dragonThe Math ForumDonate to the Math Forum

Ask Dr. Math - Questions and Answers from our Archives
_____________________________________________
Associated Topics || Dr. Math Home || Search Dr. Math
_____________________________________________

Cost of Phone Call


Date: 02/27/97 at 16:05:31
From: CAI Lab User
Subject: problem

Hi Dr. Math!
 
A direct-dial long distance call between two cities costs $1.04 for 
the first 2 minutes and $0.36 for each additional minutes or fraction
thereof.  Use the greatest integer function to write the cost (C) of a
call in terms of the time (t) (in minutes).

Can you help me?
Thanks!



Date: 03/02/97 at 23:21:08
From: Doctor Luis
Subject: Re: problem

The graph of the function you describe looks like this (notice the
position of the holes - @):

cost($) ^
   ...  |                .
   ...  |              .
   ...  |            .
   2.48 |          @**
   2.12 |        @**
   1.76 |      @**   
   1.40 |    @**    
   1.04 ******
        |      
        |          
      --|-------------------------->
        | 1  2  3  4  5       time (min)
 
This function is really composed of two parts, one in the interval 
from 0 to 2 (I'm assuming you'll be charged for the first two minutes
even if the duration of your call is less), and another for the 
interval containing values greater than 2. 

If you want to write this function as a single equation, you can think 
of it as the sum of a constant term (the 1.04 part) and a step 
function MULTIPLIED by a function (say u(t)) which is 0 when t is less 
than or equal to 2 and is 1 when t is greater than 2. 

In symbols:

  c(t) = (1.04) + s(t)*u(t)

The step function s(t) for this problem can be represented in terms of 
the greatest integer function [x] = max{z|z <= x} by the expression:

  s(t) = -(0.36)*[2-t]

The function u(t) is, by definition:

           0 , if t <= 2
  u(t) = 
           1 , if t > 2

Now, u(t) can be represented by a single expression if we introduce 
the "signum" function sgn x, and the absolute value function abs x, 
which are defined by:

            -1 , if x<0                  x , if x >= 0
  sgn(x) =   0 , if x=0        abs(x) = 
             1 , if x>0                 -x , if x < 0

  (note that sgn x gives us the sign of x, hence the name)

With these functions defined, one can easily prove that u(t) can be 
written as:

  u(t) = (sgn(abs(t-2))+sgn(t-2))/2 

Thus, the single formula expressing the cost of the phone call in 
terms of the time can be represented by:

  c(t) = (1.04)-(0.36)*[2-t]*(sgn(abs(t-2))+sgn(t-2))/2
    
-Doctor Luis,  The Math Forum
 Check out our web site!  http://mathforum.org/dr.math/   
    
Associated Topics:
High School Discrete Mathematics

Search the Dr. Math Library:


Find items containing (put spaces between keywords):
 
Click only once for faster results:

[ Choose "whole words" when searching for a word like age.]

all keywords, in any order at least one, that exact phrase
parts of words whole words

Submit your own question to Dr. Math

[Privacy Policy] [Terms of Use]

_____________________________________
Math Forum Home || Math Library || Quick Reference || Math Forum Search
_____________________________________

Ask Dr. MathTM
© 1994-2013 The Math Forum
http://mathforum.org/dr.math/