feynml.pdgid.PDG

class feynml.pdgid.PDG(id: str | None = None, pdgid: int | None = None, name: str | None = None, texname: str | None = None, type: str | None = None)[source]

Bases: Identifiable

__init__(id: str | None = None, pdgid: int | None = None, name: str | None = None, texname: str | None = None, type: str | None = None) None

Methods

__init__([id, pdgid, name, texname, type])

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.

with_id(id)

set id

with_name(value[, k])

Set name to value and return self.

with_new_id()

generate new id

with_pdgid([pdgid, type, name, feynmodel, sync])

with_texname(value[, k])

Set texname to value and return self.

with_type(value[, k])

Set type to value and return self.

Attributes

id

name

Name of the particle

pdgid

PDG ID of the particle

texname

LaTeX name of the particle

type

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

is_anti()[source]

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

is_anti_fermion()[source]

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

is_any_fermion()[source]

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

is_fermion()[source]

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

name: str | None = None

Name of the particle

pdgid: int | None = None

PDG ID of the particle

texname: str | None = None

LaTeX name of the particle

type: str | None = None

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

with_id(id: str)

set id

with_name(value, k='name')

Set name to value and return self.

with_new_id()

generate new id

with_texname(value, k='texname')

Set texname to value and return self.

with_type(value, k='type')

Set type to value and return self.