ZC trade calculated differently

Hi,
We have a ZC trade and got different results then expected.
This is what we got using the fpml parser : PV01CalibratedSum :-101759.454362
And this is what expected (using bloomberg terminal) : 192308.86
Any idea what went wrong here?

FPML:

<?xml version="1.0" encoding="utf-8"?>
<executionNotification xmlns="http://www.fpml.org/FpML-5/confirmation" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.fpml.org/FpML-5/confirmation d:\_TRAIANA\_PM\FpML\5.8\confirmation\fpml-main-5-8.xsd" fpmlVersion="5-8">
	<header>
		<messageId messageIdScheme="http://www.traiana.com/fpml">20000010000107-03_706</messageId>
		<sentBy>Ilan_ECN1</sentBy>
		<sendTo>Traiana</sendTo>
		<creationTimestamp>2017-07-08T08:57:00Z</creationTimestamp>
	</header>
	<isCorrection>false</isCorrection>
	<trade>
		<tradeHeader>
			<partyTradeIdentifier>
				<partyReference href="ExecutionFacility"/>
				<tradeId tradeIdScheme="http://www.traiana.com/fpml">SEF_TRADE-20000010000107-03_706</tradeId>
				<originatingTradeId>
					<partyReference href="ExecutionFacility"/>
					<tradeId tradeIdScheme="http://www.traiana.com/party/orderId">alloc-20000010000107-01_706</tradeId>
				</originatingTradeId>
			</partyTradeIdentifier>
			<partyTradeIdentifier>
				<partyReference href="party1"/>
				<tradeId tradeIdScheme="http://www.traiana.com/fpml">CLIENT1_TRADE-20000010000107-03_706</tradeId>
			</partyTradeIdentifier>
			<!-- Optional  - trade Id at party2 -->
			<partyTradeIdentifier>
				<partyReference href="party2"/>
				<tradeId tradeIdScheme="http://www.traiana.com/fpml">EB_TRADE_ID-20000010000107-03_706</tradeId>
			</partyTradeIdentifier>
			<!-- Optional element -->
			<partyTradeInformation>
				<partyReference href="ExecutionFacility"/>
				<executionType>Electronic</executionType>
			</partyTradeInformation>

			<tradeDate>2014-01-02</tradeDate>
		</tradeHeader>
		<swap>
			<productId productIdScheme="http://www.bloomberg.com/bbml/coding-scheme/productIdScheme">SL1T3QI1</productId>
      <swapStream id="floatingLeg">
        <payerPartyReference href="party1"/>
        <receiverPartyReference href="party2"/>
        <calculationPeriodDates id="payCalcDates">
          <effectiveDate>
            <unadjustedDate>2016-10-19</unadjustedDate>
            <dateAdjustments>
              <businessDayConvention>NONE</businessDayConvention>
            </dateAdjustments>
          </effectiveDate>
          <terminationDate>
            <unadjustedDate>2046-10-19</unadjustedDate>
            <dateAdjustments>
              <businessDayConvention>MODFOLLOWING</businessDayConvention>
              <businessCenters>
                <businessCenter businessCenterScheme="http://www.fpml.org/coding-scheme/business-center">NYFD</businessCenter>
                <businessCenter businessCenterScheme="http://www.fpml.org/coding-scheme/business-center">GBLO</businessCenter>
              </businessCenters>
            </dateAdjustments>
          </terminationDate>
          <calculationPeriodDatesAdjustments>
            <businessDayConvention>MODFOLLOWING</businessDayConvention>
            <businessCenters>
              <businessCenter businessCenterScheme="http://www.fpml.org/coding-scheme/business-center">NYFD</businessCenter>
              <businessCenter businessCenterScheme="http://www.fpml.org/coding-scheme/business-center">GBLO</businessCenter>
            </businessCenters>
          </calculationPeriodDatesAdjustments>
          <calculationPeriodFrequency>
            <periodMultiplier>3</periodMultiplier>
            <period>M</period>
            <rollConvention>19</rollConvention>
          </calculationPeriodFrequency>
        </calculationPeriodDates>
        <paymentDates>
          <calculationPeriodDatesReference href="payCalcDates"/>
          <paymentFrequency>
            <periodMultiplier>1</periodMultiplier>
            <period>T</period>
          </paymentFrequency>
          <payRelativeTo>CalculationPeriodEndDate</payRelativeTo>
          <paymentDatesAdjustments>
            <businessDayConvention>MODFOLLOWING</businessDayConvention>
            <businessCenters>
              <businessCenter businessCenterScheme="http://www.fpml.org/coding-scheme/business-center">NYFD</businessCenter>
              <businessCenter businessCenterScheme="http://www.fpml.org/coding-scheme/business-center">GBLO</businessCenter>
            </businessCenters>
          </paymentDatesAdjustments>
        </paymentDates>
        <resetDates id="payResetDates">
          <calculationPeriodDatesReference href="payCalcDates"/>
          <resetRelativeTo>CalculationPeriodStartDate</resetRelativeTo>
          <fixingDates>
            <periodMultiplier>-2</periodMultiplier>
            <period>D</period>
            <dayType>Business</dayType>
            <businessDayConvention>NONE</businessDayConvention>
            <businessCenters>
              <businessCenter businessCenterScheme="http://www.fpml.org/coding-scheme/business-center">GBLO</businessCenter>
            </businessCenters>
            <dateRelativeTo href="payResetDates"/>
          </fixingDates>
          <resetFrequency>
            <periodMultiplier>3</periodMultiplier>
            <period>M</period>
          </resetFrequency>
          <resetDatesAdjustments>
            <businessDayConvention>MODFOLLOWING</businessDayConvention>
            <businessCenters>
              <businessCenter businessCenterScheme="http://www.fpml.org/coding-scheme/business-center">NYFD</businessCenter>
              <businessCenter businessCenterScheme="http://www.fpml.org/coding-scheme/business-center">GBLO</businessCenter>
            </businessCenters>
          </resetDatesAdjustments>
        </resetDates>
        <calculationPeriodAmount>
          <calculation>
            <notionalSchedule id="payNotionalSchedule">
              <notionalStepSchedule>
                <initialValue>47456760.2599999979</initialValue>
                <currency currencyScheme="http://www.fpml.org/coding-scheme/external/iso4217-2001-08-15">USD</currency>
              </notionalStepSchedule>
            </notionalSchedule>
            <floatingRateCalculation>
              <floatingRateIndex floatingRateIndexScheme="http://www.fpml.org/coding-scheme/floating-rate-index">USD-LIBOR-BBA</floatingRateIndex>
              <indexTenor>
                <periodMultiplier>3</periodMultiplier>
                <period>M</period>
              </indexTenor>
            </floatingRateCalculation>
            <dayCountFraction dayCountFractionScheme="http://www.fpml.org/coding-scheme/day-count-fraction">ACT/360</dayCountFraction>
          </calculation>
        </calculationPeriodAmount>
      </swapStream>
      <swapStream id="fixedLeg">
        <payerPartyReference href="party2"/>
        <receiverPartyReference href="party1"/>
        <calculationPeriodDates id="recCalcDates">
          <effectiveDate>
            <unadjustedDate>2016-10-19</unadjustedDate>
            <dateAdjustments>
              <businessDayConvention>NONE</businessDayConvention>
            </dateAdjustments>
          </effectiveDate>
          <terminationDate>
            <unadjustedDate>2046-10-19</unadjustedDate>
            <dateAdjustments>
              <businessDayConvention>MODFOLLOWING</businessDayConvention>
              <businessCenters>
                <businessCenter businessCenterScheme="http://www.fpml.org/coding-scheme/business-center">NYFD</businessCenter>
                <businessCenter businessCenterScheme="http://www.fpml.org/coding-scheme/business-center">GBLO</businessCenter>
              </businessCenters>
            </dateAdjustments>
          </terminationDate>
          <calculationPeriodDatesAdjustments>
            <businessDayConvention>MODFOLLOWING</businessDayConvention>
            <businessCenters>
              <businessCenter businessCenterScheme="http://www.fpml.org/coding-scheme/business-center">NYFD</businessCenter>
              <businessCenter businessCenterScheme="http://www.fpml.org/coding-scheme/business-center">GBLO</businessCenter>
            </businessCenters>
          </calculationPeriodDatesAdjustments>
          <calculationPeriodFrequency>
            <periodMultiplier>6</periodMultiplier>
            <period>M</period>
            <rollConvention>19</rollConvention>
          </calculationPeriodFrequency>
        </calculationPeriodDates>
        <paymentDates>
          <calculationPeriodDatesReference href="recCalcDates"/>
          <paymentFrequency>
            <periodMultiplier>1</periodMultiplier>
            <period>T</period>
          </paymentFrequency>
          <payRelativeTo>CalculationPeriodEndDate</payRelativeTo>
          <paymentDatesAdjustments>
            <businessDayConvention>MODFOLLOWING</businessDayConvention>
            <businessCenters>
              <businessCenter businessCenterScheme="http://www.fpml.org/coding-scheme/business-center">NYFD</businessCenter>
              <businessCenter businessCenterScheme="http://www.fpml.org/coding-scheme/business-center">GBLO</businessCenter>
            </businessCenters>
          </paymentDatesAdjustments>
        </paymentDates>
        <calculationPeriodAmount>
          <calculation>
            <notionalSchedule id="receiveNotionalSchedule">
              <notionalStepSchedule>
                <initialValue>47456760.2599999979</initialValue>
                <currency currencyScheme="http://www.fpml.org/coding-scheme/external/iso4217-2001-08-15">USD</currency>
              </notionalStepSchedule>
            </notionalSchedule>
            <fixedRateSchedule>
              <initialValue>0.025</initialValue>
            </fixedRateSchedule>
            <dayCountFraction dayCountFractionScheme="http://www.fpml.org/coding-scheme/day-count-fraction">30/360</dayCountFraction>
          </calculation>
        </calculationPeriodAmount>
      </swapStream>
		</swap>
	</trade>
	<party id="party1">
		<partyId>Ilan_Client1</partyId>
	</party>
	<party id="party2">
		<partyId>Anonymous</partyId>
	</party>
	<party id="clearingBroker1">
		<partyId>Ilan_CM1</partyId>
	</party>
	<party id="DCO">
		<partyId>Ilan_CCP1</partyId>
	</party>
	<party id="LimitsHub">
		<partyId>Traiana</partyId>
	</party>
	<party id="ExecutionFacility">
		<partyId>Ilan_ECN1</partyId>
	</party>
