Skip to content

3.21 Chen Diagrams

Julio Toboso edited this page Apr 27, 2026 · 1 revision

“Débil” + “Identificadora” (flowchart estilizado)

flowchart LR
  classDef weak stroke-width:3px,stroke-dasharray: 6 3,rx:6,ry:6
  classDef strong stroke-width:2px

  CLIENTE([CLIENTE]):::strong -->|IDENTIFICA| PAGO([PAGO débil]):::weak
  PAGO ---|"clave parcial: Nº_Pago"| PAGO
Loading

Chen diagrams

flowchart LR
  %% estilos opcionales
  classDef entity stroke-width:2px,rx:6,ry:6
  classDef attr color:#f8f8f8,stroke:#888,rx:20,ry:20
  classDef weak stroke-dasharray:6 3

  %% entidades
  PERSON[PERSON]:::entity
  HOUSE[HOUSE]:::entity

  %% relación (rombo)
  HABITA{HABITA}

  %% atributos ejemplo
  DNI((DNI)):::attr
  nombre((nombre)):::attr
  id_house((id_house)):::attr
  direccion((direccion)):::attr

  %% enganchar atributos a entidades
  DNI --- PERSON
  nombre --- PERSON
  id_house --- HOUSE
  direccion --- HOUSE

  %% cardinalidades como etiquetas en las aristas
  PERSON -- "(1,N)" --> HABITA
  HABITA -- "(0,1)" --> HOUSE

  %% (opcional) entidad débil: aplica clase 'weak' a la caja
  %% ORDER[ORDER]:::weak

Loading
flowchart LR
  %% ==== estilos ====
  classDef entity stroke-width:2px,rx:8,ry:8
  classDef weak stroke-width:3px,stroke-dasharray:6 3,rx:8,ry:8
  classDef rel shape:diamond,stroke-width:2px,rx:4,ry:4
  classDef ident shape:diamond,stroke-width:4px,rx:4,ry:4

  %% ==== nodos ====
  E[Entidad]:::entity
  W[Entidad Débil]:::weak
  R{Relación}:::rel
  I{Vínculo identificador}:::ident

  %% ==== ejemplo de enlaces con cardinalidad (min–max) ====
  E -- "(1,N)" --- R
  R -- "(0,1)" --- W

  %% leyenda visual (opcional)
  %% - Entidad débil: borde discontinuo/grueso
  %% - Vínculo identificador: rombo “más grueso”

Loading
flowchart TB
  %% ==== estilos ====
  classDef entity stroke-width:2px,rx:8,ry:8
  classDef weak stroke-width:3px,stroke-dasharray:6 3,rx:8,ry:8
  classDef rel shape:diamond,stroke-width:2px,rx:4,ry:4
  classDef ident shape:diamond,stroke-width:4px,rx:4,ry:4
  classDef attr fill:#f8f8f8,stroke:#888,rx:20,ry:20

  %% ==== entidades ====
  CLIENTE[CLIENTE]:::entity
  PAGO[PAGO]:::weak

  %% ==== relación identificadora ====
  IDENTIFICA{IDENTIFICA}:::ident

  %% ==== atributos (círculos como ovals) ====
  DNI((DNI)):::attr
  Nombre((nombre)):::attr
  NumPago((Nº_Pago)):::attr
  Importe((importe)):::attr
  Fecha((fecha)):::attr

  %% enganchar atributos a entidades
  CLIENTE --- DNI
  CLIENTE --- Nombre
  PAGO --- NumPago
  PAGO --- Importe
  PAGO --- Fecha

  %% cardinalidades (min–max)
  CLIENTE -- "(1,N)" --> IDENTIFICA
  IDENTIFICA -- "(1,1)" --> PAGO

  %% notas:
  %% - PAGO es entidad débil (depende de CLIENTE + clave parcial Nº_Pago).
  %% - IDENTIFICA es vínculo identificador (participación total de PAGO).

Loading
flowchart TB
  %% ===== Styles (GitHub-safe) =====
  classDef entity stroke-width:2px,rx:8,ry:8
  classDef weak stroke-width:3px,stroke-dasharray:6 3,rx:8,ry:8
  classDef attr fill:#fff,stroke:#555,rx:20,ry:20
  classDef key stroke-width:3px,rx:20,ry:20
  %% Mermaid can't draw a real "double oval"; we simulate multivalued with thicker border + label
  classDef mult stroke-width:4px,rx:22,ry:22
  classDef deriv stroke-dasharray:6 3,rx:20,ry:20
  classDef partial stroke-width:3px,stroke-dasharray:6 2,rx:20,ry:20
  classDef note fill:#f8f8f8,stroke:#ccc,rx:6,ry:6,color:#333,font-size:12px

  %% ===== Example entity (normal) =====
  ENTIDAD[ENTIDAD]:::entity

  %% ===== Attribute types =====
  A1((Atributo)):::attr
  A2((Atributo Clave)):::key
  A3((Email)):::mult
  A4((Nombre)):::attr
  A4a((Nombre_de_pila)):::attr
  A4b((Apellido)):::attr
  A5((Nº_Pago)):::partial
  A6((Edad)):::deriv

  %% ===== Weak entity to host partial key =====
  PEDIDO[ENTIDAD DÉBIL]:::weak

  %% ===== Hooks =====
  ENTIDAD --- A1
  ENTIDAD --- A2
  ENTIDAD --- A3
  ENTIDAD --- A4
  A4 --- A4a
  A4 --- A4b
  PEDIDO --- A5
  ENTIDAD --- A6
Loading

Data

Legend:

  • 🔰 Start here
  • 🏵️ Important Insight
  • ⚙️ Technical and applications
  • 💻 Some Code
  • ⚜️ Advanced Topics

Start

01 · Ω — What could happen

02 · X, 𝒳 — What we observe

03 · p(x) — What we expected

04 · I(x), H(X) — What an observation tells us

05 · Data — What is consistent

06 · Statistics — What we can learn.

07 · Databases - How to store data

08 · μ(x) — Fuzzy - When data is flexible

  • 08.1 Fuzzy Logic (planned)
  • 08.2 Fuzzy Numbers (planned)
  • 08.3 Possibility vs Probability (planned)

09 · x(t) — Signals and systems - Where patterns live

  • 09.1 Signals (stub)
  • 09.2 Sampling and Aliasing (planned)
  • 09.3 Convolution (planned)
  • 09.4 Frequency (planned)

10 · f_θ — Modelling and linear algebra

  • 10.1 🔰 Vectors and Matrices (planned)
  • 10.2 Mathematical Modelling (planned)

11 · min L(θ) — Optimisation

  • 11.1 🔰 Derivatives (planned)
  • 11.2 Convex Optimisation (planned)

12 · Learning from data

13 · Cause, design, capstone

  • 13.1 Cause and Effect (planned)
  • 13.2 Capstone Guide (planned)

Appendix

Clone this wiki locally