pyfeyn2.feynmandiagram.Connector

class pyfeyn2.feynmandiagram.Connector(*args, **kwargs)[source]

Bases: Connector

__init__(*args, **kwargs)[source]

Deprecated since version 2.2.6.

Methods

__init__(*args, **kwargs)

Deprecated since version 2.2.6.

get_length()

Get length of the connector

get_style_property(key)

get_tension()

Get tension of the connector

goes_into(vertex)

goes_out_of(vertex)

is_anti()

Return True if the particle is an anti particle, False otherwise.

is_anti_fermion()

Return True if the particle is an anti fermion, False otherwise.

is_any_fermion()

Return True if the particle is a fermion or anti fermion, False otherwise.

is_fermion()

Return True if the particle is a fermion, False otherwise.

put_style(key, value)

Deprecated since version 0.0.0.

put_styles(**kwargs)

Deprecated since version 0.0.0.

raw_style()

with_class(clazz)

with_color(color)

with_id(id)

set id

with_label(value[, k])

Set label to value and return self.

with_length(length)

Add length to the connector

with_momentum(value[, k])

Set momentum to value and return self.

with_name(value[, k])

Set name to value and return self.

with_new_id()

generate new id

with_particle(value[, k])

Set particle to value and return self.

with_pdgid(value[, k])

Set pdgid to value and return self.

with_style(style)

with_style_properties(**kwargs)

with_style_property(key, value)

with_tension(tension)

Add tension to the connector

with_type(value[, k])

Set type to value and return self.

Attributes

clazz

CSS class string.

id

label

momentum

Momentum of the connector

name

Name of the particle

particle

Particle object from the particle package

pdgid

PDG ID of the particle

type

Type of the particle, e.g.

style

CSS style string.

clazz: str | None = None

CSS class string.

get_length()[source]

Get length of the connector

get_tension()[source]

Get tension of the connector

is_anti()

Return True if the particle is an anti particle, False otherwise.

is_anti_fermion()

Return True if the particle is an anti fermion, False otherwise.

is_any_fermion()

Return True if the particle is a fermion or anti fermion, False otherwise.

is_fermion()

Return True if the particle is a fermion, False otherwise.

momentum: Momentum | None = None

Momentum of the connector

name: str | None = None

Name of the particle

particle: Particle | None = None

Particle object from the particle package

pdgid: int | None = None

PDG ID of the particle

put_style(key, value)

Deprecated since version 0.0.0.

put_styles(**kwargs)

Deprecated since version 0.0.0.

style: CSSString

CSS style string.

type: str | None = None

Type of the particle, e.g. fermion, boson, etc.

with_id(id: str)

set id

with_label(value, k='label')

Set label to value and return self.

with_length(length: float)[source]

Add length to the connector

with_momentum(value, k='momentum')

Set momentum to value and return self.

with_name(value, k='name')

Set name to value and return self.

with_new_id()

generate new id

with_particle(value, k='particle')

Set particle to value and return self.

with_pdgid(value, k='pdgid')

Set pdgid to value and return self.

with_tension(tension: float)[source]

Add tension to the connector

with_type(value, k='type')

Set type to value and return self.