</executionNotification>

Hello,

Can you please tell me if your leg level NPVs are also far off from Bloomberg?

Especially on the fixed leg, it maybe helpful to see how well that lines up, in order to get an idea if the discrepancies are coming from mismatched trade params or mismatching generated cashflows.

Assuming the problem is not there, then specifics of curve construction and the market data used in the curve would be worth investigating.

PresentValue : 4692940.481426675

Fixed leg : USD 8.836089202175215E7

hey Tom,

Under the assumption that the MD is equal or negligible difference.
can you tell us what exactly the ZR coupon calculation does ? we find big difference agints BBG terminal , we don’t see this difference in other IRD product types (FRA, fixed-fload, OIS…etc)

do you need more details from us ?

As per our community support policy, we can’t really get into the details of trying to match our numbers to an external system. The code is open source, so if you feel there is a problem, you are able to debug through to identify where the numbers diverge.

Hi @stephen,

We totally understand you can’t try to match numbers with any external system.
As we understand, ZC swaps may contain either notional and interest rate or a know amount (Future Value Notional).
When processing the trades in OpenGamma we are getting a high variance between resulting DV01 figures although the financial are the same.

E.g.

Could you identify the reason for the variance?
Please let me know if you need any further information.

I’ve had a brief look at the FpML and Bloomberg capture above. The two seem to match, although I can’t confirm if Bloomberg day count 30I/360 is the same as 30/360 ISDA. Perhaps this is something to check.

