Return-Path: william@bourbon.usc.edu Delivery-Date: Fri Sep 26 19:43:51 2008 X-Spam-Checker-Version: SpamAssassin 3.2.3 (2007-08-08) on merlot.usc.edu X-Spam-Level: X-Spam-Status: No, score=-2.3 required=5.0 tests=AWL,BAYES_00 autolearn=ham version=3.2.3 Received: from bourbon.usc.edu (bourbon.usc.edu [128.125.9.75]) by merlot.usc.edu (8.14.1/8.14.1) with ESMTP id m8R2hpt1004071 for ; Fri, 26 Sep 2008 19:43:51 -0700 Received: from bourbon.usc.edu (localhost.localdomain [127.0.0.1]) by bourbon.usc.edu (8.14.2/8.14.1) with ESMTP id m8R2lK1T020860 for ; Fri, 26 Sep 2008 19:47:20 -0700 Message-Id: <200809270247.m8R2lK1T020860@bourbon.usc.edu> To: cs551@merlot.usc.edu Subject: Re: 551 warmup-2 average computation Date: Fri, 26 Sep 2008 19:47:19 -0700 From: Bill Cheng Someone wrote: > If I do CTRL-C before any customers arrive, then I get the average "inter > arrival time", "service time" and "time in system" as infinity (displayed as > NaN) because it is divided by 0 customers. > I am not able to convince myself whether to display NaN or to display 0 in > such cases. How about "undefined"? > If I display 0 then that gives an indication that the system is 100% > efficient. > If I display NaN then that gives an indication that the system is 0% > efficient. > > Since none of these cases is true, can I output something like: > average inter-arrival time = insufficient data ? Sure! Since this is not specified, you just need to do something reasonable. NaN is not reasonable! :-) -- Bill Cheng // bill.cheng@usc.edu