deepayan@isid.ac.in
>Date | Title | Group |
---|---|---|
2024-04-03 | Accept-reject + ziggurat algorithm for N(0, 1) | Sourav Biswas, Rupanjan Mukherjee |
2024-04-03 | Markov Chain Monte Carlo | Arpan Dutta, Soumyajit Roy |
2024-04-03 | Breadth first search / depth first search | Shreya Chatterjee, Adrija Bhar |
2024-04-05 | Shell sort + empirical comparison with heapsort (mean and variance) | Johny Tharakan Thomson, Arnav Rajesh Muley |
2024-04-05 | Uniform pseudo-random number generators | Sudipta Sarkar, Arnab Rakshit |
2024-04-10 | Linear time sorting (counting sort, radix sort) | Kuljeet Singh, Hrithik Sen |
2024-04-10 | Minimum spanning tree | Subhrajyoti Dutta, S Skanda |
2024-04-10 | Nelder-Mead | Yash Talreja, Mukta Khilwani |
2024-04-12 | Tests for randomness | Ananyo Dey, Kaustav Paul |
2024-04-12 | Max-Flow Min-Cut Theorem / Ford-Fulkerson Algorithm | Pranava Priyanshu, Shreyash Balaji Rao Kharat |
2024-04-12 | Numerical integration algorithms | Debanjan Bhattacharjee, Subhendu Ghosh, Swarnadeep Datta |
2024-04-19 | Traveling Salesman Problem (approximate algorithms) | Srijani Das, Yenisi Das |
2024-04-19 | Gradient descent | Rhitankar Bandyopadhyay, Subhrangsu Bhunia |
2024-04-19 | Shortest path (pairwise / all pairs) | Yugam Jain, Shaikh Ammar |
Introduction (slides) (August 1)
Overview of R (slides) (August 3)
Basic Usage of R (slides), cars.csv (demo CSV file), cars.R (demo script), (August 8, 10, 16)
R Language Fundamentals (slides) (August 18, 22)
Introduction to Data Visualization in R (slides), graphics-demo.R (demo script) (August 22, 24, 25)
Basic Statistical Modeling in R (slides), modeling-demo.R (demo script), (September 5)
Algorithms - Part 1 (slides)
Algorithms - Part 2 (slides)
Computer representation of numbers (slides)
Conditioning and Stability (slides)
Assignments are meant to be done individually, not in groups. You are welcome to discuss ideas with others, but you may not share actual code, algorithms, etc.
Due: January 27, 2024. See below for details on how to submit.
Your assignment is to modify the insertion sort algorithm to return a permutation that will sort the input array. Implement this modified algorithm using both R and Rcpp. To use Rcpp, you must first install a compiler and other tools from here.
Submit two files named order.R
and order.cpp
. It should be possible to
use the functions defined in these files by running
the following in an R session:
source("order.R") library(Rcpp) sourceCpp("order.cpp")
Doing so should define an R
function insertion_order
and an Rcpp
function insertion_order_cpp
such
that p <- insertion_order(A)
and
p <- insertion_order_cpp(A)
gives
an index vector p
such that A[p]
is
sorted.
Before submission, create a folder whose name is your
roll number. Put the two files in this folder, and
then ZIP the folder into a file whose name is
of the form MD23XX.zip
. Submit (only)
this zip file by email. Make sure that when unzipped,
the output is a folder (of the
form MD23XX
) containing the two files.
Due: February 17, 2024. See below for details on how to submit.
Suppose you are given an algorithm that given an
input integer n
, claims to produce a
random permutation of the first n
integers. Suggest a procedure to determine (i.e.,
test) whether the procedure actually produces all
permutations with equal probability.
Implement your suggested procedure as an R function
that takes such a candidate function as input, and
apply it on the sample()
function.
Submit a PDF file named report.pdf
and an
R script file named test.R
, using the
same ZIP file structure as in the previous assignemnt.