Java知识分享网 - 轻松学习从此开始!    

Java知识分享网

Java1234官方群25:java1234官方群17
Java1234官方群25:838462530
        
SpringBoot+SpringSecurity+Vue+ElementPlus权限系统实战课程 震撼发布        

最新Java全栈就业实战课程(免费)

springcloud分布式电商秒杀实战课程

IDEA永久激活

66套java实战课程无套路领取

锋哥开始收Java学员啦!

Python学习路线图

锋哥开始收Java学员啦!

ArangoDB-GraphCourse_Beginners PDF 下载


分享到:
时间:2020-06-18 16:55来源:http://www.java1234.com 作者:小锋  侵权举报
ArangoDB-GraphCourse_Beginners PDF 下载
失效链接处理
ArangoDB-GraphCourse_Beginners PDF 下载


本站整理下载:
 
相关截图:
 
主要内容:

Graph Basics
What is a graph? There are multiple definitions and types. A brief overview: 
In discrete mathematics, a graph is defined as set of vertices and edges. 
In computing it is considered an abstract data type which is really good to 
represent connections or relations – unlike the tabular data structures of 
relational database systems, which are ironically very limited in expressing 
relations. 
A good metaphor for graphs is to think of nodes as circles and edges as 
lines or arcs. The terms node and vertex are used interchangeably here. 
Usually vertices are connected by edges, making up a graph. Vertices don't 
have to be connected, but they may also be connected with more than 
one other vertex via multiple edges. You may also find vertices connected 
to themselves.
7
Vertex 
Edge
Graph Basics
Important types of graphs: 
‣ Undirected – edges connect pairs of nodes without 
having a notion of direction 
‣ Directed – edges have a direction associated with them 
(the lines/arcs have arrow heads in depictions) 
‣ DAG – Directed Acyclic Graph: edges have a direction and 
their are no loops. In the most simple case, this means 
that if you have vertices A and B and an edge from A to 
B, then there must not be another edge from B to A.
One example for a DAG is a tree topology.
8
Graph Basics
In ArangoDB, each edge has a single direction, it can't point 
both ways at once. This model is also known as oriented graph. 
Moreover, edges are always directed, but you can ignore the 
direction (follow in ANY direction) when you walk through the 
graph, or follow edges in reverse direction (INBOUND) instead 
of going in the direction they actually point to (OUTBOUND). 
Walking through a graph is called traversal. 
ArangoDB allows you to store all kinds of graphs in different 
shapes and sizes, with and without cycles. You can save one 
or more edges between two vertices or even the same vertex. 
Also note that edges are full-fledged JSON documents, 
which means you can store as much information on the edges 
as you want!
9
OUTBOUND INBOUND
ANY
Graph Basics
A few examples what can be answered by graph queries with the example dataset in mind: 
‣ Give me all flights departing from JFK (airport in New York)
‣ Give me all flights landing in LAX (airport in Los Angeles) on January 5th 
‣ Which airports can I reach with up to one stopover?
(From one or multiple starting airports) 
‣ Shortest Path: 
‣ What is the minimum amount of stopovers to fly from BIS
(Bismarck Municipal Airport in North Dakota) to LAX and where is the stopover?
‣ Pattern Matching: 
‣ Departing from BIS, which flight to JFK with one stopover
(at least 20 minutes time for the transit) is the quickest and via which airport?
10

 

------分隔线----------------------------

锋哥公众号


锋哥微信


关注公众号
【Java资料站】
回复 666
获取 
66套java
从菜鸡到大神
项目实战课程

锋哥推荐