Previous Topic: Charging For VM Resources (CMS)

Next Topic: VM Accounting Versus Batch Accounting


Charging for VM Resources (VSE)

This section applies to you if you elect to produce history records formatted for CA JARS RA for z/VSE. If you choose to create records formatted for CMS, see the section entitled Charging for VM Resources (CMS).

The CPURATE statement supplies rates used by this product to calculate dollar charges for resource usage. The rate parameters may be omitted when no data elements involving charges are selected for a given report. The set code on the CPURATE statement, as on all rate and budget control statements, is optional. A blank in position 1 indicates that the statement is used in all reports.

CPU Identification

The CPU Identification code associates each CPURATE statement with the appropriate VM data. When you run the VM Interface translate component, the VM Interface places a CPU Identification Code into its output records according to the User Accounting Table you supply. When CA JARS reads those records as input, the CPU Identification on the CPURATE statement must match the corresponding CPU Identification in the records for the rates to be applied.

If your User Accounting Table defined different CPU ID Codes for different classes of users, you need multiple CPURATE statements to calculate charges for each separate class. If this product reads a record whose CPU ID does not match the CPU ID of any CPURATE statement for a given report, it applies the rates from the first CPURATE statement for the report.

Processor Charge

This is a charge that combines Total CPU Time and Connect Time. The basic formula is:

Processor Charge = Processor Time x Basic Processor Rate

You supply the Basic Processor Rate in the CPURATE statement. The calculation of Processor Time is explained as follows:

Processor Time is calculated from times in a record and rates in a VMRATE statement.

Processor Time Algorithm (VSE):

Processor Time = ( Total CPU Time x Total CPU Time Factor
                              +
                   Connect Time x Connect Time Factor    ) /3600

The two factors are percentages (that is, 100 = 100%). One possible approach for these factors is to set one to 100 and omit the other (they default to 0). For instance, if you want to charge on Total CPU Time only, set the Total CPU Time Factor to 100 and omit the Connect Time Factor. To charge entirely on Connect time, set the Connect Time Factor to 100 and omit the other factor. If you use both factors (at 050 each, for instance) you calculate Processor Time as an average of Total CPU Time and Connect Time.

Often, people think in terms of two rates, a rate per hour they want to charge for Connect Time, and a rate per hour they want to charge for Total CPU Time. As you can see from the above formula, CA JARS does not calculate its charges in exactly that way. With a little arithmetic, though, you can convert your desired rates into factors that produces the total charge you want.

Suppose you want to charge C dollars per hour for Connect Time, and T dollars per hour for Total CPU Time. T of course is a larger rate than C. The simplest approach is to set:

Basic Processor Rate 	=	T    (your rate for Total CPU Time)
Total CPU Time Factor	=	100
Connect Time Factor	=	C/T  (rounded to whole percent)

Let us carry through an example. You want to charge:

$300.00 per hour for Total CPU Time
 $60.00 per hour for Connect Time

A user has accumulated the following figures:

3600 seconds (1 hour) of Connect Time
 900 seconds (15 minutes) of Total CPU Time

The right answer, from the calculation you are used to, is:

Processor Charge = ($60 x 1 hour) + ($300 x .25 hours) = $135.00

Using the formulas suggested, you set:

Basic Processor Rate  = $300.00 (same as your desired CPU Time rate)
Total CPU Time Factor = 100
Connect Time Factor   = 60/300 = 020% (ratio of your two rates)

CA JARS calculates the Processor Charge as:

Processor Time   = ( (100% x 900 sec) + (20% x 3600 sec) ) /3600
                 = ( 900 sec + 720 sec ) /3600
                 = 0.45 hours
Processor Charge = $300.00 x 0.45 = $135.00

There could be some loss of precision if the ratio of your two desired rates does not come out evenly to a whole percent. You can improve the precision with one more adjustment. You can divide the Basic Processor Rate by any number you like, without changing the Processor Charge, if you multiply both the Total CPU Time Factor and the Connect Time Factor by that same number.

For instance, in the previous example, dividing the Basic Processor Rate by 5 gives $60.00 per hour. Multiplying both factors by 5 gives 500% and 100% for the Total CPU Time Factor and the Connect Time Factor. The calculation would then be:

Processor Time    = ( (500% x 900 sec) + (100% x 3600 sec) ) /3600
                  = ( 4500 sec + 3600 sec) /3600
                  = 2.25 hours
Processor Charge  = $60.00 x 2.25 = $135.00

If you can find an adjustment factor that makes the ratio of your two rates come out very close to a whole percent, and does not cause much rounding error when you divide it into your Basic Processor Rate, you can make the calculation almost perfectly match the calculation you are used to.

I/O Charge

CA JARS RA for z/VSE provides two methods to calculate an I/O charge. Differences between VSE and VM accounting data make one of the two techniques inappropriate for VM data. Only the recommended method is described. The other method can still be used, but does not produce meaningful results. To assure that you use the recommended method, leave the Basic I/O Rate field (positions 15-17) blank in your CPURATE statements.

For VM data, the I/O Charge includes one true I/O component and two components that are related to device connect time. I/O Charge is calculated as follows:

I/O Charge = ( Non-spooled I/O Count x Non-spooled I/O Factor
                  +
               Temporary Disk Use x Temporary Disk Factor
                  +
               Tape Connect Time x Tape Connect Factor        ) / 1000

Note the parentheses in the formula: all three terms are divided by 1000. You supply all the factors in your CPURATE statement. The VM Interface places all the data elements into the history records.

You supply all factors as four digit numbers, interpreted as dollars and cents ($99V99). The Non-spooled I/O Factor is the rate you want to charge per 1000 nonspooled SIOs. The Temporary Disk Factor is the rate you want to charge for one cylinder-hour of temporary disk use. The Tape Connect Factor is the rate you want to charge for one hour's use of one tape drive.

