Class MaximumProfitToCostRatioAnalysis


  • public class MaximumProfitToCostRatioAnalysis
    extends Analysis
    Maximum profit to cost ratio analysis.

    Please refer to:

    Ali Dasdan , Sandy S. Irani , Rajesh K. Gupta, Efficient algorithms for optimum cycle mean and optimum cost to time ratio problems, Proceedings of the 36th ACM/IEEE conference on Design automation conference, p.37-42, June 21-25, 1999, New Orleans, Louisiana, United States

    for a detailed mathematical description of the problem.

    Since:
    Ptolemy II 4.0
    Version:
    $Id$
    Author:
    Shahrooz Shahparnia
    See Also:
    CycleMeanAnalysis
    Pt.AcceptedRating:
    Red (ssb)
    Pt.ProposedRating:
    Red (shahrooz)
    • Constructor Detail

      • MaximumProfitToCostRatioAnalysis

        public MaximumProfitToCostRatioAnalysis​(Graph graph,
                                                ToDoubleMapping edgeProfits,
                                                ToIntMapping edgeCosts)
        Construct an instance of this class using a default analyzer. Please note the limitation on edge costs which is being imposed by the default analyzer.
        Parameters:
        graph - The given graph.
        edgeProfits - The profits associated with the edges of the graph.
        edgeCosts - The costs associated with the edges of the graph.
      • MaximumProfitToCostRatioAnalysis

        public MaximumProfitToCostRatioAnalysis​(MaximumProfitToCostRatioAnalyzer analyzer)
        Construct an instance of this class using a given analyzer.
        Parameters:
        analyzer - The given analyzer.
    • Method Detail

      • cycle

        public java.util.List cycle()
        Return the nodes on the cycle that corresponds to the maximum profit to cost ratio.
        Returns:
        The nodes on the cycle as an ordered list.
      • maximumRatio

        public double maximumRatio()
        Return the maximum profit to cost ratio of the given graph.
        Returns:
        Return the maximum profit to cost ratio of the associated graph.
      • toString

        public java.lang.String toString()
        Return a description of the analysis and the associated analyzer.
        Overrides:
        toString in class Analysis
        Returns:
        A description of the analysis and the associated analyzer.
      • validAnalyzerInterface

        public boolean validAnalyzerInterface​(Analyzer analyzer)
        Check if a given analyzer is compatible with this analysis. In other words if it is possible to use it to compute the computation associated with this analysis.
        Overrides:
        validAnalyzerInterface in class Analysis
        Parameters:
        analyzer - The given analyzer.
        Returns:
        True if the given analyzer is valid for this analysis.