> For the complete documentation index, see [llms.txt](https://risk.infinity.exchange/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://risk.infinity.exchange/risk-matrix/market-risk/correlation.md).

# Correlation

Lending and borrowing positions in Infinity are not exposed to (FX,FX) or (FX,Rates) correlation risks. For example, with an ETH-1D fixed rate lending position, the present value of your 1-day ETH lending position could be expressed in either USD, PV(*USD*), or ETH, PV(*ETH*), terms:

$$
PV\_{USD}=PV\_{ETH}\times FX(0) = \frac{{1 + X \cdot T}}{{(1 + r(0,T))^T}} \cdot FX(0)
$$

"X" is the ETH fixed rate and T= 1 / Actual Days (365, or 366), where:

* PV(USD) is a function of PV(ETH) and FX(0), where PV(ETH) is the zero coupon rate r(0,T), both observed at T=0
  * **=> PV(USD) is not sensitive to the (Rates, FX) correlation**
* PV(ETH) is a linear combination of PV in a similar format to the PV(USD) above
  * **=> PV(ETH) is not sensitive to the (FX, FX) correlation**

Correlation between assets (FX,FX) or (FX,Rates) will be applied during the liquidation order. Similarly, for margining, in particular your [Maintenance Margin](/portfolio-margin/maintenance-margin.md), which depends on the stresses applied [FX](/risk-matrix/market-risk/fx-risk.md) and [Rates](/risk-matrix/market-risk/rates-risk.md) (across the yield curve).

Note: stressing FX and Rates separately and then aggregating their impact is different from stressing Rates and FX simultaneously. To illustrate this point, let’s denote PV=f(r,FX):&#x20;

* If we bump Rates and FX separately, the impact of dPV:

$$
dPV = df = \frac{\partial f}{\partial x} \cdot dx + \frac{\partial f}{\partial y} \cdot dy
$$

* If we bump both Rates and FX simultaneously, the impact of dPV is:

$$
dPV =df= \frac{\partial f}{\partial x} \cdot dx + \frac{\partial f}{\partial y} \cdot dy + \frac{\partial^2f}{\partial x \partial y} \cdot dxdy
$$

In our case:

$$
\frac{\partial^2f}{\partial x \partial y} \ \sim -T\*(1+XT)<0
$$

To maximize the impact (and apply a larger stress for StrNAV), we want dxdy>0, where Rates (r) and FX move in the same direction. In this case,

* The impact of bumping both FX and Rates simultaneously will be greater than adding the individual impacts of bumping FX and Rates in isolation, and vice versa where FX and Rates move in the opposite direction. Though, in practice, one would assume that a rise in the ETH/USD FX would be positively correlated with ETH Rates.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://risk.infinity.exchange/risk-matrix/market-risk/correlation.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