We are aware that our PV01 measure may not exactly match how Bloomberg defines DV01. But we would expect the two to be reasonably close. To determine an exact difference requires checking that the curves match in each system, and that the trades match at each payment date. With ZC trades that is of course trickier as there are no intermediate payments.

Internally, we have no special logic for zero coupon trades - the discounting swap payment pricer calculates the payment period in the same way however long it is.

Are you sure that the trade has no intermediate payments on both the fixed and floating leg?

Both legs paymentFrequency =1T

@stephen,

In your code there is a comment:

Does that mean you are referring to the known amount as the initial amount?
Shouldn’t it refer to the future value notional?

When Strata sees a knownAmountSchedule in FpML it creates a KnownAmountSwapLeg instead of a RateCalculationSwapLeg. The known amount represents the actual monetary amount to be exchanged for that leg - ie. there is no notional, day count or fixed rate. The code above is from KnownAmountSwapLeg.

For any value that can change during the life of a swap (notional, interest rate, spread, gearing, known amount), we use ValueSchedule. The “initial amount” is the amount of the value at the start of the swap, and the “steps” define how the amount changes over time.

Strata does not support the futureValueNotional field in FpML.

The FpML at the top of the page does not define futureValueNotional.

Hi,
We have two identical trades - one with known amount, and one with initial value + rate.
The two trades should recieve the same DV01 using the parser, but the numbers are not close.
10Y 3M Libor:
with Initial value: 76324
with Known amount: 150416

