Compare commits

..

17 Commits

Author SHA1 Message Date
zleyyij
b080671aa7 vault backup: 2024-09-30 15:18:49 2024-09-30 15:18:49 -06:00
zleyyij
8f8ea61710 vault backup: 2024-09-30 15:13:49 2024-09-30 15:13:49 -06:00
zleyyij
a9357af2eb vault backup: 2024-09-30 15:08:49 2024-09-30 15:08:49 -06:00
zleyyij
107002055b vault backup: 2024-09-30 15:03:49 2024-09-30 15:03:49 -06:00
zleyyij
b4cc677609 vault backup: 2024-09-30 14:58:49 2024-09-30 14:58:49 -06:00
zleyyij
948cbb3bce vault backup: 2024-09-30 14:53:49 2024-09-30 14:53:49 -06:00
zleyyij
0d914027e6 vault backup: 2024-09-30 11:38:24 2024-09-30 11:38:24 -06:00
zleyyij
8160525052 vault backup: 2024-09-30 11:33:24 2024-09-30 11:33:24 -06:00
zleyyij
5a3c1486fb vault backup: 2024-09-30 11:28:24 2024-09-30 11:28:24 -06:00
zleyyij
701bcf87aa vault backup: 2024-09-30 11:23:24 2024-09-30 11:23:24 -06:00
zleyyij
950f46655b vault backup: 2024-09-30 11:18:24 2024-09-30 11:18:24 -06:00
zleyyij
8dd761c084 vault backup: 2024-09-30 11:13:24 2024-09-30 11:13:24 -06:00
zleyyij
1d7b844ce7 vault backup: 2024-09-30 11:08:24 2024-09-30 11:08:24 -06:00
zleyyij
6be1bb929c vault backup: 2024-09-30 11:03:24 2024-09-30 11:03:24 -06:00
zleyyij
4e04256dd7 vault backup: 2024-09-30 10:58:24 2024-09-30 10:58:24 -06:00
zleyyij
a79c744389 vault backup: 2024-09-30 10:53:24 2024-09-30 10:53:24 -06:00
zleyyij
d5caf1e0b5 vault backup: 2024-09-30 10:48:24 2024-09-30 10:48:24 -06:00
5 changed files with 77 additions and 3 deletions

18
IT/Hashicorp Nomad.md Normal file
View File

@ -0,0 +1,18 @@
# Terminology
## Cluster Terms
| Phrase | Definition |
| ----------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| agent | A process running in server or client mode. |
| client/node | A Nomad client is responsible for running tasks assigned to it. A client registers itself with servers and watches for work to be assigned. When running the agent, the client may be referred to as a *node*. |
| server | A Nomad server manages all jobs and clients, monitors tasks, and controls which tasks get placed on which nodes. |
| dev_agent | The development agent is an agent configuration that provides useful defaults for running a single node cluster of nomad. |
## Work terms
| Phrase | Definition |
| ------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| task | The smallest unit of work in Nomad. Tasks are executed by task drivers like `docker` or `exec`, which allows Nomad to be flexible in the types of tasks it supports. Tasks specify their required task driver, configuration for the driver, constraints, and resources required. |
| group | A series of tasks that run on the same Nomad client. |
| job | The core unit of *control* for Nomad and defines the application and its configuration. It can contain one or many tasks |
| job_specification/jobspec | A job specification, also known as a jobspec. |
| allocation | An allocation is a mapping between a task group in a job and a client node. When a job is run, Nomad will chose a client capable of running it and allocates resources on the machine for the ask(s) in the task group defined for the job. |

View File

