Overview of LCR

The LCR feature enables the device to choose the outbound IP destination routing rule based on lowest call cost. This is useful in that it enables service providers to optimize routing costs for customers. For example, you may wish to define different call costs for local and international calls or different call costs for weekends and weekdays (specifying even the time of call). The device sends the calculated cost of the call to a syslog server (as Information messages), thereby enabling billing by third-party vendors.

LCR is implemented by defining Cost Groups and assigning them to routing rules in the IP-to-IP Routing table (for SBC calls). The device searches the routing table for matching routing rules and then selects the rule with the lowest call cost. If two routing rules have identical costs, the rule appearing higher up in the table is used (i.e., first-matched rule). If the selected route is unavailable, the device selects the next least-cost routing rule.

Even if a matched routing rule is not assigned a Cost Group, the device can select it as the preferred route over other matched rules that are assigned Cost Groups. This is determined according to the settings of the 'Default Call Cost' parameter configured for the Routing Policy (associated with the routing rule for SBC calls). To configure the Routing Policy, see Configuring SBC Routing Policy Rules for SBC calls.

The Cost Group defines a fixed connection cost (connection cost) and a charge per minute (minute cost). Cost Groups can also be configured with time segments (time bands), which define connection cost and minute cost based on specific days of the week and time of day (e.g., from Saturday through Sunday between 6:00 and 18:00, and Monday through Sunday between 18:00 and 5:00). If multiple time bands are configured per Cost Group and a call spans multiple time bands, the call cost is calculated according to minute cost per time band and the connection cost of the time band in which the call was initially established.

In addition to Cost Groups, the device can calculate the call cost using an optional, user-defined average call duration value. The logic in using this option is that a Cost Group may be cheap if the call duration is short, but due to its high minute cost, may prove very expensive if the duration is lengthy. Thus, together with Cost Groups, the device can use this option to determine least cost routing. The device calculates the Cost Group call cost as follows:

Total Call Cost = Connection Cost + (Minute Cost * Average Call Duration)

The below table shows an example of call cost when taking into consideration call duration. This example shows four defined Cost Groups and the total call cost if the average call duration is 10 minutes:

Call Cost Comparison between Cost Groups for different Call Durations

Cost Group

Connection Cost

Minute Cost

Total Call Cost per Duration

1 Minute

10 Minutes

A

1

6

7

61

B

0

10

10

100

C

0.3

8

8.3

80.3

D

6

1

7

16

If four matching routing rules are located in the routing table and each one is assigned a different Cost Group as listed in the table above, then the rule assigned Cost Group "D" is selected. Note that for one minute, Cost Groups "A" and "D" are identical, but due to the average call duration, Cost Group "D" is cheaper. Therefore, average call duration is an important factor in determining the cheapest routing role.

Below are a few examples of how you can implement LCR:

Example 1: This example uses two different Cost Groups for routing local calls and international calls:

Two Cost Groups are configured as shown below:

Cost Group

Connection Cost

Minute Cost

1. "Local Calls"

2

1

2. "International Calls"

6

3

The Cost Groups are assigned to routing rules for local and international calls:

Routing Index

Dest Phone Prefix

Destination IP

Cost Group ID

1

2000

x.x.x.x

1 "Local Calls"

2

00

x.x.x.x

2 "International Calls"

Example 2: This example shows how the device determines the cheapest routing rule in the Tel-to-IP Routing table:

The 'Default Call Cost' parameter in the Routing Policy rule is configured to Lowest Cost, meaning that if the device locates other matching routing rules (with Cost Groups assigned), the routing rule without a Cost Group is considered the lowest cost route.

The following Cost Groups are configured:

Cost Group

Connection Cost

Minute Cost

1. "A"

2

1

2. "B"

6

3

The Cost Groups are assigned to routing rules:

Routing Index

Dest Phone Prefix

Destination IP

Cost Group

1

201

x.x.x.x

"A'

2

201

x.x.x.x

"B"

3

201

x.x.x.x

0

4

201

x.x.x.x

"B"

The device calculates the optimal route in the following index order: 3, 1, 2, and then 4, due to the following logic:

Index 1 - Cost Group "A" has the lowest connection cost and minute cost
Index 2 - Cost Group "B" takes precedence over Index 4 entry based on the first-matched method rule
Index 3 - no Cost Group is assigned, but as the 'Default Call Cost' parameter is configured to Lowest Cost, it is selected as the cheapest route
Index 4 - Cost Group "B" is only second-matched rule (Index 1 is the first)
Example 3: This example shows how the cost of a call is calculated if the call spans over multiple time bands:

Assume Cost Group "CG Local" is configured with two time bands, as shown below:

Cost Group

Time Band

Start Time

End Time

Connection Cost

Minute Cost

CG Local

TB1

16:00

17:00

2

1

TB2

17:00

18:00

7

2

Assume that the call duration is 10 minutes, occurring between 16:55 and 17:05. In other words, the first 5 minutes occurs in time band "TB1" and the next 5 minutes occurs in "TB2", as illustrated below:

The device calculates the call cost as follows:

For the first 5 minutes of the call (16:55 to 17:00), the call is in time band "TB1" and the call cost for this period is calculated as follows:

Connection Cost of "TB1" + [Minute Cost of "TB1" x call duration] = 2 + [ 1 x 5 min] = 7

For the next 5 minutes of the call (17:00 to 17:05), the call is in time band "TB2" and the call cost for this period is calculated as follows:

Minute Cost of "TB2" x call duration = 2 x 5 min = 10

Therefore, the total call cost is the summation of above:

"TB1" call cost + "TB2" call cost = 7 + 10 = 17