<?xml version="1.0" encoding="UTF-8"?> IRS.dcm280164073367195840650 UBSLTD Traiana 2016-10-26T12:25:13.918 false e3d9705a-e484-43a0-8cbc-7150f0f33172 1 0000452A MARKITWIRE31145803 2244828 Counterparty ClearingFirm ClearingOrganization 2016-10-19 InterestRate:IRSwap:FixedFloat 2016-10-26 NONE 2026-10-26 MODFOLLOWING GBLO USNY MODFOLLOWING GBLO USNY 3 M 26 1 T CalculationPeriodEndDate MODFOLLOWING GBLO USNY CalculationPeriodStartDate -2 D Business NONE GBLO 3 M MODFOLLOWING GBLO USNY 81954447.03 USD USD-LIBOR-BBA 3 M ACT/360 Straight 2016-10-26 NONE 2026-10-26 MODFOLLOWING GBLO USNY MODFOLLOWING GBLO USNY 6 M 26 1 T CalculationPeriodEndDate MODFOLLOWING GBLO USNY 100000000 USD ISDA ISDA2006 EUREX B64400 UBSLTD Anonymous <?xml version="1.0" encoding="UTF-8"?> IRS.dcm280164073367195840650 UBSLTD Traiana 2016-10-26T12:25:13.918 false e3d9705a-e484-43a0-8cbc-7150f0f33172 1 0000452A MARKITWIRE31145803 2244828 Counterparty ClearingFirm ClearingOrganization 2016-10-19 InterestRate:IRSwap:FixedFloat 2016-10-26 NONE 2026-10-26 MODFOLLOWING GBLO USNY MODFOLLOWING GBLO USNY 3 M 26 1 T CalculationPeriodEndDate MODFOLLOWING GBLO USNY CalculationPeriodStartDate -2 D Business NONE GBLO 3 M MODFOLLOWING GBLO USNY 81954447.03 USD USD-LIBOR-BBA 3 M ACT/360 Straight 2016-10-26 NONE 2026-10-26 MODFOLLOWING GBLO USNY MODFOLLOWING GBLO USNY 6 M 26 1 T CalculationPeriodEndDate MODFOLLOWING GBLO USNY 81954447.03 USD 0.02000000 30/360 ISDA ISDA2006 EUREX B64400 UBSLTD Anonymous

