feraranas / Analisis-Algoritmos-Avanzados

En esta repo encuentras algoritmos implementados con diversos paradigmas algorítmicos.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Analisis y Diseño de Algoritmos Avanzados

En esta repo encuentras algoritmos implementados con diversos paradigmas algorítmicos.

Math algorithms
Newton Raphson Algorithm to Calculate the Square root
  1. Read a number from the input list, and let x be the name of a memory cell whose initial value is this number.
  2. Write the value in memory cell x. This is called the output.
  3. If the value in x is less than zero, execute instruction 11. Otherwise continue to instruction 4.
  4. Let s be the name of a memory cell whose initial value is 1.
  5. Let i be the name of a memory cell whose initial value is 3.
  6. Calculate the value of (s+(x/s))/2. Let t be the name of a memory cell whose value is the calculated quantity; that is, set t equal to the value of (x+(x/s))/2.
  7. Assign the value in to to memory cell s. That is, set s equal to the value in t and forget the old value associated with s.
  8. Decrease the value in memory cell i by 1.
  9. If the value in i is positive, execute instruction 6. Otherwise, continue to instruction 10.
  10. Write the value in s on the output answer sheet.
  11. Stop; you have finished.
graph TD
    A[Start] --> B[Read input x]
    B --> C[Output x]
    C --> D{x < 0?}
    D -->|Yes| K[Stop]
    D -->|No| E[s = 1, i = 3]
    E --> G[t = s + x/s / 2]
    G --> H[s = t]
    H --> I[i = i - 1]
    I --> J{i > 0?}
    J -->|Yes| G
    J -->|No| L[Output s]
    L --> K

Algoritmos de Comparación

Bubble Sort

Código:

Selection Sort

Código:

Insertion Sort

Código:

Heap Sort

Código:

Algoritmos No-Comparativos

Counting Sort

Código:

Radix Sort

Código:

Algoritmos Divide y Venceras

Merge Sort

Código:

Quick Sort

Código:

Ejercicio: Hanoi Towers

Explicación y código

Algoritmos Programación Dinámica

Ejercicio: Fibonacci Series

Explicación y código

Ejercicio: Ruta más corta por matriz

Explicación y código

Ejercicio: Recolección de dulces

Explicación y código

Algoritmos Avaros/Codiciosos/Voraces

Ejercicio: El problema de las monedas

Explicación y código

Ejercicio: Minimizar el tiempo de espera en una fila

Explicación y código

Ejercicio: Maximización de horas dado limites de tiempo

Explicación y código

Algoritmos Backtracking

Ejercicio: El Problema de las N-Reinas

Explicación y código

Ejercicio: El Raton en el laberinto

Explicación y código

Ejercicio: Sudoku

Explicación y código

Ejercicio: Busca la salida del laberinto

Explicación y código

Ejercicio: Máximo número de compañeros

Explicación y código

Ejercicio: The knight's tour problem

Explicación y código

Algoritmo KMP-Z

Ejercicio: Buscando patrones con el algoritmo LPS - KMP

Explicación y código

Grafos

1. Trie

Geometria Computacional

1. Proximidad e intersección

2. Diagramas de Voronoi y triangulación de Delaunay

3. Búsqueda geométrica

4. Arreglos de hiperplanos

5. Cascos convexos, politopos y computación

Implementación polígonos convexos usando Método de Graham

Algoritmos aleatorizados

About

En esta repo encuentras algoritmos implementados con diversos paradigmas algorítmicos.