CS205 S22 Assignment 1
assign1.h
Go to the documentation of this file.
1
10#ifndef __CS205_ASSIGN_1_H__
11#define __CS205_ASSIGN_1_H__
12
13#include "assign1_mat.h"
14
16extern const int MODULO;
17
26int quick_power(int x, int n);
27
37int matrix_addition(matrix mat_a, matrix mat_b, matrix mat_res);
38
47int matrix_multiplication(matrix mat_a, matrix mat_b, matrix mat_res);
48
57int naive_matrix_exp(matrix mat_a, int exp, matrix mat_res);
58
67int fast_matrix_exp(matrix mat_a, long long exp, matrix mat_res);
68
76int fast_cal_fib(long long n);
77
78#endif // __CS205_ASSIGN_1_H__
int matrix_multiplication(matrix mat_a, matrix mat_b, matrix mat_res)
int naive_matrix_exp(matrix mat_a, int exp, matrix mat_res)
int fast_matrix_exp(matrix mat_a, long long exp, matrix mat_res)
int quick_power(int x, int n)
int fast_cal_fib(long long n)
const int MODULO
Instead of using the magic number 1e9 + 7 everywhere in your program, you should use this constant wh...
Definition: assign1_mat.c:50
int matrix_addition(matrix mat_a, matrix mat_b, matrix mat_res)
Provided struct and functions for SUSTech CS205 (s22) assignment 1.
Structure to store a matrix with integers.
Definition: assign1_mat.h:22