Let me rephrase my question. We expect the following two trades to result we the same sensitivity. However, we are getting two different figures.
Trade 1 sensitivity with known amount: 150416

  <swap>
  	<productType productTypeScheme="http://www.fpml.org/coding-scheme/product-taxonomy">InterestRate:IRSwap:FixedFloat</productType>
  	<swapStream id="floatLeg">
  		<payerPartyReference href="party2"/>
  		<receiverPartyReference href="party1"/>
  		<calculationPeriodDates id="floatingLegCalcPeriodDates_2244828">
  			<effectiveDate>
  				<unadjustedDate>2016-10-26</unadjustedDate>
  				<dateAdjustments>
  					<businessDayConvention>NONE</businessDayConvention>
  				</dateAdjustments>
  			</effectiveDate>
  			<terminationDate>
  				<unadjustedDate>2026-10-26</unadjustedDate>
  				<dateAdjustments>
  					<businessDayConvention>MODFOLLOWING</businessDayConvention>
  					<businessCenters>
  						<businessCenter>GBLO</businessCenter>
  						<businessCenter>USNY</businessCenter>
  					</businessCenters>
  				</dateAdjustments>
  			</terminationDate>
  			<calculationPeriodDatesAdjustments>
  				<businessDayConvention>MODFOLLOWING</businessDayConvention>
  				<businessCenters>
  					<businessCenter>GBLO</businessCenter>
  					<businessCenter>USNY</businessCenter>
  				</businessCenters>
  			</calculationPeriodDatesAdjustments>
  			<calculationPeriodFrequency>
  				<periodMultiplier>3</periodMultiplier>
  				<period>M</period>
  				<rollConvention>26</rollConvention>
  			</calculationPeriodFrequency>
  		</calculationPeriodDates>
  		<paymentDates>
  			<calculationPeriodDatesReference href="floatingLegCalcPeriodDates_2244828"/>
  			<paymentFrequency>
  				<periodMultiplier>1</periodMultiplier>
  				<period>T</period>
  			</paymentFrequency>
  			<payRelativeTo>CalculationPeriodEndDate</payRelativeTo>
  			<paymentDatesAdjustments>
  				<businessDayConvention>MODFOLLOWING</businessDayConvention>
  				<businessCenters>
  					<businessCenter>GBLO</businessCenter>
  					<businessCenter>USNY</businessCenter>
  				</businessCenters>
  			</paymentDatesAdjustments>
  		</paymentDates>
  		<resetDates id="floatingLegresetDates_2244828">
  			<calculationPeriodDatesReference href="floatingLegCalcPeriodDates_2244828"/>
  			<resetRelativeTo>CalculationPeriodStartDate</resetRelativeTo>
  			<fixingDates>
  				<periodMultiplier>-2</periodMultiplier>
  				<period>D</period>
  				<dayType>Business</dayType>
  				<businessDayConvention>NONE</businessDayConvention>
  				<businessCenters>
  					<businessCenter>GBLO</businessCenter>
  				</businessCenters>
  				<dateRelativeTo href="floatingLegresetDates_2244828"/>
  			</fixingDates>
  			<resetFrequency>
  				<periodMultiplier>3</periodMultiplier>
  				<period>M</period>
  			</resetFrequency>
  			<resetDatesAdjustments>
  				<businessDayConvention>MODFOLLOWING</businessDayConvention>
  				<businessCenters>
  					<businessCenter>GBLO</businessCenter>
  					<businessCenter>USNY</businessCenter>
  				</businessCenters>
  			</resetDatesAdjustments>
  		</resetDates>
  		<calculationPeriodAmount>
  			<calculation>
  				<notionalSchedule>
  					<notionalStepSchedule>
  						<initialValue>81954447.03</initialValue>
  						<currency>USD</currency>
  					</notionalStepSchedule>
  				</notionalSchedule>
  				<floatingRateCalculation>
  					<floatingRateIndex>USD-LIBOR-BBA</floatingRateIndex>
  					<indexTenor>
  						<periodMultiplier>3</periodMultiplier>
  						<period>M</period>
  					</indexTenor>
  				</floatingRateCalculation>
  				<dayCountFraction>ACT/360</dayCountFraction>
  				<compoundingMethod>Straight</compoundingMethod>
  			</calculation>
  		</calculationPeriodAmount>
  	</swapStream>
  	<swapStream id="fixedLeg">
  		<payerPartyReference href="party1"/>
  		<receiverPartyReference href="party2"/>
  		<calculationPeriodDates id="fixedLegCalcPeriodDates_2244828">
  			<effectiveDate>
  				<unadjustedDate>2016-10-26</unadjustedDate>
  				<dateAdjustments>
  					<businessDayConvention>NONE</businessDayConvention>
  				</dateAdjustments>
  			</effectiveDate>
  			<terminationDate>
  				<unadjustedDate>2026-10-26</unadjustedDate>
  				<dateAdjustments>
  					<businessDayConvention>MODFOLLOWING</businessDayConvention>
  					<businessCenters>
  						<businessCenter>GBLO</businessCenter>
  						<businessCenter>USNY</businessCenter>
  					</businessCenters>
  				</dateAdjustments>
  			</terminationDate>
  			<calculationPeriodDatesAdjustments>
  				<businessDayConvention>MODFOLLOWING</businessDayConvention>
  				<businessCenters>
  					<businessCenter>GBLO</businessCenter>
  					<businessCenter>USNY</businessCenter>
  				</businessCenters>
  			</calculationPeriodDatesAdjustments>
  			<calculationPeriodFrequency>
  				<periodMultiplier>6</periodMultiplier>
  				<period>M</period>
  				<rollConvention>26</rollConvention>
  			</calculationPeriodFrequency>
  		</calculationPeriodDates>
  		<paymentDates>
  			<calculationPeriodDatesReference href="fixedLegCalcPeriodDates_2244828"/>
  			<paymentFrequency>
  				<periodMultiplier>1</periodMultiplier>
  				<period>T</period>
  			</paymentFrequency>
  			<payRelativeTo>CalculationPeriodEndDate</payRelativeTo>
  			<paymentDatesAdjustments>
  				<businessDayConvention>MODFOLLOWING</businessDayConvention>
  				<businessCenters>
  					<businessCenter>GBLO</businessCenter>
  					<businessCenter>USNY</businessCenter>
  				</businessCenters>
  			</paymentDatesAdjustments>
  		</paymentDates>
  		<calculationPeriodAmount>
  			<knownAmountSchedule>
  				<initialValue>100000000</initialValue>
  				<currency>USD</currency>
  			</knownAmountSchedule>
  		</calculationPeriodAmount>
  	</swapStream>
  </swap>

