Graphs - CS A200 Data Structures

0.0(0)
Studied by 0 people
call kaiCall Kai
Locked
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
GameKnowt Play
Card Sorting

1/26

flashcard set

Earn XP

Description and Tags

Vocabulary flashcards covering fundamental graph data structure terminology, types of edges/graphs, path/cycle definitions, and common computer science representations (Adjacency Matrix/List).

Last updated 11:51 PM on 7/27/26
Name
Mastery
Learn
Test
Matching
Spaced
Call with Kai
Chat

No analytics yet

Send a link to your students to track their progress

27 Terms

1
New cards

Graph

A data structure that consists of a set of vertices (or nodes) and a set of edges (relations) between pair of vertices.

2
New cards

Edges

Represent paths or connections between vertices; represented as line segments joining the vertices.

3
New cards

Vertices

Also known as nodes; represented as points or labeled circles.

4
New cards

Undirected edge

An edge that does not indicate direction, allowing travel in either direction along the edge.

5
New cards

Directed edge

An edge that has a direction, where travel is only possible from the origin (v1v_1) to the destination (v2v_2).

6
New cards

Self-loop edge

An edge (undirected or directed) that originates and ends at the same vertex.

7
New cards

Parallel edges

Two undirected edges with the same end vertices, or two directed edges with the same origin and destination.

8
New cards

Adjacent vertices

Vertices that have an edge connecting one to the other.

9
New cards

Directed graph (digraph)

A graph in which every edge has a direction.

10
New cards

Undirected graph

A graph in which no edge has a direction.

11
New cards

Simple graph

A graph that has no parallel edges and no self-loops.

12
New cards

Weight

A value associated with each edge in a graph representing distance, energy consumption, cost, or other metrics.

13
New cards

Weighted graph

A graph where each edge has an associated weight.

14
New cards

Unweighted graph

A graph where edges do not have associated weights; it may be considered a weighted graph where all edges have a weight of 11.

15
New cards

Degree of a vertex

The number of edges connected to a vertex.

16
New cards

In-degree

In a directed graph, the number of incoming edges to a vertex.

17
New cards

Out-degree

In a directed graph, the number of outgoing edges from a vertex.

18
New cards

Path

A sequence of vertices in which every vertex is adjacent to the next one, beginning and ending with a vertex.

19
New cards

Simple path

A path such that all its vertices and edges are distinct.

20
New cards

Length of a path

The sum of all of the edges that make up the path (e.g., the path SFO-ORD-PVD has a length of 1843+849=26921843 + 849 = 2692).

21
New cards

States

Vertices that represent possible configurations in a graph representation of a game.

22
New cards

Cycle

A circular sequence of alternating vertices and edges (a circular path) where the start and end vertices are identical.

23
New cards

Simple cycle (Undirected)

A path {v0,v1,,vk}\{v_0, v_1, \dots, v_k\} where v0=vkv_0 = v_k, k3k \geq 3, and vertices v1,v2,,vkv_1, v_2, \dots, v_k are distinct.

24
New cards

Simple cycle (Directed)

A path {v0,v1,,vk}\{v_0, v_1, \dots, v_k\} where v0=vkv_0 = v_k, the path contains at least one edge, and vertices v1,v2,,vkv_1, v_2, \dots, v_k are distinct.

25
New cards

Adjacency matrix

A square grid (n×nn \times n) of true/false values stored in a two-dimensional array, where the component at row ii and column jj is true if an edge exists from vertex ii to vertex jj.

26
New cards

Adjacency list

A representation of a graph with nn vertices using nn different linked lists; for each entry jj in list ii, there is an edge from ii to jj.

27
New cards

Sparse graph

A graph where each vertex has only a few edges; an adjacency list is preferred over an adjacency matrix for this type due to space efficiency.