finesse.tracing.tree.TraceTree.from_node

classmethod TraceTree.from_node(cls, node, dependency, bool symmetric, pre_node=None, bool is_source=False, exclude=None)

Construct a TraceTree from an optical node root.

The resulting tree includes all optical node paths traced forward from node.

Parameters
nodeOpticalNode

The root node.

dependencyCavity or Gauss

The dependency object - i.e. what the trace sub-trees depend on.

symmetricbool

Flag indicating whether the tree should be constructed assuming that opposite node beam parameters will be set via the reverse of the original node beam parameter (true indicates this will be the case). In practice, this means that the resultant tree will not include any duplicate ports.

pre_nodeOpticalNode, optional; default: None

An optional node to add before the root for the root sub-tree.

is_sourcebool, optional; default: False

Whether the root node is the source node of a TraceDependency.

excludeset, optional

Set of optical nodes to avoid branching to.

Returns
treeTraceTree

The tree of all paths from node.