Skip to content

Entity–relationship model

使用Entity–relationship model可以描述非常多在计算机科学、实际生活中的问题。

wikipedia Entity–relationship model

wikipedia Cardinality (data modeling)

NOTE: Cardinality 的中文意思是“基数”

One-to-one relation model

wikipedia One-to-one (data model)

One-to-many relation model

wikipedia One-to-many (data model)

一对多关系使用有向图来表示就是一个节点与多个节点相邻,相邻节点都有边指向它。

Example

1、polymorphism 多态

2、race condition

3、对于单核CPU、支持multitask的OS,则多个process共享一个CPU,这也是一种one-to-many relation

4、thread共享process的resource

4、多个process共享computer resource。

many-to-many relation model

wikipedia Many-to-many (data model)

Example

一个典型的例子就是多核CPU

READING LIST

https://fmhelp.filemaker.com/help/18/fmp/en/index.html#page/FMP_Help/many-to-many-relationships.html

https://support.airtable.com/hc/en-us/articles/218734758-A-beginner-s-guide-to-many-to-many-relationships

https://dzone.com/articles/how-to-handle-a-many-to-many-relationship-in-datab