mirror#
- class waveresponse.mirror(rao, dof, sym_plane='xz')[source]#
Mirrors/folds an RAO object about a symmetry plane.
Requires that the RAO is defined for directions that allow folding with the given symmetry plane. I.e., folding about the xz-plane requires that the RAO is defined for directions in the range [0, 180] degrees or [180, 360] degrees. Similarly, folding about the yz-plane requires that the RAO is defined for directions in the range [90, 270] degrees or [270, 90] degrees.
- Parameters:
rao (RAO) – RAO object.
dof ({'surge', 'sway', 'heave', 'roll', 'pitch', 'yaw'}) – Which degree-of-freedom the RAO object represents.
sym_plane ({'xz', 'yz'}) – Symmetry plane, determining which axis to mirror the RAO about.
- Returns:
rao – Extended (mirrored) RAO object.
- Return type:
Examples
If you have an RAO defined only in half the directional domain (e.g., [0, 180] degrees), you can mirror it once about a symmetry plane to obtain the ‘full’ RAO, defined over the whole directional domain:
>>> # Symmetry about xz-plane >>> rao_full = wr.mirror(rao, "heave", sym_plane="xz")
If you have an RAO defined only in one quadrant (e.g., [0, 90] degrees), you can mirror it twise to obtain the ‘full’ RAO, defined over the whole directional domain:
>>> # Symmetry about xz- and yz-plane >>> rao_full = wr.mirror( ... wr.mirror(rao, "heave", sym_plane="xz"), ... "heave", ... sym_plane="yz" ... )