bluemira.radiation_transport.neutronics.wires ============================================= .. py:module:: bluemira.radiation_transport.neutronics.wires .. autoapi-nested-parse:: Info about straight line wires and circles. Made to be simpler to modify than a whole BluemiraWire. Classes ------- .. autoapisummary:: bluemira.radiation_transport.neutronics.wires.StraightLineInfo bluemira.radiation_transport.neutronics.wires.CircleInfo bluemira.radiation_transport.neutronics.wires.WireInfo bluemira.radiation_transport.neutronics.wires.WireInfoList Module Contents --------------- .. py:class:: StraightLineInfo Bases: :py:obj:`NamedTuple` .. autoapi-inheritance-diagram:: bluemira.radiation_transport.neutronics.wires.StraightLineInfo :parts: 1 :private-bases: Key information about a straight line .. py:attribute:: start_point :type: collections.abc.Iterable[float] .. py:attribute:: end_point :type: collections.abc.Iterable[float] .. py:method:: reverse() -> StraightLineInfo Flip the wire's direction .. py:class:: CircleInfo Bases: :py:obj:`NamedTuple` .. autoapi-inheritance-diagram:: bluemira.radiation_transport.neutronics.wires.CircleInfo :parts: 1 :private-bases: Arc of a Circle, LESS THAN 180° .. py:attribute:: start_point :type: collections.abc.Iterable[float] .. py:attribute:: end_point :type: collections.abc.Iterable[float] .. py:attribute:: center :type: collections.abc.Iterable[float] .. py:attribute:: radius :type: float .. py:method:: reverse() -> CircleInfo Flip the wire's direction .. py:class:: WireInfo A tuple to store: 1. the key points about this wire (and what kind of wire this is) 2. The tangent to that wire at the start and end 3. A copy of the wire itself .. py:attribute:: key_points :type: StraightLineInfo | CircleInfo .. py:attribute:: tangents :type: collections.abc.Sequence[collections.abc.Iterable[float]] .. py:attribute:: wire :type: bluemira.geometry.wire.BluemiraWire | None :value: None .. py:method:: reverse() -> WireInfo Flip the wire's direction .. py:method:: from_2P(start_point: numpy.typing.NDArray[numpy.float64], end_point: numpy.typing.NDArray[numpy.float64]) -> WireInfo :classmethod: Create the WireInfo for a straight line (i.e. one where the key_points is of instance StraightLineInfo) using only two points. :returns: A WireInfo representing the straight-line. .. py:class:: WireInfoList(info_list: collections.abc.Iterable[WireInfo]) A class to store info about a series of wires .. py:attribute:: info_list .. py:method:: __len__() -> int Number of wire infos .. py:method:: __getitem__(index_or_slice) -> list[WireInfo] | WireInfo Get a WireInfo .. py:method:: __repr__() -> str String representation .. py:method:: pop(index: int) -> WireInfo Pop one WireInfo out of the list. :returns: The required WireInfo instance popped out of the list. .. py:method:: get_3D_coordinates() -> numpy.typing.NDArray Get the vertices (connecting point between each pair of adjacent wires) in the entire WireInfoList. :returns: A list of 3D-coordinates of the vertices. shape = (N+1, 3). .. py:property:: start_point The start_point for the entire series of wires .. py:property:: end_point The end_point for the entire series of wires .. py:method:: reverse() -> WireInfoList Flip this list of wires .. py:method:: restore_to_wire() -> bluemira.geometry.wire.BluemiraWire Re-create a bluemira wire from a series of WireInfo. :returns: WireInfo reconstructed back into a bluemira wire.