Product Mixer Performance Metrics in Refinery Simulation

Why ProductMixer Requires Specialized Statistics

       In refinery simulation and petroleum refining digital twin applications, evaluating a fuel blending operation requires considerably more information than simply measuring inlet and outlet flow rates. A ProductMixer continuously decides which incoming streams satisfy product quality specifications, determines how much of each stream is accepted into the final blend, rejects non-compliant material, injects additives, and verifies that the resulting product satisfies all blending constraints. These operations cannot be evaluated using conventional flow statistics alone. ProductMixer Statistics are collected regardless of the selected blending algorithm and are available for both Automatic Product Blending and Manual Product Blending modes.
       To support engineering analysis, ProductMixer Statistics combines process monitoring, blending optimization, and quality-control information within a single API for refinery simulation models. In addition to monitoring material flows, it evaluates product properties, tracks rejected streams, reports additive consumption, and verifies compliance with blending constraints. Together, these metrics provide a complete picture of the blending process and allow engineers to understand not only how much product is produced, but also why the optimizer selected a particular blending solution. For an overview of ProductMixer capabilities, see the ProductMixer Complete Guide.
       The Anylogic based Petroleum Refining Library organizes these performance metrics into several logical categories covering incoming flows, blended product statistics, quality constraints, additives, and optimization summary information. Together, these statistics provide a comprehensive framework for monitoring refinery blending operations, validating optimization results, and analyzing ProductMixer performance throughout the simulation. Although this article describes the available performance metrics, their generation and retrieval are integrated into the ProductMixer runtime API. For details about runtime configuration, public methods, events, and advanced control, see ProductMixer Control in Refinery Simulation. See the ProductMixer performance simulation for an interactive example.

ProductMixer Statistics Categories

       ProductMixer exposes a comprehensive set of blending performance metrics covering every stage of the refinery blending process. Unlike conventional process mixers, which primarily report inlet and outlet flow rates, ProductMixer provides statistics describing feed composition, product formation, quality constraint evaluation, additive consumption, and optimization results. These metrics allow engineers to evaluate not only the quantity of blended product, but also the quality of the blending solution generated during simulation.
       For easier interpretation, the statistics are organized into five logical categories based on their engineering purpose. Together, they provide a complete framework for analyzing refinery blending operations, validating optimization results, and integrating ProductMixer into Digital Twin dashboards and production planning systems. Access to ProductMixer Statistics is provided through the ProductMixer runtime API. For information about runtime configuration, public methods, and event-driven integration, see ProductMixer Control in Refinery Simulation.
       The Petroleum Refining Library provides direct access to all ProductMixer performance metrics through the ProductMixerStatistics class. The ProductMixer Statistics API operates independently of the selected operating mode, providing identical performance metrics for both the Automatic Product Blending and Manual Product Blending algorithms. The API enables developers to retrieve real-time operating data, evaluate blend quality, inspect optimization results, analyze additive consumption, and integrate ProductMixer statistics into custom applications, refinery dashboards, and Digital Twin platforms. Together, these statistics provide a complete operational picture of refinery blending. They enable engineers to monitor product quality, analyze rejected streams, validate blending constraints, optimize additive consumption, and compare alternative blending strategies using objective performance indicators collected throughout the simulation.

Input Statistics

       Input statistics provide complete visibility into the incoming refinery feed streams entering the ProductMixer before the blending process begins. These metrics provide complete visibility into the material entering the ProductMixer and allow engineers to evaluate feedstock availability, analyze the contribution of individual inlet streams, and verify that the blending process receives the expected product flows. Unlike product statistics, which characterize the blending result, input statistics represent the initial conditions supplied to the optimization algorithm.
       The ProductMixer Statistics API provides both aggregate and stream-level information. Engineers can retrieve the total incoming flow, obtain the flow associated with a particular inlet connection, or analyze the contribution of individual input streams using their internal mixer indices. These statistics are available both as numerical values for application development and as formatted reports suitable for operator interfaces and debugging.
       Input statistics are widely used for feedstock analysis, refinery blending optimization, Digital Twin dashboards, and verification of production scenarios. They allow engineers to compare the contribution of different feedstocks, identify dominant inlet streams, validate upstream process behavior, and ensure that the optimization algorithm operates on the expected feed composition. Since all subsequent blending calculations are based on these incoming flows, input statistics form the foundation for evaluating ProductMixer performance and validating refinery blending simulations.

