In section 3.2 of this paper [1], where 2D planar frame structures are being analyzed, the authors mentioned a transformation matrix to be used in extracting the element displacement vector from the displacement vector of the ground structure in global coordinates.
$u_i^e = (u_x^{(1)},u_y^{(1)}, \theta^{(1)},u_x^{(2)},u_y^{(2)}, \theta^{(2)})$ is the element $i$'s displacement vector in local coordinates. $$u_i^e=T_i u$$ where $T_i \in \mathbb{R}^ {6\times d}$. What should be the matrix $T_i$?
Note: The same matrices are used to assemble the global stiffness matrix from elements stiffness matrix in local coordinates using the following formula: $$K= \sum_{i\in E}\sum_{j=1}^3 k_{ij}b_{ij}b_{ij}^\top$$ where $b_{i1}, b_{i2},b_{i3}\in \mathbb{R}^d$ are defined by ($\hat{b_{ij}}$ are $6\times 1$ constant vectors):
$$b_{ij}=T_i^\top \hat{b_{ij}}$$
I am not an expert in statics or mechanical concepts but I need these relations for the optimization problem that I am using for my research.
[1] Kureta, Rui, and Yoshihiro Kanno. "A mixed integer programming approach to designing periodic frame structures with negative Poisson’s ratio." Optimization and Engineering 15.3 (2014): 773-800.