Course detail

Programming and Algorithms 1

FEKT-BPC-PP1Acad. year: 2025/2026

The whole course will be taught in the MATLAB environment (or its freeware alternatives). Students will learn matrix operations, logical and relation operators. Next, advanced data types (e.g. complex numbers, structures, cells, queue, stack, linked list, tree, graph, etc.), program controlling methods (if-elseif-else conditions, for and while cycles, switch-case structures) will be taught. Next, fundamental programing paradigms, e.g. brute force, greedy algorithm, command and conquer, dynamic programing, backtracking, etc. will be taught. Methods for a program acceleration like the vectorization and code optimization will be emphasized. Students will learn about the object oriented programming basics and graphical user interface.   

Language of instruction

Czech

Number of ECTS credits

5

Mode of study

Not applicable.

Entry knowledge

The subject knowledge on the secondary school level is required.

Rules for evaluation and completion of the course

Students can obtain 36 points for the activity in PC tutorials and home works, 40 points for tests during the semester, and 24 points for an individual project in MATLAB.
Evaluation of activities is specified by a regulation, which is issued by the lecturer responsible for the course annually.

Aims

Students should learn the basics of programming and algorithms. The subject will be taught in MATLAB which is a programming language oriented on algorithms (no variable allocation or memory management is needed in comparison to the C language). Next, students should get used to good programming habits (atomization of program, code structure, comments, names of variables, etc.) After this course, students should be able to build their toolbox with a graphical user interface (GUI).
The graduate can:
1) Process matrix operations in MATLAB.
2) Transform mathematical algorithms into MATLAB functions.
3) Plot 2D a 3D functions.
4) Create MATLAB applications with graphical user interface.
5) Write well-arranged and understandable code according to programming conventions.

Study aids

Not applicable.

Prerequisites and corequisites

Not applicable.

Basic literature

Cormen, Thomas H., et al. Introduction to algorithms. MIT press, 2009. (CS)
MATLAB Primer. Www.mathworks.com [online]. 3 Apple Hill Drive Natick, MA 01760-2098: The MathWorks, 2017 [cit. 2017-08-21]. Dostupné z: https://www.mathworks.com/help/pdf_doc/matlab/getstart.pdf (CS)

Recommended reading

VALENTINE, D. T. a Brian D. HAHN. Essential MATLAB for engineers and scientists. 3rd ed. London: Butterworth Heinemann, 2007. (CS)

Classification of course in study plans

  • Programme BPC-ECT Bachelor's 1 year of study, summer semester, compulsory
  • Programme BPC-MET Bachelor's 0 year of study, summer semester, elective
  • Programme BPC-NCP Bachelor's 0 year of study, summer semester, elective

Type of course unit

 

Lecture

26 hod., optionally

Teacher / Lecturer

Syllabus

1. Introduction, history of Matlab, alternatives, coding conventions, script.
2. Matrix creation, matrix operations, indexing, logical and relational operations.
3. Advanced data types (complex numbers, char, logical, structures, cell).
4. Program controls, conditions, cycles.
5. Functions- header, local vs. global variables and Workspace.
6. Algorithms - algorithm description, time/memory complexity, sorting algorithms.
7. Algorithms - data structures, paradigms - Brute force, Command and Conquer, Greedy algorithm, Dynamic programing, backtracking.
8. Functions - handle, vectorization, code optimization, bsxfun, arrayfun, cellfun.
9. Graphics – plotting options, tex commands.
10. File management – read and write.
11. GUI – graphical user interface, appdesigner interface.
12. GUI - graphical user interface and uicontrols.
13. OOP - class/object, properties and methods, constructor, set, get, inheritance, access, namespace, enumeration.

Exercise in computer lab

39 hod., compulsory

Teacher / Lecturer

Syllabus

1. Introduction, history of Matlab, alternatives, coding conventions, script.
2. Matrix creation, matrix operations, indexing, logical and relational operations.
3. Advanced data types (complex numbers, char, logical, structures, cell).
4. Program controls, conditions, cycles.
5. Functions- header, local vs. global variables and Workspace.
6. Algorithms - algorithm description, time/memory complexity, sorting algorithms.
7. Algorithms - data structures, paradigms - Brute force, Command and Conquer, Greedy algorithm, Dynamic programing, backtracking.
8. Functions - handle, vectorization, code optimization, bsxfun, arrayfun, cellfun.
9. Graphics – plotting options, tex commands.
10. File management – read and write.
11. GUI – graphical user interface, appdesigner interface.
12. GUI - graphical user interface and uicontrols.
13. OOP - class/object, properties and methods, constructor, set, get, inheritance, access, namespace, enumeration.