ProductContribution Statistics

       While input statistics describe the feed entering the ProductMixer, product statistics characterize the results of the fuel blending process and blended product production. These metrics show how much material is incorporated into the final product, how much is rejected during blending, and how each incoming stream contributes to the finished blend. Together, they provide a direct measure of fuel blending efficiency and product utilization.
       Unlike conventional mixers, ProductMixer does not necessarily accept all incoming material. During optimization, each inlet stream is evaluated against the specified product quality constraints. Material that satisfies the blending requirements is directed to the final product, while the remaining portion is diverted to the residual outlet. Product contribution statistics therefore provide visibility into both accepted and rejected material, enabling engineers to identify feedstocks that limit product quality or reduce production efficiency.
       ProductContribution statistics are widely used to evaluate blending efficiency, analyze rejected feedstocks, validate optimization results, and compare alternative blending strategies. They provide engineers with a clear understanding of how each inlet stream contributes to the final product, how much material is rejected due to quality constraints, and how effectively the available feedstock is utilized throughout the blending process. These metrics are also valuable for refinery Digital Twin dashboards, production planning, and optimization analysis.

Constraint Statistics

       Constraint statistics measure and verify the blended product satisfies the required fuel quality specifications. Unlike flow statistics, which describe material movement, these metrics measure fuel properties such as octane number, sulfur content, density, or any other configured blending constraint. They enable engineers to compare calculated product characteristics with the specified quality limits and validate the optimization results.
       The ProductMixer Statistics API reports both the characteristics of the incoming blend and the calculated properties of the final product. This allows engineers to understand how the blending process modifies product quality and how additives or changes in feed composition influence the final result. Each reported characteristic is evaluated according to its configured constraint type and direction (minimum or maximum), making the statistics suitable for refinery quality control, optimization validation, and Digital Twin applications.
       Constraint statistics are essential for validating blend quality, comparing optimization scenarios, troubleshooting product specification violations, and analyzing refinery blending performance. They provide engineers with complete visibility into how each quality constraint influences the blending solution and help verify that the final product satisfies all technological and commercial requirements before it leaves the ProductMixer.

Additive Statistics

       Additives play an essential role in fuel blending optimization and refinery blending by adjusting product properties to satisfy quality specifications or improve commercial value. ProductMixer supports two independent additive mechanisms. The first introduces predefined additives directly into individual inlet streams or the final product according to user-defined ratios. The second automatically injects a balance additive during optimization to satisfy blending constraints or maximize product production. ProductMixer statistics provide complete visibility into both mechanisms and quantify additive consumption and blend optimization throughout the blending process.
       The ProductMixer Statistics API reports additive consumption for individual inlet streams, additives contained in the final blended product, and the balancing additive generated by the optimization algorithm. These metrics enable engineers to evaluate additive usage, compare alternative blending strategies, estimate additive consumption, and verify the optimizer's decisions. They are particularly valuable when minimizing additive consumption and blend optimization is one of the optimization objectives.
       Additive statistics help engineers evaluate additive consumption, validate optimization strategies, estimate operating costs, and compare alternative blending solutions. By exposing both manually configured additives and automatically calculated balancing additives, ProductMixer provides comprehensive information for refinery quality control, production optimization, Digital Twin dashboards, and blend cost analysis.

Summary Statistics

       Besides detailed flow, constraint, and additive metrics, ProductMixer provides summary statistics describing the current operating mode and blending optimization status. These statistics give engineers a concise overview of the blending process without requiring analysis of every individual performance indicator. They are particularly useful for operator dashboards, model debugging, and monitoring refinery Digital Twins.
       The summary includes the ProductMixer identifier, the current calculation mode, the active optimization objective, and, when available, the maximum achievable production rate. Depending on the selected operating mode, the summary also indicates whether ProductMixer is minimizing balancing additive consumption or maximizing finished product production. This information allows engineers to quickly verify that the blending algorithm is operating under the expected optimization strategy.
       Summary statistics provide a high-level overview of ProductMixer operation and are commonly used for simulation monitoring, optimization verification, and Digital Twin dashboards. Although concise, these metrics allow engineers to determine the current optimization mode, verify that automatic calculations are active, and assess the overall state of the blending process without examining detailed flow or quality statistics.

ProductMixer Statistics API

       The Petroleum Refining Library automatically creates a ProductMixerStatistics object for every ProductMixer instance. No additional configuration is required. All performance metrics are available through the statistics field, which provides unified access to input, output, constraint, and additive statistics. This hierarchical structure simplifies application development and allows engineers to retrieve only the statistics relevant to a particular engineering task. Because ProductMixer Statistics are generated for both supported blending algorithms, engineers can directly compare the performance of Automatic Product Blending and Manual Product Blending using the same set of metrics.
       The ProductMixer Statistics API is organized into four logical groups, each responsible for a specific aspect of the blending process: ProductMixer → ProductMixerStatistics → Input, Output, ProductContribution, Constraint, Additive.

For example, the total incoming flow can be obtained as follows:
double totalInput =
        productMixer.statistics
                    .input
                    .getTotalFlow(MASS_FLOW);