Trade 2 sensitivity with Initial value: 76324

> 		<swap>
> 			<productType productTypeScheme="http://www.fpml.org/coding-scheme/product-taxonomy">InterestRate:IRSwap:FixedFloat</productType>
> 			<swapStream id="floatLeg">
> 				<payerPartyReference href="party2"/>
> 				<receiverPartyReference href="party1"/>
> 				<calculationPeriodDates id="floatingLegCalcPeriodDates_2244828">
> 					<effectiveDate>
> 						<unadjustedDate>2016-10-26</unadjustedDate>
> 						<dateAdjustments>
> 							<businessDayConvention>NONE</businessDayConvention>
> 						</dateAdjustments>
> 					</effectiveDate>
> 					<terminationDate>
> 						<unadjustedDate>2026-10-26</unadjustedDate>
> 						<dateAdjustments>
> 							<businessDayConvention>MODFOLLOWING</businessDayConvention>
> 							<businessCenters>
> 								<businessCenter>GBLO</businessCenter>
> 								<businessCenter>USNY</businessCenter>
> 							</businessCenters>
> 						</dateAdjustments>
> 					</terminationDate>
> 					<calculationPeriodDatesAdjustments>
> 						<businessDayConvention>MODFOLLOWING</businessDayConvention>
> 						<businessCenters>
> 							<businessCenter>GBLO</businessCenter>
> 							<businessCenter>USNY</businessCenter>
> 						</businessCenters>
> 					</calculationPeriodDatesAdjustments>
> 					<calculationPeriodFrequency>
> 						<periodMultiplier>3</periodMultiplier>
> 						<period>M</period>
> 						<rollConvention>26</rollConvention>
> 					</calculationPeriodFrequency>
> 				</calculationPeriodDates>
> 				<paymentDates>
> 					<calculationPeriodDatesReference href="floatingLegCalcPeriodDates_2244828"/>
> 					<paymentFrequency>
> 						<periodMultiplier>1</periodMultiplier>
> 						<period>T</period>
> 					</paymentFrequency>
> 					<payRelativeTo>CalculationPeriodEndDate</payRelativeTo>
> 					<paymentDatesAdjustments>
> 						<businessDayConvention>MODFOLLOWING</businessDayConvention>
> 						<businessCenters>
> 							<businessCenter>GBLO</businessCenter>
> 							<businessCenter>USNY</businessCenter>
> 						</businessCenters>
> 					</paymentDatesAdjustments>
> 				</paymentDates>
> 				<resetDates id="floatingLegresetDates_2244828">
> 					<calculationPeriodDatesReference href="floatingLegCalcPeriodDates_2244828"/>
> 					<resetRelativeTo>CalculationPeriodStartDate</resetRelativeTo>
> 					<fixingDates>
> 						<periodMultiplier>-2</periodMultiplier>
> 						<period>D</period>
> 						<dayType>Business</dayType>
> 						<businessDayConvention>NONE</businessDayConvention>
> 						<businessCenters>
> 							<businessCenter>GBLO</businessCenter>
> 						</businessCenters>
> 						<dateRelativeTo href="floatingLegresetDates_2244828"/>
> 					</fixingDates>
> 					<resetFrequency>
> 						<periodMultiplier>3</periodMultiplier>
> 						<period>M</period>
> 					</resetFrequency>
> 					<resetDatesAdjustments>
> 						<businessDayConvention>MODFOLLOWING</businessDayConvention>
> 						<businessCenters>
> 							<businessCenter>GBLO</businessCenter>
> 							<businessCenter>USNY</businessCenter>
> 						</businessCenters>
> 					</resetDatesAdjustments>
> 				</resetDates>
> 				<calculationPeriodAmount>
> 					<calculation>
> 						<notionalSchedule>
> 							<notionalStepSchedule>
> 								<initialValue>81954447.03</initialValue>
> 								<currency>USD</currency>
> 							</notionalStepSchedule>
> 						</notionalSchedule>
> 						<floatingRateCalculation>
> 							<floatingRateIndex>USD-LIBOR-BBA</floatingRateIndex>
> 							<indexTenor>
> 								<periodMultiplier>3</periodMultiplier>
> 								<period>M</period>
> 							</indexTenor>
> 						</floatingRateCalculation>
> 						<dayCountFraction>ACT/360</dayCountFraction>
> 						<compoundingMethod>Straight</compoundingMethod>
> 					</calculation>
> 				</calculationPeriodAmount>
> 			</swapStream>
> 			<swapStream id="fixedLeg">
> 				<payerPartyReference href="party1"/>
> 				<receiverPartyReference href="party2"/>
> 				<calculationPeriodDates id="fixedLegCalcPeriodDates_2244828">
> 					<effectiveDate>
> 						<unadjustedDate>2016-10-26</unadjustedDate>
> 						<dateAdjustments>
> 							<businessDayConvention>NONE</businessDayConvention>
> 						</dateAdjustments>
> 					</effectiveDate>
> 					<terminationDate>
> 						<unadjustedDate>2026-10-26</unadjustedDate>
> 						<dateAdjustments>
> 							<businessDayConvention>MODFOLLOWING</businessDayConvention>
> 							<businessCenters>
> 								<businessCenter>GBLO</businessCenter>
> 								<businessCenter>USNY</businessCenter>
> 							</businessCenters>
> 						</dateAdjustments>
> 					</terminationDate>
> 					<calculationPeriodDatesAdjustments>
> 						<businessDayConvention>MODFOLLOWING</businessDayConvention>
> 						<businessCenters>
> 							<businessCenter>GBLO</businessCenter>
> 							<businessCenter>USNY</businessCenter>
> 						</businessCenters>
> 					</calculationPeriodDatesAdjustments>
> 					<calculationPeriodFrequency>
> 						<periodMultiplier>6</periodMultiplier>
> 						<period>M</period>
> 						<rollConvention>26</rollConvention>
> 					</calculationPeriodFrequency>
> 				</calculationPeriodDates>
> 				<paymentDates>
> 					<calculationPeriodDatesReference href="fixedLegCalcPeriodDates_2244828"/>
> 					<paymentFrequency>
> 						<periodMultiplier>1</periodMultiplier>
> 						<period>T</period>
> 					</paymentFrequency>
> 					<payRelativeTo>CalculationPeriodEndDate</payRelativeTo>
> 					<paymentDatesAdjustments>
> 						<businessDayConvention>MODFOLLOWING</businessDayConvention>
> 						<businessCenters>
> 							<businessCenter>GBLO</businessCenter>
> 							<businessCenter>USNY</businessCenter>
> 						</businessCenters>
> 					</paymentDatesAdjustments>
> 				</paymentDates>
> 				<calculationPeriodAmount>
> 					<calculation>
> 						<notionalSchedule>
> 							<notionalStepSchedule>
> 								<initialValue>81954447.03</initialValue>
> 								<currency>USD</currency>
> 							</notionalStepSchedule>
> 						</notionalSchedule>
> 						<fixedRateSchedule>
> 							<initialValue>0.02000000</initialValue>
> 						</fixedRateSchedule>
> 						<dayCountFraction>30/360</dayCountFraction>
> 					</calculation>
> 				</calculationPeriodAmount>
> 			</swapStream>
> 		</swap>

