联系方式

  • QQ:99515681
  • 邮箱:99515681@qq.com
  • 工作时间:8:00-21:00
  • 微信:codinghelp

您当前位置:首页 >> Python编程Python编程

日期:2024-04-16 09:23

Graph databases [30 marks]

Consider a simple application where walking treks are cycles (it ends where it starts) made up

of sections between two huts, each offering a number #beds of beds and, potentially, showers.

The sections have a distance in kilometers, and treks have a name and location.

Fig. 1. Property Graph

Questions:

1. Write down the formal property graph model (V, E, η, λ, ν) for the property graph in

Figure 1. [6 marks]

2. Write the following English language query in regular property graph logic:

Return the trek nodes that have 2 or 3 sections. [4 marks]

3. Write the following English language query in regular property graph logic:

Find all pairs of hut nodes, each having showers and at least 15 beds, and directly connected by a section. [4 marks]

4. Write the following English language query in regular property graph logic:

Return all trek nodes that have some section, each at most 25kms long and only connecting

huts with showers available. [4 marks]

5. Write down the queries from Questions 2, 3, and 4 in regular property graph algebra.

[12 marks]

2


版权所有:编程辅导网 2021 All Rights Reserved 联系方式:QQ:99515681 微信:codinghelp 电子信箱:99515681@qq.com
免责声明:本站部分内容从网络整理而来,只供参考!如有版权问题可联系本站删除。 站长地图

python代写
微信客服:codinghelp