@ -1,3 +1,5 @@
# Sine/Cosine
![A graph of sine and cosine](./assets/graphsincos.png)
Given the above graph:
@ -13,8 +15,6 @@ Given the above graph:
| $y = cos(2x)$ | Horizontal shrink by a factor of 2 |
# Periodic Functions
A function is considered periodic if it repeats itself at even intervals, where each interval is a complete cycle, referred to as a *period*.
# Sinusoidal Functions
A function that has the same shape as a sine or cosine wave is known as a sinusoidal function.
@ -33,3 +33,55 @@ How to find the:
$$ y = A * \sin(B(x-\frac{C}{B})) $$
# Tangent
$$ y = tan(x) $$
![Graph of tangent](assets/graphtan.png)
To find relative points to create the above graph, you can use the unit circle:
If $tan(x) = \frac{sin(x)}{cos(x})$, then:
| $sin(0) = 0$ | $cos(0) = 1$ | $tan(0) = \frac{cos(0)}{sin(0)} = \frac{0}{1} =0$ |
| ----------------------------------------- | ----------------------------------------- | ---------------------------------------------------------------- |
| $sin(\frac{\pi}{4}) = \frac{\sqrt{2}}{2}$ | $cos(\frac{\pi}{4}) = \frac{\sqrt{2}}{2}$ | $tan(\frac{\pi}{4}) = \frac{\sqrt{2}}{2}/\frac{\sqrt{2}}{2} = 1$ |
| $sin(\frac{\pi}{2}) = 1$ | $cos(\frac{\pi}{2}) = 0$ | $tan(\frac{\pi}{2}) = \frac{1}{0} = DNF$ |
Interpreting the above table:
- When $x = 0$, $y = 0$
- When $x = \frac{\pi}{4}$, $y = 1$
- When $x = \frac{\pi}{2}$, there's an asymptote
Without any transformations applied, the period of $tan(x) = \pi$. Because $tan$ is an odd function, $tan(-x) = -tan(x)$.
# Cotangent
$$ y = cot(x) $$
![Graph of cotangent](assets/graphcot.svg)
To find relative points to create the above graph, you can use the unit circle:
If $cot(x) = \frac{cos(x)}{sin(x)}$, then:
| $sin(0) = 0$ | $cos(0) = 1$ | $cot(0) = \frac{sin(0)}{cos(0)} = \frac{1}{0} = DNF$ |
| ----------------------------------------- | ----------------------------------------- | ---------------------------------------------------------------- |
| $sin(\frac{\pi}{4}) = \frac{\sqrt{2}}{2}$ | $cos(\frac{\pi}{4}) = \frac{\sqrt{2}}{2}$ | $cot(\frac{\pi}{4}) = \frac{\sqrt{2}}{2}/\frac{\sqrt{2}}{2} = 1$ |
| $sin(\frac{\pi}{2}) = 1$ | $cos(\frac{\pi}{2}) = 0$ | $tan(\frac{\pi}{2}) = \frac{1}{0} = DNF$ |
Without any transformations applied, the period of $cot(x) = \pi$. Because $cot$ is an odd function, $cot(-x) = -cot(x)$.
# Features of Tangent and Cotangent
Given the form $y = A\tan(Bx - C) + D$ (the same applies for $\cot$)
- The stretching factor is $|A|$
- The period is $\frac{\pi}{|B|}$
- The domain of $tan$ is all of $x$, where $x \ne \frac{C}{B} + \frac{\pi}{2} + {\pi}{|B|}k$, where $k$ is an integer. (everywhere but the asymptotes)
- The domain of $cot$ is all of $x$, where $x \ne \frac{C}{B} + \frac{\pi}{|B|}k$, where $k$ is an integer (everywhere but the asymptotes)
- The range of both is $(-\infty, \infty)$
- The phase shift is $\frac{C}{B}$
- The vertical shift is $D$
# Examples
> Given $-2\tan(\pi*x + \pi) - 1$
$A = -2$, $B = \pi$, $C = -\pi$, $D = -1$
| Transformation | Equation |
| -------------- | ------------------------- |
| Stretch | $\|-2\| = 2$ |
| Period | $\frac{\pi}{\|\pi\|} = 1$ |
| Phase shift | $\frac{-\pi}{\pi} = -1$ |
| Vertical shift | $-1$ |

File diff suppressed because one or more lines are too long

After

Width:  |  Height:  |  Size: 6.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 201 KiB

View File

@ -32,6 +32,9 @@ C99 adds a `long long` int
## Floats
A float is a decimal value. Slower arithmetic and inexact values are both drawbacks of using floats.
## Characters
In C, a `char` denotes a single byte of arbitrary encoding.
## Variables
A variable must be declared before it is assigned.