These trades differ only in the definition of the fixed leg payments. The first says:

      <calculationPeriodAmount>
        <knownAmountSchedule>
          <initialValue>100000000</initialValue>
          <currency>USD</currency>
        </knownAmountSchedule>
      </calculationPeriodAmount>

This is a single payment of 100 million at the end. The accrual frequency is not relevant. If working correctly, I’d expect one instance of KnownAmountSwapPaymentPeriod within the ResolvedSwapLeg. This period would only be sensitive to the discount curve, not the Ibor forward curve.

The second says:

      <calculationPeriodAmount>
        <calculation>
          <notionalSchedule>
            <notionalStepSchedule>
              <initialValue>81954447.03</initialValue>
              <currency>USD</currency>
            </notionalStepSchedule>
          </notionalSchedule>
          <fixedRateSchedule>
            <initialValue>0.02000000</initialValue>
          </fixedRateSchedule>
          <dayCountFraction>30/360</dayCountFraction>
        </calculation>
      </calculationPeriodAmount>

This is 2% interest on 81.954447 million, which accrues every 6 months for 10 years and pays once at the end. Since the FpML trade does not specify the compoundingMethod, it is in fact an invalid FpML trade, see here and here. When not specified, Strata defaults to no compounding. Does 2% interest calculated every six months over 10 years with no compounding result in a total payment of 100M? I suspect not.

