SubjectsSubjects(version: 945)
Course, academic year 2023/2024
   Login via CAS
Computer programming for descriptive geometry I - NMTD103
Title: Programování pro deskriptivní geometrii I
Guaranteed by: Department of Mathematics Education (32-KDM)
Faculty: Faculty of Mathematics and Physics
Actual: from 2023
Semester: winter
E-Credits: 3
Hours per week, examination: winter s.:0/2, C [HT]
Capacity: unlimited
Min. number of students: unlimited
4EU+: no
Virtual mobility / capacity: no
State of the course: taught
Language: Czech
Teaching methods: full-time
Teaching methods: full-time
Guarantor: doc. RNDr. Pavel Töpfer, CSc.
doc. RNDr. Antonín Slavík, Ph.D.
Incompatibility : NMIN111, NMUG103, NPRG030
Interchangeability : NMIN111, NMUG103, NPRG030
Is co-requisite for: NMTD104
Is incompatible with: NMUG103, NMIN111
Is interchangeable with: NMUG103
Annotation -
Last update: doc. RNDr. Pavel Töpfer, CSc. (18.05.2022)
A basic course of programming for first-year students. The course covers programming in Python, basic algorithms and data structures and practical program design and debugging.
Course completion requirements -
Last update: doc. RNDr. Pavel Töpfer, CSc. (10.07.2022)

TStudents will receive a credit for this course by active participation in the practice sessions in the computer lab. Generally this means that students must complete the assigned programming exercises, either during the lab session or later on at home.

Due to the nature of this requirement, a failed attempt cannot be repeated as is possible for exams. The instructor may establish conditions whereby a student can make up for missing homework assignments.

Literature -
Last update: doc. RNDr. Pavel Töpfer, CSc. (10.07.2022)

John V. Guttag, Introduction to Computation and Programming Using Python: With Application to Understanding Data, 2nd ed.,, MIT Press, Cambridge, MA 2016

Allen B. Downey, Think Python: How to Think Like a Computer Scientist, 2nd ed., O'Reilly Media, Sebastopol, CA 2015

Syllabus -
Last update: doc. RNDr. Pavel Töpfer, CSc. (10.07.2022)
Python programming language

  • Python as a calculator
  • integers
  • float numbers and accuracy problems
  • operators and their priorities
  • assignment
  • conditions and cycles (while)
  • program structure: comments, indentation
  • basic input() and print()
  • program debugging, using the development environment (IDLE/PyCharm)
  • for loop, range()
  • break, continue
  • lists used as fields
  • the list assignment assigns only the link
  • function definition and function call
  • optional parameters
  • abstraction and modularity of programs
  • local identifiers and their visibility
  • recursion principle
  • functions passing to other functions
  • lists and their operations
  • queue and stack
  • iterating over a list
  • cuts
  • list comprehension
  • strings
  • use of libraries, import
  • graphs drawing using matplotlib
  • details of type system
  • tuples
  • dictionaries and operations with them
  • exceptions and their catching
  • classes and objects
  • description of reality using objects
  • type derivation, inheritance
  • working with files
  • standard library

Basic algorithms

  • time complexity
  • decomposition of numbers into digits
  • Euclidean algorithm
  • prime numbers calculated by dividing till the square root
  • factorization
  • evaluation of polynomials (Horner's scheme)
  • the k’th smallest element computed in time k*n
  • Eratosthenes sieve
  • matrix multiplication
  • Gauss elimination
  • elementary sorting algorithms
  • binary search
  • finding the roots of functions: halving the interval, linear interpolation
  • merging sorted sequences
 
Charles University | Information system of Charles University | http://www.cuni.cz/UKEN-329.html