This document contains a summary of a lecture on graph analytics and complexity by Dr. Animesh Chaturvedi. It includes questions and answers on graph algorithms like minimum spanning tree (MST), single-source shortest path (SSSP) problems, and the Agrawal–Kayal–Saxena primality test. Sample algorithms are provided to calculate the average MST and average SSP of multiple graphs by combining the graphs and running standard algorithms. The document is in English and other languages with thank you messages at the end.
Numerical Methods in Mechanical Engineering - Final ProjectStasik Nemirovsky
Final Project for the class of "Numerical Methods in Mechanical Engineering" - MECH 309.
In this project, various engineering problems were analyzed and solved using advanced numerical approximation methods and MATLAB software.
In computer science, divide and conquer (D&C) is an algorithm design paradigm based on multi-branched recursion. A divide and conquer algorithm works by recursively breaking down a problem into two or more sub-problems of the same (or related) type, until these become simple enough to be solved directly. The solutions to the sub-problems are then combined to give a solution to the original problem.
In computer science, merge sort (also commonly spelled mergesort) is an O(n log n) comparison-based sorting algorithm. Most implementations produce a stable sort, which means that the implementation preserves the input order of equal elements in the sorted output. Mergesort is a divide and conquer algorithm that was invented by John von Neumann in 1945. A detailed description and analysis of bottom-up mergesort appeared in a report by Goldstine and Neumann as early as 1948.
Divide and Conquer Algorithms - D&C forms a distinct algorithm design technique in computer science, wherein a problem is solved by repeatedly invoking the algorithm on smaller occurrences of the same problem. Binary search, merge sort, Euclid's algorithm can all be formulated as examples of divide and conquer algorithms. Strassen's algorithm and Nearest Neighbor algorithm are two other examples.
Dynamic Programming design technique is one of the fundamental algorithm design techniques, and possibly one of the ones that are hardest to master for those who did not study it formally. In these slides (which are continuation of part 1 slides), we cover two problems: maximum value contiguous subarray, and maximum increasing subsequence.
International Journal of Engineering Research and Applications (IJERA) is an open access online peer reviewed international journal that publishes research and review articles in the fields of Computer Science, Neural Networks, Electrical Engineering, Software Engineering, Information Technology, Mechanical Engineering, Chemical Engineering, Plastic Engineering, Food Technology, Textile Engineering, Nano Technology & science, Power Electronics, Electronics & Communication Engineering, Computational mathematics, Image processing, Civil Engineering, Structural Engineering, Environmental Engineering, VLSI Testing & Low Power VLSI Design etc.
Numerical Methods in Mechanical Engineering - Final ProjectStasik Nemirovsky
Final Project for the class of "Numerical Methods in Mechanical Engineering" - MECH 309.
In this project, various engineering problems were analyzed and solved using advanced numerical approximation methods and MATLAB software.
In computer science, divide and conquer (D&C) is an algorithm design paradigm based on multi-branched recursion. A divide and conquer algorithm works by recursively breaking down a problem into two or more sub-problems of the same (or related) type, until these become simple enough to be solved directly. The solutions to the sub-problems are then combined to give a solution to the original problem.
In computer science, merge sort (also commonly spelled mergesort) is an O(n log n) comparison-based sorting algorithm. Most implementations produce a stable sort, which means that the implementation preserves the input order of equal elements in the sorted output. Mergesort is a divide and conquer algorithm that was invented by John von Neumann in 1945. A detailed description and analysis of bottom-up mergesort appeared in a report by Goldstine and Neumann as early as 1948.
Divide and Conquer Algorithms - D&C forms a distinct algorithm design technique in computer science, wherein a problem is solved by repeatedly invoking the algorithm on smaller occurrences of the same problem. Binary search, merge sort, Euclid's algorithm can all be formulated as examples of divide and conquer algorithms. Strassen's algorithm and Nearest Neighbor algorithm are two other examples.
Dynamic Programming design technique is one of the fundamental algorithm design techniques, and possibly one of the ones that are hardest to master for those who did not study it formally. In these slides (which are continuation of part 1 slides), we cover two problems: maximum value contiguous subarray, and maximum increasing subsequence.
International Journal of Engineering Research and Applications (IJERA) is an open access online peer reviewed international journal that publishes research and review articles in the fields of Computer Science, Neural Networks, Electrical Engineering, Software Engineering, Information Technology, Mechanical Engineering, Chemical Engineering, Plastic Engineering, Food Technology, Textile Engineering, Nano Technology & science, Power Electronics, Electronics & Communication Engineering, Computational mathematics, Image processing, Civil Engineering, Structural Engineering, Environmental Engineering, VLSI Testing & Low Power VLSI Design etc.
Response Surface in Tensor Train format for Uncertainty QuantificationAlexander Litvinenko
We apply low-rank Tensor Train format to solve PDEs with uncertain coefficients. First, we approximate uncertain permeability coefficient in TT format, then the operator and then apply iterations to solve stochastic Galerkin system.
Enumeration methods are very important in a variety of settings, both mathematical and applications. For many problems there is actually no real hope to do the enumeration in reasonable time since the number of solutions is so big. This talk is about how to compute at the limit.
The talk is decomposed into:
(a) Regular enumeration procedure where one uses computerized case distinction.
(b) Use of symmetry groups for isomorphism checks.
(c) The augmentation scheme that allows to enumerate object up to isomorphism without keeping the full list in memory.
(d) The homomorphism principle that allows to map a complex problem to a simpler one.
Finite-difference modeling, accuracy, and boundary conditions- Arthur Weglein...Arthur Weglein
This short report gives a brief review on the finite difference modeling method used in MOSRP
and its boundary conditions as a preparation for the Green’s theorem RTM. The first
part gives the finite difference formulae we used and the second part describes the implemented
boundary conditions. The last part, using two examples, points out some impacts of the accuracy
of source fields on the results of modeling.
International Journal of Managing Information Technology (IJMIT)IJMIT JOURNAL
We present an improved SPFA algorithm for the single source shortest path problem. For a random graph, the empirical average time complexity is O(|E|), where |E| is the number of edges of the input network. SPFA maintains a queue of candidate vertices and add a vertex to the queue only if that vertex is relaxed. In the improved SPFA, MinPoP principle is employed to improve the quality of the queue. We theoretically analyse the advantage of this new algorithm and experimentally demonstrate that the algorithm is efficient
An improved spfa algorithm for single source shortest path problem using forw...IJMIT JOURNAL
We present an improved SPFA algorithm for the single source shortest path problem. For a random graph,
the empirical average time complexity is O(|E|), where |E| is the number of edges of the input network.
SPFA maintains a queue of candidate vertices and add a vertex to the queue only if that vertex is relaxed.
In the improved SPFA, MinPoP principle is employed to improve the quality of the queue. We theoretically
analyse the advantage of this new algorithm and experimentally demonstrate that the algorithm is efficient.
An improved spfa algorithm for single source shortest path problem using forw...IJMIT JOURNAL
We present an improved SPFA algorithm for the single source shortest path problem. For a random graph,
the empirical average time complexity is O(|E|), where |E| is the number of edges of the input network.
SPFA maintains a queue of candidate vertices and add a vertex to the queue only if that vertex is relaxed.
In the improved SPFA, MinPoP principle is employed to improve the quality of the queue. We theoretically
analyse the advantage of this new algorithm and experimentally demonstrate that the algorithm is efficient.
Representational State Transfer (REST)
IaaS and Hybrid Cloud
Orchestration & Virtualization: Eucalyptus & Amazon
Content Delivery Network (CDN): Facebook and Akamai
PaaS and Container as a Service (CaaS)
PaaS: Google App Engine (GAE) and Ruby on Rails
CaaS: DockerHub
SaaS and Distributed Version Control (DVC)
SaaS: Facebook Testing (Infer and Sapienz)
DVC: GitHub and Git-LFS
Cloud Security and Privacy policies
NIST Guidelines, GDPR, CDN Security
Representational State Transfer (REST)
IaaS and Hybrid Cloud
Orchestration & Virtualization: Eucalyptus & Amazon
Content Delivery Network (CDN): Facebook and Akamai
PaaS and Container as a Service (CaaS)
PaaS: Google App Engine (GAE) and Ruby on Rails
CaaS: DockerHub
SaaS and Distributed Version Control (DVC)
SaaS: Facebook Testing (Infer and Sapienz)
DVC: GitHub and Git-LFS
Cloud Security and Privacy policies
NIST Guidelines, GDPR, CDN Security
Cloud Service Life-Cycle
Cloud Deployment Scenarios
Cloud Service Development and Testing
Web Service Slicing for Regression Testing of Services
Cloud Service Evolution Analytics
Quality of Service and Service Level Agreement
System of Systems Engineering (SoSE),
System “ilities” (Reliability, Availability, Maintainability, and Changeability),
State Series,
System Evolution Analytics,
System Network Evolution Rules,
System Network Complexity,
System Evolution Recommender
Service Evolution Analytics
P, NP, NP-Complete, and NP-Hard
Reductionism in Algorithms
NP-Completeness and Cooks Theorem
NP-Complete and NP-Hard Problems
Travelling Salesman Problem (TSP)
Travelling Salesman Problem (TSP) - Approximation Algorithms
PRIMES is in P - (A hope for NP problems in P)
Millennium Problems
Conclusions
Systems Analysis,
Systems Design,
Systems Modelling,
Systems Architecture,
System Development and Testing,
System Maintenance and Evolution,
SDLC example (Cloud Service life cycle)
Requirements Engineering,
Functional and Non-Functional Requirements,
Engineering Design Process and Process Engineering,
Logistics Management,
Risk management, and
Requirements specification
Complex systems,
Software systems,
Database systems,
Operating systems,
Bioinformatics systems,
Social Systems,
Service Oriented Systems,
Cloud Systems,
Ubiquitous systems,
Distributed Version Control Systems (GitHub), and
Software Container Systems (DockerHub and Google App Engine).
Interdisciplinary Science, Engineering, and Management,
Systems theory,
Systems thinking,
System development life cycles,
Synergy,
Project management,
Engineering Domains (Industry 4.0) , and
Communities (INCOSE and IEEE SMC Society).
1. Big Data Analytics
- Big Data
- Spark: Big Data Analytics
- Resilient Distributed Datasets (RDD)
- Spark libraries (SQL, DataFrames, MLlib for machine learning, GraphX, and Streaming)
- PFP: Parallel FP-Growth
2. Ubiquitous Computing
- Edge Computing
- Cloudlet
- Fog computing
- Internet of Things (IoT)
- Virtualization
- Virtual Conferencing
- Virtual Events (2D, 3D, and Hybrid)
1. Representational State Transfer (REST)
2. IaaS and Hybrid Cloud
- Orchestration & Virtualization: Eucalyptus & Amazon
- Content Delivery Network (CDN): Facebook and Akamai
3. PaaS and Container as a Service (CaaS)
- PaaS: Google App Engine (GAE) and Ruby on Rails
- CaaS: DockerHub
4. SaaS and Distributed Version Control (DVC)
- SaaS: Facebook Testing (Infer and Sapienz)
- DVC: GitHub and Git-LFS
5. Cloud Security and Privacy policies
- NIST Guidelines, GDPR, and CDN Security
1. Cloud Life-Cycle
2. Cloud Deployment Scenario
3. Cloud Service Development and Testing
4. Web Service Slicing for Regression Testing of Services
5. Cloud Service Evolution Analytics
6. Quality of Service and Service Level Agreement
Transcript: Selling digital books in 2024: Insights from industry leaders - T...BookNet Canada
The publishing industry has been selling digital audiobooks and ebooks for over a decade and has found its groove. What’s changed? What has stayed the same? Where do we go from here? Join a group of leading sales peers from across the industry for a conversation about the lessons learned since the popularization of digital books, best practices, digital book supply chain management, and more.
Link to video recording: https://bnctechforum.ca/sessions/selling-digital-books-in-2024-insights-from-industry-leaders/
Presented by BookNet Canada on May 28, 2024, with support from the Department of Canadian Heritage.
Software Delivery At the Speed of AI: Inflectra Invests In AI-Powered QualityInflectra
In this insightful webinar, Inflectra explores how artificial intelligence (AI) is transforming software development and testing. Discover how AI-powered tools are revolutionizing every stage of the software development lifecycle (SDLC), from design and prototyping to testing, deployment, and monitoring.
Learn about:
• The Future of Testing: How AI is shifting testing towards verification, analysis, and higher-level skills, while reducing repetitive tasks.
• Test Automation: How AI-powered test case generation, optimization, and self-healing tests are making testing more efficient and effective.
• Visual Testing: Explore the emerging capabilities of AI in visual testing and how it's set to revolutionize UI verification.
• Inflectra's AI Solutions: See demonstrations of Inflectra's cutting-edge AI tools like the ChatGPT plugin and Azure Open AI platform, designed to streamline your testing process.
Whether you're a developer, tester, or QA professional, this webinar will give you valuable insights into how AI is shaping the future of software delivery.
Essentials of Automations: Optimizing FME Workflows with ParametersSafe Software
Are you looking to streamline your workflows and boost your projects’ efficiency? Do you find yourself searching for ways to add flexibility and control over your FME workflows? If so, you’re in the right place.
Join us for an insightful dive into the world of FME parameters, a critical element in optimizing workflow efficiency. This webinar marks the beginning of our three-part “Essentials of Automation” series. This first webinar is designed to equip you with the knowledge and skills to utilize parameters effectively: enhancing the flexibility, maintainability, and user control of your FME projects.
Here’s what you’ll gain:
- Essentials of FME Parameters: Understand the pivotal role of parameters, including Reader/Writer, Transformer, User, and FME Flow categories. Discover how they are the key to unlocking automation and optimization within your workflows.
- Practical Applications in FME Form: Delve into key user parameter types including choice, connections, and file URLs. Allow users to control how a workflow runs, making your workflows more reusable. Learn to import values and deliver the best user experience for your workflows while enhancing accuracy.
- Optimization Strategies in FME Flow: Explore the creation and strategic deployment of parameters in FME Flow, including the use of deployment and geometry parameters, to maximize workflow efficiency.
- Pro Tips for Success: Gain insights on parameterizing connections and leveraging new features like Conditional Visibility for clarity and simplicity.
We’ll wrap up with a glimpse into future webinars, followed by a Q&A session to address your specific questions surrounding this topic.
Don’t miss this opportunity to elevate your FME expertise and drive your projects to new heights of efficiency.
DevOps and Testing slides at DASA ConnectKari Kakkonen
My and Rik Marselis slides at 30.5.2024 DASA Connect conference. We discuss about what is testing, then what is agile testing and finally what is Testing in DevOps. Finally we had lovely workshop with the participants trying to find out different ways to think about quality and testing in different parts of the DevOps infinity loop.
Key Trends Shaping the Future of Infrastructure.pdfCheryl Hung
Keynote at DIGIT West Expo, Glasgow on 29 May 2024.
Cheryl Hung, ochery.com
Sr Director, Infrastructure Ecosystem, Arm.
The key trends across hardware, cloud and open-source; exploring how these areas are likely to mature and develop over the short and long-term, and then considering how organisations can position themselves to adapt and thrive.
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...UiPathCommunity
💥 Speed, accuracy, and scaling – discover the superpowers of GenAI in action with UiPath Document Understanding and Communications Mining™:
See how to accelerate model training and optimize model performance with active learning
Learn about the latest enhancements to out-of-the-box document processing – with little to no training required
Get an exclusive demo of the new family of UiPath LLMs – GenAI models specialized for processing different types of documents and messages
This is a hands-on session specifically designed for automation developers and AI enthusiasts seeking to enhance their knowledge in leveraging the latest intelligent document processing capabilities offered by UiPath.
Speakers:
👨🏫 Andras Palfi, Senior Product Manager, UiPath
👩🏫 Lenka Dulovicova, Product Program Manager, UiPath
Search and Society: Reimagining Information Access for Radical FuturesBhaskar Mitra
The field of Information retrieval (IR) is currently undergoing a transformative shift, at least partly due to the emerging applications of generative AI to information access. In this talk, we will deliberate on the sociotechnical implications of generative AI for information access. We will argue that there is both a critical necessity and an exciting opportunity for the IR community to re-center our research agendas on societal needs while dismantling the artificial separation between the work on fairness, accountability, transparency, and ethics in IR and the rest of IR research. Instead of adopting a reactionary strategy of trying to mitigate potential social harms from emerging technologies, the community should aim to proactively set the research agenda for the kinds of systems we should build inspired by diverse explicitly stated sociotechnical imaginaries. The sociotechnical imaginaries that underpin the design and development of information access technologies needs to be explicitly articulated, and we need to develop theories of change in context of these diverse perspectives. Our guiding future imaginaries must be informed by other academic fields, such as democratic theory and critical theory, and should be co-developed with social science scholars, legal scholars, civil rights and social justice activists, and artists, among others.
Accelerate your Kubernetes clusters with Varnish CachingThijs Feryn
A presentation about the usage and availability of Varnish on Kubernetes. This talk explores the capabilities of Varnish caching and shows how to use the Varnish Helm chart to deploy it to Kubernetes.
This presentation was delivered at K8SUG Singapore. See https://feryn.eu/presentations/accelerate-your-kubernetes-clusters-with-varnish-caching-k8sug-singapore-28-2024 for more details.
UiPath Test Automation using UiPath Test Suite series, part 4DianaGray10
Welcome to UiPath Test Automation using UiPath Test Suite series part 4. In this session, we will cover Test Manager overview along with SAP heatmap.
The UiPath Test Manager overview with SAP heatmap webinar offers a concise yet comprehensive exploration of the role of a Test Manager within SAP environments, coupled with the utilization of heatmaps for effective testing strategies.
Participants will gain insights into the responsibilities, challenges, and best practices associated with test management in SAP projects. Additionally, the webinar delves into the significance of heatmaps as a visual aid for identifying testing priorities, areas of risk, and resource allocation within SAP landscapes. Through this session, attendees can expect to enhance their understanding of test management principles while learning practical approaches to optimize testing processes in SAP environments using heatmap visualization techniques
What will you get from this session?
1. Insights into SAP testing best practices
2. Heatmap utilization for testing
3. Optimization of testing processes
4. Demo
Topics covered:
Execution from the test manager
Orchestrator execution result
Defect reporting
SAP heatmap example with demo
Speaker:
Deepak Rai, Automation Practice Lead, Boundaryless Group and UiPath MVP
State of ICS and IoT Cyber Threat Landscape Report 2024 previewPrayukth K V
The IoT and OT threat landscape report has been prepared by the Threat Research Team at Sectrio using data from Sectrio, cyber threat intelligence farming facilities spread across over 85 cities around the world. In addition, Sectrio also runs AI-based advanced threat and payload engagement facilities that serve as sinks to attract and engage sophisticated threat actors, and newer malware including new variants and latent threats that are at an earlier stage of development.
The latest edition of the OT/ICS and IoT security Threat Landscape Report 2024 also covers:
State of global ICS asset and network exposure
Sectoral targets and attacks as well as the cost of ransom
Global APT activity, AI usage, actor and tactic profiles, and implications
Rise in volumes of AI-powered cyberattacks
Major cyber events in 2024
Malware and malicious payload trends
Cyberattack types and targets
Vulnerability exploit attempts on CVEs
Attacks on counties – USA
Expansion of bot farms – how, where, and why
In-depth analysis of the cyber threat landscape across North America, South America, Europe, APAC, and the Middle East
Why are attacks on smart factories rising?
Cyber risk predictions
Axis of attacks – Europe
Systemic attacks in the Middle East
Download the full report from here:
https://sectrio.com/resources/ot-threat-landscape-reports/sectrio-releases-ot-ics-and-iot-security-threat-landscape-report-2024/
Epistemic Interaction - tuning interfaces to provide information for AI supportAlan Dix
Paper presented at SYNERGY workshop at AVI 2024, Genoa, Italy. 3rd June 2024
https://alandix.com/academic/papers/synergy2024-epistemic/
As machine learning integrates deeper into human-computer interactions, the concept of epistemic interaction emerges, aiming to refine these interactions to enhance system adaptability. This approach encourages minor, intentional adjustments in user behaviour to enrich the data available for system learning. This paper introduces epistemic interaction within the context of human-system communication, illustrating how deliberate interaction design can improve system understanding and adaptation. Through concrete examples, we demonstrate the potential of epistemic interaction to significantly advance human-computer interaction by leveraging intuitive human communication strategies to inform system design and functionality, offering a novel pathway for enriching user-system engagements.
UiPath Test Automation using UiPath Test Suite series, part 3DianaGray10
Welcome to UiPath Test Automation using UiPath Test Suite series part 3. In this session, we will cover desktop automation along with UI automation.
Topics covered:
UI automation Introduction,
UI automation Sample
Desktop automation flow
Pradeep Chinnala, Senior Consultant Automation Developer @WonderBotz and UiPath MVP
Deepak Rai, Automation Practice Lead, Boundaryless Group and UiPath MVP
UiPath Test Automation using UiPath Test Suite series, part 3
Graph Analytics and Complexity Questions and answers
1. Graph Analytics and Complexity
Questions and Answers
by
Dr.Animesh Chaturvedi
Assistant Professor: LNMIIT Jaipur
Post Doctorate: King’s College London &TheAlanTuring Institute
PhD: IIT Indore
9. A5
There could be many ways to answer this question. For example
• CG1: the number of incoming edges to that function, the priority of
calling a procedures, number of variables function B inherits from
function A, time required to call, cost of calling a procedure by a caller
procedure, time or duration of call or request between two
procedures, etc.
• WN2: frequency of the word, memory required to store a word, cost
we must spend in order to connect, number of conjunction between
words.
10. A5
MST3) Average-MST(G1, G2, G3)
n = size of G1
M1 = Prim's-MST(G1)
M2 = Prim's-MST(G2)
M3 = Prim's-MST(G3)
G[n, n] <- Graph
for i=1 to n
for j=1 to n
if M1[i][j]==1 or M2[i][j]==1 or M3[i][j]==1
G[i,j] = 1
else
G[i,j] = 0
return Prim's-MST(G)
11. A5
SP4) Average-SSSP(G1, G2, G3)
n = size of G1
D1 = Dijkstra's-SP(G1)
D2 = Dijkstra's-SP(G2)
D3 = Dijkstra's-SP(G3)
G[n, n] <- Graph
for i=1 to n
for j=1 to n
if D1[i][j]==1 or D2[i][j]==1 or D3[i][j]==1
G[i,j] = 1
else
G[i,j] = 0
return Dijkstra's-SP(G)
12. A5
MST3
int Average-MST(Graph* G1,Graph* G2,Graph* G3){
int min_g1=Algorithm_Prim_MST(G1);
int min_g2=Algorithm_Prim_MST(G2);
int min_g3=Algorithm_Prim_MST(G3);
return (min_g1+min_g2+min_g3)/3;
}
SP4
14. A5
SP4: Average-SSSP(Graph G1, Graph G2, Graph G3):
SP1[]=Algorithm Dijkstra's-SP(G1);
SP2[]=Algorithm Dijkstra's-SP(G2);
SP3[]=Algorithm Dijkstra's-SP(G3);
SP4[]=ceil((sum of element at index i in SP1[], SP2[], SP3[])/3) for i=1
to no. of vertices
return SP4[]
15. A5
MST3
Get MSTs of all the graphs. Combine their edges to make a new graph. Find the MST of this new graph.
Algorithm:
mst1 = PrimsMST(G1)
mst2 = PrimsMST(G2)
mst3 = PrimsMST(G3)
Graph G = new Graph(V: 6)
for all edges of mst1 do
insert edge in G
for all edges of mst2 do
insert edge in G
for all edges of mst2 do
insert edge in G
Graph avgMST = PrimsMST(G);
return avgMST
16. A5
SP4
Get the single source shortest path(SSSP) of all the graphs. After that, the
shortest path for each of the nodes can be taken as the minimum of the 3
SSSPs derived from the given graphs for the required vertex.
Algorithm:
for v of vertex 2 to 6 do
sssp1 = DijkstraSP(G1, 1, v)
sssp2 = DijkstraSP(G2, 1, v)
sssp3 = DijkstraSP(G3, 1, v)
avgSSSP[v] = min(sssp1, sssp2, sssp3)
end
17. A5
MST3. Make MST of the three graphs. Then we find the distance between two vertices on all those MST, take
there average and form a direct edge between those vertices with weight of that edge being the average
calculated earlier. We do this for every vertices pair. The resultant structure would be a completely connected
graph. We take the MST of this graph and that would be the result.
1 Average MST(G1,G2,G3):
2 GM1= Algorithm Prim's-MST(G1)
3 GM2= Algorithm Prim's-MST(G2)
4 GM3= Algorithm Prim's-MST(G3)
5 for all vertices(u, v) // u and v are vertices are one vertices pair
6 w=distance(u,v,GM1,GM2,GM3) // takes average of sum distance
7 Add(A, u, v, w) // Add edge of weight w between u and v in a graph A
8 return Algorithm Prim's-MST(A)
This would help us in order to understand what the average performance and space consumption by all three
methods. It would also tell us how every function is connected to one another and what should be the most
optimal way to define variables.
18. A5
SP4. The approach would be like that of Average-MST
We take Shortest Path between all vertices of the three graphs. Then we find the distance between
two vertices on all those graphs, take there average and form an edge between those vertices with
weight of that edge being the average calculated earlier. We do this for every vertices pair. The
resultant structure would be a completely connected graph. We take the shortest path of this graph
and that would be the result.
1 Average SSSP(G1,G2,G3):
2 GM1= Algorithm Dijkstra-SP(G1)
3 GM2= Algorithm Dijkstra-SP(G2)
4 GM3= Algorithm Dijkstra-SP(G3)
5 for all vertices(u,v) // u and v are vertices are one vertice pair
6 w=distance(u,v,GM1,GM2,GM3) // takes average of sum distance
7 Add(A,u,v,w) // Add edge of weight w between u and v in a graph A
8 return Algorithm Dijkstra-SP(A)
20. A6
• NP1) Calculate probability of each edge.
• NP2) Not reducible to TSP or any other NPC. Because the NP1 is a
simple problem that can be solved by calculating probability (for this
we need to traverse back to the same node, which is not allowed in
TSP), whereas NPCs are NP hard problems.
22. A7
AKS1
• The key idea of AKS primality test is to find the coefficient of xi in ((x+a)n - (xn + a)). If all
coefficients are multiple of n, then n is prime else composite number.
• To get internal elements, remove first and last elements of each row in a Pascal triangle. For a nth
row of a Pascal triangle, the internal element are the coefficients of above equation with a = -1,
then the equation ((x-1)n - (xn -1))
AKS2 For N=19
• ((x-1)19- (x19 -1)) = -19x18 + 171x17 - 969x16 + 3876x15 - 11628x14 + 27132x13 - 50388x12 + 75582x11 -
92378x10 + 92378x9 - 75582x8 + 50388x7 - 27132x6 + 11628x5 - 3876x4 + 969x3 - 171x2 + 19x.
• The coefficient of equation or the internal elements of Pascal triangle row: 1, 19, 171, 969, 3876,
11628, 27132, 50388, 75582, 92378, 92378, 75582, 50388, 27132, 11628, 3876, 969, 171, 19, 1
• Here, each the coefficient or the internal element is the multiple of 19. Therefore, 19 is a prime
number as per AKS.