Thank you for the response.
When processing fixed leg having a compoundingMethod, sensitivity figures seems accurate. However, when processing the trade with the knownAmount the figures are still different.
Are you expecting interest rates for the floating leg and discount rates for the fixed leg?

Not sure what you mean. A vanilla fixed-Ibor swap will typically price against two curves, one providing a discount factors (the discounting curve) and one providing a prediction of the future of the Ibor index (the forward curve). A fixed leg, by definition, has no reference to an Ibor index. As such, it is only sensitive to the discounting curve. Whereas, the floating leg will be sensitive to both the discounting and forward curve.

Thanks Stephen,
following your answer,
We use code version 1.1. While we debug your code, the swap above (fpml msg with knownAmount element) is parsed as “KnownAmountSwapLeg” , there is no clue for “ResolvedSwapLeg” you mentioned in your previous answer.
Maybe your FPML parser is out of sync with this new addition, if so, do we need to create another parser with the new leg type “ResolvedSwapLeg” within the new element “KnownAmountSwapPaymentPeriod” (v1.1) ?
If not, I probably miss something…

The FpML parser creates an instanceof KnownAmountSwapLeg. However, in order to be priced, the leg has to be “resolved”. This involves a call to resolve(ReferenceData). The result of that method call is an instance of ResolvedSwapLeg that holds one or more KnownAmountSwapPaymentPeriod instances. It is this resolved swap leg that is used in pricing.