Temporary Disk Use is stored in the record in units of one/thousandth of a cylinder hour. For example, one cylinder of temporary disk, held for one hour, produces the number 1,000 in the Temporary Disk Use field. Two cylinders held for three hours would produce 6,000 for Temporary Disk Use.

Tape Connect Time is stored in the record in units of one/thousandth of an hour. For example, one tape drive held for one hour produces the number 1,000 in the Tape Connect Time field. Two tape drives held for three hours each would produce 6,000 for Tape Connect Time.

If temporary disk is allocated on an FBA device, the raw VM account records contain a count of FBA blocks rather than a number of cylinders. The VM Interface converts the FBA block count to an equivalent number of cylinders. It divides the block count by a number that represents the number of blocks in one cylinder. The default value for this number is 1000. You may supply a different number in the FBLK parameter of your VMPARM statement when you run the VM Interface.

Unit Record Charge

The Unit Record Charge gives you the ability to charge for unit record use (reader, punch and printer). The Reader Rate on the CPURATE statement defines the rate you wish to charge per 1000 cards read. The first calculation of U/R Charge is:

U/R Charge = (Cards Read x Reader Rate) / 1000

To include Lines Printed in the U/R Charge, you must supply a FORMRATE statement with a Forms ID of *PR*. If you include a Line/Card Rate in this FORMRATE statement, the U/R Charge is adjusted to:

U/R Charge = U/R Charge
                  +
             (Lines Printed x Line/Card Rate)/1000

To include statements Punched in the U/R Charge, you must supply a FORMRATE statement with a Forms ID of *PU*. If you include a Line/Card Rate in this FORMRATE statement, the U/R Charge is adjusted to:

U/R Charge = U/R Charge
                  +
             (Cards Punched x Line/Card Rate)/1000

By including both *PU* and *PR* FORMRATE statements, you can have both Lines Printed and Cards Punched included in the U/R Charge, along with Cards Read.

The Tape and Disk Allocation Charge fields permit you to charge for tape mounts and disk mounts.

Setup Charge = # of Tape Mounts x Tape Mount Charge
                          +
               # of Disk Mounts x Disk Mount Charge

Total Charge

The Total Charge is defined as:

Total Charge = Processor Charge
                     +
               I/O Charge
                     +
               U/R Charge
                     +
               Setup Charge

Each of the four Charges in the above formula can be adjusted by a percentage from a PRIORITY statement.

If you supply a Minimum Job Charge on the CPURATE statement, and that charge is greater than the Total Charge computed above, the Minimum Job Charge is used as the Total Charge.

If you are using the Project, Product, or Interval Accounting features of the VM Interface, you should probably not supply a Minimum Job Charge. A job means the period of time covered by one raw type 01 VM account record. If no special data collection features are active, that is the entire user session from LOGON to LOGOFF. If the VM Interface is gathering extra information through project, product or interval accounting, there may be many type 01 records created for a single user in a day's work, some representing only a short time interval. A Minimum Job Charge could severely overcharge a user.

If you elect to produce VSE-formatted records from the translation component of the VM Interface, you require a copy of the CA JARS RA for z/VSE product to report on them. There are a two differences in the use of control statements you must take into account.

CPURATE Statement

This statement is input to CA JARS RA for z/VSE, if you choose to use that product as the reporting component for the VM Interface.

To bill for VM data under CA JARS RA for z/VSE, you use the CPURATE statement to define the rate parameters for the billing algorithm. VM data is treated as if it were POWER Data. Therefore, POWER data cannot be processed concurrently with VM data unless the grouping feature is used to select and/or charge CPU ID for at least one type of data.

Position

Field Length

Field Name

Notes

1

1

Set Code

 

2-9

8

Statement Type

CPURATE

10

1

CPU Identification

CPU ID or blank

11-14

4

Basic Processor Rate

9999; dollars per hour

15-17

3

Basic I/O Rate

999; dollars per hour; blanks recommended

18-20
21-23

3
3

Connect Time Factor
Total CPU Time Factor

999; percentage must be blank or numeric


27-29
30-32
33-35
36-38
39-41

3
3
3
3
3
3

Spool Reader I/O Factor
Spool Printer I/O Factor
Spool Punch I/O Factor
Tape I/O Factor
Disk I/O Factor
Other I/O Factor

999; SIO count per second; blanks recommended

42-45

4

Reader Rate

99V99; dollars per 1000 cards

46-49

4

Tape Rate

99V99; dollars per 1000

50-53

4

Temporary-Disk Rate

99V99; dollars per cyl-hour

54-57

4

Non-spooled I/O Rate

99V99; dollars per 1000 I/O

58-61

4

Tape Allocation Charge

99V99; dollars per tape drive

62-65

4

Disk Mount Charge

99V99; dollars per mount

66-69

4

Minimum Session Charge

99V99; dollars

70-80

11

Reserved

Not used

FORMRATE Statement

Place *PR* or *PU* in the Forms ID field. The number you enter in the Line/card Rate field is then your charge per 1000 lines sent to a virtual printer (*PR* Forms ID) or per 1000 virtual cards punched (*PU* Forms ID). You may submit two FORMRATE statements to a single run, one to charge for lines printed, the other to charge for cards punched.

Position

Field Length

Field Name

Notes

1

1

Set Code

Optional

2-9

8

Statement Type

FORMRATE

10

1

CPU Identification

 

11

1

Reserved

Not used

12-15

4

Forms ID

*PR* or *PU*

16-19

4

Setup Charge

99V99; dollars

20-23

4

Line/Card Rate

99V99; dollars per 1000

24-80

57

Reserved

Not used