Cascading Polygon Interpolation Blocks (Polygon) in PCS 7 APL
In SIMATIC PCS 7 APL (V9.0 SP3), expanding non-linear characteristic curve interpolation beyond 8 coordinate pairs by cascading two Polygon blocks (FB1881) requires adhering to strict parameter linking and monotonicity rules. To cascade, connect CasOut of the preceding Polygon block to CasIn of the succeeding Polygon block, set CasEn = 1 on the succeeding block, and route the common analog input (In) to both blocks. Crucially, coordinate points across both blocks must form a strictly monotonically increasing sequence where X1 of the second block is greater than or equal to X8 of the first block. If X-coordinates overlap or CasEn is omitted, the second block fails to evaluate, clamping the output to default limits.
Table of Contents
- Executive Summary
- Architecture and Fundamental Mechanics
- Step-by-Step Implementation Procedure
- Verification
- Limitations and Operational Precautions
- Engineer FAQ
- Technical References
- Related Articles
- Related Tags
Executive Summary
Non-linear signal conditioning is vital in process automation for tasks such as calculating liquid volume in horizontal cylindrical vessels with dished heads, characterizing non-linear valve flow coefficients, or linearizing thermocouple temperature curves. The PCS 7 APL Polygon block (FB1881) provides piece-wise linear interpolation for up to 8 coordinate points. When applications require higher resolution (e.g., 16 or 24 points), multiple Polygon blocks must be cascaded. Engineers frequently find that while individual blocks function correctly, the second cascaded block fails to calculate, holding its output at zero. This technical guide details the cascading architecture, parameter handshakes, and monotonic coordinate constraints required for seamless multi-block interpolation.
Architecture and Fundamental Mechanics
The interpolation and cascading engine of the PCS 7 APL Polygon block operates under strict mathematical and logical rules:
1. Single Block Piece-Wise Linear Interpolation:
- Each Polygon block defines up to 8 coordinate pairs ($X_1, Y_1$ through $X_8, Y_8$).
- Parameter Num (2 to 8) specifies the number of active interpolation points.
- Within a block, $X$-values must be strictly monotonically increasing ($X_1 < X_2 < \dots < X_n$).
- For any input $In$ between $X_k$ and $X_{k+1}$, output Out is calculated via linear interpolation:
$$\text{Out} = Y_k + \frac{Y_{k+1} - Y_k}{X_{k+1} - X_k} \cdot (\text{In} - X_k)$$
2. The Cascading Handshake (CasIn, CasOut, CasEn):
- When $In$ exceeds $X_n$ on the first block, standard execution clamps Out to $Y_n$.
- When cascaded:
a. Block 1: Emits its status and boundary handover token via output parameter CasOut.
b. Block 2: Receives this token via input parameter CasIn.
c. Parameter CasEn (Cascade Enable) on Block 2 must be set to 1. This instructs Block 2 to remain inactive while $In < X_{1\text{, Block 2}}$ (letting Block 1 drive the signal) and take over calculation once $In \ge X_{1\text{, Block 2}}$.
3. Coordinate Continuity Across Blocks:
- Block 2's starting coordinate ($X_1, Y_1$) must match Block 1's final coordinate ($X_8, Y_8$) to guarantee smooth mathematical continuity without step-change jumps.
Step-by-Step Implementation Procedure
-
Instantiate Polygon Blocks in CFC:
a. Open the CFC chart requiring non-linear characterization.
b. Insert two instances ofPolygon(FB1881) from the APL Math library.
c. Name the first blockPoly_Stage1and the second blockPoly_Stage2. -
Interconnect Process Input to Both Blocks:
a. Route the raw scaled process variable (e.g., vessel level 0–100% fromPcs7AnIn.PV_Out) to inputInofPoly_Stage1.
b. Route the identical signal to inputInofPoly_Stage2. -
Connect Cascading Handshake Parameters:
a. ConnectPoly_Stage1.CasOutdirectly toPoly_Stage2.CasIn.
b. OnPoly_Stage2, set input parameter CasEn.Value = 1 (Cascade Enable).
c. OnPoly_Stage1, verifyCasEn.Value = 0(first block is the cascade master). -
Configure Monotonic Interpolation Points:
a. OnPoly_Stage1(Points 1 to 8):- Set
Num = 8. - Configure coordinates: e.g., $X_1 = 0.0, Y_1 = 0.0$ up to $X_8 = 50.0, Y_8 = 420.0$.
b. OnPoly_Stage2(Points 9 to 16): - Set
Num = 8. - Set point 1 to match the end of Stage 1: $X_1 = 50.0, Y_1 = 420.0$.
- Configure remaining points monotonically: $X_2 = 60.0$ up to $X_8 = 100.0, Y_8 = 1000.0$.
- Set
-
Combine Final Output Signals:
a.Poly_Stage2.Outrepresents the final cascaded result across the entire 0–100% span.
b. ConnectPoly_Stage2.Outto the downstream technological block (e.g., volume display onMonAnL.PV).
c. Compile CFC charts and execute delta download in RUN.
Verification
- In CFC online, simulate
In = 25.0(within Stage 1): verifyPoly_Stage1calculates active interpolation andPoly_Stage2.Outpasses through the valid Stage 1 value viaCasIn. - Simulate
In = 50.0(boundary): verifyPoly_Stage2.Outreflects exactly 420.0. - Simulate
In = 75.0(within Stage 2): verifyPoly_Stage2takes over interpolation actively, calculating the correct higher-range non-linear volume. - Verify that signal quality remains
16#80(Good) across the entire 0–100% range.
Limitations and Operational Precautions
Never configure overlapping or decreasing X-values between cascaded blocks (e.g., Block 2 starting at X1 = 40 when Block 1 ends at X8 = 50). Non-monotonic sequences cause calculation errors and trigger ErrorNum = 1.
Engineer FAQ
How many points can a single Polygon block interpolate in APL?
A single Polygon block can interpolate between 2 and 8 coordinate points.
What parameter enables cascading on the second Polygon block?
Parameter CasEn (Cascade Enable) must be set to 1 on the succeeding block.
What parameter carries the cascading token between Polygon blocks?
CasOut of the first block connects to CasIn of the second block.
Where do I take the final interpolated output in a 2-block cascade?
Take the final output from Out of the second (succeeding) Polygon block.
What happens if X coordinates are not strictly increasing?
The block detects non-monotonic coordinates, sets ErrorNum = 1, and holds Out at the low limit or zero.
Technical References
- SIMATIC Process Control System PCS 7 Advanced Process Library Manual
- SIMATIC PCS 7 Mathematical Operations Configuration Guide
- Siemens Industry Online Support Entry 109780813 (APL Polygon Block Applications)
Related Articles
- PID Block Selection Guidelines in PCS 7: PIDConL vs PIDConR vs PIDStepL
- Dynamic Scale Limit Configuration on APL Analog Input Channel Drivers (Pcs7AnIn) and Monitoring Blocks (MonAnL)
- Understanding and Configuring the Sample Time (SAMPLE_T) Parameter on INT_P Integrator Blocks
Related Tags
- Polygon
- Cascading
- Non-linear Interpolation
- CasIn
- CasOut
- APL Math