# Thread: Relations and functions.

1. ## Relations and functions.

Not sure if this is under the section, if not I do apoligize.

Im having a little trouble with the last 2 questions in my example sheet, the others were pretty straights forward, as there was a lot of references on my others.
But I was wondering if someone could throw me a line.

The questions were as follows:
Part C
iii)
Define a relation to show how pages on a website are related.

iv)
Describe and show how you could use relational composition to
identify those pages which are
two links apart. How could you use

relational composition to identify pages which are
n-links apart?

Thanks again and sorry i this is in the wrong sections

JT

2. Define a relation to show how pages on a website are related.
There are many ways to define a relation, but what is probably meant is this: for two pages x and y, R(x,y) is true iff x has a link to y.

Describe and show how you could use relational composition to
identify those pages which are two links apart.
You can get from a page x to a page y by following exactly 2 links iff $R^2(x,y)$. Here $R^2=R\circ R$. This generalizes to n links.

3. Thansk for the swift reply.

JT
{"extraction_info": {"found_math": true, "script_math_tex": 0, "script_math_asciimath": 0, "math_annotations": 0, "math_alttext": 0, "mathml": 0, "mathjax_tag": 0, "mathjax_inline_tex": 0, "mathjax_display_tex": 0, "mathjax_asciimath": 0, "img_math": 0, "codecogs_latex": 2, "wp_latex": 0, "mimetex.cgi": 0, "/images/math/codecogs": 0, "mathtex.cgi": 0, "katex": 0, "math-container": 0, "wp-katex-eq": 0, "align": 0, "equation": 0, "x-ck12": 0, "texerror": 0, "math_score": 0.7924357652664185, "perplexity": 1197.5983047180775}, "config": {"markdown_headings": true, "markdown_code": true, "boilerplate_config": {"ratio_threshold": 0.18, "absolute_threshold": 20, "end_threshold": 15, "enable": false}, "remove_buttons": true, "remove_image_figures": true, "remove_link_clusters": true, "table_config": {"min_rows": 2, "min_cols": 3, "format": "plain"}, "remove_chinese": true, "remove_edit_buttons": true, "extract_latex": true}, "warc_path": "s3://commoncrawl/crawl-data/CC-MAIN-2018-09/segments/1518891813626.7/warc/CC-MAIN-20180221143216-20180221163216-00405.warc.gz"}