skaller wrote:
> Any thoughts on how to add 'costing' information to Felix?
>   
Chris King wrote:
 > but who chooses the constants?

This last point on the constants makes a big difference.  I will come 
back to that.

First, one has to decide what is really being 'costed'.  Worst-case or 
average-case?  Neither are fully satisfactory, for obvious reasons.

How should costing be done?  Well, there the answer is fairly 
well-understood now: series.  Or more precisely, and asymptotic series. 

But constants matter a lot.  For example, consider two algorithms which 
have cost n^3 and 10^12*n^2 respectively.  The n^3 algorithm is to be 
chosen over the O(n^2) algorithm essentially *always*, as the cross-over 
is at n=10^12, which is likely bigger than what can realistically be 
done.  These are extreme cases, but I have seen more subtle instances 
where the "fast" algorithm was never useful.  Note that there are times 
when it is sub-dominant terms which allow you to choose between 2 
algorithms.

I guess what I am saying is that whatever you implement, the above 
considerations should be used in the *design* (ie design-for-change), as 
if Felix is successful, whatever first approximation of costing will 
need to evolve towards handling the above issues.

Jacques

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Felix-language mailing list
Felix-language@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/felix-language

Reply via email to