Skip to content

Yarden-Ankonina/Random-graphs

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 

Repository files navigation

Erdős–Rényi model - Random graph's

This repo contains an implementation to Erdős–Rényi model to test it out as a class assignment.

C++

Main Purpose

We will use graphs with 1000 nodes and check the graph's characteristics :

  1. connectivity
  2. diameter
  3. isolated vertex

  • Write a function to build a random graph with a given connectivity probability - p (0-1)
  • Using a adjacency list to represent the graph
  • Impelment functions for each characteristic
  • Impelment bfs - breadth first seach algorithm to find the diameter
  • Run on 500 Graph's with different connectivity chances and look for conclusions.
  • Make sure program runs in less than 3-4 hours depends on hardware

Thershold

  • To check connectivity we'll define Threshold = lnv(v)/v if the threshold is less than p - the graph should be connected.
  • To check diameter we'll define Threshold = sqrt(2lnv(v)/v) if the threshold is less than p - the graph's diameter should be 2.
  • To check isolated vertex we'll define Threshold = lnv(v)/v if the threshold is less than p - the graph should not have a isolated vertex .

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages