# elchinnorojas15-crypto/proyecto_alcaravan architecture

> Architecture diagram of the GitHub repository elchinnorojas15-crypto/proyecto_alcaravan, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-12-03). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/elchinnorojas15-crypto/proyecto_alcaravan
- Repository: https://github.com/elchinnorojas15-crypto/proyecto_alcaravan

## Overview

Quiz Alcaraván is a browser-based algebra practice app: a student selects a difficulty, works through generated questions, submits MathLive answers for automatic checking, and reviews results and a saved record. Its main controller coordinates question selection, correction, graph display, and score recording; the modules share state through the app object. The README also describes offline use and these math-library integrations. The graph follows shown calls and documented capabilities; unsampled HTML wiring and library setup are not inferred beyond those statements.

Main entry points: [`js/main.js`](https://github.com/elchinnorojas15-crypto/proyecto_alcaravan/blob/develop/js/main.js) (Quiz controller), [`js/modulos/grafica.js`](https://github.com/elchinnorojas15-crypto/proyecto_alcaravan/blob/develop/js/modulos/grafica.js) (Function graph), [`index.html`](https://github.com/elchinnorojas15-crypto/proyecto_alcaravan/blob/develop/index.html) (Quiz interface), [`js/modulos/correccion.js`](https://github.com/elchinnorojas15-crypto/proyecto_alcaravan/blob/develop/js/modulos/correccion.js) (Answer correction)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_experience["Student experience"]
  node_interface["Quiz interface<br/>[index.html]"]
  node_results["Results and review<br/>[main.js]"]
end

subgraph group_quiz["Quiz workflow"]
  node_controller["Quiz controller<br/>[main.js]"]
  node_question_bank[("Question bank<br/>[banco.js]")]
end

subgraph group_math["Math feedback"]
  node_answer_check["Answer correction<br/>[correccion.js]"]
  node_graph["Function graph<br/>[grafica.js]"]
  node_compute_engine["Compute Engine"]
  node_jsxgraph["JSXGraph"]
end

subgraph group_progress["Progress tracking"]
  node_score["Score and history<br/>[progreso.js]"]
  node_record_store[("Browser record<br/>[progreso.js]")]
end

node_student(("Student"))

node_student -->|"uses"| node_interface
node_interface -->|"starts"| node_controller
node_controller -->|"gets questions"| node_question_bank
node_controller -->|"checks answer"| node_answer_check
node_answer_check -->|"evaluates expressions"| node_compute_engine
node_controller -->|"updates graph"| node_graph
node_graph -->|"compiles functions"| node_compute_engine
node_controller -->|"creates board"| node_jsxgraph
node_graph -->|"draws curves"| node_jsxgraph
node_controller -->|"records result"| node_score
node_score -->|"reads and writes"| node_record_store
node_controller -->|"shows results"| node_results
node_student -->|"reviews answers"| node_results

click node_interface "https://github.com/elchinnorojas15-crypto/proyecto_alcaravan/blob/develop/index.html"
click node_controller "https://github.com/elchinnorojas15-crypto/proyecto_alcaravan/blob/develop/js/main.js"
click node_question_bank "https://github.com/elchinnorojas15-crypto/proyecto_alcaravan/blob/develop/js/modulos/banco.js"
click node_answer_check "https://github.com/elchinnorojas15-crypto/proyecto_alcaravan/blob/develop/js/modulos/correccion.js"
click node_graph "https://github.com/elchinnorojas15-crypto/proyecto_alcaravan/blob/develop/js/modulos/grafica.js"
click node_score "https://github.com/elchinnorojas15-crypto/proyecto_alcaravan/blob/develop/js/modulos/progreso.js"
click node_record_store "https://github.com/elchinnorojas15-crypto/proyecto_alcaravan/blob/develop/js/modulos/progreso.js"
click node_results "https://github.com/elchinnorojas15-crypto/proyecto_alcaravan/blob/develop/js/main.js"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_interface,node_results toneBlue
class node_controller,node_question_bank toneAmber
class node_answer_check,node_graph,node_compute_engine,node_jsxgraph toneMint
class node_score,node_record_store toneRose
class node_student toneIndigo
```

## Components

### Student experience

- [Quiz interface](https://github.com/elchinnorojas15-crypto/proyecto_alcaravan/blob/develop/index.html): `index.html`
- [Results and review](https://github.com/elchinnorojas15-crypto/proyecto_alcaravan/blob/develop/js/main.js): `js/main.js`

### Quiz workflow

- [Quiz controller](https://github.com/elchinnorojas15-crypto/proyecto_alcaravan/blob/develop/js/main.js): `js/main.js`
- [Question bank](https://github.com/elchinnorojas15-crypto/proyecto_alcaravan/blob/develop/js/modulos/banco.js): `js/modulos/banco.js`

### Math feedback

- [Answer correction](https://github.com/elchinnorojas15-crypto/proyecto_alcaravan/blob/develop/js/modulos/correccion.js): `js/modulos/correccion.js`
- [Function graph](https://github.com/elchinnorojas15-crypto/proyecto_alcaravan/blob/develop/js/modulos/grafica.js): `js/modulos/grafica.js`
- **Compute Engine**
- **JSXGraph**

### Progress tracking

- [Score and history](https://github.com/elchinnorojas15-crypto/proyecto_alcaravan/blob/develop/js/modulos/progreso.js): `js/modulos/progreso.js`
- [Browser record](https://github.com/elchinnorojas15-crypto/proyecto_alcaravan/blob/develop/js/modulos/progreso.js): `js/modulos/progreso.js`

### Other components

- **Student**

## Connections

- Student → Quiz interface: uses (evidence: `README.md`)
- Quiz interface → Quiz controller: starts (evidence: `js/main.js`)
- Quiz controller → Question bank: gets questions (evidence: `js/main.js`)
- Quiz controller → Answer correction: checks answer (evidence: `js/main.js`)
- Answer correction → Compute Engine: evaluates expressions (evidence: `js/modulos/correccion.js`)
- Quiz controller → Function graph: updates graph (evidence: `js/main.js`)
- Function graph → Compute Engine: compiles functions (evidence: `js/modulos/grafica.js`)
- Quiz controller → JSXGraph: creates board (evidence: `js/main.js`)
- Function graph → JSXGraph: draws curves (evidence: `js/modulos/grafica.js`)
- Quiz controller → Score and history: records result (evidence: `js/main.js`)
- Score and history → Browser record: reads and writes (evidence: `js/modulos/progreso.js`)
- Quiz controller → Results and review: shows results (evidence: `js/main.js`)
- Student → Results and review: reviews answers (evidence: `js/main.js`)