Similarly, the total blended product flow is available through the output statistics:
double productFlow =
        productMixer.statistics
                    .output
                    .getTotalProductFlow(MASS_FLOW);
Finally, the balancing additive calculated by the optimization algorithm can be obtained using the additive statistics:
double balanceAdditive =
        productMixer.statistics
                    .additive
                    .getBalanceAdditive(MASS_FLOW);
By organizing statistics into dedicated groups, the ProductMixer Statistics API provides a consistent and intuitive interface for refinery simulation, blending optimization, Digital Twin dashboards, and production planning applications. Engineers can access individual performance indicators without navigating the internal ProductMixer implementation, making the API suitable for both operational monitoring and advanced analytical applications.

Applications of ProductMixer Statistics

       ProductMixer performance metrics are widely used in refinery simulation, fuel blending optimization, production planning, process monitoring, and Digital Twin applications. Because the API provides detailed information about incoming streams, blended products, quality constraints, additives, and optimization results, engineers can evaluate both the performance of the blending process and the quality of the resulting product.
       These application scenarios demonstrate that ProductMixer Statistics are useful throughout the entire refinery simulation lifecycle—from model development and debugging to production optimization and real-time operational monitoring.

Conclusion

       ProductMixer Statistics provides a comprehensive framework for fuel blending monitoring, refinery process optimization, and performance analysis throughout the simulation lifecycle. Unlike conventional flow statistics, it combines process monitoring, product quality evaluation, additive tracking, and optimization analysis within a single API. This enables engineers to understand not only how much product is produced, but also how the blending algorithm achieves the required product specifications.
       By organizing statistics into Input, ProductContribution, Constraint, Additive, and Summary categories, the Petroleum Refining Library offers a consistent and intuitive interface for analyzing ProductMixer performance. These statistics support engineering tasks ranging from model verification and debugging to refinery Digital Twins, production planning, quality assurance, and optimization validation.
Whether ProductMixer is used to maximize production, minimize additive consumption, or satisfy complex blending specifications, the ProductMixer Statistics API provides the detailed operational information required to evaluate blending performance, validate optimization results, and improve refinery decision-making.
       Together, these capabilities make ProductMixer Statistics an essential component of refinery simulation software, Digital Twin platforms, and fuel blending optimization systems.

FAQ

1. What are ProductMixer Statistics?
ProductMixer Statistics are a collection of performance metrics that monitor refinery blending operations during simulation. They provide information about incoming flows, blended products, rejected streams, quality constraints, additive consumption, and optimization results through a unified ProductMixer Statistics API.

2. What statistics does ProductMixer collect?
ProductMixer organizes its performance metrics into five categories: Input Statistics, Product Contribution Statistics, Constraint Statistics, Additive Statistics, and Summary Statistics. Together, these metrics provide a complete view of the blending process and its optimization results.

3. How can I monitor rejected streams during blending?
Rejected material can be monitored using the Residual Flow Statistics. These statistics report the amount of each inlet stream that cannot be incorporated into the final product because of blending constraints or optimization decisions.

4. Can ProductMixer statistics verify product quality?
Yes. Constraint Statistics calculate the properties of both the incoming blend and the final product, allowing engineers to compare calculated values with configured quality limits and verify that all blending specifications are satisfied.

5. Does ProductMixer report additive consumption?
Yes. ProductMixer reports additives injected into individual inlet streams, additives contained in the final blended product, and the balancing additive automatically calculated by the optimization algorithm. These statistics help evaluate additive usage and optimization performance.

6. Can ProductMixer statistics be used in Digital Twin dashboards?
Yes. All performance metrics are available through the ProductMixer Statistics API, making them suitable for refinery Digital Twin dashboards, operational monitoring, production planning systems, and custom engineering applications.

7. How do ProductMixer statistics support optimization?
ProductMixer statistics expose optimization objectives, product quality indicators, rejected streams, additive consumption, and summary information, allowing engineers to validate optimization results and compare alternative blending strategies.

8. How can I access ProductMixer Statistics?
Every ProductMixer automatically creates a ProductMixerStatistics object. Statistics are accessed through the statistics field, which provides separate interfaces for Input, ProductContribution, Constraint, Additive, and Summary statistics.

9. Can ProductMixer statistics be exported?
Yes. ProductMixer statistics are available through the ProductMixer Statistics API, allowing applications to retrieve performance metrics programmatically. This enables developers to export statistics to databases, spreadsheets, reporting tools, Digital Twin platforms, or custom monitoring systems for further analysis and visualization.

10. Are ProductMixer statistics available in real time?
Yes. ProductMixer statistics are updated during simulation and can be accessed at any time through the ProductMixer Statistics API. This allows engineers to monitor blending performance, product quality, additive consumption, and optimization results in real time for operational dashboards, Digital Twin applications, and production monitoring.