repo
stringlengths
26
115
file
stringlengths
54
212
language
stringclasses
2 values
license
stringclasses
16 values
content
stringlengths
19
1.07M
https://github.com/Complex2-Liu/macmo
https://raw.githubusercontent.com/Complex2-Liu/macmo/main/contests/2023/content/problem-01.typ
typst
#import "../lib/math.typ": problem, solution, note, ans #problem[ 求 $tan(15 degree)$ 的值. ] #solution[ 设 $t = tan(15 degree)$, 利用两倍角公式 $tan (2x) = (2 tan x) / (1 - tan^2 x)$, 可得 $ sqrt(3) / 3 = tan(30 degree) = (2 t) / (1 - t^2). $ 这是一个关于 $t$ 的二次方程, 解得 $t = -sqrt(3) plus.minus 2$. 因为 $tan x > 0$ for $0 < x < 90 degree$, 所以 #ans[$tan(15 degree) = 2 - sqrt(3)$.] ] #note[ 当然我们也可以用 $tan$ 的差角公式来计算 $tan(15 degree) = tan(45 degree - 30 degree)$. ] /* vim: set ft=typst: */
https://github.com/Canadauni/typst-static-dashboard
https://raw.githubusercontent.com/Canadauni/typst-static-dashboard/main/_extensions/typst_static_dashboard/typst-template.typ
typst
#let dashcell(inner) = { rect( width: 100%, height: 100%, radius: 2pt, stroke: 0.5pt + rgb("#C9C9C9"), inner ) } #let dashboard( title: "Static Dashboard Template", grid-cols: 3, grid-rows: 3, font-size: 12, font-col: "3E4440", paper: "us-letter", flipped: true, margin: (x: 0.15in, y: 0.6in), header-col: "FFA500", logo-path: none, body ) = { set page( paper: paper, flipped: true, margin: margin, fill: rgb(header-col), background: place(horizon, rect( fill: white, height: 7.5in, width: 100%) ), header: text( font: "Calibri", weight: "bold", fill: white, size: 16pt, title ), header-ascent: 45%, footer: if logo-path == none { none } else { align(left)[ #image(logo-path, width: 15%) ] }, footer-descent: 22% ) set text( font: "Calibri", size: font-size, fill: rgb(font-col) ) set grid( columns: (1fr,) * grid-cols, rows: (1fr,) * grid-rows, column-gutter: 5pt, row-gutter: 5pt ) body }
https://github.com/AliothCancer/AppuntiUniversity
https://raw.githubusercontent.com/AliothCancer/AppuntiUniversity/main/capitoli_dispositivi/03ProtesiVascolari.typ
typst
#import "../custom_functions.typ": def = Protesi Vascolari #def[Protesi Vascolare][Dispositivi medici impiantati permanentemente per *ripristinare la funzione di un tratto vascolare* non più in grado di trasportare correttamente il sangue.] == Condizione patologica - *Stenosi* (occlusione parziale) - *Aneurisma* (dilatazione anomala) == Diametri dei Vasi #let img = image("../immagini/diametri_vasi_var.png") #figure( img, caption: "" ) \ \ \ == Compliance #def("Compliance o Capacitanza")[ È l'equivalente idraulico della capacità elettrica. È la quantità di energia che può essere immagazzinata sottoforma di energia potenziale elastica da un segmento di vaso. *Definizione matematica:* $ C = "dV"/ "dP" $ *dV*: Variazione del volume del segmento di vaso considerato\ *dP*: Variazione della pressione del vaso del segmento di vaso considerato Siccome il flusso è di tipo pulsatile, l'elasticità del vaso ha il compito di trasmettere l'impulso pressorio attraverso una dilatazione locale del vaso. ] L'impianto di una protesi vascolare modifica la compliance del vaso poichè la compliance è una caratteristica data dalle proprietà meccaniche del vaso, in particolare è data dalla geometria e dal materiale, modifica quindi la caduta di pressione a valle e quindi anche il flusso.
https://github.com/CaldeCrack/Typst-Templates
https://raw.githubusercontent.com/CaldeCrack/Typst-Templates/main/modules/auto_rect.typ
typst
/* width: width of the rect height: height of the rect color: color displayed in rect value: value to display in rect */ #let auto_rect(width, height, color, position, value) = { align(position)[ #rect( width: width, height: height, fill: color, )[#if type(value) == int {str(value)} else {value}] ] }
https://github.com/Pablo-Gonzalez-Calderon/apuntes-botanica
https://raw.githubusercontent.com/Pablo-Gonzalez-Calderon/apuntes-botanica/main/src/main.typ
typst
Other
#import "template.typ": * #import "@preview/showybox:1.1.0": showybox #import "months/august.typ": * #import "months/september.typ": * #import "months/october.typ": * #import "months/november.typ": * #show: properties.with() #title() // Agosto #clase-1-2 #clase-3-4 #clase-5-6 // Septiembre #clase-7-8 #clase-9 #clase-10-11 // Octubre #clase-12 #clase-13-14 #clase-15-16 // Noviembre #clase-17-18 #clase-19-20 #clase-21-22 #clase-23-24
https://github.com/alberto-lazari/computer-science
https://raw.githubusercontent.com/alberto-lazari/computer-science/main/lcd/project-presentation/sections/stack.typ
typst
#import "/common.typ": * #new-section-slide[Technological stack] #slide(title: [Programming language])[ Choice: OCaml Widely used ML dialect #pause === #text(green)[Pros] - Pattern matching! #pause - I know ML #pause - Popular parser generators available ] #slide(title: [Parser generator])[ OCaml versions of lex and yacc available - ocamllex, the standard - Menhir, more recent twist on ocamlyacc ] #slide(title: [Package manager])[ - Language setup with `opam init` - Project build and installation with `opam install .` - Powerful build system with Dune ]
https://github.com/justmejulian/typst-documentation-template
https://raw.githubusercontent.com/justmejulian/typst-documentation-template/main/theme/disclaimer.typ
typst
#import "constant.typ": body-font, sans-font #let disclaimer( title: "", author: "", submissionDate: none, ) = { set page( margin: (left: 30mm, right: 30mm, top: 40mm, bottom: 40mm), numbering: none, number-align: center, ) set text( font: body-font, size: 12pt, lang: "en" ) set par(leading: 1em) // --- Disclaimer --- v(75%) text("I confirm ...") v(15mm) grid( columns: 2, gutter: 1fr, "Zurich, " + submissionDate, author ) }
https://github.com/valentinvogt/npde-summary
https://raw.githubusercontent.com/valentinvogt/npde-summary/main/src/chapters/05.typ
typst
#import "../setup.typ": * #show: thmrules = Non-Linear Elliptic Boundary Value Problems <ch:non-linear-elliptic-bvp> == Elastic String Model <sub:elastic-string-model> We want to derive the general variational equation for an elastic string. For this, one approximates the string as $n$ point masses affected by gravity connected with springs, whose energy behaves according to Hooke’s law. Then, one takes the limit $n arrow.r oo$ to derive a continuous model. The total energy is then just given by the sum of elastic and gravitational energies — given positions $(mu_0 , dots.h , mu_n)$ and $x_i = a + h i$, assuming the spring constants are $1$: #mybox( "Total energy of discrete spring system", ..unimportant, )[ $ E (mu) = 1 / 2 sum_(i = 0)^n (sqrt(h^2 + (mu_(i + 1) - mu_i)^2))^2 + sum_(i = 1)^n m_i mu_i g $ ] Then, the equilibrium position for this model can be found by minimizing this expression over $mu$. A continuous model is derived by replacing the discrete positions $mu_i$ by a function $u (x_i)$, and the mass by a mass density. Then, performing some manipulations, one obtains #mybox( "Total energy for the continuous string model", ..unimportant, )[ $ J_s (u) = integral_a^b 1 / 2 frac(b - a, L) sigma (x) (sqrt(1 + lr(|u prime (x)|)^2) - frac(L, b - a))^2 + g rho (x) u (x) dif x $ ] where $sigma$ is the spring stiffness, $L$ is the total rest length of the string, and $rho$ is the mass density. The term $sqrt(1 + lr(|u' (x)|)^2)$ is the length of the spring at position $x$. In a similar fashion, a membrane model can be derived by assuming a two-dimensional grid of springs containing points masses and taking the limit $n arrow.r oo$ springs. The energy then becomes #mybox( "Total energy for the membrane model", ..unimportant, )[ $ J_M (u) = integral_Omega frac(1, 2 L) sigma (bx) ( &(sqrt(1 + lr(|frac(partial u, partial x_1) (bx)|)^2) - frac(L, b - a))^2 \ + &(sqrt(1 + lr(|frac(partial u, partial x_2)(bx)|)^2) - frac(L, b - a))^2) + g rho (bx) u (bx) dif bx $ ] In the limit of a taut membrane, i.e. for $L lt.double b - a$, these equations just reduce to the problem of minimizing the familiar functionals seen in earlier chapters: #mybox( "Elastic string/membrane: taut limit", ..unimportant, )[ #neq( $ J_s (u) &= 1 / 2 integral_a^b hat(sigma) (x) lr(|u prime (x)|)^2 + g rho (x) u (x) dif x \ J_M (u) &= 1 / 2 integral_Omega hat(sigma) (bx) norm(grad u (bx))^2 + g rho (bx) u (bx) dif bx $, )<eq:taut-limit> ] == Calculus of Variations <sub:calculus-of-variations> The difference between the equations seen in @eq:taut-limit, which hold in the limit of a very stretched string/membrane, and the general equations given above, is that the former are #strong[quadratic] minimization problems, while the latter are #strong[nonlinear] minimization problems. The theory used so far mapped quadratic minimization problems to #strong[linear] variational problems, which were then discretized. The new equations, however, yield nonlinear variational equations. Therefore, more general variational problems need to be derived. The idea employed is that, for a minimizer $u_*$ of $J (u)$, every perturbation $J (u_* + v)$ would be larger than $J (u_*)$. This means that $f (t) = J (u_* + t v)$ has a minimum at $t = 0$ for every function $v$: #theorem( number: "5.2.1.5", "Characterization of global minimizers", )[ Assume $u_* in V_0$ is a global minimizer of $J (u)$, i.e. $ u_* = op("argmin", limits: #true)_(u in V_0) J (u) $ Then, if $phi_v (t) = J (u_* + t v)$ is differentiable in $t = 0$, we have $ frac(dif phi_v, phi t) (0) = 0 quad forall v in V_0 $ ] This means that nonlinear variational equations can be derived by computing this derivative for an arbitrary $v$. As an example, for the elastic string model introduced in the last sub-chapter, this yields #mybox( "Variational equations for elastic string model", ..unimportant, )[ $ integral_a^b frac(sigma (x), c) (sqrt(1 + lr(|u prime (x)|)^2) - c) frac(u' (x) v' (x), sqrt(1 + lr(|u' (x)|)^2)) + g rho (x) v (x) dif x = 0 quad forall v in H_0^1 (openint(a, b)) $ ] This can be formulated more generally as a #strong[general variational equation];: #mybox("General variational equation")[ A general, nonlinear variational equation reads $ u in mhat(V) : quad a (u ; v) = 0 quad forall v in V_0 $ Where $a$ is #strong[linear in the second argument] $v$ and $V_0 , mhat(V)$ are function spaces. ] == Nonlinear Boundary Value Problems <sub:nonlinear-bvp> Similarly to the linear case, nonlinear PDEs can be derived from the variational equations by "stripping" of the derivatives of $v$ by partial integration and employing the fundamental lemma of calculus of variations. As an example, for the string model, this yields for $u (a) = u_a$, $u (b) = u_b$ $ frac(dif, dif x) (frac(sigma (x), c) (sqrt(1 + lr(|u '(x)|)^2) - c) frac(u' (x), sqrt(1 + lr(|u ' (x)|)^2))) = g rho (x) quad upright(" in ") thin openint(a, b) $ == Galerkin Discretization of Non-Linear BVPs <sub:galerkin-non-linear-bvps> The idea of Galerkin discretization for non-linear variational equations is exactly the same as for linear equations, but they yield nonlinear systems of equations instead of linear systems of equations: One restricts $u$ and $v$ to a finite function space $u_h in mhat(V)_h$ and $v_h in V_(0 , h)$, and expands the functions in some basis of the space. This, then, leads to nonlinear equations for the basis expansion coefficients. These equations could be solved directly by employing some fixed-point iteration seen in NumCSE. #mybox( "Nonlinear Galerkin Discretization", )[ Given a variational problem $a (u ; v) = 0 med forall v in V_(0 , h)$, the Galerkin discretization reads $ (F (mu))_i = a (u_(0 , h) + sum_(j = 1)^N mu_j b_h^j ; b_h^i) , quad i = 1 , dots.h , N $ where $b_h^i$ are fixed basis functions, $mu_i$ are the basis function coefficients and $u_(0 , h)$ contains Dirichlet boundary conditions. ] Another option is to already linearize the continuous problem, and then discretize it to derive linear systems of equations. This is done by employing Newton's method in function space: The conventional Newton iteration is given as $ xi^((k + 1)) = xi^((k)) - upright(D) F (xi^((k)))^(- 1) F (xi^((k))) $ Replacing the vector $xi$ with a function $u$ and the derivative by a function derivative now gives #equation( number: "5.3.2.5", "Functional Newton iteration", )[ $ w in V_0 : a (u^((k)) ; v) + upright(D)_u a (u^((k)) ; v) w = 0 quad forall v in V_0\ u^((k + 1)) = u^((k)) + w $ ] Here, the directional derivative is defined as #align( center, )[ #subtle-box[ $ upright(D)_u a (u^((k)) ; v) w = lim_(t arrow.r 0) frac(a (u + t w ; v) - a (u ; v), t) , quad u^((k)) in mhat(V) , quad v , w in V_0 $ ] ] #tip-box( "Computing the directional derivative", )[ You can simply compute the defining limit by Taylor-expanding $a(u + t w, v)$. If you do this once, you notice that only the first-order term in $t$ remains: the 0th order term cancels out with $a(u, v)$, and the higher-order terms vanish in the limit $t arrow.r 0$. So a more convenient method is to do Taylor expansion and to keep only the first-order term. ] Now, the advantage of this equation for $w$ is that the functional derivative is linear, i.e. $(v , w) arrow.r.bar D_u a (u^((k)) ; v) w$ is a #strong[bilinear form];. Now, one can employ Galerkin discretization for the linear problem in $w$, exactly like it was done in Chapter 2 and 3. The final equations then read #equation( number: "5.3.3.6", "Nonlinear Newton equations for variational problems", )[ $ w_h in V_(0 , h)^((k)) : upright(D)_u a (u_h^((k - 1)) ; v_h) w_h = - a (u_h^((k - 1)) ; v_h) quad forall v_h in V_(0 , h)^((k))\ u_h^((k)) = P_h^((k)) (u_h^((k - 1)) + w_h) $ ] Here, different function spaces can be used for each iterations, so a projector $P_h^((k))$ needs to be used to project the solution from $V_h^((k - 1))$ to $V_h^((k))$. In all of these equations, the previous iterate $u_h^((k - 1))$ is kept fixed, a linear system like derived in Chapter 2 is solved to obtain the intermediate $w_h$, and then a new iterate $u^((k))$ is obtained.
https://github.com/gongke6642/tuling
https://raw.githubusercontent.com/gongke6642/tuling/main/可视化/图像/tuxiang.typ
typst
= image 元素 光栅图形或矢量图形。 支持的格式包括 PNG、JPEG、GIF 和 SVG。 注意:SVG 导出工作正在进行中,生成的 PDF 中可能存在视觉不准确之处。确保仔细检查嵌入的 SVG 图像。如果您有问题,也请随时在 GitHub 上报告。 #image("1.png") #image("2.png") #image("3.png") = 定义 = decode 从字节或字符串中解码光栅或矢量图形。 #image("4.png") #image("5.png")
https://github.com/nayaabkhan/the-science-of-getting-rich
https://raw.githubusercontent.com/nayaabkhan/the-science-of-getting-rich/main/main.typ
typst
Creative Commons Zero v1.0 Universal
// override the built-in smallcaps #let smallcaps(body) = { set text(font: "MrsEavesSmallCaps") [#body] } #let numeric(body) = { set text(font: "MrsEavesFractions") [#body] } #show emph: it => [ #text(font: "MrsEaves", style: "italic", it.body) ] #let title = "The Science of Getting Rich" #let author = "<NAME>" #set document( title: title, author: author, ) #set page( paper: "a5", margin: 2cm, ) #set text(font: "HQGQAX+MrsEavesOT-Roman", size: 12pt) // cover page #page(align(center + horizon)[ #text(34pt, smallcaps(title)) #v(5em, weak: true) #text(21pt, smallcaps(author))\ #text(13pt, emph("Author of “New Science of Living and Healing”")) #v(5em, weak: true) #box(stroke: (y: 1pt), inset: 4pt, text(13pt, upper[ Price, \$#numeric("1.00") ])) #v(5em, weak: true) #text(8pt, upper("Published By"))\ #text(13pt, upper("<NAME>"))\ #text(13pt, upper("Holyoke, MASS,"))\ #text(8pt, numeric("1910")) #v(3em, weak: true) #line(length: 50%, stroke: (thickness: 0.5pt, dash: "loosely-dotted")) #text(8pt, emph("Only for the team at")) #image("innovace.svg", width: 50pt) ]) #align(center + top, text(13pt, smallcaps[ Copyright, April 1, 1910\ By #author ])) #pagebreak(to: "odd") #show heading.where(level: 1): it => { block(width: 100%)[ #v(1em) #set align(center) #set par(justify: false, leading: 0.5em) #set text(21pt) #smallcaps[ #it.body ] #v(1em) ] } #outline(title: [Chapters], fill: none, indent: 2em) #let chaptercounter = counter("heading") #show heading.where(level: 1): it => { // start a new chapter on odd page pagebreak(to: "odd") chaptercounter.step() let number = chaptercounter.display("I") block(width: 100%)[ #v(1em) #set align(center) #set par(justify: false, leading: 0.5em) #set text(13pt) Chapter #number #v(1em, weak: true) #set text(21pt) #smallcaps[ #it.body ] #v(1em) ] } #set page( paper: "a5", margin: 2cm, header: locate(loc => { let pagenumber = counter(page).display() let i = counter(page).at(loc).first() // Are we on a page that starts a chapter? (We also check // the previous page because some headings contain pagebreaks.) let all = query(heading, loc) if all.any(it => it.location().page() == i) { return [ #set text(size: 0.7em, tracking: 1.5pt) #h(1fr) #numeric(pagenumber) ] } // Are we on an odd page? if calc.odd(i) { return [ #set text(size: 0.7em, tracking: 1.5pt) #smallcaps(title) #h(1fr) #numeric(pagenumber) ] } // Find the heading of the section we are currently in. let before = query(selector(heading).before(loc), loc) if before != () { return [ #set text(size: 0.7em, tracking: 1.5pt) #numeric(pagenumber) #h(1fr) #smallcaps(before.last().body) ] } }), ) #set par( justify: true, leading: 0.35em, ) = The Right To Be Rich. Whatever may be said in praise of poverty, the fact remains that it is not possible to live a really complete or successful life unless one is rich. No man can rise to his greatest possible height in talent or soul development unless he has plenty of money; for to unfold the soul and to develop talent he must have many things to use, and he cannot have these things unless he has money to buy them with. Man develops in mind, soul, and body by making use of things, and society is so organized that man must have money in order to become the possessor of things; therefore, the basis of all advancement for man must be the science of getting rich. The object of all life is development; and everything that lives has an inalienable right to all the development it is capable of attaining. Man’s right to life means his right to have the free and unrestricted use of all the things which may be necessary to his fullest mental, spiritual, and physical unfoldment; or, in other words, his right to be rich. In this book, I shall not speak of riches in a figurative way; to be really rich does not mean to be satisfied or contented with a little. No man ought to be satisfied with a little if he is capable of using and enjoying more. The purpose of Nature is the advancement and unfoldment of life; and every man should have all that can contribute to the power, elegance, beauty, and richness of life; to be content with less is sinful. The man who owns all he wants for the living of all the life he is capable of living is rich; and no man who has not plenty of money can have all he wants. Life has advanced so far, and become so complex, that even the most ordinary man or woman requires a great amount of wealth in order to live in a manner that even approaches completeness. Every person naturally wants to become all that he is capable of becoming; this desire to realize innate possibilities is inherent in human nature; we cannot help wanting to be all that we can be. Success in life is becoming what you want to be; you can become what you want to be only by making use of things, and you can have the free use of things only as you become rich enough to buy them. To understand the science of getting rich is therefore the most essential of all knowledge. There is nothing wrong in wanting to get rich. The desire for riches is really the desire for a richer, fuller, and more abundant life; and that desire is praiseworthy. The man who does not desire to live more abundantly is abnormal, and so the man who does not desire to have money enough to buy all he wants is abnormal. There are three motives for which we live; we live for the body, we live for the mind, and we live for the soul. No one of these is better or holier than the other; all are alike desirable, and no one of the three--body, mind, or soul--can live fully if either of the others is cut short of full life and expression. It is not right or noble to live only for the soul and deny mind or body; and it is wrong to live for the intellect and deny body and soul. We are all acquainted with the loathsome consequences of living for the body and denying both mind and soul; and we see that real life means the complete expression of all that man can give forth through body, mind, and soul. Whatever he may say, no man can be really happy or satisfied unless his body is living fully in every function, and unless the same is true of his mind and his soul. Wherever there is unexpressed possibility, or function not performed, there is unsatisfied desire. Desire is possibility seeking expression, or function seeking performance. Man cannot live fully in body without good food, comfortable clothing, and warm shelter; and without freedom from excessive toil. Rest and recreation are also necessary to his physical life. He cannot live fully in mind without books and time to study them, without opportunity for travel and observation, or without intellectual companionship. To live fully in mind he must have intellectual recreations, and must surround himself with all the objects of art and beauty he is capable of using and appreciating. To live fully in soul, man must have love; and love is denied expression by poverty. Man’s highest happiness is found in the bestowal of benefits on those he loves; love finds its most natural and spontaneous expression in giving. The man who has nothing to give cannot fill his place as a husband or father, as a citizen, or as a man. It is in the use of material things that man finds full life for his body, develops his mind, and unfolds his soul. It is therefore of supreme importance to him that he should be rich. It is perfectly right that you should desire to be rich; if you are a normal man or woman you cannot help doing so. It is perfectly right that you should give your best attention to the Science of Getting Rich, for it is the noblest and most necessary of all studies. If you neglect this study, you are derelict in your duty to yourself, to God, and to humanity; for you can render God and humanity no greater service than to make the most of yourself. = There Is A Science Of Getting Rich. There is a Science of getting rich, and it is an exact science, like algebra or arithmetic. There are certain laws which govern the process of acquiring riches; once these laws are learned and obeyed by any man, he will get rich with mathematical certainty. The ownership of money and property comes as a result of doing things in a certain way; those who do things in this Certain Way, whether on purpose or accidentally, get rich; while those who do not do things in this Certain Way, no matter how hard they work or how able they are, remain poor. It is a natural law that like causes always produce like effects; and, therefore, any man or woman who learns to do things in this Certain Way will infallibly get rich. That the above statement is true is shown by the following facts:-- Getting rich is not a matter of environment, for, if it were, all the people in certain neighborhoods would become wealthy; the people of one city would all be rich, while those of other towns would all be poor; or the inhabitants of one state would roll in wealth, while those of an adjoining state would be in poverty. But everywhere we see rich and poor living side by side, in the same environment, and often engaged in the same vocations. When two men are in the same locality, and in the same business, and one gets rich while the other remains poor, it shows that getting rich is not, primarily, a matter of environment. Some environments may be more favorable than others, but when two men in the same business are in the same neighborhood, and one gets rich while the other fails, it indicates that getting rich is the result of doing things in a Certain Way. And further, the ability to do things in this Certain Way is not due solely to the possession of talent, for many people who have great talent remain poor, while others who have very little talent get rich. Studying the people who have got rich, we find that they are an average lot in all respects, having no greater talents and abilities than other men. It is evident that they do not get rich because they possess talents and abilities that other men have not, but because they happen to do things in a Certain Way. Getting rich is not the result of saving, or “thrift”; many very penurious people are poor, while free spenders often get rich. Nor is getting rich due to doing things which others fail to do; for two men in the same business often do almost exactly the same things, and one gets rich while the other remains poor or becomes a bankrupt. From all these things, we must come to the conclusion that getting rich is the result of doing things in a Certain Way. If getting rich is the result of doing things in a Certain Way, and if like causes always produce like effects, then any man or woman who can do things in that way can become rich, and the whole matter is brought within the domain of exact science. The question arises here, whether this Certain Way may not be so difficult that only a few may follow it. This cannot be true, as we have seen, so far as natural ability is concerned. Talented people get rich, and blockheads get rich; intellectually brilliant people get rich, and very stupid people get rich; physically strong people get rich, and weak and sickly people get rich. Some degree of ability to think and understand is, of course, essential; but in so far as natural ability is concerned, any man or woman who has sense enough to read and understand these words can certainly get rich. Also, we have seen that it is not a matter of environment. Location counts for something; one would not go to the heart of the Sahara and expect to do successful business. Getting rich involves the necessity of dealing with men, and of being where there are people to deal with; and if these people are inclined to deal in the way you want to deal, so much the better. But that is about as far as environment goes. If anybody else in your town can get rich, so can you; and if anybody else in your state can get rich, so can you. Again, it is not a matter of choosing some particular business or profession. People get rich in every business, and in every profession; while their next door neighbors in the same vocation remain in poverty. It is true that you will do best in a business which you like, and which is congenial to you; and if you have certain talents which are well developed, you will do best in a business which calls for the exercise of those talents. Also, you will do best in a business which is suited to your locality; an ice-cream parlor would do better in a warm climate than in Greenland, and a salmon fishery will succeed better in the Northwest than in Florida, where there are no salmon. But, aside from these general limitations, getting rich is not dependent upon your engaging in some particular business, but upon your learning to do things in a Certain Way. If you are now in business, and anybody else in your locality is getting rich in the same business, while you are _not_ getting rich, it is because you are not doing things in the same Way that the other person is doing them. No one is prevented from getting rich by lack of capital. True, as you get capital the increase becomes more easy and rapid; but one who has capital is already rich, and does not need to consider how to become so. No matter how poor you may be, if you begin to do things in the Certain Way you will begin to get rich; and you will begin to have capital. The getting of capital is a part of the process of getting rich; and it is a part of the result which invariably follows the doing of things in the Certain Way. You may be the poorest man on the continent, and be deeply in debt; you may have neither friends, influence, nor resources; but if you begin to do things in this Way, you must infallibly begin to get rich, for like causes must produce like effects. If you have no capital, you can get capital; if you are in the wrong business, you can get into the right business; if you are in the wrong location, you can go to the right location; and you can do so _by beginning in your present business and in your present location_ to do things in the Certain Way which causes success. = Is Opportunity Monopolized? No man is kept poor because opportunity has been taken away from him; because other people have monopolized the wealth, and have put a fence around it. You may be shut off from engaging in business in certain lines, but there are other channels open to you. Probably it would be hard for you to get control of any of the great railroad systems; that field is pretty well monopolized. But the electric railway business is still in its infancy, and offers plenty of scope for enterprise; and it will be but a very few years until traffic and transportation through the air will become a great industry, and in all its branches will give employment to hundreds of thousands, and perhaps to millions, of people. Why not turn your attention to the development of aerial transportation, instead of competing with <NAME> and others for a chance in the steam railway world? It is quite true that if you are a workman in the employ of the steel trust you have very little chance of becoming the owner of the plant in which you work; but it is also true that if you will commence to act in a Certain Way, you can soon leave the employ of the steel trust; you can buy a farm of from ten to forty acres, and engage in business as a producer of foodstuffs. There is great opportunity at this time for men who will live upon small tracts of land and cultivate the same intensively; such men will certainly get rich. You may say that it is impossible for you to get the land, but I am going to prove to you that it is not impossible, and that you can certainly get a farm if you will go to work in a Certain Way. At different periods the tide of opportunity sets in different directions, according to the needs of the Whole, and the particular stage of social evolution which has been reached. At present, in America, it is setting toward agriculture and the allied industries and professions. To-day, opportunity is open before the farmer in his line more than before the factory worker in his line. It is open before the business man who supplies the farmer more than before the one who supplies the factory worker; and before the professional man who waits upon the farmer more than before the one who serves the working class. There is abundance of opportunity for the man who will go with the tide, instead of trying to swim against it. So the factory workers, either as individuals or as a class, are not deprived of opportunity. The workers are not being “kept down” by their masters; they are not being “ground” by the trusts and combinations of capital. As a class, they are where they are because they do not do things in a Certain Way. If the workers of America chose to do so, they could follow the example of their brothers in Belgium and other countries, and establish great department stores and co-operative industries; they could elect men of their own class to office, and pass laws favoring the development of such co-operative industries; and in a few years they could take peaceable possession of the industrial field. The working class may become the master class whenever they will begin to do things in a Certain Way; the law of wealth is the same for them as it is for all others. This they must learn; and they will remain where they are as long as they continue to do as they do. The individual worker, however, is not held down by the ignorance or the mental slothfulness of his class; he can follow the tide of opportunity to riches, and this book will tell him how. No one is kept in poverty by a shortness in the supply of riches; there is more than enough for all. A palace as large as the capitol at Washington might be built for every family on earth from the building material in the United States alone; and under intensive cultivation, this country would produce wool, cotton, linen, and silk enough to clothe each person in the world finer than Solomon was arrayed in all his glory; together with food enough to feed them all luxuriously. The visible supply is practically inexhaustible; and the invisible supply really IS inexhaustible. _Everything you see on earth is made from one original substance, out of which all things proceed._ New forms are constantly being made, and older ones are dissolving; but all are shapes assumed by One Thing. There is no limit to the supply of Formless Stuff, or Original Substance. The universe is made out of it; but it was not all used in making the universe. The spaces in, through, and between the forms of the visible universe are permeated and filled with the Original Substance; with the Formless Stuff; with the raw material of all things. Ten thousand times as much as has been made might still be made, and even then we should not have exhausted the supply of universal raw material. No man, therefore, is poor because nature is poor, or because there is not enough to go around. Nature is an inexhaustible storehouse of riches; the supply will never run short. Original Substance is alive with creative energy, and is constantly producing more forms. When the supply of building material is exhausted, more will be produced; when the soil is exhausted so that foodstuffs and materials for clothing will no longer grow upon it, it will be renewed or more soil will be made. When all the gold and silver has been dug from the earth, if man is still in such a stage of social development that he needs gold and silver, more will be produced from the Formless. The Formless Stuff responds to the needs of man; it will not let him be without any good thing. This is true of man collectively; the race as a whole is always abundantly rich, and if individuals are poor, it is because they do not follow the Certain Way of doing things which makes the individual man rich. The Formless Stuff is intelligent; it is stuff which thinks. It is alive, and is always impelled toward more life. It is the natural and inherent impulse of life to seek to live more; it is the nature of intelligence to enlarge itself, and of consciousness to seek to extend its boundaries and find fuller expression. The universe of forms has been made by Formless Living Substance, throwing itself into form in order to express itself more fully. The universe is a great Living Presence, always moving inherently toward more life and fuller functioning. Nature is formed for the advancement of life; its impelling motive is the increase of life. For this cause, everything which can possibly minister to life is bountifully provided; there can be no lack unless God is to contradict himself and nullify his own works. You are not kept poor by lack in the supply of riches; it is a fact which I shall demonstrate a little farther on that even the resources of the Formless Supply are at the command of the man or woman who will act and think in a Certain Way. = The First Principle In The Science Of Getting Rich. Thought is the only power which can produce tangible riches from the Formless Substance. The stuff from which all things are made is a substance which thinks, and a thought of form in this substance produces the form. Original Substance moves according to its thoughts; every form and process you see in nature is the visible expression of a thought in Original Substance. As the Formless Stuff thinks of a form, it takes that form; as it thinks of a motion, it makes that motion. That is the way all things were created. We live in a thought world, which is part of a thought universe. The thought of a moving universe extended throughout Formless Substance, and the Thinking Stuff moving according to that thought, took the form of systems of planets, and maintains that form. Thinking Substance takes the form of its thought, and moves according to the thought. Holding the idea of a circling system of suns and worlds, it takes the form of these bodies, and moves them as it thinks. Thinking the form of a slow-growing oak tree, it moves accordingly, and produces the tree, though centuries may be required to do the work. In creating, the Formless seems to move according to the lines of motion it has established; the thought of an oak tree does not cause the instant formation of a full-grown tree, but it does start in motion the forces which will produce the tree, along established lines of growth. Every thought of form, held in thinking Substance, causes the creation of the form, but always, or at least generally, along lines of growth and action already established. The thought of a house of a certain construction, if it were impressed upon Formless Substance, might not cause the instant formation of the house; but it would cause the turning of creative energies already working in trade and commerce into such channels as to result in the speedy building of the house. And if there were no existing channels through which the creative energy could work, then the house would be formed directly from primal substance, without waiting for the slow processes of the organic and inorganic world. _No thought of form can be impressed upon Original Substance without causing the creation of the form._ Man is a thinking center, and can originate thought. All the forms that man fashions with his hands must first exist in his thought; he cannot shape a thing until he has thought that thing. And so far man has confined his efforts wholly to the work of his hands; he has applied manual labor to the world of forms, seeking to change or modify those already existing. He has never thought of trying to cause the creation of new forms by impressing his thoughts upon Formless Substance. When man has a thought-form, he takes material from the forms of nature, and makes an image of the form which is in his mind. He has, so far, made little or no effort to co-operate with Formless Intelligence; to work “with the Father.” He has not dreamed that he can “do what he seeth the Father doing.” Man re-shapes and modifies existing forms by manual labor; he has given no attention to the question whether he may not produce things from Formless Substance by communicating his thoughts to it. We propose to prove that he may do so; to prove that any man or woman may do so, and to show how. As our first step, we must lay down three fundamental propositions. First, we assert that there is one original formless stuff, or substance, from which all things are made. All the seemingly many elements are but different presentations of one element; all the many forms found in organic and inorganic nature are but different shapes, made from the same stuff. And this stuff is thinking stuff; a thought held in it produces the form of the thought. Thought, in thinking substance, produces shapes. Man is a thinking center, capable of original thought; if man can communicate his thought to original thinking substance, he can cause the creation, or formation, of the thing he thinks about. To summarize this:-- _There is a thinking stuff from which all things are made, and which, in its original state, permeates, penetrates, and fills the interspaces of the universe._ _A thought, in this substance, produces the thing that is imaged by the thought._ _Man can form things in his thought, and, by impressing his thought upon formless substance, can cause the thing he thinks about to be created._ It may be asked if I can prove these statements; and without going into details, I answer that I can do so, both by logic and experience. Reasoning back from the phenomena of form and thought, I come to one original thinking substance; and reasoning forward from this thinking substance, I come to man’s power to cause the formation of the thing he thinks about. And by experiment, I find the reasoning true; and this is my strongest proof. If one man who reads this book gets rich by doing what it tells him to do, that is evidence in support of my claim; but if every man who does what it tells him to do gets rich, that is positive proof until some one goes through the process and fails. The theory is true until the process fails; and this process will not fail, for every man who does exactly what this book tells him to do will get rich. I have said that men get rich by doing things in a Certain Way; and in order to do so, men must become able to think in a certain way. _A man’s way of doing things is the direct result of the way he thinks about things._ To do things in the way you want to do them, you will have to acquire the ability to think the way you want to think; this is the first step toward getting rich. _To think what you want to think is to think TRUTH, regardless of appearances._ Every man has the natural and inherent power to think what he wants to think, but it requires far more effort to do so than it does to think the thoughts which are suggested by appearances. To think according to appearances is easy; to think truth regardless of appearances is laborious, and requires the expenditure of more power than any other work man is called upon to perform. There is no labor from which most people shrink as they do from that of sustained and consecutive thought; it is the hardest work in the world. This is especially true when truth is contrary to appearances. Every appearance in the visible world tends to produce a corresponding form in the mind which observes it; and this can only be prevented by holding the thought of the TRUTH. To look upon the appearance of disease will produce the form of disease in your own mind, and ultimately in your body, unless you hold the thought of the truth, which is that there is no disease; it is only an appearance, and the reality is health. To look upon the appearances of poverty will produce corresponding forms in your own mind, unless you hold to the truth that there is no poverty; there is only abundance. To think health when surrounded by the appearances of disease, or to think riches when in the midst of appearances of poverty, requires power; but he who acquires this power becomes a MASTER MIND. He can conquer fate; he can have what he wants. This power can only be acquired by getting hold of the basic fact which is behind all appearances; and that fact is that there is one Thinking Substance, from which and by which all things are made. Then we must grasp the truth that every thought held in this substance becomes a form, and that man can so impress his thoughts upon It as to cause them to take form and become visible things. When we realize this, we lose all doubt and fear, for we know that we can create what we want to create; we can get what we want to have, and can become what we want to be. As a first step toward getting rich, you must believe the three fundamental statements given previously in this chapter; and in order to emphasize them, I repeat them here:-- _There is a thinking stuff from which all things are made, and which, in its original state, permeates, penetrates, and fills the interspaces of the universe._ _A thought, in this substance, produces the thing that is imaged by the thought._ _Man can form things in his thought, and, by impressing his thought upon formless substance, can cause the thing he thinks about to be created._ You must lay aside all other concepts of the universe than this monistic one; and you must dwell upon this until it is fixed in your mind, and has become your habitual thought. Read these creed statements over and over again; fix every word upon your memory, and meditate upon them until you firmly believe what they say. If a doubt comes to you, cast it aside as a sin. Do not listen to arguments against this idea; do not go to churches or lectures where a contrary concept of things is taught or preached. Do not read magazines or books which teach a different idea; if you get mixed up in your faith, all your efforts will be in vain. Do not ask why these things are true, nor speculate as to how they can be true; simply take them on trust. The science of getting rich begins with the absolute acceptance of this faith. = Increasing Life. You must get rid of the last vestige of the old idea that there is a Deity whose will it is that you should be poor, or whose purposes may be served by keeping you in poverty. The Intelligent Substance which is All, and in all, and which lives in All and lives in you, is a consciously Living Substance. Being a consciously living substance, It must have the natural and inherent desire of every living intelligence for increase of life. Every living thing must continually seek for the enlargement of its life, because life, in the mere act of living, must increase itself. A seed, dropped into the ground, springs into activity, and in the act of living produces a hundred more seeds; life, by living, multiplies itself. It is forever Becoming More; it must do so, if it continues to be at all. Intelligence is under this same necessity for continuous increase. Every thought we think makes it necessary for us to think another thought; consciousness is continually expanding. Every fact we learn leads us to the learning of another fact; knowledge is continually increasing. Every talent we cultivate brings to the mind the desire to cultivate another talent; we are subject to the urge of life, seeking expression, which ever drives us on to know more, to do more, and to be more. In order to know more, do more, and be more we must have more; we must have things to use, for we learn, and do, and become, only by using things. We must get rich, so that we can live more. The desire for riches is simply the capacity for larger life seeking fulfillment; every desire is the effort of an unexpressed possibility to come into action. It is power seeking to manifest which causes desire. That which makes you want more money is the same as that which makes the plant grow; it is Life, seeking fuller expression. The One Living Substance must be subject to this inherent law of all life; it is permeated with the desire to live more; that is why it is under the necessity of creating things. The One Substance desires to live more in you; hence it wants you to have all the things you can use. It is the desire of God that you should get rich. He wants you to get rich because he can express himself better through you if you have plenty of things to use in giving him expression. He can live more in you if you have unlimited command of the means of life. The universe desires you to have everything you want to have. Nature is friendly to your plans. Everything is naturally for you. Make up your mind that this is true. It is essential, however, that _your purpose should harmonize with the purpose that is in All_. You must want real life, not mere pleasure or sensual gratification. Life is the performance of function; and the individual really lives only when he performs every function, physical, mental, and spiritual, of which he is capable, without excess in any. You do not want to get rich in order to live swinishly, for the gratification of animal desires; that is not life. But the performance of every physical function is a part of life, and no one lives completely who denies the impulses of the body a normal and healthful expression. You do not want to get rich solely to enjoy mental pleasures, to get knowledge, to gratify ambition, to outshine others, to be famous. All these are a legitimate part of life, but the man who lives for the pleasures of the intellect alone will only have a partial life, and he will never be satisfied with his lot. You do not want to get rich solely for the good of others, to lose yourself for the salvation of mankind, to experience the joys of philanthropy and sacrifice. The joys of the soul are only a part of life; and they are no better or nobler than any other part. You want to get rich in order that you may eat, drink, and be merry when it is time to do these things; in order that you may surround yourself with beautiful things, see distant lands, feed your mind, and develop your intellect; in order that you may love men and do kind things, and be able to play a good part in helping the world to find truth. But remember that extreme altruism is no better and no nobler than extreme selfishness; both are mistakes. Get rid of the idea that God wants you to sacrifice yourself for others, and that you can secure his favor by doing so; God requires nothing of the kind. What he wants is that you should make the most of yourself, for yourself, and for others; and _you can help others more by making the most of yourself than in any other way_. You can make the most of yourself only by getting rich; so it is right and praiseworthy that you should give your first and best thought to the work of acquiring wealth. Remember, however, that the desire of Substance is for all, and its movements must be for more life to all; it cannot be made to work for less life to any, because it is equally in all, seeking riches and life. Intelligent Substance will make things for you, but it will not take things away from some one else and give them to you. You must get rid of the thought of competition. You are to create, not to compete for what is already created. You do not have to take anything away from any one. You do not have to drive sharp bargains. You do not have to cheat, or to take advantage. You do not need to let any man work for you for less than he earns. You do not have to covet the property of others, or to look at it with wishful eyes; no man has anything of which you cannot have the like, and that without taking what he has away from him. You are to become a creator, not a competitor; you are going to get what you want, but in such a way that when you get it every other man will have more than he has now. I am aware that there are men who get a vast amount of money by proceeding in direct opposition to the statements in the paragraph above, and may add a word of explanation here. Men of the plutocratic type, who become very rich, do so sometimes purely by their extraordinary ability on the plane of competition; and sometimes they unconsciously relate themselves to Substance in its great purposes and movements for the general racial upbuilding through industrial evolution. Rockefeller, Carnegie, Morgan, _et al._, have been the unconscious agents of the Supreme in the necessary work of systematizing and organizing productive industry; and in the end, their work will contribute immensely toward increased life for all. Their day is nearly over; they have organized production, and _will soon be succeeded by the agents of the multitude, who will organize the machinery of distribution_. The multi-millionaires are like the monster reptiles of the prehistoric eras; they play a necessary part in the evolutionary process, but the same Power which produced them will dispose of them. And it is well to bear in mind that they have never been really rich; a record of the private lives of most of this class will show that they have really been the most abject and wretched of the poor. Riches secured on the competitive plane are never satisfactory and permanent; they are yours to-day, and another’s to-morrow. Remember, if you are to become rich in a scientific and certain way, you must rise entirely out of the competitive thought. You must never think for a moment that the supply is limited. Just as soon as you begin to think that all the money is being “cornered” and controlled by bankers and others, and that you must exert yourself to get laws passed to stop this process, and so on; in that moment you drop into the competitive mind, and your power to cause creation is gone for the time being; and what is worse, you will probably arrest the creative movements you have already instituted. KNOW that there are countless millions of dollars’ worth of gold in the mountains of the earth, not yet brought to light; and know that if there were not, more would be created from Thinking Substance to supply your needs. KNOW that the money you need will come, even if it is necessary for a thousand men to be led to the discovery of new gold mines to-morrow. _Never look at the visible supply; look always at the limitless riches in Formless Substance, and KNOW that they are coming to you as fast as you can receive and use them._ Nobody, by cornering the visible supply, can prevent you from getting what is yours. So never allow yourself to think for an instant that all the best building spots will be taken before you get ready to build your house, unless you hurry. Never worry about the trusts and combines, and get anxious for fear they will soon come to own the whole earth. Never get afraid that you will lose what you want because some other person “beats you to it.” That cannot possibly happen; you are not seeking anything that is possessed by anybody else; you are causing what you want to be created from Formless Substance, and the supply is without limits. Stick to the formulated statement:-- _There is a thinking stuff from which all things are made, and which, in its original state, permeates, penetrates, and fills the interspaces of the universe._ _A thought, in this substance, produces the thing that is imaged by the thought._ _Man can form things in his thought, and, by impressing his thought upon formless substance, can cause the thing he thinks about to be created._ = How Riches Come To You. When I say that you do not have to drive sharp bargains, I do not mean that you do not have to drive any bargains at all, or that you are above the necessity for having any dealings with your fellow men. I mean that you will not need to deal with them unfairly; you do not have to get something for nothing, _but can give to every man more than you take from him_. You cannot give every man more in cash market value than you take from him, but you can give him more in use value than the cash value of the thing you take from him. The paper, ink, and other material in this book may not be worth the money you paid for it; but if the ideas suggested by it bring you thousands of dollars, you have not been wronged by those who sold it to you; they have given you a great use value for a small cash value. Let us suppose that I own a picture by one of the great artists, which, in any civilized community, is worth thousands of dollars. I take it to Baffin Bay, and by “salesmanship” induce an Eskimo to give a bundle of furs worth \$500 for it. I have really wronged him, for he has no use for the picture; it has no use value to him; it will not add to his life. But suppose I give him a gun worth \$50 for his furs; then he has made a good bargain. He has use for the gun; it will get him many more furs and much food; it will add to his life in every way; it will make him rich. When you rise from the competitive to the creative plane, you can scan your business transactions very strictly, and if you are selling any man anything which does not add more to his life than the thing he gives you in exchange, you can afford to stop it. You do not have to beat anybody in business. And if you are in a business which does beat people, get out of it at once. Give every man more in use value than you take from him in cash value; then you are adding to the life of the world by every business transaction. If you have people working for you, you must take from them more in cash value than you pay them in wages; but _you can so organize your business that it will be filled with the principle of advancement_, and so that each employee who wishes to do so may advance a little every day. You can make your business do for your employees what this book is doing for you. You can so conduct your business that it will be a sort of ladder, by which every employee who will take the trouble may climb to riches himself; and given the opportunity, if he will not do so it is not your fault. And finally, because you are to cause the creation of your riches from Formless Substance which permeates all your environment, it does not follow that they are to take shape from the atmosphere and come into being before your eyes. If you want a sewing machine, for instance, I do not mean to tell you that you are to impress the thought of a sewing machine on Thinking Substance until the machine is formed without hands, in the room where you sit, or elsewhere. But if you want a sewing machine, hold the mental image of it with the most positive certainty that it is being made, or is on its way to you. After once forming the thought, have the most absolute and unquestioning faith that the sewing machine is coming; never think of it, or speak of it, in any other way than as being sure to arrive. Claim it as already yours. It will be brought to you by the power of the Supreme Intelligence, acting upon the minds of men. If you live in Maine, it may be that a man will be brought from Texas or Japan to engage in some transaction which will result in your getting what you want. If so, the whole matter will be as much to that man’s advantage as it is to yours. Do not forget for a moment that the Thinking Substance is through all, in all, communicating with all, and can influence all. The desire of Thinking Substance for fuller life and better living has caused the creation of all the sewing machines already made; and it can cause the creation of millions more, and will, whenever men set it in motion by desire and faith, and by acting in a Certain Way. You can certainly have a sewing machine in your house; and it is just as certain that you can have any other thing or things which you want, and which you will use for the advancement of your own life and the lives of others. You need not hesitate about asking largely; “it is your Father’s pleasure to give you the kingdom,” said Jesus. Original Substance wants to live all that is possible in you, and wants you to have all that you can or will use for the living of the most abundant life. If you fix upon your consciousness the fact that the desire you feel for the possession of riches is one with the desire of Omnipotence for more complete expression, your faith becomes invincible. Once I saw a little boy sitting at a piano, and vainly trying to bring harmony out of the keys; and I saw that he was grieved and provoked by his inability to play real music. I asked him the cause of his vexation, and he answered, “I can feel the music in me, but I can’t make my hands go right.” The music in him was the URGE of Original Substance, containing all the possibilities of all life; all that there is of music was seeking expression through the child. God, the One Substance, is trying to live and do and enjoy things through humanity. He is saying, “I want hands to build wonderful structures, to play divine harmonies, to paint glorious pictures; I want feet to run my errands, eyes to see my beauties, tongues to tell mighty truths and to sing marvelous songs,” and so on. All that there is of possibility is seeking expression through men. God wants those who can play music to have pianos and every other instrument, and to have the means to cultivate their talents to the fullest extent; He wants those who can appreciate beauty to be able to surround themselves with beautiful things; He wants those who can discern truth to have every opportunity to travel and observe; He wants those who can appreciate dress to be beautifully clothed, and those who can appreciate good food to be luxuriously fed. He wants all these things because it is Himself that enjoys and appreciates them; it is God who wants to play, and sing, and enjoy beauty, and proclaim truth, and wear fine clothes, and eat good foods. “It is God that worketh in you to will and to do,” said Paul. The desire you feel for riches is the Infinite, seeking to express Himself in you as He sought to find expression in the little boy at the piano. So you need not hesitate to ask largely. Your part is to focalize and express the desires of God. This is a difficult point with most people; they retain something of the old idea that poverty and self-sacrifice are pleasing to God. They look upon poverty as a part of the plan, a necessity of nature. They have the idea that God has finished His work, and made all that He can make, and that the majority of men must stay poor because there is not enough to go around. They hold to so much of this erroneous thought that they feel ashamed to ask for wealth; they try not to want more than a very modest competence, just enough to make them fairly comfortable. I recall now the case of one student who was told that he must get in mind a clear picture of the things he desired, so that the creative thought of them might be impressed on Formless Substance. He was a very poor man, living in a rented house, and having only what he earned from day to day; and he could not grasp the fact that all wealth was his. So, after thinking the matter over, he decided that he might reasonably ask for a new rug for the floor of his best room, and an anthracite coal stove to heat the house during the cold weather. Following the instructions given in this book, he obtained these things in a few months; and then it dawned upon him that he had not asked enough. He went through the house in which he lived, and planned all the improvements he would like to make in it; he mentally added a bay window here and a room there, until it was complete in his mind as his ideal home; and then he planned its furnishings. Holding the whole picture in his mind, he began living in the Certain Way, and moving toward what he wanted; and he owns the house now, and is rebuilding it after the form of his mental image. And now, with still larger faith, he is going on to get greater things. It has been unto him according to his faith, and it is so with you and with all of us. = Gratitude. The illustrations given in the last chapter will have conveyed to the reader the fact that the first step toward getting rich is to convey the idea of your wants to the Formless Substance. This is true, and you will see that in order to do so it becomes necessary to relate yourself to the Formless Intelligence in a harmonious way. To secure this harmonious relation is a matter of such primary and vital importance that I shall give some space to its discussion here, and give you instructions which, if you will follow them, will be certain to bring you into perfect unity of mind with God. The whole process of mental adjustment and atonement can be summed up in one word, _gratitude_. First, you believe that there is one Intelligent Substance, from which all things proceed; second, you believe that this Substance gives you everything you desire; and third, you relate yourself to It by a feeling of deep and profound gratitude. Many people who order their lives rightly in all other ways are kept in poverty by their lack of gratitude. Having received one gift from God, they cut the wires which connect them with Him by failing to make acknowledgment. It is easy to understand that the nearer we live to the source of wealth, the more wealth we shall receive; and it is easy also to understand that the soul that is always grateful lives in closer touch with God than the one which never looks to Him in thankful acknowledgment. The more gratefully we fix our minds on the Supreme when good things come to us, the more good things we will receive, and the more rapidly they will come; and the reason simply is that the mental attitude of gratitude draws the mind into closer touch with the source from which the blessings come. If it is a new thought to you that gratitude brings your whole mind into closer harmony with the creative energies of the universe, consider it well, and you will see that it is true. The good things you already have have come to you along the line of obedience to certain laws. Gratitude will lead your mind out along the ways by which things come; and it will keep you in close harmony with creative thought and prevent you from falling into competitive thought. Gratitude alone can keep you looking toward the All, and prevent you from falling into the error of thinking of the supply as limited; and to do that would be fatal to your hopes. There is a Law of Gratitude, and it is absolutely necessary that you should observe the law, if you are to get the results you seek. The law of gratitude is the natural principle that action and reaction are always equal, and in opposite directions. The grateful outreaching of your mind in thankful praise to the Supreme _is a liberation or expenditure of force; it cannot fail to reach that to which it is addressed, and the reaction is an instantaneous movement toward you_. “Draw nigh unto God, and He will draw nigh unto you.” That is a statement of psychological truth. And if your gratitude is strong and constant, the reaction in Formless Substance will be strong and continuous; the movement of the things you want will be always toward you. Notice the grateful attitude that Jesus took; how He always seems to be saying, “I thank Thee, Father, that Thou hearest me.” You cannot exercise much power without gratitude; for it is gratitude that keeps you connected with Power. But the value of gratitude does not consist solely in getting you more blessings in the future. Without gratitude you cannot long keep from dissatisfied thought regarding things as they are. The moment you permit your mind to dwell with dissatisfaction upon things as they are, you begin to lose ground. You fix attention upon the common, the ordinary, the poor, and the squalid and mean; and your mind takes the form of these things. Then you will transmit these forms or mental images to the Formless, and the common, the poor, the squalid, and mean will come to you. To permit your mind to dwell upon the inferior is to become inferior and to surround yourself with inferior things. On the other hand, to fix your attention on the best is to surround yourself with the best, and to become the best. The Creative Power within us makes us into the image of that to which we give our attention. We are Thinking Substance, and thinking substance always takes the form of that which it thinks about. The grateful mind is constantly fixed upon the best; therefore it tends to become the best; it takes the form or character of the best, and will receive the best. Also, faith is born of gratitude. The grateful mind continually expects good things, and expectation becomes faith. The reaction of gratitude upon one’s own mind produces faith; and every outgoing wave of grateful thanksgiving increases faith. He who has no feeling of gratitude cannot long retain a living faith; and without a living faith you cannot get rich by the creative method, as we shall see in the following chapters. It is necessary, then, to cultivate the habit of being grateful for every good thing that comes to you; and to give thanks continuously. And because all things have contributed to your advancement, you should include all things in your gratitude. Do not waste time thinking or talking about the shortcomings or wrong actions of plutocrats or trust magnates. Their organization of the world has made your opportunity; all you get really comes to you because of them. Do not rage against corrupt politicians; if it were not for politicians we should fall into anarchy, and your opportunity would be greatly lessened. God has worked a long time and very patiently to bring us up to where we are in industry and government, and He is going right on with His work. There is not the least doubt that He will do away with plutocrats, trust magnates, captains of industry, and politicians as soon as they can be spared; but in the meantime, behold they are all very good. Remember that they are all helping to arrange the lines of transmission along which your riches will come to you, and be grateful to them all. This will bring you into harmonious relations with the good in everything, and the good in everything will move toward you. = Thinking In The Certain Way. Turn back to chapter VI., and read again the story of the man who formed a mental image of his house, and you will get a fair idea of the initial step toward getting rich. You must form a clear and definite mental picture of what you want; you cannot transmit an idea unless you have it yourself. You must have it before you can give it; and many people fail to impress Thinking Substance because they have themselves only a vague and misty concept of the things they want to do, to have, or to become. It is not enough that you should have a general desire for wealth “to do good with”; everybody has that desire. It is not enough that you should have a wish to travel, see things, live more, etc. Everybody has those desires also. If you were going to send a wireless message to a friend, you would not send the letters of the alphabet in their order, and let him construct the message for himself; nor would you take words at random from the dictionary. You would send a coherent sentence; one which meant something. When you try to impress your wants upon Substance, remember that it must be done by a coherent statement; you must know what you want, and be definite. You can never get rich, or start the creative power into action, by sending out unformed longings and vague desires. Go over your desires just as the man I have described went over his house; see just what you want, and get a clear mental picture of it as you wish it to look when you get it. That clear mental picture you must have continually in mind, as the sailor has in mind the port toward which he is sailing the ship; you must keep your face toward it all the time. You must no more lose sight of it than the steersman loses sight of the compass. It is not necessary to take exercises in concentration, nor to set apart special times for prayer and affirmation, nor to “go into the silence,” nor to do occult stunts of any kind. These things are well enough, but all you need is to know what you want, and to want it badly enough so that it will stay in your thoughts. Spend as much of your leisure time as you can in contemplating your picture, but no one needs to take exercises to concentrate his mind on a thing which he really wants; it is the things you do not really care about which require effort to fix your attention upon them. And unless you really want to get rich, so that the desire is strong enough to hold your thoughts directed to the purpose as the magnetic pole holds the needle of the compass, it will hardly be worth while for you to try to carry out the instructions given in this book. The methods herein set forth are for people whose desire for riches is strong enough to overcome mental laziness and the love of ease, and make them work. The more clear and definite you make your picture, then, and the more you dwell upon it, bringing out all its delightful details, the stronger your desire will be; and the stronger your desire, the easier it will be to hold your mind fixed upon the picture of what you want. Something more is necessary, however, than merely to see the picture clearly. If that is all you do, you are only a dreamer, and will have little or no power for accomplishment. Behind your clear vision must be the purpose to realize it; to bring it out in tangible expression. And behind this purpose must be an invincible and unwavering FAITH that the thing is already yours; that it is “at hand” and you have only to take possession of it. Live in the new house, mentally, until it takes form around you physically. In the mental realm, enter at once into full enjoyment of the things you want. “Whatsoever things ye ask for when ye pray, believe that ye receive them, and ye shall have them,” said Jesus. See the things you want as if they were actually around you all the time; see yourself as owning and using them. Make use of them in imagination just as you will use them when they are your tangible possessions. Dwell upon your mental picture until it is clear and distinct, and then take the Mental Attitude of Ownership toward everything in that picture. Take possession of it, in mind, in the full faith that it is actually yours. Hold to this mental ownership; do not waver for an instant in the faith that it is real. And remember what was said in a preceding chapter about gratitude; be as thankful for it all the time as you expect to be when it has taken form. The man who can sincerely thank God for the things which as yet he owns only in imagination, has real faith. He will get rich; he will cause the creation of whatsoever he wants. You do not need to pray repeatedly for the things you want; it is not necessary to tell God about it every day. “Use not vain repetitions as the heathen do,” said Jesus to His pupils, “for your Father knoweth that ye have need of these things before ye ask Him.” Your part is to intelligently formulate your desire for the things which make for a larger life, and to get these desires arranged into a coherent whole; and then to impress this Whole Desire upon the Formless Substance, which has the power and the will to bring you what you want. You do not make this impression by repeating strings of words; you make it by holding the vision with unshakable PURPOSE to attain it, and with steadfast FAITH that you do attain it. The answer to prayer is not according to your faith while you are talking, but according to your faith while you are working. You cannot impress the mind of God by having a special Sabbath day set apart to tell Him what you want, and then forgetting Him during the rest of the week. You cannot impress Him by having special hours to go into your closet and pray, if you then dismiss the matter from your mind until the hour of prayer comes again. Oral prayer is well enough, and has its effect, especially upon yourself, in clarifying your vision and strengthening your faith; but it is not your oral petitions which get you what you want. In order to get rich you do not need a “sweet hour of prayer”; you need to “pray without ceasing.” And by prayer I mean holding steadily to your vision, with the purpose to cause its creation into solid form, and the faith that you are doing so. “Believe that ye _receive_ them.” The whole matter turns on receiving, once you have clearly formed your vision. When you _have_ formed it, it is well to make an oral statement, addressing the Supreme in reverent prayer; and from that moment you must, in mind, receive what you ask for. Live in the new house; wear the fine clothes; ride in the automobile; go on the journey, and confidently plan for greater journeys. Think and speak of all the things you have asked for in terms of actual present ownership. Imagine an environment, and a financial condition exactly as you want them, and live all the time in that imaginary environment and financial condition. Mind, however, that you do not do this as a mere dreamer and castle builder; hold to the FAITH that the imaginary is being realized, and to the PURPOSE to realize it. Remember that it is faith and purpose in the use of the imagination which make the difference between the scientist and the dreamer. And having learned this fact, it is here that you must learn the proper use of the Will. = How To Use The Will. To set about getting rich in a scientific way, you do not try to apply your will power to anything outside of yourself. You have no right to do so, anyway. It is wrong to apply your will to other men and women, in order to get them to do what you wish done. It is as flagrantly wrong to coerce people by mental power as it is to coerce them by physical power. If compelling people by physical force to do things for you reduces them to slavery, compelling them by mental means accomplishes exactly the same thing; the only difference is in methods. If taking things from people by physical force is robbery, then taking things by mental force is robbery also; there is no difference in principle. You have no right to use your will power upon another person, even “for his own good”; for you do not know what is for his good. The science of getting rich does not require you to apply power or force to any other person, in any way whatsoever. There is not the slightest necessity for doing so; indeed, any attempt to use your will upon others will only tend to defeat your purpose. You do not need to apply your will to things, in order to compel them to come to you. That would simply be trying to coerce God, and would be foolish and useless, as well as irreverent. You do not have to compel God to give you good things, any more than you have to use your will power to make the sun rise. You do not have to use your will power to conquer an unfriendly deity, or to make stubborn and rebellious forces do your bidding. Substance is friendly to you, and is more anxious to give you what you want than you are to get it. To get rich, you need only to use your will power upon yourself. When you know what to think and do, then you must use your will to compel yourself to think and do the right things. That is the legitimate use of the will in getting what you want--to use it in holding yourself to the right course. Use your will to keep yourself thinking and acting in the Certain Way. Do not try to project your will, or your thoughts, or your mind out into space, to “act” on things or people. Keep your mind at home; it can accomplish more there than elsewhere. Use your mind to form a mental image of what you want, and to hold that vision with faith and purpose; and use your will to keep your mind working in the Right Way. The more steady and continuous your faith and purpose, the more rapidly you will get rich, because you will make only POSITIVE impressions upon Substance; and you will not neutralize or offset them by negative impressions. The picture of your desires, held with faith and purpose, is taken up by the Formless, and permeates it to great distances,--throughout the universe, for all I know. As this impression spreads, all things are set moving toward its realization; every living thing, every inanimate thing, and the things yet uncreated, are stirred toward bringing into being that which you want. All force begins to be exerted in that direction; all things begin to move toward you. The minds of people, everywhere, are influenced toward doing the things necessary to the fulfilling of your desires; and they work for you, unconsciously. But you can check all this by starting a negative impression in the Formless Substance. Doubt or unbelief is as certain to start a movement away from you as faith and purpose are to start one toward you. It is by not understanding this that most people who try to make use of “mental science” in getting rich make their failure. Every hour and moment you spend in giving heed to doubts and fears, every hour you spend in worry, every hour in which your soul is possessed by unbelief, sets a current away from you in the whole domain of intelligent Substance. All the promises are unto them that believe, and unto them only. Notice how insistent Jesus was upon this point of belief; and now you know the reason why. Since belief is all important, it behooves you to guard your thoughts; and as your beliefs will be shaped to a very great extent by the things you observe and think about, it is important that you should command your attention. And here the will comes into use; for it is by your will that you determine upon what things your attention shall be fixed. If you want to become rich, you must not make a study of poverty. Things are not brought into being by thinking about their opposites. Health is never to be attained by studying disease and thinking about disease; righteousness is not to be promoted by studying sin and thinking about sin; and no one ever got rich by studying poverty and thinking about poverty. Medicine as a science of disease has increased disease; religion as a science of sin has promoted sin, and economics as a study of poverty will fill the world with wretchedness and want. Do not talk about poverty; do not investigate it, or concern yourself with it. Never mind what its causes are; you have nothing to do with them. What concerns you is the cure. Do not spend your time in charitable work, or charity movements; all charity only tends to perpetuate the wretchedness it aims to eradicate. I do not say that you should be hard-hearted or unkind, and refuse to hear the cry of need; but you must not try to eradicate poverty in any of the conventional ways. Put poverty behind you, and put all that pertains to it behind you, and “make good.” Get rich; that is the best way you can help the poor. And you cannot hold the mental image which is to make you rich if you fill your mind with pictures of poverty. Do not read books or papers which give circumstantial accounts of the wretchedness of the tenement dwellers, of the horrors of child labor, and so on. Do not read anything which fills your mind with gloomy images of want and suffering. You cannot help the poor in the least by knowing about these things; and the wide-spread knowledge of them does not tend at all to do away with poverty. What tends to do away with poverty is not the getting of pictures of poverty into your mind, but getting pictures of wealth into the minds of the poor. You are not deserting the poor in their misery when you refuse to allow your mind to be filled with pictures of that misery. Poverty can be done away with, not by increasing the number of well-to-do people who think about poverty, but by increasing the number of poor people who propose with faith to get rich. The poor do not need charity; they need inspiration. Charity only sends them a loaf of bread to keep them alive in their wretchedness, or gives them an entertainment to make them forget for an hour or two; but inspiration will cause them to rise out of their misery. If you want to help the poor, demonstrate to them that they can become rich; prove it by getting rich yourself. The only way in which poverty will ever be banished from this world is by getting a large and constantly increasing number of people to practice the teachings of this book. People must be taught to become rich by creation, not by competition. Every man who becomes rich by competition throws down behind him the ladder by which he rises, and keeps others down; but every man who gets rich by creation opens a way for thousands to follow him, and inspires them to do so. You are not showing hardness of heart or an unfeeling disposition when you refuse to pity poverty, see poverty, read about poverty, or think or talk about it, or to listen to those who do talk about it. Use your will power to keep your mind OFF the subject of poverty, and to keep it fixed with faith and purpose ON the vision of what you want. = Further Use Of The Will. You cannot retain a true and clear vision of wealth if you are constantly turning your attention to opposing pictures, whether they be external or imaginary. Do not tell of your past troubles of a financial nature, if you have had them; do not think of them at all. Do not tell of the poverty of your parents, or the hardships of your early life; to do any of these things is to mentally class yourself with the poor for the time being, and it will certainly check the movement of things in your direction. “Let the dead bury their dead,” as Jesus said. Put poverty and all things that pertain to poverty completely behind you. You have accepted a certain theory of the universe as being correct, and are resting all your hopes of happiness on its being correct; and what can you gain by giving heed to conflicting theories? Do not read religious books which tell you that the world is soon coming to an end; and do not read the writings of muck-rakers and pessimistic philosophers who tell you that it is going to the devil. The world is not going to the devil; it is going to God. It is a wonderful Becoming. True, there may be a good many things in existing conditions which are disagreeable; but what is the use of studying them when they are certainly passing away, and when the study of them only tends to check their passing and keep them with us? Why give time and attention to things which are being removed by evolutionary growth, when you can hasten their removal only by promoting the evolutionary growth as far as your part of it goes? No matter how horrible in seeming may be the conditions in certain countries, sections, or places, you waste your time and destroy your own chances by considering them. You should interest yourself in the world’s becoming rich. Think of the riches the world is coming into, instead of the poverty it is growing out of; and bear in mind that the only way in which you can assist the world in growing rich is by growing rich yourself through the creative method--not the competitive one. Give your attention wholly to riches; ignore poverty. Whenever you think or speak of those who are poor, think and speak of them as those who are becoming rich; as those who are to be congratulated rather than pitied. Then they and others will catch the inspiration, and begin to search for the way out. Because I say that you are to give your whole time and mind and thought to riches, it does not follow that you are to be sordid or mean. To become really rich is the noblest aim you can have in life, for it includes everything else. On the competitive plane, the struggle to get rich is a Godless scramble for power over other men; but when we come into the creative mind, all this is changed. All that is possible in the way of greatness and soul unfoldment, of service and lofty endeavor, comes by way of getting rich; all is made possible by the use of things. If you lack for physical health, you will find that the attainment of it is conditional on your getting rich. Only those who are emancipated from financial worry, and who have the means to live a care-free existence and follow hygienic practices, can have and retain health. Moral and spiritual greatness is possible only to those who are above the competitive battle for existence; and only those who are becoming rich on the plane of creative thought are free from the degrading influences of competition. If your heart is set on domestic happiness, remember that love flourishes best where there is refinement, a high level of thought, and freedom from corrupting influences; and these are to be found only where riches are attained by the exercise of creative thought, without strife or rivalry. You can aim at nothing so great or noble, I repeat, as to become rich; and you must fix your attention upon your mental picture of riches, to the exclusion of all that may tend to dim or obscure the vision. You must learn to see the underlying TRUTH in all things; you must see beneath all seemingly wrong conditions the Great One Life ever moving forward toward fuller expression and more complete happiness. It is the truth that there is no such thing as poverty; that there is only wealth. Some people remain in poverty because they are ignorant of the fact that there is wealth for them; and these can best be taught by showing them the way to affluence in your own person and practice. Others are poor because, while they feel that there is a way out, they are too intellectually indolent to put forth the mental effort necessary to find that way and travel it; and for these the very best thing you can do is to arouse their desire by showing them the happiness that comes from being rightly rich. Others still are poor because, while they have some notion of science, they have become so swamped and lost in the maze of metaphysical and occult theories that they do not know which road to take. They try a mixture of many systems and fail in all. For these, again, the very best thing to do is to show the right way in your own person and practice; an ounce of doing things is worth a pound of theorizing. The very best thing you can do for the whole world is to make the most of yourself. You can serve God and man in no more effective way than by getting rich; that is, if you get rich by the creative method, and not by the competitive one. Another thing. We assert that this book gives in detail the principles of the science of getting rich; and if that is true, you do not need to read any other book upon the subject. This may sound narrow and egotistical, but consider: there is no more scientific method of computation in mathematics than by addition, subtraction, multiplication, and division; no other method is possible. There can be but one shortest distance between two points. There is only one way to think scientifically, and that is to think in the way that leads by the most direct and simple route to the goal. No man has yet formulated a briefer or less complex “system” than the one set forth herein; it has been stripped of all non-essentials. When you commence on this, lay all others aside; put them out of your mind altogether. Read this book every day; keep it with you; commit it to memory, and do not think about other “systems” and theories. If you do, you will begin to have doubts, and to be uncertain and wavering in your thought; and then you will begin to make failures. After you have made good and become rich, you may study other systems as much as you please; but until you are quite sure that you have gained what you want, do not read anything on this line but this book, unless it be the authors mentioned in the Preface. And read only the most optimistic comments on the world’s news; those in harmony with your picture. Also, postpone your investigations into the occult. Do not dabble in Theosophy, Spiritualism, or kindred studies. It is very likely that the dead still live, and are near; but if they are, let them alone; mind your own business. Wherever the spirits of the dead may be, they have their own work to do, and their own problems to solve; and we have no right to interfere with them. We cannot help them, and it is very doubtful whether they can help us, or whether we have any right to trespass upon their time if they can. Let the dead and the hereafter alone, and solve your own problem; get rich. If you begin to mix with the occult, you will start mental cross-currents which will surely bring your hopes to shipwreck. Now, this and the preceding chapters have brought us to the following statement of basic facts:-- _There is a thinking stuff from which all things are made, and which, in its original state, permeates, penetrates, and fills the interspaces of the universe._ _A thought, in this substance, produces the thing that is imaged by the thought._ _Man can form things in his thought, and, by impressing his thought upon formless substance, can cause the thing he thinks about to be created._ _In order to do this, man must pass from the competitive to the creative mind; he must form a clear mental picture of the things he wants, and hold this picture in his thoughts with the fixed PURPOSE to get what he wants, and the unwavering FAITH that he does get what he wants, closing his mind against all that may tend to shake his purpose, dim his vision, or quench his faith._ And in addition to all this, we shall now see that he must live and act in a Certain Way. = Acting In The Certain Way. Thought is the creative power, or the impelling force which causes the creative power to act; thinking in a Certain Way will bring riches to you, but you must not rely upon thought alone, paying no attention to personal action. That is the rock upon which many otherwise scientific metaphysical thinkers meet shipwreck--the failure to connect thought with personal action. We have not yet reached the stage of development, even supposing such a stage to be possible, in which man can create directly from Formless Substance without nature’s processes or the work of human hands; man must not only think, but his personal action must supplement his thought. By thought you can cause the gold in the hearts of the mountains to be impelled toward you; but it will not mine itself, refine itself, coin itself into double eagles, and come rolling along the roads seeking its way into your pocket. Under the impelling power of the Supreme Spirit, men’s affairs will be so ordered that some one will be led to mine the gold for you; other men’s business transactions will be so directed that the gold will be brought toward you, and you must so arrange your own business affairs that you may be able to receive it when it comes to you. Your thought makes all things, animate and inanimate, work to bring you what you want; but your personal activity must be such that you can rightly receive what you want when it reaches you. You are not to take it as charity, nor to steal it; you must give every man more in use value than he gives you in cash value. The scientific use of thought consists in forming a clear and distinct mental image of what you want; in holding fast to the purpose to get what you want; and in realizing with grateful faith that you _do_ get what you want. Do not try to “project” your thought in any mysterious or occult way, with the idea of having it go out and do things for you; that is wasted effort, and will weaken your power to think with sanity. The action of thought in getting rich is fully explained in the preceding chapters; your faith and purpose positively impress your vision upon Formless Substance, which has THE SAME DESIRE FOR MORE LIFE THAT YOU HAVE; and this vision, received from you, sets all the creative forces at work IN AND THROUGH THEIR REGULAR CHANNELS OF ACTION, but directed toward you. It is not your part to guide or supervise the creative process; all you have to do with that is to retain your vision, stick to your purpose, and maintain your faith and gratitude. But you must act in a Certain Way, so that you can appropriate what is yours when it comes to you; so that you can meet the things you have in your picture, and put them in their proper places as they arrive. You can readily see the truth of this. When things reach you, they will be in the hands of other men, who will ask an equivalent for them. And you can only get what is yours by giving the other man what is his. Your pocketbook is not going to be transformed into a Fortunatus’s purse, which shall be always full of money without effort on your part. This is the crucial point in the science of getting rich; right here, where thought and personal action must be combined. There are very many people who, consciously or unconsciously, set the creative forces in action by the strength and persistence of their desires, but who remain poor because they do not provide for the reception of the thing they want when it comes. By thought, the thing you want is brought to you; by action you receive it. Whatever your action is to be, it is evident that you must act NOW. You cannot act in the past, and it is essential to the clearness of your mental vision that you dismiss the past from your mind. You cannot act in the future, for the future is not here yet. And you cannot tell how you will want to act in any future contingency until that contingency has arrived. Because you are not in the right business, or the right environment now, do not think that you must postpone action until you get into the right business or environment. And do not spend time in the present taking thought as to the best course in possible future emergencies; have faith in your ability to meet any emergency when it arrives. If you act in the present with your mind on the future, your present action will be with a divided mind, and will not be effective. Put your whole mind into present action. Do not give your creative impulse to Original Substance, and then sit down and wait for results; if you do, you will never get them. Act now. There is never any time but now, and there never will be any time but now. If you are ever to begin to make ready for the reception of what you want, you must begin now. And your action, whatever it is, must most likely be in your present business or employment, and must be upon the persons and things in your present environment. You cannot act where you are not; you cannot act where you have been, and you cannot act where you are going to be; you can act only where you are. Do not bother as to whether yesterday’s work was well done or ill done; do to-day’s work well. Do not try to do to-morrow’s work now; there will be plenty of time to do that when you get to it. Do not try, by occult or mystical means, to act on people or things that are out of your reach. Do not wait for a change of environment before you act; get a change of environment by action. You can so act upon the environment in which you are now, as to cause yourself to be transferred to a better environment. Hold with faith and purpose the vision of yourself in the better environment, but act upon your present environment with all your heart, and with all your strength, and with all your mind. Do not spend any time in day dreaming or castle building; hold to the one vision of what you want, and act NOW. Do not cast about seeking some new thing to do, or some strange, unusual, or remarkable action to perform as a first step toward getting rich. It is probable that your actions, at least for some time to come, will be those you have been performing for some time past; but you are to begin now to perform these actions in the Certain Way, which will surely make you rich. If you are engaged in some business, and feel that it is not the right one for you, do not wait until you get into the right business before you begin to act. Do not feel discouraged, or sit down and lament because you are misplaced. No man was ever so misplaced but that he could find the right place, and no man ever became so involved in the wrong business but that he could get into the right business. Hold the vision of yourself in the right business, with the purpose to get into it, and the faith that you will get into it, and are getting into it; but ACT in your present business. Use your present business as the means of getting a better one, and use your present environment as the means of getting into a better one. Your vision of the right business, if held with faith and purpose, will cause the Supreme to move the right business toward you; and your action, if performed in the Certain Way, will cause you to move toward the business. If you are an employee, or wage earner, and feel that you must change places in order to get what you want, do not “project” your thought into space and rely upon it to get you another job. It will probably fail to do so. Hold the vision of yourself in the job you want, while you ACT with faith and purpose on the job you have, and you will certainly get the job you want. Your vision and faith will set the creative force in motion to bring it toward you, and your action will cause the forces in your own environment to move you toward the place you want. In closing this chapter, we will add another statement to our syllabus:-- _There is a thinking stuff from which all things are made, and which, in its original state, permeates, penetrates, and fills the interspaces of the universe._ _A thought, in this substance, produces the thing that is imaged by the thought._ _Man can form things in his thought, and, by impressing his thoughts upon formless substance, can cause the thing he thinks about to be created._ _In order to do this, man must pass from the competitive to the creative mind; he must form a clear mental picture of the things he wants, and hold this picture in his thoughts with the fixed PURPOSE to get what he wants, and the unwavering FAITH that he does get what he wants, closing his mind to all that may tend to shake his purpose, dim his vision, or quench his faith._ _That he may receive what he wants when it comes, man must act NOW upon the people and things in his present environment._ = Efficient Action. You must use your thought as directed in previous chapters, and begin to do what you can do where you are; and you must do ALL that you can do where you are. You can advance only by being larger than your present place; and no man is larger than his present place who leaves undone any of the work pertaining to that place. The world is advanced only by those who more than fill their present places. If no man quite filled his present place, you can see that there must be a going backward in everything. Those who do not quite fill their present places are a dead weight upon society, government, commerce, and industry; they must be carried along by others at a great expense. The progress of the world is retarded only by those who do not fill the places they are holding; they belong to a former age and a lower stage or plane of life, and their tendency is toward degeneration. No society could advance if every man was smaller than his place; social evolution is guided by the law of physical and mental evolution. In the animal world, evolution is caused by excess of life. When an organism has more life than can be expressed in the functions of its own plane, it develops the organs of a higher plane, and a new species is originated. There never would have been new species had there not been organisms which more than filled their places. The law is exactly the same for you; your getting rich depends upon your applying this principle to your own affairs. Every day is either a successful day or a day of failure; and it is the successful days which get you what you want. If every day is a failure, you can never get rich; while if every day is a success, you cannot fail to get rich. If there is something that may be done to-day, and you do not do it, you have failed in so far as that thing is concerned; and the consequences may be more disastrous than you imagine. You cannot foresee the results of even the most trivial act; you do not know the workings of all the forces that have been set moving in your behalf. Much may be depending on your doing some simple act; it may be the very thing which is to open the door of opportunity to very great possibilities. You can never know all the combinations which Supreme Intelligence is making for you in the world of things and of human affairs; your neglect or failure to do some small thing may cause a long delay in getting what you want. Do, every day, ALL that can be done that day. There is, however, a limitation or qualification of the above that you must take into account. You are not to overwork, nor to rush blindly into your business in the effort to do the greatest possible number of things in the shortest possible time. You are not to try to do to-morrow’s work to-day, nor to do a week’s work in a day. _It is really not the number of things you do, but the EFFICIENCY of each separate action that counts._ Every act is, in itself, either a success or a failure. Every act is, in itself, either effective or inefficient. Every inefficient act is a failure, and if you spend your life in doing inefficient acts, your whole life will be a failure. The more things you do, the worse for you, if all your acts are inefficient ones. On the other hand, every efficient act is a success in itself, and if every act of your life is an efficient one, your whole life MUST be a success. The cause of failure is doing too many things in an inefficient manner, and not doing enough things in an efficient manner. You will see that it is a self-evident proposition that if you do not do any inefficient acts, and if you do a sufficient number of efficient acts, you will become rich. If, now, it is possible for you to make each act an efficient one, you see again that the getting of riches is reduced to an exact science, like mathematics. The matter turns, then, on the question whether you can make each separate act a success in itself. And this you can certainly do. You can make each act a success, because All Power is working with you; and All Power cannot fail. Power is at your service; and to make each act efficient you have only to put power into it. Every action is either strong or weak; and when every one is strong, you are acting in the Certain Way which will make you rich. Every act can be made strong and efficient by holding your vision while you are doing it, and putting the whole power of your FAITH and PURPOSE into it. It is at this point that the people fail who separate mental power from personal action. They use the power of mind in one place and at one time, and they act in another place and at another time. So their acts are not successful in themselves; too many of them are inefficient. But if All Power goes into every act, no matter how commonplace, every act will be a success in itself; and as in the nature of things every success opens the way to other successes, your progress toward what you want, and the progress of what you want toward you, will become increasingly rapid. Remember that successful action is cumulative in its results. Since the desire for more life is inherent in all things, when a man begins to move toward larger life more things attach themselves to him, and the influence of his desire is multiplied. Do, every day, all that you can do that day, and do each act in an efficient manner. In saying that you must hold your vision while you are doing each act, however trivial or commonplace, I do not mean to say that it is necessary at all times to see the vision distinctly to its smallest details. It should be the work of your leisure hours to use your imagination on the details of your vision, and to contemplate them until they are firmly fixed upon your memory. If you wish speedy results, spend practically all your spare time in this practice. By continuous contemplation you will get the picture of what you want, even to the smallest details, so firmly fixed upon your mind, and so completely transferred to the mind of Formless Substance, that in your working hours you need only to mentally refer to the picture to stimulate your faith and purpose, and cause your best effort to be put forth. Contemplate your picture in your leisure hours until your consciousness is so full of it that you can grasp it instantly. You will become so enthused with its bright promises that the mere thought of it will call forth the strongest energies of your whole being. Let us again repeat our syllabus, and by slightly changing the closing statements bring it to the point we have now reached. _There is a thinking stuff from which all things are made, and which, in its original state, permeates, penetrates, and fills the interspaces of the universe._ _A thought, in this substance, produces the thing that is imaged by the thought._ _Man can form things in his thought, and, by impressing his thought upon formless substance, can cause the thing he thinks about to be created._ _In order to do this, man must pass from the competitive to the creative mind; he must form a clear mental picture of the things he wants, and do, with faith and purpose, all that can be done each day, doing each separate thing in an efficient manner._ = Getting Into The Right Business. Success, in any particular business, depends for one thing upon your possessing in a well-developed state the faculties required in that business. Without good musical faculty no one can succeed as a teacher of music; without well-developed mechanical faculties no one can achieve great success in any of the mechanical trades; without tact and the commercial faculties no one can succeed in mercantile pursuits. But to possess in a well-developed state the faculties required in your particular vocation does not insure getting rich. There are musicians who have remarkable talent, and who yet remain poor; there are blacksmiths, carpenters, and so on who have excellent mechanical ability, but who do not get rich; and there are merchants with good faculties for dealing with men who nevertheless fail. The different faculties are tools; it is essential to have good tools, but it is also essential that the tools should be used in the Right Way. One man can take a sharp saw, a square, a good plane, and so on, and build a handsome article of furniture; another man can take the same tools and set to work to duplicate the article, but his production will be a botch. He does not know how to use good tools in a successful way. The various faculties of your mind are the tools with which you must do the work which is to make you rich; it will be easier for you to succeed if you get into a business for which you are well equipped with mental tools. Generally speaking, you will do best in that business which will use your strongest faculties; the one for which you are naturally “best fitted.” But there are limitations to this statement, also. No man should regard his vocation as being irrevocably fixed by the tendencies with which he was born. You can get rich in ANY business, for if you have not the right talent for it you can develop that talent; it merely means that you will have to make your tools as you go along, instead of confining yourself to the use of those with which you were born. It will be EASIER for you to succeed in a vocation for which you already have the talents in a well-developed state; but you CAN succeed in any vocation, for you can develop any rudimentary talent, and there is no talent of which you have not at least the rudiment. You will get rich most easily in point of effort, if you do that for which you are best fitted; but you will get rich most satisfactorily if you do that which you WANT to do. Doing what you want to do is life; and there is no real satisfaction in living if we are compelled to be forever doing something which we do not like to do, and can never do what we want to do. And it is certain that you can do what you want to do; the desire to do it is proof that you have within you the power which can do it. Desire is a manifestation of power. The desire to play music is the power which can play music seeking expression and development; the desire to invent mechanical devices is the mechanical talent seeking expression and development. Where there is no power, either developed or undeveloped, to do a thing, there is never any desire to do that thing; and where there is strong desire to do a thing, it is certain proof that the power to do it is strong, and only requires to be developed and applied in the Right Way. All things else being equal, it is best to select the business for which you have the best developed talent; but if you have a strong desire to engage in any particular line of work, you should select that work as the ultimate end at which you aim. You can do what you want to do, and it is your right and privilege to follow the business or avocation which will be most congenial and pleasant. You are not obliged to do what you do not like to do, and should not do it except as a means to bring you to the doing of the thing you want to do. If there are past mistakes whose consequences have placed you in an undesirable business or environment, you may be obliged for some time to do what you do not like to do; but you can make the doing of it pleasant by knowing that it is making it possible for you to come to the doing of what you want to do. If you feel that you are not in the right vocation, do not act too hastily in trying to get into another one. The best way, generally, to change business or environment is by growth. Do not be afraid to make a sudden and radical change if the opportunity is presented, and you feel after careful consideration that it is the right opportunity; but never take sudden or radical action when you are in doubt as to the wisdom of doing so. There is never any hurry on the creative plane; and there is no lack of opportunity. When you get out of the competitive mind you will understand that you never need to act hastily. No one else is going to beat you to the thing you want to do; there is enough for all. If one place is taken, another and a better one will be opened for you a little farther on; there is plenty of time. When you are in doubt, wait. Fall back on the contemplation of your vision, and increase your faith and purpose; and by all means, in times of doubt and indecision, cultivate gratitude. A day or two spent in contemplating the vision of what you want, and in earnest thanksgiving that you are getting it, will bring your mind into such close relationship with the Supreme that you will make no mistake when you do act. There is a mind which knows all there is to know; and you can come into close unity with this mind by faith and the purpose to advance in life, if you have deep gratitude. Mistakes come from acting hastily, or from acting in fear or doubt, or in forgetfulness of the Right Motive, which is more life to all, and less to none. As you go on in the Certain Way, opportunities will come to you in increasing number; and you will need to be very steady in your faith and purpose, and to keep in close touch with the All Mind by reverent gratitude. Do all that you can do in a perfect manner every day, but do it without haste, worry, or fear. Go as fast as you can, but never hurry. Remember that in the moment you begin to hurry you cease to be a creator and become a competitor; you drop back upon the old plane again. Whenever you find yourself hurrying, call a halt; fix your attention on the mental image of the thing you want, and begin to give thanks that you are getting it. The exercise of GRATITUDE will never fail to strengthen your faith and renew your purpose. = The Impression Of Increase. Whether you change your vocation or not, your actions for the present must be those pertaining to the business in which you are now engaged. You can get into the business you want by making constructive use of the business you are already established in; by doing your daily work in a Certain Way. And in so far as your business consists in dealing with other men, whether personally or by letter, the key-thought of all your efforts must be to convey to their minds the impression of increase. Increase is what all men and all women are seeking; it is the urge of the Formless Intelligence within them, seeking fuller expression. The desire for increase is inherent in all nature; it is the fundamental impulse of the universe. All human activities are based on the desire for increase; people are seeking more food, more clothes, better shelter, more luxury, more beauty, more knowledge, more pleasure--increase in something, more life. Every living thing is under this necessity for continuous advancement; where increase of life ceases, dissolution and death set in at once. Man instinctively knows this, and hence he is forever seeking more. This law of perpetual increase is set forth by Jesus in the parable of the talents; only those who gain more retain any; from him who hath not shall be taken away even that which he hath. The normal desire for increased wealth is not an evil or a reprehensible thing; it is simply the desire for more abundant life; it is aspiration. And because it is the deepest instinct of their natures, all men and women are attracted to him who can give them more of the means of life. In following the Certain Way as described in the foregoing pages, you are getting continuous increase for yourself, and you are giving it to all with whom you deal. You are a creative center, from which increase is given off to all. Be sure of this, and convey assurance of the fact to every man, woman, and child with whom you come in contact. No matter how small the transaction, even if it be only the selling of a stick of candy to a little child, put into it the thought of increase, and make sure that the customer is impressed with the thought. Convey the impression of advancement with everything you do, so that all people shall receive the impression that you are an Advancing Man, and that you advance all who deal with you. Even to the people whom you meet in a social way, without any thought of business, and to whom you do not try to sell anything, give the thought of increase. You can convey this impression by holding the unshakable faith that you, yourself, are in the Way of Increase; and by letting this faith inspire, fill, and permeate every action. Do everything that you do in the firm conviction that you are an advancing personality, and that you are giving advancement to everybody. Feel that you are getting rich, and that in so doing you are making others rich, and conferring benefits on all. Do not boast or brag of your success, or talk about it unnecessarily; true faith is never boastful. Wherever you find a boastful person, you find one who is secretly doubtful and afraid. Simply feel the faith, and let it work out in every transaction; let every act and tone and look express the quiet assurance that you are getting rich; that you are already rich. Words will not be necessary to communicate this feeling to others; they will feel the sense of increase when in your presence, and will be attracted to you again. You must so impress others that they will feel that in associating with you they will get increase for themselves. See that you give them a use value greater than the cash value you are taking from them. Take an honest pride in doing this, and let everybody know it; and you will have no lack of customers. People will go where they are given increase; and the Supreme, which desires increase in all, and which knows all, will move toward you men and women who have never heard of you. Your business will increase rapidly, and you will be surprised at the unexpected benefits which will come to you. You will be able from day to day to make larger combinations, secure greater advantages, and to go on into a more congenial vocation if you desire to do so. But in doing all this, you must never lose sight of your vision of what you want, or your faith and purpose to get what you want. Let me here give you another word of caution in regard to motives. _Beware of the insidious temptation to seek for power over other men._ Nothing is so pleasant to the unformed or partially developed mind as the exercise of power or dominion over others. The desire to rule for selfish gratification has been the curse of the world. For countless ages kings and lords have drenched the earth with blood in their battles to extend their dominions; this not to seek more life for all, but to get more power for themselves. To-day, the main motive in the business and industrial world is the same; men marshal their armies of dollars, and lay waste the lives and hearts of millions in the same mad scramble for power over others. Commercial kings, like political kings, are inspired by the lust for power. Jesus saw in this desire for mastery the moving impulse of that evil world He sought to overthrow. Read the twenty-third chapter of Matthew, and see how He pictures the lust of the Pharisees to be called “Master,” to sit in the high places, to domineer over others, and to lay burdens on the backs of the less fortunate; and note how He compares this lust for dominion with the brotherly seeking for the Common Good to which He calls His disciples. Look out for the temptation to seek for authority, to become a “master,” to be considered as one who is above the common herd, to impress others by lavish display, and so on. The mind that seeks for mastery over others is the competitive mind; and the competitive mind is not the creative one. In order to master your environment and your destiny, it is not at all necessary that you should rule over your fellow men; and indeed, when you fall into the world’s struggle for the high places, you begin to be conquered by fate and environment, and your getting rich becomes a matter of chance and speculation. Beware of the competitive mind! No better statement of the principle of creative action can be formulated than the favorite declaration of the late “Golden Rule” Jones of Toledo: “What I want for myself, I want for everybody.” = The Advancing Man. What I have said in the last chapter applies as well to the professional man and the wage-earner as to the man who is engaged in mercantile business. No matter whether you are a physician, a teacher, or a clergyman, if you can give increase of life to others and make them sensible of the fact, they will be attracted to you, and you will get rich. The physician who holds the vision of himself as a great and successful healer, and who works toward the complete realization of that vision with faith and purpose, as described in former chapters, will come into such close touch with the Source of Life that he will be phenomenally successful; patients will come to him in throngs. No one has a greater opportunity to carry into effect the teachings of this book than the practitioner of medicine; it does not matter to which of the various schools he may belong, for the principle of healing is common to all of them, and may be reached by all alike. The Advancing Man in medicine, who holds to a clear mental image of himself as successful, and who obeys the laws of faith, purpose, and gratitude, will cure every curable case he undertakes, no matter what remedies he may use. In the field of religion, the world cries out for the clergyman who can teach his hearers the true science of abundant life. He who masters the details of the science of getting rich, together with the allied sciences of being well, of being great, and of winning love, and who teaches these details from the pulpit, will never lack for a congregation. This is the gospel that the world needs; it will give increase of life, and men will hear it gladly, and will give liberal support to the man who brings it to them. What is now needed is a demonstration of the science of life from the pulpit. We want preachers who can not only tell us how, but who in their own persons will show us how. We need the preacher who will himself be rich, healthy, great, and beloved, to teach us how to attain to these things; and when he comes he will find a numerous and loyal following. The same is true of the teacher who can inspire the children with the faith and purpose of the advancing life. He will never be “out of a job.” And any teacher who has this faith and purpose can give it to his pupils; he cannot help giving it to them if it is part of his own life and practice. What is true of the teacher, preacher, and physician is true of the lawyer, dentist, real estate man, insurance agent--of everybody. The combined mental and personal action I have described is infallible; it cannot fail. Every man and woman who follows these instructions steadily, perseveringly, and to the letter, will get rich. The law of the Increase of Life is as mathematically certain in its operation as the law of gravitation; getting rich is an exact science. The wage-earner will find this as true of his case as of any of the others mentioned. Do not feel that you have no chance to get rich because you are working where there is no visible opportunity for advancement, where wages are small and the cost of living high. Form your clear mental vision of what you want, and begin to act with faith and purpose. Do all the work you can do, every day, and do each piece of work in a perfectly successful manner; put the power of success, and the purpose to get rich, into everything that you do. But do not do this merely with the idea of currying favor with your employer, in the hope that he, or those above you, will see your good work and advance you; it is not likely that they will do so. The man who is merely a “good” workman, filling his place to the very best of his ability, and satisfied with that, is valuable to his employer; and it is not to the employer’s interest to promote him; he is worth more where he is. To secure advancement, something more is necessary than to be too large for your place. The man who is certain to advance is the one who is too big for his place, and who has a clear concept of what he wants to be; who knows that he can become what he wants to be, and who is determined to BE what he wants to be. Do not try to more than fill your present place with a view to pleasing your employer; do it with the idea of advancing yourself. Hold the faith and purpose of increase during work hours, after work hours, and before work hours. Hold it in such a way that every person who comes in contact with you, whether foreman, fellow workman, or social acquaintance, will feel the power of purpose radiating from you; so that every one will get the sense of advancement and increase from you. Men will be attracted to you, and if there is no possibility for advancement in your present job, you will very soon see an opportunity to take another job. There is a Power which never fails to present opportunity to the Advancing Man who is moving in obedience to law. God cannot help helping you, if you act in a Certain Way; He must do so in order to help Himself. There is nothing in your circumstances or in the industrial situation that can keep you down. If you cannot get rich working for the steel trust, you can get rich on a ten-acre farm; and if you begin to move in the Certain Way, you will certainly escape from the “clutches” of the steel trust and get on to the farm or wherever else you wish to be. If a few thousands of its employees would enter upon the Certain Way, the steel trust would soon be in a bad plight; it would have to give its workingmen more opportunity, or go out of business. Nobody has to work for a trust; the trusts can keep men in so-called hopeless conditions only so long as there are men who are too ignorant to know of the science of getting rich, or too intellectually slothful to practice it. Begin this way of thinking and acting, and your faith and purpose will make you quick to see any opportunity to better your condition. Such opportunities will speedily come, for the Supreme, working in All, and working for you, will bring them before you. Do not wait for an opportunity to be all that you want to be; when an opportunity to be more than you are now is presented and you feel impelled toward it, take it. It will be the first step toward a greater opportunity. There is no such thing possible in this universe as a lack of opportunities for the man who is living the advancing life. It is inherent in the constitution of the cosmos that all things shall be for him and work together for his good; and he must certainly get rich if he acts and thinks in the Certain Way. So let wage-earning men and women study this book with great care, and enter with confidence upon the course of action it prescribes; it will not fail. = Some Cautions, And Concluding Observations. Many people will scoff at the idea that there is an exact science of getting rich; holding the impression that the supply of wealth is limited, they will insist that social and governmental institutions must be changed before even any considerable number of people can acquire a competence. But this is not true. It is true that existing governments keep the masses in poverty, but this is because the masses do not think and act in the Certain Way. If the masses begin to move forward as suggested in this book, neither governments nor industrial systems can check them; all systems must be modified to accommodate the forward movement. If the people have the Advancing Mind, have the Faith that they can become rich, and move forward with the fixed purpose to become rich, nothing can possibly keep them in poverty. Individuals may enter upon the Certain Way at any time, and under any government, and make themselves rich; and when any considerable number of individuals do so under any government, they will cause the system to be so modified as to open the way for others. The more men who get rich on the competitive plane, the worse for others; the more who get rich on the creative plane, the better for others. The economic salvation of the masses can only be accomplished by getting a large number of people to practice the scientific method set down in this book, and become rich. These will show others the way, and inspire them with a desire for real life, with the faith that it can be attained, and with the purpose to attain it. For the present, however, it is enough to know that neither the government under which you live nor the capitalistic or competitive system of industry can keep you from getting rich. When you enter upon the creative plane of thought you will rise above all these things and become a citizen of another kingdom. But remember that your thought must be held upon the creative plane; you are never for an instant to be betrayed into regarding the supply as limited, or into acting on the moral level of competition. Whenever you do fall into old ways of thought, correct yourself instantly; for when you are in the competitive mind, you have lost the co-operation of the Mind of the Whole. Do not spend any time in planning as to how you will meet possible emergencies in the future, except as the necessary policies may affect your actions to-day. You are concerned with doing to-day’s work in a perfectly successful manner, and not with emergencies which may arise to-morrow; you can attend to them as they come. Do not concern yourself with questions as to how you shall surmount obstacles which may loom upon your business horizon, unless you can see plainly that your course must be altered to-day in order to avoid them. No matter how tremendous an obstruction may appear at a distance, you will find that if you go on in the Certain Way it will disappear as you approach it, or that a way over, through, or around it will appear. No possible combination of circumstances can defeat a man or woman who is proceeding to get rich along strictly scientific lines. No man or woman who obeys the law can fail to get rich, any more than one can multiply two by two and fail to get four. Give no anxious thought to possible disasters, obstacles, panics, or unfavorable combinations of circumstances; it is time enough to meet such things when they present themselves before you in the immediate present, and you will find that every difficulty carries with it the wherewithal for its overcoming. Guard your speech. Never speak of yourself, your affairs, or of anything else in a discouraged or discouraging way. Never admit the possibility of failure, or speak in a way that infers failure as a possibility. Never speak of the times as being hard, or of business conditions as being doubtful. Times may be hard and business doubtful for those who are on the competitive plane, but they can never be so for you; you can create what you want, and you are above fear. When others are having hard times and poor business, you will find your greatest opportunities. Train yourself to think of and to look upon the world as a something which is Becoming, which is growing; and to regard seeming evil as being only that which is undeveloped. Always speak in terms of advancement; to do otherwise is to deny your faith, and to deny your faith is to lose it. Never allow yourself to feel disappointed. You may expect to have a certain thing at a certain time, and not get it at that time; and this will appear to you like failure. But if you hold to your faith you will find that the failure is only apparent. Go on in the certain way, and if you do not receive that thing, you will receive something so much better that you will see that the seeming failure was really a great success. A student of this science had set his mind on making a certain business combination which seemed to him at the time to be very desirable, and he worked for some weeks to bring it about. When the crucial time came, the thing failed in a perfectly inexplicable way; it was as if some unseen influence had been working secretly against him. He was not disappointed; on the contrary, he thanked God that his desire had been overruled, and went steadily on with a grateful mind. In a few weeks an opportunity so much better came his way that he would not have made the first deal on any account; and he saw that a Mind which knew more than he knew had prevented him from losing the greater good by entangling himself with the lesser. That is the way every seeming failure will work out for you, if you keep your faith, hold to your purpose, have gratitude, and do, every day, all that can be done that day, doing each separate act in a successful manner. _When you make a failure, it is because you have not asked for enough; keep on, and a larger thing than you were seeking will certainly come to you._ Remember this. You will not fail because you lack the necessary talent to do what you wish to do. If you go on as I have directed, you will develop all the talent that is necessary to the doing of your work. It is not within the scope of this book to deal with the science of cultivating talent; but it is as certain and simple as the process of getting rich. However, do not hesitate or waver for fear that when you come to any certain place you will fail for lack of ability; keep right on, and when you come to that place, the ability will be furnished to you. The same source of Ability which enabled the untaught Lincoln to do the greatest work in government ever accomplished by a single man is open to you; you may draw upon all the mind there is for wisdom to use in meeting the responsibilities which are laid upon you. Go on in full faith. Study this book. Make it your constant companion until you have mastered all the ideas contained in it. While you are getting firmly established in this faith, you will do well to give up most recreations and pleasures; and to stay away from places where ideas conflicting with these are advanced in lectures or sermons. Do not read pessimistic or conflicting literature, or get into arguments upon the matter. Do very little reading, outside of the writers mentioned in the Preface. Spend most of your leisure time in contemplating your vision, and in cultivating gratitude, and in reading this book. It contains all you need to know of the science of getting rich; and you will find all the essentials summed up in the following chapter. = Summary Of The Science Of Getting Rich. There is a thinking stuff from which all things are made, and which, in its original state, permeates, penetrates, and fills the interspaces of the universe. A thought in this substance produces the thing that is imaged by the thought. Man can form things in his thought, and by impressing his thought upon formless substance can cause the thing he thinks about to be created. In order to do this, man must pass from the competitive to the creative mind; otherwise he cannot be in harmony with the Formless Intelligence, which is always creative and never competitive in spirit. Man may come into full harmony with the Formless Substance by entertaining a lively and sincere gratitude for the blessings it bestows upon him. Gratitude unifies the mind of man with the intelligence of Substance, so that man’s thoughts are received by the Formless. Man can remain upon the creative plane only by uniting himself with the Formless Intelligence through a deep and continuous feeling of gratitude. Man must form a clear and definite mental image of the things he wishes to have, to do, or to become; and he must hold this mental image in his thoughts, while being deeply grateful to the Supreme that all his desires are granted to him. The man who wishes to get rich must spend his leisure hours in contemplating his Vision, and in earnest thanksgiving that the reality is being given to him. Too much stress cannot be laid on the importance of frequent contemplation of the mental image, coupled with unwavering faith and devout gratitude. This is the process by which the impression is given to the Formless, and the creative forces set in motion. The creative energy works through the established channels of natural growth, and of the industrial and social order. All that is included in his mental image will surely be brought to the man who follows the instructions given above, and whose faith does not waver. What he wants will come to him through the ways of established trade and commerce. In order to receive his own when it shall come to him, man must be active; and this activity can only consist in more than filling his present place. He must keep in mind the Purpose to get rich through the realization of his mental image. And he must do, every day, all that can be done that day, taking care to do each act in a successful manner. He must give to every man a use value in excess of the cash value he receives, so that each transaction makes for more life; and he must so hold the Advancing Thought that the impression of Increase will be communicated to all with whom he comes in contact. The men and women who practice the foregoing instructions will certainly get rich; and the riches they receive will be in exact proportion to the definiteness of their vision, the fixity of their purpose, the steadiness of their faith, and the depth of their gratitude. = Further Aids Toward Getting Rich Right THE NAUTILUS is published monthly for the express purpose of making Men and Women Who Can Do What They Will To Do. It abounds in practical ideas and in the bright inspiration that impels you to USE the ideas. Use it as first aid! <NAME>, who wrote this book, teaches “Constructive Science” in every number of the magazine. How to think so as to PROMOTE YOURSELF is what you want to know. He teaches it! Elizabeth and <NAME>e teach it, too. They are the editors and owners of THE NAUTILUS, and their success is worth knowing about and learning from. And <NAME>, of the Sheldon School of Salesmanship, writes for NAUTILUS on business growing. So does <NAME>ws Fall, of the University of New York. And several others. These folks know how. GET IN TOUCH with success and successful people through NAUTILUS. Then there is our Success Department, where everybody is invited to say his say, and prizes are given for best letters. THE NAUTILUS teaches and inspires health, wealth, and happiness in ALL departments of life. Don’t miss <NAME>attles’ great new serial story, “As a Grain of Mustard Seed,” which will begin in an early number of the magazine. Send \$1.00 for a year’s subscription to THE NAUTILUS, with a copy of “Making The Man Who Can,” and “Marital Unrest: a New Remedy,” both by <NAME>. Or, send 10 cents for a three months’ trial and a copy of “Marital Unrest.” Do you want more books on how to succeed? Read Bruce McClelland’s “Prosperity Through Thought Force,” price, \$1.00, to which Ells Wheeler Wilcox gave nearly a page of space in the New York Journal; and read “How to Grow Success,” by Elizabe<NAME>, 50c. And don’t you want to read Wallace D. Wattles’ “New Science of Living and Healing,” price, 50c.? Address: ELIZABETH TOWNE, Dept. TS, HOLYOKE, MASS.
https://github.com/Jollywatt/typst-fletcher
https://raw.githubusercontent.com/Jollywatt/typst-fletcher/master/docs/gallery/node-groups.typ
typst
MIT License
#import "@preview/fletcher:0.5.1" as fletcher: diagram, node, edge #set page(width: auto, height: auto, margin: 5mm, fill: white) #diagram( node-corner-radius: 4pt, node((0,0), $S a$), node((1,0), $T b$), node((0,1), $S a'$), node((1,1), $T b'$), edge((0,0), (1,0), "->", $f$), edge((0,1), (1,1), "->", $f'$), edge((0,0), (0,1), "->", $alpha$), edge((1,0), (1,1), "->", $beta$), node((2,0), $(a, b, f)$), edge("->", text(0.8em, $(alpha, beta)$)), node((2,1), $(a', b', f')$), node((0,2), $S a$), edge("->", $f$), node((1,2), $T b$), node((2,2), $(a, b, f)$), { let tint(c) = (stroke: c, fill: rgb(..c.components().slice(0,3), 5%), inset: 8pt) node(enclose: ((0,0), (1,1)), ..tint(teal), name: <big>) node(enclose: ((2,0), (2,1)), ..tint(teal), name: <tall>) node(enclose: ((0,2), (1,2)), ..tint(green), name: <wide>) node(enclose: ((2,2),), ..tint(green), name: <small>) }, edge(<big>, <tall>, "<==>", stroke: teal + .75pt), edge(<wide>, <small>, "<==>", stroke: green + .75pt), edge(<big>, <wide>, "<=>", stroke: .75pt), edge(<tall>, <small>, "<=>", stroke: .75pt), )
https://github.com/blaisdellma/rustic-typster
https://raw.githubusercontent.com/blaisdellma/rustic-typster/master/README.md
markdown
MIT License
# Rustic-Typster This is a typing practice game specifically for typing rust. The game scrapes crates.io for recently downloaded crates, finds their github repo, and pulls lines from any *.rs files. ![Screenshot](screenshots/rustic_typster_screenshot.png) ## Note about OpenSSL Requires openssl libs to be installed. Depending on where your openssl installation is either change `.cargo/config.toml` or set environment variables.
https://github.com/SillyFreak/typst-packages-old
https://raw.githubusercontent.com/SillyFreak/typst-packages-old/main/pre-plantuml/README.md
markdown
MIT License
# pre-plantuml This package provides a [prequery](https://typst.app/universe/package/prequery) for UML diagrams specified using [PlantUML](https://www.plantuml.com/) syntax. The diagrams can be extracted either as source code, or as URLs to a specific PlantUML Webservice. See the [manual](docs/manual.pdf) for details.
https://github.com/typst/packages
https://raw.githubusercontent.com/typst/packages/main/packages/preview/unichar/0.1.0/ucd/block-0860.typ
typst
Apache License 2.0
#let data = ( ("SYRIAC LETTER MALAYALAM NGA", "Lo", 0), ("SYRIAC LETTER MALAYALAM JA", "Lo", 0), ("SYRIAC LETTER MALAYALAM NYA", "Lo", 0), ("SYRIAC LETTER MALAYALAM TTA", "Lo", 0), ("SYRIAC LETTER MALAYALAM NNA", "Lo", 0), ("SYRIAC LETTER MALAYALAM NNNA", "Lo", 0), ("SYRIAC LETTER MALAYALAM BHA", "Lo", 0), ("SYRIAC LETTER MALAYALAM RA", "Lo", 0), ("SYRIAC LETTER MALAYALAM LLA", "Lo", 0), ("SYRIAC LETTER MALAYALAM LLLA", "Lo", 0), ("SYRIAC LETTER MALAYALAM SSA", "Lo", 0), )
https://github.com/dyc3/senior-design
https://raw.githubusercontent.com/dyc3/senior-design/main/balancer-requirements.typ
typst
= Requirements <Chapter::balancer-requirements> == Introduction As elaborated in @Chapter::SolutionOverview, the goal is to create a load balancer that meets the requirements specified in this chapter. == Stakeholders - End Users - People that use any instance of OTT to watch videos - Self-hosters - People that host their own instance of OTT - Developers/Maintainers - The authors of this document - Fly.io - The platform that hosts OTT - Video Providers - The platforms that host the videos that are watched on OTT - YouTube, Vimeo, etc. == Key Concepts See @glossary #import "lib/requirements.typ": * == User Requirements <Section::req-user> #figure( table( columns: 1, [#req("Current End User Experience must be maintained or improved", mustHave, usecase: [@UseCase::end-user])], [#req("Self-hosters must not be required to use the load balancer", mustHave, usecase: [@UseCase::self-host])], [#req("Must not allow multiple Monoliths to load the same room at the same time", mustHave, usecase: [@UseCase::end-user]) <Req::room-uniqueness>], [#req("Must not allow external users to pose as a Monolith to the Balancer", mustHave)], [#req("Must provide sufficient configurability", mustHave, usecase: [@UseCase::maintaining])], [#req("Should be easily configurable", shouldHave, usecase: [@UseCase::maintaining])], [#req("Should not require any external services (like Redis or Kafka)", shouldHave)], [#req("System must route traffic to the closest region", mustHave, usecase: [@UserStory::Responsive])], [#req("Clients must be able to interface with OTT with and without the Balancer with minimal code changes.", mustHave, usecase: [@UseCase::end-user])], [#req("Should listen on both IPv4 ports and IPv6 ports addresses", shouldHave)], [#req("Must prioritize routing requests to monoliths in the same region as the balancer", mustHave, usecase: [@UserStory::Responsive])], [#req("Must be able to route requests to any region", mustHave, usecase: [@UseCase::end-user])], [#req("Balancer can be configured with new routing rules without recompiling", wouldBeNiceToHave, usecase: [@UseCase::maintaining])], [#req("Balancer is able to work on protocols other than HTTP", wouldBeNiceToHave, usecase: [@UseCase::maintaining])], [#req("Any deployment of OTT must appear from the outside to be a single entity. Users must not need to manually select what server they are connecting to.", mustHave, usecase: [@UseCase::end-user]) <Req::single-entity>], ), caption: [Balancer User Requirements] ) == System Requirements <Section::req-system> #figure( table( columns: 1, [#req("Should fit within Fly.io's smallest machine (1 core, 256 MB RAM)", shouldHave, usecase: [@UseCase::maintaining])], [#req("Must be runnable in a Docker container", mustHave, usecase: [@UseCase::maintaining, @UseCase::self-host])], [#req("Should minimize Docker image size", shouldHave, usecase: [@UseCase::maintaining, @UseCase::end-user])], [#req("Must interface with visualization", mustHave, usecase: [@UseCase::visualization-interface])] ), caption: [Balancer System Requirements] ) == Non-Functional Requirements <Section::req-nonfunc> #figure( table( columns: 1, [#req("Capable of handling current OTT traffic (about 80 concurrent users max)", mustHave, usecase: [@UseCase::end-user, @UserStory::WatchTogether])], [#req("Must run on Linux", mustHave, usecase: [@UseCase::maintaining, @UseCase::self-host])], [#req("Must run in Docker", mustHave, usecase: [@UseCase::maintaining, @UseCase::self-host])], [#req("Must be very fault tolerant", mustHave, usecase: [@UseCase::maintaining, @UserStory::Reliable])], [#req("Clients must be able to interface with OTT with and without the Balancer with minimal code changes.", mustHave, usecase: [@UseCase::end-user])], [#req("Must be safe to scale horizontally", mustHave, usecase: [@UseCase::maintaining, @UserStory::Reliable])], [#req("Must be safe to do multi-region deployments", mustHave, usecase: [@UseCase::maintaining, @UserStory::Responsive])], ), caption: [Balancer Non-Functional Requirements] ) == Domain Requirements <Section::req-domain> #figure( table( columns: 1, [#req("Balancer should follow best practices with regards to HTTP", couldHave, usecase: [@UseCase::end-user, @UserStory::HttpApi])], [#req("OTT must remain in compliance with the YouTube API Terms of Service", mustHave, usecase: [@UseCase::maintaining])], [#req("The Balancer must comply with the GDPR.", mustHave, usecase: [@UseCase::maintaining])], ), caption: [Balancer Domain Requirements] )
https://github.com/DashieTM/ost-5semester
https://raw.githubusercontent.com/DashieTM/ost-5semester/main/cyberdef/weeks/week3.typ
typst
#import "../../utils.typ": * #section("Incident Response") #align( center, [#image("../../Screenshots/2023_10_03_08_33_35.png", width: 100%)], ) #subsection("First actions") #columns(2, [ #align( center, [#image("../../Screenshots/2023_10_03_08_46_30.png", width: 100%)], ) #colbreak() - best not to act quickly - quick actions are likly not enough - attacker might see that you are aware of the attack - endblow might happen - attacker might change attack vector ]) #subsection("Indicator of Compromise IOC") This is the "object" that has been compromised and needs to be checked. The IOC is used to check this indicator across all PCs servers etc in an organization. #align(center, [#image("../../Screenshots/2023_10_03_08_45_14.png", width: 80%)]) - IMPHASH\ hash based on behavior - MUTEX\ a ransomware doesn't want to be ran twice as it might encrypt itself. Hence, the use of a "mutex", aka a check to see if this is the first time the malware runs
https://github.com/SWATEngineering/Docs
https://raw.githubusercontent.com/SWATEngineering/Docs/main/src/3_PB/ManualeUtente/meta.typ
typst
MIT License
#let title = "Manuale Utente"
https://github.com/rdboyes/resume
https://raw.githubusercontent.com/rdboyes/resume/main/modules_en/projects.typ
typst
// Imports #import "@preview/brilliant-cv:2.0.2": cvSection, cvEntry #let metadata = toml("../metadata.toml") #let cvSection = cvSection.with(metadata: metadata) #let cvEntry = cvEntry.with(metadata: metadata) #cvSection("Projects & Associations") #cvEntry( title: [Volunteer Data Analyst], society: [ABC Nonprofit Organization], date: [2019 - Present], location: [New York, NY], description: list( [Analyze donor and fundraising data to identify trends and opportunities for growth], [Create data visualizations and dashboards to communicate insights to the board of directors], [Collaborate with other volunteers to develop and implement data-driven strategies], ), )
https://github.com/julius2718/tempura
https://raw.githubusercontent.com/julius2718/tempura/main/0.0.1/main.typ
typst
MIT License
#let sans(it, font: ("Hiragino Sans", "BIZ UDPGothic", "Noto Sans JP",)) = { text(font: font)[ #it ] } #let gtheading( it, font: ("Helvetica", "Noto Sans JP", "BIZ UDPGothic", "Hiragino Sans"), ) = { text(sans(font: font)[#h(-1em) *#it* #h(1em)]) } #let signature(title: "", date: "", author: "", titlefont: "Noto Sans JP") = { align( center, text( 1.5em, font: (titlefont, "Hiragino Sans", "BIZ UDPGothic"), weight: "semibold", )[ #title ], ) v(0.25em) align(center, text(1em)[ #date #v(0.3em) #author ]) v(0.3em) } #let itm_label(name) = place[#figure(supplement: [])[]#label(name)] #let jpdoc( doc, textfont: "Noto Serif JP", mathfont: "STIX Two Math", headfont: "Noto Sans JP", ) = { set text( font: (textfont, "Hiragino Mincho ProN", "BIZ UDPMincho",), size: 10.5pt, ) show math.equation: set text(font: (mathfont, "STIX Two Math")) show raw: set text(font: "Osaka", size: 1.4em) show figure.where(kind: table): set figure.caption(position: top) set heading(numbering: "1.") set page(margin: 1in, numbering: "1") set par(first-line-indent: 1em, justify: true, leading: 0.88em) set block(spacing: 1em) show heading: it => { // v(0.6em) // sans[#it] set text(font: headfont, weight: "semibold") block(it) par(text(size: 0.3em, "")) } show ref: it => { let el = it.element if el != none and el.func() == heading { let n = numbering(el.numbering, ..counter(heading).at(el.location())) if el.level == 1 { [#n 章] } else { [#n 節] } } else { it } } show heading.where(level: 1): it => { // v(0.6em) // set align(center) set text(size: 14pt) block(it) // block(smallcaps(it.body)) par(text(size: 0.3em, "")) } [#doc] } #let jpsdoc( doc, textfont: "Noto Serif JP", mathfont: "STIX Two Math", headfont: "Noto Sans JP", ) = { set text( font: (textfont, "Hiragino Mincho ProN", "BIZ UDPMincho",), size: 10.5pt, ) show math.equation: set text(font: (mathfont, "STIX Two Math")) show raw: set text(font: "Osaka", size: 1.4em) set page(margin: 1in, numbering: "1") set par(first-line-indent: 1em, justify: true, leading: 0.88em) set block(spacing: 1em) show heading: it => { // v(0.6em) // sans[#it] set text(font: headfont, weight: "semibold") block(it) par(text(size: 0.3em, "")) } show heading.where(level: 1): it => { // v(0.6em) // set align(center) set text(size: 14pt) block(it) // block(smallcaps(it.body)) par(text(size: 0.3em, "")) } show figure.where(kind: table): set figure.caption(position: top) [#doc] } #let jpprez(doc) = { import "@preview/polylux:0.3.1": * set page(paper: "presentation-16-9", footer: [ #set align(right) #set text(size: 10pt) #counter(page).display("1") ]) set text(font: ("Roboto", "BIZ UDPGothic", "Hiragino Sans"), size: 25pt) set par(leading: 1em) show math.equation: set text(font: "STIX Two Math") show raw: set text(font: "Osaka", size: 1.4em) show heading: it => { it v(0.6em) } [#doc] }
https://github.com/hexWars/resume
https://raw.githubusercontent.com/hexWars/resume/main/README.md
markdown
MIT License
# typst-resume-template [中文](./README-zh.md) ![resume](https://img.shields.io/badge/resume-typst-9cf) This project is a resume template designed using Typst and inspired by [this website](https://satnaing.dev/blog). ## Preview | | | |:---:|:---:| | ![preview](./assets/typst-resume-template.png) | ![preview2](./assets/typst-resume-template2.png) | ## Usage The commonly used SVG files are already in the folder `typst`, and the template file is `typst/resume.typ`. Enter your resume content in the file `typst/main.typ`. You can download this project and upload the `typst` folder to the typst website for use. ### Update page parameters ```typst #set page(margin: (top: 15mm, bottom: 15mm)) #set text(font: "Linux Libertine", lang: "zh", 1em) #set par(leading: 0.58em) ``` Including font size, language, top distance, bottom distance and so on. ### Change color Update the `theme_color` parameter. ### Modify the vertical line If you want to modify the vertical line, you can find ```typst line( start: (0%, 11.1%), end: (0%, 0%), length: 4cm, stroke: 6pt + theme_color, ) ``` to make the changes. ### dividing_line Divider, which can be used to separate sections for multiple educational qualifications. ## License Format is MIT but all the data is owned by hexWars
https://github.com/linsyking/messenger-manual
https://raw.githubusercontent.com/linsyking/messenger-manual/main/advanced.typ
typst
#import "@preview/fletcher:0.4.5" as fletcher: diagram, node, edge #pagebreak() = Advanced Usage == LocalStorage <localstorage> #link("https://developer.mozilla.org/en-US/docs/Web/API/Window/localStorage")[Local storage] is a mechanism to store data in the browser. It allows the game to save data locally. In Messenger, local storage content is defined by a `String`. When users need to save something to local storage, they need to first serialize it (for example, use `Json`). Users can read or write to local storage by editing `globalData.userdata` and the data type in local storage is defined in `Lib/UserData.elm`. However, not all things in `UserData` are needed to store to local storage. Users will need to implement `initGlobalData` and `saveGlobalData` functions. They act as a decoder and decoder for global data. `initGlobalData` is called when the game starts. Its type is: ```elm initGlobalData : String -> UserViewGlobalData UserData ``` The string it needs is the real local storage data. Users will use the local storage data to initialize a global data. The `UserViewGlobalData` `saveGlobalData` is called when user wants to save the global data (emitted by a `SOMSaveGlobalData` message). Users may encode some part of global data. == Advanced Component Management Components are the most useful and flexible objects in Messenger. They can be very powerful if used in a correct way. === Component Group <componentgroup> Users may use the following command when creating a component to configure the directory the component is created in: ```bash # Use -cd Or --cdir messenger component Home Comp1 -cd CSet1 ``` This will create a `Scenes/Home/CSet1/Comp1` directory and corresponding component files. The default value of `--cdir` is `Components`. Grouping components can be helpful because they may have different types of `BaseData`, `Msg` and `Target`. So every group will have a `ComponentBase.elm` and it can be set individually, which means different groups of concrete component type will be abstract into different abstract type. In this way, the component configurations can be organized more methodically, instead of putting everything in one type. The cons is that it is inconvenient to communicate between different groups of components. Therefore, this feature should be used only after careful consideration. In other words, use it only when the component type in one group hardly need to communicate with other groups of components. Portable components can be used in an advanced way through this feature. Users can translate the same concrete type into different abstract type for different groups (different from using multiple translators in one group), so that their usages can be managed more clearly. Moreover, some portable components can be set in one group without other user components if needed. Then users can easily manage some portable components that is weakly related to the main game logic such as decorating elements. === Sub-component and Component Composition Users can add components in the component data, this might sounds amazing but reasonable since every data type can be put into a component, including scenes and layers (interesting but useless). Adding components, named as sub-components, could be useful in some situation. Imagine a situation that in an adventure game, the main character cast magic to fight against enemies. Since the magic system is the core mechanics in this game, it is designed in a complex way: different magics are corresponding to different spells; the magic system needs level value and MP value to judge if a magic can be cast or not; the magic system stores all the magics that the main character has learned. Of course it can be implement in the character component, combine with other features such as movement, level up, weapons and so on. But this is obviously not a good choice, especially when the magic system is such a complex mechanics. A better way is to abstract the magic system into a component. For example, the magics have been learned can be stored in `data`, the logic of casting a magic can be implemented in `updaterec` function, and the visual effects of different magic are implemented in `view` function. Since the component for magic system do not need to communicate with other components, it can be put into a separate group. *Note.* The main character here should not be treated as the same layer component but a parent object when judging the communication objects of the magic system. Then a magic system component can be added to the data of main character and in the main logic of main character users don't need to care about the implementation of magic system anymore. In other words, the magic system provides some interfaces to outside in this way. After make a sub-component in this way, users can do more than the previous things! What if some boss in the game has the ability to cast magic? This feature can be easily implemented by adding a magic system component to boss component (maybe a composition of enemy and special features). This is what is called #link("https://en.wikipedia.org/wiki/Emergent_gameplay")[Emergent gameplay]. Using component composition strategy can somehow do it easy at the code level. *Note.* Users don't have to use the component type for compositing features. A simple timer, for instance, can be implemented by just `basedata` and `update`. But component type is more general for most of the situations, and it is easier since many tools have been prepared for a component. *Note.* Do not abstract every simple feature into a component or custom type because you don't need too many portable features! Too many sub-components are chaotic and unmanageable. So use this strategy after thoughtful consideration. === Five-Step Updating to Manage Components Five-Step updating strategy is used to simplify the update logic of a parent object with components (usually is layer). When developing in Messenger, managing the components could be a complex issue, especially when there are several component groups to deal with. Generally, the `update` function in a parent object with components can be divided into five steps: + Update basic data (remove dead components, etc.) ```elm type alias BasicUpdater data cdata userdata tar msg scenemsg = Env cdata userdata -> UserEvent -> data -> ( data, List (MMsg tar msg scenemsg userdata), ( Env cdata userdata, Bool ) ) ``` + Update component groups by using `updateComponents` + Determine the messages that need to be sent to components and distribute them (collisions, etc.) ```elm type alias Distributor data cdata userdata tar msg scenemsg cmsgpacker = Env cdata userdata -> UserEvent -> data -> ( data, ( List (Msg tar msg scenemsg userdata), cmsgpacker ), Env cdata userdata ) ``` where `cmsgpacker` type is a helper type for users to send different type of messages to different component groups. Generally, it should be a record with a similar structure to `data`: ```elm type alias ComponentMsgPacker = { components1: List ( Components1Target, Components1Msg ) , components2: List ( Components2Target, Components2Msg ) ... } ``` For the objects only need to manage one list of components, the `cmsgpacker` type could be: ```elm type alias ComponentMsgPacker = List ( ComponentTarget, ComponentMsg ) ``` Distributor type can also be useful in `updaterec` function. + Update the components with the `cmsgpacker` in step 3 using `updateComponentsWithTarget`. If there are multiple `cmsgpacker` results, they need to be combined together first. + Handle all the component messages generated from the previous steps. Here is an example of a layer with two lists of components in different component groups: ```elm update : LayerUpdate SceneCommonData UserData Target LayerMsg SceneMsg Data update env evt data = let --- Step 1 ( newData1, newlMsg1, ( newEnv1, newBlock1 ) ) = updateBasic env evt data --- Step 2 ( newAComps2, newAcMsg2, ( newEnv2_1, newBlock2_1 ) ) = updateComponentsWithBlock newEnv1 evt newBlock1 newData1.acomponents ( newBComps2, newBcMsg2, ( newEnv2_2, newBlock2_2 ) ) = updateComponentsWithBlock newEnv2_1 evt newBlock2_1 newData1.bcomponents --- Step 3 ( newData3, ( newlMsg3, compMsgs ), newEnv3 ) = distributeComponentMsgs newEnv2_2 evt { newData1 | acomponents = newAComps2, bcomponents = newBComp2 } --- Step 4 ( newAComps4, newAcMsg4, newEnv4_1 ) = updateComponentsWithTarget newEnv3 compMsgs.acomponents newData3.acomponents ( newBComp4, newBcMsg4, newEnv4_2 ) = updateComponentsWithTarget newEnv4_1 compMsgs.bcomponents newData3.bcomponents --- Step 5 ( newData5_1, newlMsg5_1, newEnv5_1 ) = handleComponentMsgs newEnv4_2 (newAcMsg2 ++ newAcMsg4) { newData3 | acomponents = newAComps4, bcomponents = newBComp4 } (newlMsg1 ++ newlMsg3) handlePComponentMsg ( newData5_2, newlMsg5_2, newEnv5_2 ) = handleComponentMsgs newEnv5_1 (newBcMsg2 ++ newBcMsg4) newData5_1 newlMsg5_1 handleUComponentMsg in ( newData5_2, (newlMsg5_2, ( newEnv5_2, newBlock2_2 ) ) ``` \ \ #align(center)[ #diagram( node-stroke: 1pt, edge-stroke: 1pt, node((0.8, 0.3), [`otherData`], corner-radius: 0pt), node((0, 0), [`acomponents`], corner-radius: 0pt), node((0, 0.6), [`bcomponents`], corner-radius: 0pt), node(enclose: ((0.8, 0.3), (0, 0),(0, 0.6) ), stroke: (paint: blue), corner-radius: 6pt, inset: 8pt, name: <init>), node((0.8, -0.2), text(fill: blue)[`Data`], stroke: none), node((0.8, 2.3), [`otherData'`], corner-radius: 0pt), node((0, 2), [`acomponents'`], corner-radius: 0pt), node((0, 2.6), [`bcomponents'`], corner-radius: 0pt), node(enclose: ((0.8, 2.3), (0, 2),(0, 2.6) ), stroke: (paint: blue), corner-radius: 6pt, inset: 8pt, name: <step1>), node((0.8, 1.8), text(fill: blue)[`Data1`], stroke: none), edge(<init>, <step1>, `BasicUpdater`, "->", label-side: center), node((0.8, 4.3), [`otherData'`], corner-radius: 0pt), node((0, 4), [`acomponents2`], corner-radius: 0pt), node((0, 4.6), [`bcomponents'`], corner-radius: 0pt), node(enclose: ((0.8, 4.3), (0, 4),(0, 4.6) ), stroke: (paint: blue), corner-radius: 6pt, inset: 8pt, name: <step1.5>), node((0.8, 3.8), text(fill: blue)[`Data1'`], stroke: none), edge(<step1>, <step1.5>, `updateComponentsWithBlock a`, "->", label-side: center), node((0.8, 6.3), [`otherData'`], corner-radius: 0pt), node((0, 6), [`acomponents2`], corner-radius: 0pt), node((0, 6.6), [`bcomponents2`], corner-radius: 0pt), node(enclose: ((0.8, 6.3), (0, 6),(0, 6.6) ), stroke: (paint: blue), corner-radius: 6pt, inset: 8pt, name: <step2>), node((0.8, 5.8), text(fill: blue)[`Data1''`], stroke: none), edge(<step1.5>, <step2>, `updateComponentsWithBlock b`, "->", label-side: center), node((0.8, 8.3), [`otherData''`], corner-radius: 0pt), node((0, 8), [`acomponents2'`], corner-radius: 0pt), node((0, 8.6), [`bcomponents2'`], corner-radius: 0pt), node(enclose: ((0.8, 8.3), (0, 8),(0, 8.6) ), stroke: (paint: blue), corner-radius: 6pt, inset: 8pt, name: <step3>), node((0.8, 7.8), text(fill: blue)[`Data3`], stroke: none), edge(<step2>, <step3>, `Distributor`, "->", label-side: center), node((2.3, 1.3), [`LayerMsg1`], corner-radius: 0pt), edge((0.8, 1.3), (2.3, 1.3), "->"), node((-1.2, 3.3), [`AcMsg2`], corner-radius: 0pt), edge((-0.3, 3.3), (-1.2, 3.3), "->"), node((-2.7, 5.3), [`BcMsg2`], corner-radius: 0pt), edge((-0.3, 5.3), (-2.7, 5.3), "->"), node((2.3, 7.3), [`LayerMsg3`], corner-radius: 0pt), edge((0.8, 7.3), (2.3, 7.3), "->"), // node((-1.2, 7.3), [`toAcMsg3`], corner-radius: 0pt), // edge((0, 7.3), (-1.2, 7.3), "->"), // node((-2.7, 7.3), [`toBcMsg3`], corner-radius: 0pt), // edge((-1.2, 7.3), (-2.7, 7.3), "-"), node(enclose: ((2.3, 0.3), (2.3, 7.3)), stroke: (paint: red, dash: "dashed"), inset: 8pt), node((2.3, 0.3), text(fill: red)[Layer Msg], stroke: none), node(enclose: ((-1.2, 2.3), (-1.2, 9.3)), stroke: (paint: green, dash: "dashed"), inset: 8pt), node((-1.2, 2.3), text(fill: green)[A Msg], stroke: none), node(enclose: ((-2.7, 4.3), (-2.7, 9.3)), stroke: (paint: purple, dash: "dashed"), inset: 8pt), node((-2.7, 4.3), text(fill: purple)[B Msg], stroke: none), edge(<step3>, (0.4, 9.5), "->"), edge((2.3, 7.8),(2.3, 9.5),stroke: (paint: red, dash: "dashed"), "->"), edge((0, 7.3), (-0.7, 7.3), (-0.7, 9.5), "->") ) ] #align(center)[ #diagram( node-stroke: 1pt, edge-stroke: 1pt, edge((-0.7, 0.0), (-0.7, 0.3)), edge((-0.75, 0.3), (0.3, 0.3), `toAcMsg`, "->"), edge((-0.7, 2.3), (-0.7, 3.6)), edge((-0.7, 3.6), (0.3, 3.6), `toBcMsg`, "->"), node((0.8, 2.3), [`otherData''`], corner-radius: 0pt), node((0, 2), [`acomponents4`], corner-radius: 0pt), node((0, 2.6), [`bcomponents2'`], corner-radius: 0pt), node(enclose: ((0.8, 2.3), (0, 2),(0, 2.6) ), stroke: (paint: blue), corner-radius: 6pt, inset: 8pt, name: <step3.5>), node((0.8, 1.8), text(fill: blue)[`Data3'`], stroke: none), edge((0.4, 0), <step3.5>, `updateComponentsWithTarget a`,"->", label-side: center), node((0.8, 5.3), [`otherData''`], corner-radius: 0pt), node((0, 5), [`acomponents4`], corner-radius: 0pt), node((0, 5.6), [`bcomponents4`], corner-radius: 0pt), node(enclose: ((0.8, 5.3), (0, 5),(0, 5.6) ), stroke: (paint: blue), corner-radius: 6pt, inset: 8pt, name: <step4>), node((0.8, 4.8), text(fill: blue)[`Data3''`], stroke: none), edge(<step3.5>, <step4>, `updateComponentsWithTarget b`,"->", label-side: center), node((0.8, 8.3), [`otherData'''`], corner-radius: 0pt), node((0, 8), [`acomponents4'`], corner-radius: 0pt), node((0, 8.6), [`bcomponents4'`], corner-radius: 0pt), node(enclose: ((0.8, 8.3), (0, 8),(0, 8.6) ), stroke: (paint: blue), corner-radius: 6pt, inset: 8pt, name: <step5_1>), node((0.8, 7.8), text(fill: blue)[`Data5_1`], stroke: none), edge(<step4>, <step5_1>, `handleComponentMsgs a`,"->", label-side: center), node((0.8, 11.3), [`otherData''''`], corner-radius: 0pt), node((0, 11), [`acomponents4''`], corner-radius: 0pt), node((0, 11.6), [`bcomponents4''`], corner-radius: 0pt), node(enclose: ((0.8, 11.3), (0, 11),(0, 11.6) ), stroke: (paint: blue), corner-radius: 6pt, inset: 8pt, name: <step5_2>), node((0.8, 10.8), text(fill: blue)[`Data5_2`], stroke: none), edge(<step5_1>, <step5_2>, `handleComponentMsgs b`,"->", label-side: center), node((-1.2, 1.3), [`AcMsg4`], corner-radius: 0pt), edge((0.3, 1.3), (-1.2, 1.3), "->"), node((-2.7, 4.3), [`BcMsg4`], corner-radius: 0pt), edge((0.3, 4.3), (-2.7, 4.3), "->"), node((2.3, 7.3), [`LayerMsg5_1`], corner-radius: 0pt), edge((0.5, 7.3), (2.3, 7.3), "->"), edge((2.3, 7.3), (2.3, 9.3), (0.6, 9.3), stroke: (paint: red, dash: "dashed"), "->"), node((2.3, 10.3), [`LayerMsg5_2`], corner-radius: 0pt), edge((0.5, 10.3), (2.3, 10.3), "->"), edge((2.3, 0),(2.3, 6.3), (0.6, 6.3),stroke: (paint: red, dash: "dashed"), "->"), node(enclose: ((-1.2, 0), (-1.2, 1.3)), stroke: (paint: green, dash: "dashed"), inset: 8pt), node((-1.2, 0), text(fill: green)[A Msg], stroke: none), edge((-1.2, 1.8),(-1.2, 6.3), (0.2, 6.3),stroke: (paint: green, dash: "dashed"), "->"), node(enclose: ((-2.7, 0), (-2.7, 4.3)), stroke: (paint: purple, dash: "dashed"), inset: 8pt), node((-2.7, 0), text(fill: purple)[B Msg], stroke: none), edge((-2.7, 4.8),(-2.7, 9.3), (0.2, 9.3),stroke: (paint: purple, dash: "dashed"), "->"), node(enclose: ((-1, 12), (2.3, 10.3)), stroke: (paint: blue, dash: "dashed"), inset: 8pt), node((2, 11.8), text(fill: blue)[Result], stroke: none) ) ] == Initial Asset Loading Scene User may want to have an asset loading scene just like what Reweave does. When Messenger is loading assets, `update` of the initial scene will not be called. All the user input and events are ignored. However, `view` will be called. `globalTime` and `currentTimeStamp` will be updated but `sceneStartTime` will not be updated. Moreover, users can get the number of loaded assets by using the `loadedResourceNum` function. Then you can compare it with `resourceNum resource`. An example: ```elm startText : GlobalData UserData -> Renderable startText gd = let loaded = loadedResourceNum gd total = resourceNum resources progress = String.slice 0 4 <| String.fromFloat (toFloat loaded / toFloat total * 100) text = if loaded /= total then "Loading... " ++ progress ++ "%" else "Click to start" in group [ alpha (0.7 + sin (toFloat gd.globalTime / 10) / 3) ] [ renderTextWithColorCenter gd 60 text "Arial" Color.black ( 960, 900 ) ] ``` The full example is in #link("https://github.com/linsyking/messenger-examples/tree/main/spritesheet")[messenger examples].
https://github.com/Toniolo-Marco/git-for-dummies
https://raw.githubusercontent.com/Toniolo-Marco/git-for-dummies/main/book/components/code-blocks.typ
typst
// Definisci una funzione per creare i bottoni della finestra #let window-button(color) = circle( fill: color, radius: 4pt, ) // Definisci la barra del titolo con i tre bottoni #let window-titlebar = box.with( fill: rgb("#1d2433"), radius: 5pt, inset: 4pt, )( stack( dir: rtl, spacing: 8pt, window-button(rgb("#27c93f")), // Verde (massimizza) window-button(rgb("#ffbd2e")), // Giallo (minimizza) window-button(rgb("#ff5f56")), // Rosso (chiudi) ) ) // Definisci il blocco di codice con la barra del titolo #let code-block = block.with( fill: rgb("#1d2433"), inset: 0pt, radius: 5pt, breakable: false, )
https://github.com/derliemonne/compute-math-lectures-fefu-5th-semester-kolobov
https://raw.githubusercontent.com/derliemonne/compute-math-lectures-fefu-5th-semester-kolobov/main/src/lectures.typ
typst
#import "utils.typ": * #set page("a5", numbering: "1") #set text(lang: "ru") #set par(justify: true) #set heading(numbering: "1.") `24 Сентября 2024` = Вводная <NAME>, D947 Чтобы получить экзамен нужно: - допуск от преподавателя по практике - сдача теории (экзамен) Можно сдавать частями (три коллоквиума): - Прямые методы - Итерационные методы - Собственные значения Курсовой проект. Подробно разобрать конкретный метод, который каждому будет дан. Ещё будет две теоретические задачи. #linebreak() = Первая лекция В конечномерном пространстве все нормы эквивалентны. #def[ $norm(x)$ --- число, для которого выполняются 3 аксиомы:\ 1. $norm(x) >= 0, norm(x) = 0 <=> x = 0$ 2. $norm(lambda x) = lambda norm(x)$ 3. $norm(x+y) <= norm(x) + norm(y)$ ] #def[ Нормы вектора. $ &norm(x)_1 = sum_(i=1)^n abs(x_i)\ &norm(x)_2 = sqrt((x, x)) - "евклидова норма"\ &norm(x)_oo = max_i abs(x_i) $ ] СЛАУ: $ A x = f $ #def[ Нормы матрицы. Евклидова норма: $ norm(A)_E = sqrt(sum_(i, j) a^2_(i j)) $ ] #def[ Подчинённая матричная норма: $ norm(А) = sup_(x!=0) norm(A x) / norm(x) $ ] Свойства: 1. $norm(I) = 1 $ 2. $norm(A B) <= norm(A) norm(B) $ Евклидова норма не является подчинённой, ведь $norm(I)_E = sqrt(n) != 1$. Из определения подчинённой матричной нормы вытекает: $ norm(А) = sup_(x!=0) norm(A x) / norm(x) => norm(A x) <= norm(A) norm(x) $ Обратное #def[ Согласованная матричная норма такая, что: $ norm(A x) <= norm(A) norm(x) $ ] $ &norm(A)_1 = max_j sum_(i=1)^n abs(a_(i j)) \ &norm(A)_2 = sqrt(max_i lambda_i (A^* A)), " где" A^* - "транспонированная матрица"\ &norm(A)_oo = max_i sum_(j=1)^n abs(a_(i j)) $ $ norm(A) = sup_(x!=0) norm(A x) / norm(x) $ // $ norm(A x)_1 = max_i abs(sum_(j=1)^n a_(i j)x_j) // <= max_i sum_(j=1)^n abs(a_(i j)) abs(x_j) $ $ norm(A x)_1 = sum_(i=1)^n abs(sum_(j=1)^n a_(i j)x_j) <= sum_(i=1)^n sum_(j=1)^n abs(a_(i j)) abs(x_j) = \ = sum_(j=1)^n sum_(i=1)^n abs(a_(i j)) abs(x_j) = sum_(j=1)^n (abs(x_j) sum_(i=1)^n abs(a_(i j))) <= \ <= sum_(j=1)^n ((max_j sum_(i=1)^n abs(a_(i j)))abs(x_j)) = max_j sum_i abs(a_(i j)) dot sum_j abs(x_j) =\ = (max_j sum_i abs(a_(i j))) norm(x)_1 $ Доказали, что $ norm(A x)_1 / norm(x)_1 <= max_j sum_(i=1)^n abs(a_(i j)) $ $k -$ номер столбца, где достигается максимум: $ sum_(i=1)^n abs(a_(i k)) = max_j sum_(i=1)^n abs(a_(i j)) $ $ e_k = vec(0, dots, underbrace(1, k-"й индекс"), dots, 0, 0) = max_j sum_(i=1)^n abs(a_(i j)) norm(x) ??? $ $ norm(A e_k)_1 = sum_i abs(a_(i k)) $ Для второй матричной нормы $norm(A)_2 = sqrt(max_i lambda_i (A^* A))$: $ lambda_i$ должны быть действительными и положительными $A^* A - $ неотрицательно определена и симметрична $ (A^* A)^* = A^* (A^*)^* = A^* A $ #def[ Матрица $C$ называется неотрицательно определённой, если $ forall (y, y) >= 0 $ Похожим образом определяются положительно определённая матрица и другие. ] Свойство скалярного произведения: $ (B x, y) = (x, B^* y) $ $ (A^*A x, x) = (A x, A x)) >= 0 $ Из курса линейной алгебры известно, что все собственные значения симметрической матрицы вещественны. Значит, $norm(A)_2 = sqrt(max_i lambda_i (A^* A))$ имеет смысл для симметрических матриц. У симметрических матриц существует полная система ортонормированных собственных векторов. $ (A^* A) u^((i)) = lambda_i u^((i))\ (u^((i)), u^((j))) = cases( 1 when i = j, 0 when i != j ) $ $ x = sum_(i=1)^n alpha_i u^((i)) $ $ norm(x)_2 = sqrt((x, x)) = sqrt((sum_(i=1)^n alpha_i u^((i)), sum_(j=1)^n alpha_j u^((j)))) = \ = sqrt(sum_(i=1)^n alpha_i^2) $ $ norm(A x)_2 = sqrt((A x, A x)) = sqrt((A^* A x, x)) =\ = sqrt((A^*A sum_i alpha_i u^((i)), sum_j alpha_j u^((j)) )) = sqrt((sum_i alpha_i A^* A u^((i)) comma sum_j alpha_j u^((j)))) =\ = sqrt((sum_i alpha_i lambda_i u^((i)) comma sum_j alpha_j u^((j)))) = sqrt(sum_i alpha_i^2 lambda_i) <=\ <= sqrt(sum_i alpha_i^2 max_j lambda_i (A^* A)) = sqrt(max_i lambda_i (A^*A)) norm(x)_2 $ $ lambda_k (A^* A) = max_i lambda_i (A^* A) $ Посчитаем вторую норму. Предположим, что матрица симметричная: $ A^* = A $ $ norm(A)_2 = sqrt(max_i lambda_i (A^* A)) = sqrt(max_i lambda_i (A^2)) = sqrt(max_i lambda_i^2 (A)) = max_i abs(lambda_i (A)) $ #linebreak() `1 Октября 2024` = Обусловленность матрицы систем #def[ Число обусловленности: $ mu(A) = sup_(x, y != 0)(norm(A x)/norm(x) div norm(A y)/norm(y)) $ ] $ A x = f $ $ A(x+ xi) = f + phi $ $ A xi = phi $ Попробуем оценить следующую величину: $ norm(xi) / norm(x) dot norm(f) / norm(phi) = norm(xi) / norm(x) dot norm(A x) / norm( A xi) = norm(A x) / norm(x) div norm(A xi) / norm(xi) <= mu(A) $ $ norm(xi) / norm(x) <= mu(a) norm(phi) / norm(f) $ Представим, что $mu(A)$ невелико, меньше единицы оно быть не может, тогда маленькое возмущение правой части гарантирует, что возмущение в решении тоже невелико. Как влияет погрешность матрицы на результат: $ (A + Sigma)(x + xi) = f + phi $ $ norm(xi)/norm(x) <= mu(A) / (1 - mu(A) norm(Sigma)/norm(A)) (norm(phi)/norm(f) + norm(Sigma)/norm(A)) $ При условии: $ norm(A^(-1)) norm(Sigma) < 1 $ Нам нужна формула, по которой мы будем искать число обусловленности, выведем её. $ mu(A) = sup_(x!=0)(norm(A x)/norm(x)) / (inf_(y!=0)(norm(A y)/norm(y))) = norm(A) / (inf_(z!=0) 1/(norm(A^(-1) z) / norm(z))) =\ =norm(A) / (1/(sup_(z!=0) norm(A^(-1) z) / norm(z))) = norm(A) norm(A^(-1)) $ $ z := A y $ #showybox(breakable: true, title: "Пример")[ $ A = mat(1, 1.0001; 1.0001, 1) wide f = vec(2.0001, 2.0001) $ $ x = vec(1, 1) $ $ norm(A) = max_(i = 1,2) abs(lambda_i (A)) $ $ matdet(1-lambda, 1.0001; 1.0001, 1-lambda) = 0 $ $ (1-lambda)^2 - 1.0001^2 = 0 $ $ lambda_1 = 0.0001 wide lambda_2 = -10^(-4) $ $ norm(A) = 2.0001 wide norm(A^(-1)) = 10^4 $ $ mu(A) = 2001 "большое число" $ Рассмотрим следующую систему: $ (A+Sigma)y = f + phi $ $ Sigma = mat(0, 0; 0, 0.00005) wide phi = vec(0.0001, 0) $ Решение системы: $ y = vec(0, 2) $ ] #linebreak() = Прямые методы == Метод Гаусса (метод исключения неизвестных) Метод в основе которого лежит использование элементарных преобразований матрицы с целью применения её к треугольному или диагональному виду. $ A x = f $ $ cases( a_(11)x_1 + ... + a_(1 n)x_n = f_1, dots, a_(n 1)x_1 + ... + a_(n n)x_n = f_n, ) $ Исключаем элемент $x_1$. Пусть $a_11 != 0$: $ x_1 + a_(12) / a_11 x_2 + ... + a_(1 n)/a_(11) x_n = f_1 / a_11 | dot a_21 $ $ a_21 x_1 + a_21 a_(12) / a_11 x_2 + ... + a_21 a_(1 n)/a_(11) x_n = a_21 f_1 / a_11 $ Теперь из второго уравнения системы вычитаем вот это, таким образом получим уравнение, в котором нет $x_1$. $ cases( a_(11)x_1 + a_(22) x_2 +... + a_(1 n)x_n = f_1, #hide[$a_(11)x_1 + $] a_22^((1))x_2 + ... + a_(2 n)^((1))x_n = f_2^((1)), dots, a_(n 1)x_1 + a_(n 2)x_2 +... + a_(n n)x_n = f_n, ) $ $ cases( a_(11)x_1 + a_(22) x_2 +... + a_(1 n)x_n = f_1, #hide[$a_(11)x_1 + $] a_22^((1))x_2 + ... + a_(2 n)^((1))x_n = f_2^((1)), dots, #hide[$a_(11)x_1 + $] a_(n 2)^((1))x_2 +... + a_(n n)^((1))x_n = f_n^((1)), ) $ Второй шаг. $a_22^((1)) != 0$ и делаем аналогично. После $n-1$ шагов получим матрицу, которая имеет верхний треугольный вид. Теперь запишем формулы всех этих шагов. 1 шаг: $ d_(i 1) = a_(i 1) / a_11 $ $ a_(i j)^((1)) = a_(i j) - d_(i 1) a_(1 j), quad i, j = 2, ..., n $ $ f_i^((1)) = f_i - d_(i 1) f_1 $ 2 шаг: $ d_(i 2) = a_(i 2)^((1)) / a_22^((1)) $ $ a_(i j)^((2)) = a_(i j)^((1)) - d_(i 2) a_(2 j)^((1)), quad i, j = 3, ..., n $ $ f_i^((2)) = f_i^((1)) - d_(i 2) f_2^((1)) $ $ A_(n-1) x = f^((n -1)) $ $ A_(n-1) =: U "верхняя треугольная матрица" $ $ f^((n-1)) =: g $ $ U x = g $ $ u_(n n) x_n = g_n $ $ x_n = g_n / u_(n n) $ $k-й$ шаг обратного хода: $ u_(k k) x_k + sum_(j=k+1)^n u_(k j) x_j = g_k $ $ x_k = (g_k - sum_(j=k+1)^n u_(k j)x_j) / u_(k k) $ Условие, при котором ведущий элемент не равен нулю. Во-первых матрица должна быть невырожденной. #bbox[Критерий работы метода Гаусса][ Отличие от нуля всех главных миноров.] $ det mat( a_11, a_12, ..., a_(1 k); a_21, a_22, ..., a_(2 k); ..., ..., ..., ... ; a_(k 1), a_(k 2), ..., a_(k k) ) != 0 $ $ a_11 != 0 $ $ matdet(a_11, a_12; 0, a_22^((1))) != 0 $ $ a_11 a_22^((1)) != 0 $ $ a_22^((1)) != 0 $ $ matdet( a_11, a_12, a_13; 0, a_22^((1)), a_23^((1)); 0, 0, a_33^((2)) ) != 0 $ $ a_11 a_22^((1)) a_33^((2)) != 0 $ $ a_33^((2)) != 0 $ Все главные элементы отличны от нуля. == LU-разложене Тот же метод Гаусса, но записанный через разложение матриц. $ D_1 := mat( 1, 0, 0; -d_21, 1, 0; -d_31, 0, 1; dots.v; -d_(n 1), 0, 0, dots, 1 ) $ $ A_1 = D_1 A $ $ D_2 := mat( 1; 0, 1, ..., 0; 0, -d_32, ...; 0, -d_42, ...; dots.v; 0, -d_(n 2), ..., 1; ) $ $ A_2 = D_2 A_1 $ $ A_(n -1) $ $ U = A_(n - 1) = D_(n-1) A_(n-2) = D_(n-1) D_(n-2) A_(n-3) = ... $ $ U = D_(n-1) D_(n-2) dots D_1 A $ $ D := D_(n-1) D_(n-2) dots D_1 $ $ U = D A $ $ L := D^((-1)) $ $ A = L U $ Как выглядит эта матрица: $ L = mat( 1, ; d_21, 1; d_31, d_32, 1; dots.v, dots.v, dots.v, dots.down; d_(n 1), d_(n 2), d_(n 3), dots, 1 ) $ $ L U x = f $ $ U x := y $ $ L y = f $ Докажем необходимость в критерии работы метода Гаусса. $ A = L U $ $ A^((k)) = L^((k)) U^((k)) $ Подматрица $k$-го порядка. $ det A^((k)) = det L^((k)) det U^((k)) $ $ det L^((k)) = 1 $ $ det U^((k)) = u_11 u_12 dots u_(k k) $ $ u_(i i) != 0, quad i=overline(1 comma k) $ $ det A^((k)) != 0 $ `08 Октября 2024` == Метод квадратного корня Считаем, что все главные миноры не равны нулю. $ A = L U $ $ U = D V $ $ D = mat( d_1; ,d_2; ,,dots.down; ,,,d_n; ) wide V = mat( 1, v_12, v_13, dots, v_(1 n); ,1,v_23,dots, v_(2 n); ,,,,dots.v; ,,,,1 ) $ $ U = mat( d_1, d_1 v_12, d_1 v_13, dots, d_1 v_(1 n); , d_2, d_2 v_23, dots, d_2 v_(2 n); , , , ,dots.v; ,,,,d_n ) $ $ d_i =u_(i i) quad v_(i j) = u_(i j)/(u_(i i)) $ Есть далее понятие LDV-разложение, оно определяется единственным образом. Пусть $A$ - симметрическая: $ A = A^* $ $ A = L D V $ $ A^* = (L D V)^* = V^* D^* L^* = (V^* D L^*) = A $ $ => L = V^*, V = L^* $ $ A = V^* D V $ Пусть матрица $A$ положительно определённая. Тогда по критерию Сильвестра все её угловые миноры положительны. $ (A x, x) > 0 $ $ (D x, x) = (D V y, V y) = (A y, y) > 0 $ $ x = V y $ Все элементы на диагонали в $D$ больше нуля. $ D^(1/2) = "diag"(sqrt(d_1), ..., sqrt(d_n)) $ $ A = V^* D^(1/2) D^(1/2) V $ $ W = D^(1/2) V $ $ W^* = V^* D^(1/2) $ $ A = W^* W $ $ A x = f $ $ W^* W x = f $ $ y:= W x $ $ W^* y = f $ $ a_(i j) = sum_(k = 1)^n W^*_(i k) W_(k j) = sum_(k = 1)^n W_(k i) W_(k j) = sum_(k = 1)^i W_(k i) W_(k j) $ $ a_11 = W_11 W_11 => W_11 = sqrt(a_11) $ $ i = 1 quad j = 2, 3, ..., n:\ a_(1 j) = W_(1 1)W_(1 j) \ W_(1 j) = a_(1 j) / W_11 $ $ a_(i i) = sum_(k=1)^i W_(k i) W_(k i) = sum_(k=1)^(i-1) W^2_(k i) + W^2_(i i) $ $ W_(i i) = sqrt(a_(i i) - sum_(k=1)^(i-1) W_(k i)^2) $ $ a_(i j) = sum_(k=1)^(i-1) W_(k i) W_(k j) + W_(i i) W_(i j) $ $ W_(i j) = (a_(i j) - sum_(k=1)^(i-1) W_(k i) W_(k j))/ W_(i i) $ $ j = i+1, ..., n $ Это был метод квадратного корня. Если матрица симметрическая, но не является положительно определённой, значит решением будут комплексные числа, ничего страшного). == QR разложение (Пуэр разложение) #def[ Гиперплоскость с нормалью $p = vec(p_1, dots.v, p_n)$, проходящая через начало координат $ (p, x) = p_1 x_1 + p_2 x_2 + dots + p_n x_n = 0 $ ] Ортогональное преобразование отражения относительно гиперплоскости, проходящей через начало координат: $ y = x - 2 ((p, x))/((p, p)) p $ $ y = x - 2 ((p, x))/((p, p)) p = x - 2/((p, p)) (p,x) p = x - 2/((p, p)) p p^* x =\ = (I - 2/((p,p)) p p^* )x $ $ P := I - 2/((p,p)) p p^* $ $ y = P x $ *Свойства:* + $P^2 = I$ $ P^2 x = P(P x) = P( x - 2((p,x))/((p,p)) p) = P x - 2((p,x))/((p,p))P p = \ = P x - 2 ((p/x))/((p,p)) (p - 2 ((p,p))/((p,p)) p) = x - cancel(2 ((p, x))/((p, p))) + cancel(2 ((p,x))/(p, p)) = x $ + $P^* =P$ $ P^* = ( I - 2/((p,p)) p p^*)^* = I - 2/((p, p)) p^(**) p^* = p $ + Матрица ортогональная $P^* P = P^2 = I$ + Преобразование отражения не изменится, если вместо вектора нормали $p$ взять вектор $beta p$ $ P = I - 2/((beta p, beta p)) (beta p) (beta p)^* = I - 2/((p, p)) p ^* $ + Вектор нормали $p$ можно определить как разность между исходным и отражённым вектором: $p = x - y$ $ x - y = 2 ((p,x))/((p,p)) p $ + $p_1 = p_2 = dots = p_k = 0$ $=> y_1 = x_1, y_2 = x_2, dots, y_k = x_k$ Докажем: $ y_i = x_i - 2p_i / (sum_(l=1)^n p_l^2) sum_(l=1)^n p_l x_l $ Из этой формулы очевидно (я хз??? он так сказал на лекции) + $p_1 = p_2 = dots = p_k = 0 " и " x_(k+1) = dots = x_n = 0 $ $=> y_(k+1) = dots = y_n = 0$ $ A = Q R,\ "где" Q "ортогональная матрица, а" R "верхняя треугольная" $ Получим матрицу $A_1$ следующим образом: $ A_1 = P_1 A $ Как должен выглядеть первый столбец: $ vec(a_(11)^((1)), 0, 0, dots.v, 0) $ Введём обозначение столбцов матрицы $A$ и $A_1$: $ a_(j), a^((1))_j$. $ vec(a_11, a_21, dots.v, a_(n 1)) = a_1 quad vec(a_(11)^((1)), 0, dots.v, 0) = a_1^((1)) $ $ P_1 a_1 = vec( a_11^((1)), 0, 0, dots.v, 0) $ Вектор нормали $p^((1)) = a_1 - a_1^((1))$ (разность между исходным и отражённым) $ &p^((1))_1 = a_11 - a_11^((1)) \ &p^((1))_2 = a_21 \ &dots.v \ &p^((1))_n = a_(n 1) $ При ортогональном преобразовании длина вектора не меняется: $ norm(a^((1))_1)_2^2 = norm(a_1)_2^2 $ $ (a_11^((1)))^2 = sum_(l=1)^n a_11^2 $ $ a_11^((1)) = plus.minus sqrt(sum_(l=1)^n a_(l i)^2) $ $ p_1^((1)) = a_11 plus.minus sqrt(sum_(l=1)^n a_(l i)^2) $ $ sigma_1 := cases( 1 when a_11 >= 0, -1 when a_11 < 0 ) $ $ p_1^((1)) = a_11 + sigma_1 sqrt(sum_(l=1)^n a_(l i)^2) $ $ a_j^((1)) = a_j - 2 ((p^((1)), a_j)) / ((p_1^((1)), p_1^((1)))) p^((1)) where j = 2, ..., n $ По этой формуле полностью будет определена матрица $A_1$. `15 Октября 2024` $ mat( a_11^((1)), a_12^((1)), dots, a_(1,k-1)^((1)), a_(1 k)^((1)), a_(1,k+1)^((1)), dots, a_(1 n)^((1)); ,a_22^((2)), dots, a_(2,k-1)^((2)), a_(2 k)^((1)), a_(2, k+1)^((1)), dots, a_(2 n)^((1)); ,,dots.down; ,,,a_(k-1,k-1)^((k-1)), a_(k-1,k)^((k-1)), a_(k-1, k+1)^((k-1)), dots, a_(k-1, n)^((k-1)); ,,,,a_(k k)^((k)), a_(k,k+1)^((k)), dots, d_(k,n)^((k)); ,,,,a_(k+1, k)^((k+1)), a_(k+1,k+1)^((k+1)), dots, d_(k+1,n)^((k+1)); ,,,,a_(n-1, k)^((n-1)), a_(n-1,k+1)^((n-1)), dots, d_(n-1,n)^((n-1)); ) $ $ A_k = P_k A_(k - 1) $ $ a_k^((k)) = P_k a_k^((k-1)) = mat( a_(1 k)^((1)); a_(2 k)^((2)); dots.v; a_(n-1,k)^((k-1)); a_(k k)^((k)); 0; dots.v; 0 ) $ $ p^((k)) = a_k^((k-1)) - a_k^((k)) $ $ p_l^((k)) = 0, quad l = 1, 2, dots, n-1 $ $ p_k^((k)) = a_(k k)^((k-1)) - a_(k k)^((k)) $ $ p_l^((k)) = a_(l k)^((k-1)), quad l = k+1, dots, n $ $ norm(a_k^((k+1)))_2^2 = norm(a_k^((k)))_2^2 $ $ a_(k k)^((k)) = plus.minus sqrt(sum_(l=k)^n (a_(l k)^((k-1)))^2) $ $ sigma_k = cases( 1 comma space a_(k k)^((k-1)) >= 0, -1 comma space a_(k k)^((k-1)) < 0 ) $ $ p_k^((k)) = a_(k k)^((k-1)) + sigma_k sqrt(sum_(l=k)^n (a_(l k)^((k-1)))^2) $ $ a_j^((k)) = a_j^((k-1)) - 2 (p^((k)), a_j^((k-1))) / ((p^((k)), p^((k)))) p^k $ $ a_(i j)^((k)) = a_(i j)^((k-1)) - 2 p_i^((k)) / (sum_(l=n)^n (p_l^((k)))^2) sum_(l=k)^n p_l^((k)) a_(l j)^((k-1)) $ $ j = k+1, dots, n $ $ p_1^((k)) = p_2^((k)) = dots = p_(k-1)^((k)) = 0 $ Нужно сделать $n-1$ шаг. Рассмотрим весь процесс в целом. $ R = A_(n-1) = P_(n-1) A_(n-2) = P_(n-1) P_(n-2) A_(n-3) = dots =\ = P_(n-1) P_(n-2) dots P_2 P_1 A $ $ Q := P_1 P_2 dots P_(n-1) $ Матрица $Q$ ортогональная (как произведение ортогональных матриц). $ Q^* = P_(n-1)^* dots P_1^* = P_(n-1) dots P_1 $ $ R = Q^* A $ $ A = Q R $ Требования для существования этого разложения: Рассмотрим случай, когда мы делим на ноль. $ sum_(l=k)^n (p_l^((k)))^2 = 0 <=> p_l^((k)) = 0, space l = k, dots, n $ Подберём вектор нормали, который будет ненулевым, но оставит вектор на месте. Чтобы формально в алгоритме шаг выполнился. Например, $ p^((k)) = vec(0, dots.v, 0, sqrt(2), 0, dots.v, 0) $ Теперь можем говорить, что QR разложение существует для любых матриц. // $ a_(l k)^((k-1)) = 0, quad l = k, ..., n $ Рассмотрим вопрос решения уравнений с помощью QR разложений. $ A x = f $ $ Q R x = f quad $ $ R x = Q^* f $ Распишем $Q^*$: $ Q^* = P_(n-1) dots P_1 $ $ Q^* f := g $ $ f^((1)) = P_1 f $ $ f^((2)) = P_2 f^((1)) $ $ g= f^((n-1)) = P_(n-1) f^((n-2)) $ $ f^((1)) = f - 2 ((p^((1)), f)) / ((p^((1)), p^((1)))) p^((1)) $ $ f^((k)) = f^((k-1)) - 2 p^((k)) / (sum_(l=k)^(n) (p_l^((k)))^2 ) sum_(l = k)^n p_l^((k)) f_l^((k-1)), quad i = k, k+1, dots, n $ == Метод окаймления Способ отыскания обратной матрицы. $ A = A_n = mat(augment: #(hline:-1, vline:-1), a_11, a_12, dots, a_(1 n-1), a_(1 n); a_21, a_22, dots, a_(2 n-1), a_(2 n); dots.v; a_(n-1, 1), a_(n-1, 2), dots, a_(n-1, n-1), a_(n-1, n); a_(n,1), a_(n,2), dots, a_(n, n-1), a_(n, n) ) $ $ A_(n - 1) $ $ v_n = (a_(n 1), a_(n 2), dots, a_(n,n-1)) $ $ u_n = (a_(1 n), a_(2,n), dots, a_(n-1, n))^* $ $ A_n = mat(A_n-1, u_n; v_n, a_(n n)) $ $ A_n^(-1) = mat(P_(n-1), r_n; q_n, 1/alpha_n) = D_n $ Предполагаем, что $A_(n-1)^(-1)$ известна $ mat(A_n-1, u_n; v_n, a_(n n)) mat(P_(n-1), r_n; q_n, 1/alpha_n) = mat(E, 0; 0, 1) $ $ cases( A_(n-1) P_(n-1) + u_n q_n = E, v_n P_(n-1) + a_(n n) q_n = 0, A_(n-1) r_n + u_n/alpha_n = 0, v_n r_n + a_(n n)/alpha_n = 1 ) $ Возмьём третье и выразим: #cbox[ $ r_n = -A_(n-1)^(-1) u_n / alpha_n $] Подставляем в четвёртое: $ - (v_n A_(n-1)^(-1) u_n) / alpha_n + a_(n n) / alpha_n = 1 $ #cbox[ $ alpha_n = a_(n n) - v_n A_(n-1)^(-1) u_n $] // Перейдём ко второму: #cbox[ $ P_(n-1) = A_(n-1)^(-1) - A_(n-1)^(-1) u_n q_n $] $ v_n (A_(n-1)^(-1) - A_(n-1)^(-1) u_n q_n) + a_(n n)q_n = 0 $ $ v_n A_(n-1)^(-1) + (a_(n n)- v_n A_(n-1)^(-1) u_n) q_n = 0 $ $ v_n A_(n-1)^(-1) + alpha_n q_n = 0 $ #cbox[ $ q_n = - (v_n A_(n-1)^(-1))/alpha_n $] + $ -A_(n-1)^(-1) u_n wide (beta_(1 n), dots, beta_(n-1, n))^* $ + $ -v_n A_(n-1)^(-1) wide (gamma_(n 1), dots, gamma_(n, n-1)) $ + $ alpha_n = a_(n n) + sum_(i=1)^(n-1) a_(n i) beta_(i n) = a_(n n) + sum_(i=1)^(n-1) a_(i n) gamma_(n i) $ + $ d_(i k) = d_(i k) + (beta_(i k) gamma_(n k))/ alpha_n, quad i, k <= n-1 $ $ d_(i n) = beta_(i n) / alpha_n quad d_(n k) = gamma_(n k) / alpha_n $ Работа в первом блоке завершена. Можно сдавать первый коллоквиум по прямым методам. Д947. = Итерационные методы $ A x = f $ $ { x^((k)) } $ $ lim_(k->oo) x^((k)) = x^* $ $ lim_(k->oo) norm(x^((k)) - x^*) = 0 $ Каноническая форма записи: $ B (x^((k-1)) - x^((k)))/(tau_k) + A x^((k)) = f, space k = 0, 1, dots $ $x^((0)) "начальное приближение"$ $B - "невырожденная матрица"\ tau - "итерационный параметр (может меняться на разных шагах)" $ Если $tau$ не зависит от $k$, то метод называется стационарным. Если методы сходятся, то они сходятся к точному решению. Поэтому нужно доказывать только сходимость. Скорость сходимости. Надо добиться наивысшей скорости сходимости. Зависит от параметра и от матрицы $B$. Сейчас нас будут интересовать только стационарные методы: $ B (x^((k-1)) - x^((k)))/(tau) + A x^((k)) = f, space k = 0, 1, dots $ $ B x^((k+1)) = B x^((k)) - tau A x^((k)) + tau f $ $ B x^((k+1)) = (B - tau A)x^((k)) + tau f $ Матрица $B$ должна быть простая, чтобы систему можно было просто решать, а то игра не стоит свеч. Показатели: + Вектор погрешности или вектор ошибки $z^((k)) = x^((k)) - x^*$. + Вектор невязки: $r^((k)) = A x^((k)) - f$ $ lim_(k->oo) norm(z^((k))) = 0 - "сходимость к точному решению" $ Добавим и отнимем точное решение: $ B (x^((k-1)) -x^* - x^((k)) + x^*)/tau + A x^((k)) - A x^* = 0 $ $ B (z^((k+1)) - z^(k)) / tau + A z^((k)) = 0 $ $ B z^((k+1)) = B z^((k)) + tau A z^((k)) $ $ z^((k+1)) = (I - tau B^(-1)A) z^((k)) $ Матрица перехода $S = (I - tau B^(-1)A)$: $ z^((k+1)) = S z^((k)) $ Для того, чтобы можно было сравнивать скорости сходимости для разных методом существует асимптотическая скорость сходимости. $ norm(z^((k))) <= 1/e norm(z^((0))) $ Сколько шагов нужно сделать, чтобы начальная ошибка уменьшилась в $e$ раз. $ z^((k+1)) = S z^((k)) => z^((k)) = S^k z^((0)) $ $ norm(z^((k))) <= norm(S)^k norm(z^((0))) $ Самый грубый подход. Потребуем, чтобы: $ norm(S)^k <= 1/e $ Вытащим отсюда $k$: $ k ln norm(S) <= -1 $ Для сходящихся методов норма матрицы всегда меньше единицы. Мы это докажем. $ k >= 1 / (-ln norm(S)) $ $ R = - ln norm(N) - "ассимптотическая скорость сходимости" $ Теперь рассмотрим основополагающую теорему о сходимости стационарных методов. #bbox[Критерий сходимости][ Для того, чтобы стационарный метод сходился при любом начальном приближении, небходимо и достаточно, чтобы все собственные значения матрицы перехода были по модулю меньше единицы. $ abs((lambda(S))) < 1 $ ] Критерий плох тем, что надо постоянно искать собственные значения. Поэтому это теорема базовая. Докажем необходимость. Пусть метод сходится при любом начальном приближении. Докажем, что все собственные значения по модулю меньше единицы. От противного. Пусть метод сходится, но существует хотя бы одно $abs(lambda(S)) >= 1$. Обозначим за $u$ собственный вектор, который соответствует этому собственному значению. $S u = lambda u$. В качестве начального приближения возьмём $x^((0)) = x^* + u$. Тогда $z^((0)) = u$. $ z^((k)) = S^k z^((0)) = S^k u = lambda^k u $ $ norm(z^((k))) = norm(lambda^k u) = abs(lambda)^k norm(u) $ $ u!=0, quad k->oo $ $ norm(z^((k))) arrow.not.r_(k->oo) 0 $ Получили противоречие. Сформулируем лемму, которая понадобится для доказательства достаточности. #bbbox[Лемма][ Пусть все собственные значения матрицы $S$: $ abs(lambda_i (s)) < q, space i = 1, dots, n $ Тогда существует такая невырожденная матрица $T$, что матрица $Lambda = T S T^(-1)$ удовлетворяет такому условию: $norm(Lambda)_oo <= q$ ] Напоминание: $ Lambda tilde S => "собственные значения у них совпадают" $ Теперь докажем достаточность. $ abs(lambda (S)) < 1 $ $ q < 1 $ $ max_i abs(lambda_i (s)) < q $ Надо показать, что $lim_(k->oo) norm(z^((k))) = 0$. Теперь привлекаем лемму. Существует такая невырожденная матрица $T$, что $norm(Lambda)_oo <= q $. $ S = T^(-1) Lambda T $ Подставим $S$ в определение $z^((k))$. $ S^k = T^(-1) Lambda^k T $ $ z^((k)) = S^k z^((0)) = T^(-1) Lambda^k T z^((0)) $ $ norm(z^((k)))_oo = norm(S^k z^((0)) = T^(-1) Lambda^k T z^((0)))_oo <= \ <= norm(T^(-1))_oo norm(Lambda)_oo^k norm(T)_oo norm(z^((0)))_oo <= \ <= mu_oo(T) norm(Lambda^k)_oo norm(z^((0)))_oo <= mu_oo (T) q^k norm(z^((0)))_oo -->_(k->oo) 0 $ #bbox[Теорема][ Для сходимости двуслойного стационарного метода при любом начальном приближении достаточно, чтобы хотя бы одна из норм матрицы перехода $S$, согласованная с какой-нибудь векторной, была меньше единицы. $ norm(S) < 1 $ ] Собственное значение и вектор: $ S u = lambda u $ $ abs(lambda) norm(u) = norm(lambda u) = norm(S u) <= norm(S) norm(u) $ $ abs(lambda) <= norm(S) $ Собственное значение всегда ограничено нормой. $ norm(S) < 1 => abs(lambda) < 1 $
https://github.com/Mayu-onakasuita/typst_japanese_thesis
https://raw.githubusercontent.com/Mayu-onakasuita/typst_japanese_thesis/main/Main.typ
typst
#set text(/*lang:"ja",*/ font: "<NAME>") #import "lib.typ": * #let chapters-on-odd = true #show: ntnu-thesis.with( title: [Show Title], short-title: [Short Title], authors: ("Author 1, ""), //shortauthor: ("<NAME>."), titlepage: true, chapters-on-odd: chapters-on-odd, bibliography: bibliography( "kokoni.bib", style: "american-psychological-association", title: "参考文献" ), figure-index: (enabled: true, title: "図"), table-index: (enabled: true, title: "表"), listing-index: (enabled: false), ) #include "./Chapters/chapter1.typ" #show: appendix.with() #include "Chapters/chapter2.typ"
https://github.com/Myriad-Dreamin/typst.ts
https://raw.githubusercontent.com/Myriad-Dreamin/typst.ts/main/fuzzers/corpora/bugs/square-base_00.typ
typst
Apache License 2.0
#import "/contrib/templates/std-tests/preset.typ": * #show: test-page #set page(height: 80pt) #square(width: 40%, rect(width: 60%, height: 80%))
https://github.com/Raekker/typst_playground
https://raw.githubusercontent.com/Raekker/typst_playground/master/dellabel.typ
typst
#import "@preview/tablex:0.0.5": tablex, rowspanx, colspanx, cellx, hlinex, vlinex, gridx #set page( header-ascent: 0%, footer-descent: 0%, margin: (top: 5mm, bottom: 5mm, left: 5mm, right: 5mm) ) /* unfortunately we can't just change column widths willy nilly in here so replaction of the label table layout isn't exactly doable, at least with one function call here's an example of label layout with varying columns width using stack and tablex function calls */ #stack(dir: ttb, spacing: none, tablex(columns: (5fr, 4fr), rows: (3cm,), [Item Code #v(1fr) #text(20pt)[*31000428*]], [#align(center)[#rect(width:75%,height:2cm)[_Imagine Barcode Here_] #v(1fr) Charge: *BK3264232401*]] ), tablex(columns: (1fr,), rows: (2cm,), [#align(left + horizon)[#text(20pt)[*NE Van Swch MP 6(6x3.5fz)*]]] ), tablex(columns: (1fr,), rows: (7mm,), [Storage: DFR] ), tablex(columns: (5fr, 4fr), rows: (2cm,), [BBD #h(1fr) #text(20pt)[*30.09.2024*] \ (DD.MM.YYYY)], rowspanx(2)[Daily Coding \ #align(left + horizon)[#text(18pt)[*3264*]]], [placeholder] ), tablex(columns: 2 * (1fr,), [Lot \ #text(20pt)[*BK3264232401*]], [Remark/Line], ), tablex(columns: (1fr,), rows: (2cm,), [Supplier], ), tablex(columns: (2fr,1fr,), rows: (2cm,), [Order Number], [Original Amount \ #h(1fr) #text(20pt)[*275.000 CR*]], ) ) // here's an example of table layout with varying column widths // using one main tablex call and then subsequent rows with tablex calls // we need to set inset to 0pt in the main tablex call to not have padding in each cell /* #tablex( columns: (1fr,), header-rows:0, inset: 0pt, tablex(columns: (5fr, 4fr), rows: (3cm,), [Item Code #v(1fr) #text(20pt)[*31000428*]], [#align(center)[#rect(width:75%,height:2cm)[_Imagine Barcode Here_] #v(1fr) Charge: *BK3264232401*]] ), tablex(columns: (1fr,), rows: (2cm,), [#align(left + horizon)[#text(20pt)[*NE Van Swch MP 6(6x3.5fz)*]]] ), tablex(columns: (1fr,), rows: (7mm,), [Storage: DFR] ), tablex(columns: (5fr, 4fr), rows: (2cm,), [BBD #h(1fr) #text(20pt)[*30.09.2024*] \ (DD.MM.YYYY)], rowspanx(2)[Daily Coding \ #align(left + horizon)[#text(18pt)[*3264*]]], [placeholder] ), tablex(columns: 2 * (1fr,), [Lot \ #text(20pt)[*BK3264232401*]], [Remark/Line], ), tablex(columns: (1fr,), rows: (2cm,), [Supplier], ), tablex(columns: (2fr,1fr,), rows: (2cm,), [Order Number], [Original Amount \ #h(1fr) #text(20pt)[*275.000 CR*]], ) ) */ #text(20pt)[ Sample taken at: `________________` (date/signature) \ 2nd Invest at:\u{0020} \u{0020} \u{0020} `________________` (date/signature) // added space unicode chars #align(center)[ #rect(width: 80%, height: 2cm)[_Imagine Barcode Here_] *(00)312001097001032515* ] ] #pagebreak() #set page( header-ascent: 0%, footer-descent: 0%, margin: (left: 1cm, right: 1cm), ) #text(38pt)[ #align(center)[ *Dreyer’s Grand Ice Cream* ] ] #tablex( columns: 3 * (1fr,), header-rows: 0, repeat-header: false, vlinex(stroke: black + 2pt), hlinex(stroke: black + 2pt), colspanx(3)[SSCC \ #align(center)[*#text(30pt)[3] #text(38pt)[12 00109 700103251] #text(30pt)[5]*]], vlinex(stroke: black + 2pt), colspanx(3)[Item #h(1fr) 31000428 #h(1fr) \ #align(center)[#text(20pt)[*NE Van Swch MP 6(6x3.5fz)*]]], colspanx(3)[ #gridx( columns: 3 * (1fr,), [GTIN], [#align(center)[QTY/Pal.]], [#align(right)[Num.GTIN/Layer x Num.Layer]], [00072554753718], [#align(center)[275.0]], [#align(right)[( 25 x 11 )]], ) ], colspanx(3)[ #gridx( columns: 2 * (1fr,), [Included GTIN],[#align(right)[QTY/Pal.]], [00072554111860],[#align(right)[1650.0]], ) ], [BBD/DDM (MM/DD/YY) \ #text(18pt)[*09/30/24*]],[Lot \ BK3264232401],[Gr.Wt./Pal. (KG) \ #text(18pt)[*782.05*]], hlinex(stroke: black + 2pt), ) #rect(width: 90%, height: 2cm)[_Imagine Barcode Here_] (02)00072554753718(15)240930(37)275 #rect(width: 100%, height: 2cm)[_Imagine Barcode Here_] (3302)078205(10)BK3264232401(20)00 #rect(width: 70%, height: 2cm)[_Imagine Barcode Here_] (00)312001097001032515
https://github.com/kalintas/resume
https://raw.githubusercontent.com/kalintas/resume/master/template.typ
typst
#let template(fullname, info, doc) = { show link: underline.with(offset: 2pt) set text(font: "Times New Roman", size: 11pt, lang: "en") set page(margin: (x: 1in, top: 1in, bottom: 1in)) set list(tight: true) let name = n => align(center, text(size: 20pt, n)) grid( columns: (1fr), rows: (auto, auto), gutter: 5pt, name(fullname), info ) doc } #let experience = (where, when) => { where; h(1fr); when } #let project = (repo, name, description) => { link("https://github.com/kalintas/" + repo, emph(name)) [: ] description }
https://github.com/El-Naizin/cv
https://raw.githubusercontent.com/El-Naizin/cv/main/metadata.typ
typst
Apache License 2.0
// NOTICE: Copy this file to your root folder. /* Personal Information */ #let firstName = "Léo" #let lastName = "Naizin" #let personalInfo = ( github: "El-naizin", phone: "+33 6 32 06 02 42", email: "<EMAIL>", linkedin: "leo-naizin", //gitlab: "mintyfrankie", //homepage: "jd.me.org", //orcid: "0000-0000-0000-0000", //researchgate: "John-Doe", //extraInfo: "", ) /* Language-specific */ // Add your own languages while the keys must match the varLanguage variable #let headerQuoteInternational = ( "": [ Data Analyst looking for a full time job starting from now], "en": [Software Engineer looking for a 12 week internship], "fr": [Analyste de données expérimenté à la recherche d'un emploi à temps plein disponible dès maintenant], "zh": [具有丰富经验的数据分析师,随时可入职] ) #let cvFooterInternational = ( "": "Curriculum vitae", "en": "Curriculum vitae", "fr": "Résumé", "zh": "简历" ) #let letterFooterInternational = ( "": "Cover Letter", "en": "Cover Letter", "fr": "Lettre de motivation", "zh": "申请信" ) #let nonLatinOverwriteInfo = ( "customFont": "Heiti SC", "firstName": "王道尔", "lastName": "", // submit an issue if you think other variables should be in this array ) /* Layout Setting */ #let awesomeColor = "red" // Optional: skyblue, red, nephritis, concrete, darknight #let profilePhoto = "" // Leave blank if profil photo is not needed #let varLanguage = "en" // INFO: value must matches folder suffix; i.e "zh" -> "./modules_zh" #let varEntrySocietyFirst = false // Decide if you want to put your company in bold or your position in bold #let varDisplayLogo = true // Decide if you want to display organisation logo or not
https://github.com/jgm/typst-hs
https://raw.githubusercontent.com/jgm/typst-hs/main/test/typ/layout/grid-rtl-01.typ
typst
Other
#set text(dir: rtl) #table(columns: 2)[A][B][C][D]
https://github.com/fabriceHategekimana/master
https://raw.githubusercontent.com/fabriceHategekimana/master/main/3_Theorie/Syntax.typ
typst
#import "@preview/simplebnf:0.1.0": * #import "../src/module.typ" : * #pagebreak() == Syntax du langage Après avoir défini ses différents composants, nous allons maintenant faire une présentation complète du langage prototype système C3PO. #Definition()[Syntax du langage Système C3PO #bnf( Prod( $E$, annot: $sans("Expression")$, { Or[$"let" x = "E1" "in" "E2"$][*let*] Or[$"func"<overline("a")>(overline("x":"T")) -> "T" { "E" }$][*func*] Or[$"if" "E1" "then" "E2" "else" "E3" $][*if*] Or[$"op"$][*bop*] Or[$("E1")< overline( "a")>( overline( "E")) $][*func_app*] Or[$"first"("E") $][*first_arr*] Or[$"rest"("E") $][*rest_arr*] Or[$V $][*V value*] }, ), Prod( $V$, annot: "Value", { Or[$"n" in NN$][*number*] Or[$"true" $][*true*] Or[$"false" $][*false*] Or[$[ overline( "E")] $][*array*] }, ), Prod( $T$, annot: "Type", { Or[$<overline("a")>( overline( "T")) -> "T"$][*function_type*] Or[$["I";"T"] $][*array_type*] Or[$"int" $][*int*] Or[$"bool" $][*bool*] } ), Prod( $I$, annot: "Index", { Or[$"n" in NN$][*number*] Or[$"I" + "I"$][*addition*] } ), Prod( $op$, annot: "bop", { Or[$"E1" "and" "E2" $][*and*] Or[$"E1" "or" "E2" $][*or*] Or[$"E1" + "E2" $][*plus*] Or[$"E1" :: "E2" $][*concat*] Or[$"E1" == "E2"$][*equal*] Or[$"E1" < "E2"$][*lower*] Or[$"E1" <= "E2"$][*lower or equal*] Or[$"E1" > "E2"$][*greater*] Or[$"E1" >= "E2"$][*greater or equal*] } ), Prod( $"ctx"$, annot: "context", { Or[$tack.r Gamma "ctxt" $][*valid_context*] Or[$Gamma tack.r I "index" $][*Index*] } ) ) ]
https://github.com/kdog3682/mathematical
https://raw.githubusercontent.com/kdog3682/mathematical/main/0.1.0/src/utils.typ
typst
#import "formulas.typ": * #let get-dxdy(p1, p2) = { let dx = p2.at(0) - p1.at(0) let dy = p2.at(1) - p1.at(1) return (dx, dy) } #let get-angle-between-points(p1, p2) = { let (dx, dy) = get-dxdy(p1, p2) return calc.atan2(dy, dx) } #let get-adjacently-paired-segments(points) = { let store = () let l = points.len() for i in range(l) { let p1 = points.at(i) let p2 = points.at(calc.rem(i + 1, l)) store.push((p1, p2)) } return store } /// frequently used for determining point position of brace decoration #let get-offset-point(p1, p2, offset) = { let (dx, dy) = get-dxdy(p1, p2) let length = hypot(dx, dy) let ux = -dy / length let uy = dx / length return (p1.at(0) + offset * ux, p1.at(1) + offset * uy) } #let get-centroid(points) = { let sum-x = 0 let sum-y = 0 let n = points.len() for point in points { sum-x += point.at(0) sum-y += point.at(1) } return (sum-x / n, sum-y / n) } #let get-adjacent-pairs = get-adjacently-paired-segments #let hyp = hypot
https://github.com/7sDream/fonts-and-layout-zhCN
https://raw.githubusercontent.com/7sDream/fonts-and-layout-zhCN/master/chapters/05-features/value-records.typ
typst
Other
#import "/lib/glossary.typ": tr #import "/template/theme.typ": theme #let normal-underline-with-style = (f, body) => box[ #place(underline( // underline stroke: 1pt + theme.main, evade: false, background: false, // with transparent character text(fill: rgb("00000000"), body), )) #f(body) ] #let test-font-with-feature = (feature: (), body) => { let features = if type(feature) == array { feature } else { (feature,) } let font = ("TTX Test",) normal-underline-with-style( text.with(features: features), text(font: font, body) ) } #show figure: set block(breakable: true, inset: (y: 1em)) #figure(placement: none)[ #show: align.with(start) 无#tr[positioning]规则:#test-font-with-feature[ABAB] ```fea pos A B <150 0 0 0>```:#test-font-with-feature(feature: "ss01")[ABAB] ```fea pos A B <0 150 0 0>```:#test-font-with-feature(feature: "ss02")[ABAB] ```fea pos A B <0 0 150 0>```:#test-font-with-feature(feature: "ss03")[ABAB] ```fea pos A B <0 0 0 150>```:#test-font-with-feature(feature: "ss04")[ABAB] ]
https://github.com/ludwig-austermann/typst-ouset
https://raw.githubusercontent.com/ludwig-austermann/typst-ouset/main/ouset.typ
typst
MIT License
/// helper function #let __wrap(s, dw, c: 0, insert-and: true) = { if calc.odd(c) { // left clip for e.g. &= if insert-and { h(dw) $&$ } h(-dw) } s if c > 1 { // right clip for e.g. =& h(-dw) if insert-and { $&$ h(dw) } } } /// clip param c ∈ {0,1,2,3} ≜ {no clip, left clip, right clip, both clip}, /// param insert-and: inserts a & at clip positions #let overset(s, t, c: 0, insert-and: true) = if c == 0 { $limits(#s)^(#t)$ } else { context { let sw = measure(s).width let tw = measure($script(#t)$).width let dw = calc.max(tw - sw, 0pt) / 2 __wrap($limits(#s)^(#t)$, dw, c: c, insert-and: insert-and) } } /// clip param c ∈ {0,1,2,3} ≜ {no clip, left clip, right clip, both clip}, /// param insert-and: inserts a & at clip positions #let underset(s, b, c: 0, insert-and: true) = if c == 0 { $limits(#s)_(#b)$ } else { context { let sw = measure(s).width let bw = measure($script(#b)$).width let dw = calc.max(bw - sw, 0pt) / 2 __wrap($limits(#s)_(#b)$, dw, c: c, insert-and: insert-and) } } /// clip param c ∈ {0,1,2,3} ≜ {no clip, left clip, right clip, both clip} /// param insert-and: inserts a & at clip positions #let overunderset(s, t, b, c: 0, insert-and: true) = if c == 0 { $limits(#s)^(#t)_(#b)$ } else { context { let sw = measure(s).width let tw = measure($script(#t)$).width let bw = measure($script(#b)$).width let dw = calc.max(calc.max(tw, bw) - sw, 0pt) / 2 __wrap($limits(#s)^(#t)_(#b)$, dw, c: c, insert-and: insert-and) } } /// wrapper for the other functions. Write `ouset(&, <, toptext, bottomtext, &)`, no argument is mandatory, but first & will be search at first and last position, otherwise everything must be in this order. #let ouset(..a-sym-over-under-a, insert-and: true) = { let params = a-sym-over-under-a.pos() let pl = params.len() if pl == 0 { return } let frontand = params.at(0) == $&$.body let backand = params.last() == $&$.body let c = if frontand { 1 } else { 0 } + if backand { 2 } else { 0 } let rest-params = params.slice( if frontand { 1 } else { 0 }, if backand { pl - 1 } else { pl }, ) overunderset( rest-params.at(0, default: []), rest-params.at(1, default: []), rest-params.at(2, default: []), c: c, insert-and: insert-and, ) }
https://github.com/ludwig-austermann/typst-idwtet
https://raw.githubusercontent.com/ludwig-austermann/typst-idwtet/main/README.md
markdown
MIT License
# Package IDWTET The name `idwtet` stands for "I Don't Wanna Type Everything Twice". It provides a `typst-ex` and a `typst-ex-code` codeblock, which *shows **and** executes* typst code. It is meant for code demonstration, e.g. when publishing a package, and provides some niceties: - the code should always be correct in the examples: As the example code is used for the code block, but also for evaluation, there is no need to write it twice - easy configuration with simple, uniform and good look However, there are some limitations: - Every code block has its own local scope and the default behaviour is that variables are not reachable from outside. A similar restriction lies on import statements. That is why, there is the `eval-scope` argument, which captures variables and simulates global variables. Additionally, a `typst` codeblock is provided for a consistent look. - Locality can be displayed to the users by automatically wrapping code in `typst-ex-code`, but `typst-ex` does not provide such functionality. It might thus be difficult for users to understand code examples this way. - The page width has to be defined in absolute terms. It is quite nice, for a showcase, to take the least possible space, but tracking the widths of all boxes and then setting the page width accordingly is not (yet) possible. ## Usage Only one function is defined, `init(body, bcolor: luma(210), inset: 5pt, border: 2pt, radius: 2pt, content-font: "linux libertine", code-font-size: 9pt, content-font-size: 11pt, code-return-box: true, wrap-code: false, eval-scope: (:), escape-bracket: "%")`, which is supposed to be used with a show rule. Then raw codeblocks (with `block=true`) of the languages `typst`, `typst-ex`, `typst-code` and `typst-ex-code` are modified. The main feature of this package are `typst-ex` and `typst-ex-code`. The `typst` and `typst-code` blocks do not evaluate anything, but their design fits that of the others. The parameters of `init` are: - `body`: for usage with show rule, hence the whole document. - `bcolor`: the background- (and border-) color of the blocks - `inset`: inset param of code and content blocks, should be ≥ 2pt - `border`: border thickness - `radius`: block radius - `content-font`: The font used in the previewed content / result. - `code-font-size`: The fontsize used in the code blocks. - `content-font-size`: The fontsize used in the preview content / result. - `code-return-box`: If to show the code return type on `typst-ex-code` blocks. - `wrap-code`: If to wrap the code in `#{` and `}`, to symbolize local scope. - `eval-scope`: A dictionary with the keys as the variable names and the values as another dictionary with keys `value` and `code`, both of these are optional. The former has the defined value, the latter the code recreate the variable, for usage in the code blocks. - `escape-bracket`: The text to wrap a variable with, to access the `code` part of a `eval-scope` variable. ## Hiding code and replacements There are currently two methods to change the code: - use the `eval-scope` argument from the `init` function. There is a `code` field in the dictionaries, which enables the usage of the key escaped in `escape-bracket` to be replaced in the codeblock code half and to be removed in the codeblock result half, as the value is given via scope. Take a look at the example below, where `%ouset%` is used this way. - use the `ENDHIDDEN` feature. When escaped in `escape-bracket`, everything above the statement is removed from the codeblock code half BUT everything (without the `ENDHIDDEN` statement) is evaluated. Take a look at the example in the examples folder. ## Example ````typst #set page(margin: 0.5cm, width: 14cm, height: auto) #import "@preview/idwtet:0.1.0" #show: idwtet.init.with(eval-scope: ( ouset: ( value: {import "@preview/ouset:0.1.1": ouset; ouset}, code: "#import \"@preview/ouset:0.1.1\": ouset" ) )) == ouset package #text(gray)[(v0.1.1)] ```typst-ex %ouset% $ "Expression 1" ouset(&, <==>, "Theorem 1") "Expression 2"\ ouset(&, ==>,, "Theorem 7") "Expression 3" $ ``` Or something like ```typst-ex-code let a = range(10) a ``` ```` Further examples are given in the repo example folder.
https://github.com/jgm/typst-hs
https://raw.githubusercontent.com/jgm/typst-hs/main/test/typ/compiler/import-04.typ
typst
Other
// Edge case for module access that isn't fixed. #import "module.typ" // Works because the method name isn't categorized as mutating. #test((module,).at(0).item(1, 2), 3) // Doesn't work because of mutating name. // Error: 2-11 cannot mutate a temporary value #(module,).at(0).push()
https://github.com/ns-shop/ns-shop-typst
https://raw.githubusercontent.com/ns-shop/ns-shop-typst/main/cover.typ
typst
#let cover(border: true) = { rect(width: 100%, height: 100%, stroke: if(border) {2.5pt} else {0pt}, [ #set align(center) \ BAN CƠ YẾU CHÍNH PHỦ \ *HỌC VIỆN KỸ THUẬT MẬT MÃ* #line(start: (50% - (3.5cm / 2), 0%), length: 3.5cm) #image("./images/logo.png", width: 3.5cm) \ ĐỒ ÁN TỐT NGHIỆP \ \ #text( weight: "bold", size: 16pt, "XÂY DỰNG WEBSITE THƯƠNG MẠI ĐIỆN TỬ AN TOÀN") \ \ \ #set align(left) #pad( left: 8cm, [ #"\t\t\tNgành: An toàn thông tin" \ #"Mã số: 7.48.02.02" \ ] ) \ #pad(left: 2cm, [ _Sinh viên thực hiện_: \ #pad(left: 1cm, [*Ngô Quang Sang*]) #pad(left: 1cm, [Lớp: AT15H]) _Người hướng dẫn_: \ #pad(left: 1cm, [*ThS. Nguyễn Thị Kim Oanh*]) #pad(left: 1cm, [Khoa Công Nghệ Thông Tin - Trường Cao đẳng \ Nông Nghiệp và Phát triển Nông Thôn Bắc Bộ]) ]) #set align((center + bottom)) #pad(bottom: .25cm, "Thành phố Hồ Chí Minh, 2023") ]) }
https://github.com/Jeomhps/datify
https://raw.githubusercontent.com/Jeomhps/datify/main/tests/test_formats.typ
typst
MIT License
// To compile this file : typst compile --root .. .\test_formats.typ #import "../src/formats.typ": custom-date-format #let date = datetime(year: 2024, month: 8, day: 29) #assert(custom-date-format(date, "YYYY-MM-DD") == "2024-08-29") #assert(custom-date-format(date, "MM/DD/YYYY") == "08/29/2024") #assert(custom-date-format(date, "Month DD, YYYY") == "August 29, 2024") #assert(custom-date-format(date, "month DD, YYYY") == "august 29, 2024") #assert(custom-date-format(date, "month DDth, YYYY") == "august 29th, 2024") #let french_date = datetime(year: 2024, month: 5, day: 23) #assert(custom-date-format(french_date, "Day, DD Month YYYY", "fr") == "Jeudi, 23 Mai 2024") #let french_date = datetime(year: 2024, month: 8, day: 23) #assert(custom-date-format(french_date, "Day, DD MMM YYYY", "fr") == "Vendredi, 23 aoû 2024") #let spanish_date = datetime(year: 2023, month: 2, day: 23) #assert(custom-date-format(spanish_date, "day, DD de month de YYYY", "es") == "jueves, 23 de febrero de 2023") #let spanish_date = datetime(year: 2024, month: 8, day: 9) #assert(custom-date-format(spanish_date, "day, DD de month de YYYY", "es") == "viernes, 09 de agosto de 2024")
https://github.com/ammar-ahmed22/typst-resume
https://raw.githubusercontent.com/ammar-ahmed22/typst-resume/main/src/utils/init.typ
typst
#let init( headingFont: "Linux Libertine", bodyFont: "Linux Libertine", fontSize: 11pt, lineSpacing: 6pt, accentColor: black, doc, ) = { set page( paper: "us-letter", margin: 1.25cm ) set text( font: headingFont, size: fontSize, hyphenate: false, ) set list( spacing: lineSpacing ) set par( leading: lineSpacing ) show heading.where( level: 1, ): it => block(width: 100%)[ #set align(center) #set text(font: headingFont, size: 1.5em, weight: "bold", fill: accentColor) #smallcaps(it.body) ] show heading.where( level: 2, ): it => block(width: 100%)[ #set align(left) #set text(font: headingFont, size: 1em, weight: "semibold", fill: accentColor) #smallcaps(it.body) #v(-0.75em) #line(length: 100%, stroke: 1pt + accentColor) ] doc }
https://github.com/augustebaum/petri
https://raw.githubusercontent.com/augustebaum/petri/main/src/cetz-shapes.typ
typst
MIT License
#import "@preview/cetz:0.2.2" as cetz: draw #import cetz.drawable: path #import cetz.vector #let _label(label, labelled-element-name: "", anchor: "north", ..style) = { let opposite-anchor = ( "north-west": "south-east", "north": "south", "north-east": "south-west", "west": "east", "center": "center", "east": "west", "south-west": "north-east", "south": "north", "south-east": "north-west", ).at(anchor) draw.content( (name: labelled-element-name, anchor: anchor), label, anchor: opposite-anchor, ..style ) } /// CeTZ shape for Petri places #let _token(center, name: "", ..style) = draw.circle(center, name: name, ..style) #let _place_tokens(tokens, ..style) = { let radius(n_tokens) = (0.12 / calc.sin(180deg / n_tokens)) let ngon(n, start-angle: 90deg) = { for k in range(n) { _token((start-angle + 360deg * k / n, radius(n)), ..style) } } if tokens == 0 { } else if tokens == 1 { _token((0,0), ..style) } else if tokens == 2 { ngon(tokens, start-angle: 0deg) } else if tokens in range(3, 7) { ngon(tokens) } else if tokens == 7 { ngon(6) _token((0,0), ..style) } else { _token((0,0), name: "token", ..style) draw.content("token.south", text(size:0.7em)[#tokens], anchor: "north", padding: 0.07em) } } #let place(center, label, name: none, ..style) = { draw.group(name: name, ctx => { let shape-name = "place" // Define a default style let def-style = ( tokens: 0, radius: 1em, label-style: (anchor: "north", padding: 0.5em), // TODO: Make the default token radius and spacing dependent on the node radius token-style: (radius: 0.2em, spacing: 1em, fill: black) ) let style = cetz.styles.resolve( ctx.style, merge: style.named(), base: def-style, root: shape-name ) draw.circle(center, ..style, name: shape-name) draw.copy-anchors(shape-name) _label(label, labelled-element-name: shape-name, ..style.label-style) draw.set-origin(center) _place_tokens(style.tokens, ..style.token-style) }) } /// CeTZ shape for Petri transitions #let transition(center, label, name: none, ..style) = { draw.group(name: name, ctx => { let shape-name = "transition" let def-style = ( width: 0.4em, height: 2.5em, fill: black, stroke: none, label-style: (anchor: "north", padding: 0.5em), ) let style = cetz.styles.resolve( ctx.style, merge: style.named(), base: def-style, root: shape-name ) let w = style.width / 2 let h = style.height / 2 draw.set-origin(center) draw.rect( (- w, - h), ( w, h), ..style, name: shape-name ) _label(label, labelled-element-name: shape-name, ..style.label-style) }) }
https://github.com/typst/packages
https://raw.githubusercontent.com/typst/packages/main/packages/preview/fletcher/0.1.1/src/exports.typ
typst
Apache License 2.0
#import "main.typ": arrow-diagram, node, conn #import "all.typ" as arrow-diagrams
https://github.com/SWATEngineering/Docs
https://raw.githubusercontent.com/SWATEngineering/Docs/main/src/3_PB/PianoDiQualifica/content.typ
typst
MIT License
#import "functions.typ": glossary, team #let fornitura=csv("Mfornitura.csv") #show link: underline /*************************************/ /* INSERIRE SOTTO IL CONTENUTO */ /*************************************/ = Introduzione Il _Piano di Qualifica_ è un documento che delinea le strategie e le attività mirate a garantire la qualità del prodotto e propone di guidare il team attraverso un percorso di miglioramento continuo, principio a cui anch'esso è soggetto. Il documento viene regolarmente aggiornato in modo tale da guidare gli sforzi di qualità sulla base delle mutevoli esigenze del progetto, garantendo così che il processo e il prodotto crescano e si evolvano con il tempo. Il documento costituisce un impegno concreto per assicurare la qualità in modo costante nel corso del progetto. == Scopo Questo documento ha lo scopo di garantire la qualità del processo e del prodotto attraverso diversi passaggi fondamentali. La definizione di metriche quantitative e la loro periodica misurazione permettono al team di valutare l'andamento del progetto e di intraprendere decisioni che ne permettano la costante ottimizzazione. Si propone inoltre di guidare il team attraverso tutte le fasi di testing: dalla pianificazione dei test fino alla valutazione dei risultati ottenuti. == Glossario Al fine di evitare possibili ambiguità relative al linguaggio utilizzato nei documenti, viene fornito il _Glossario v2.0_, nel quale sono presenti tutte le definizioni di termini aventi un significato specifico che vuole essere disambiguato. Tali termini, sono scritti in _corsivo_ e marcati con una #sub("G") a pedice. Un'attività che comprende l'inserimento di un termine di glossario può considerarsi conclusa solo nel momento in cui il termine viene scritto e spiegato nel _Glossario_. == Riferimenti === Normativi - _Norme di Progetto v2.0_; - Documento e presentazione di capitolato d'appalto C6 - InnovaCity: - _ https://www.math.unipd.it/~tullio/IS-1/2023/Progetto/C6.pdf _ (05/12/2023) - _ https://www.math.unipd.it/~tullio/IS-1/2023/Progetto/C6p.pdf _ (20/11/2023) - Regolamento di progetto: - _ https://www.math.unipd.it/~tullio/IS-1/2023/Dispense/PD2.pdf _ (15/03/2024) === Informativi - Slide dell'insegnamento di Ingegneria del Software: - Qualità del software: - _ https://www.math.unipd.it/~tullio/IS-1/2023/Dispense/T7.pdf _ (29/11/2023) - Qualità di processo: - _ https://www.math.unipd.it/~tullio/IS-1/2023/Dispense/T8.pdf _ (05/12/2023) - Verifica e Validazione: - _ https://www.math.unipd.it/~tullio/IS-1/2023/Dispense/T9.pdf _ (18/12/2023) - _ https://www.math.unipd.it/~tullio/IS-1/2023/Dispense/T10.pdf _ (04/01/2024) - _ https://www.math.unipd.it/~tullio/IS-1/2023/Dispense/T11.pdf _ (04/01/2024) #pagebreak() = Qualità di processo La qualità di processo si fonda sull'assunto che, al fine di ottenere un prodotto che soddisfi determinati standard di qualità, è necessario che i processi che lo sottendono siano sottoposti a controlli periodici con lo scopo ultimo di ottimizzarli. Il concetto di qualità di processo viene dunque applicato all'intero spettro di attività, pratiche e metodi utilizzati lungo l'intero ciclo di vita del software. In sintesi, la qualità di processo mira a rendere la qualità una parte integrante del prodotto, garantendo che sia costruita nel processo stesso e non sia solo un obiettivo secondario. Di seguito vengono presentate le metriche che il team si impegna a soddisfare nel contesto della qualità di processo. Come presentato nel documento _Norme di Progetto v2.0_, la sigla MPC sta ad indicare le metriche di processo. == Processi primari === Fornitura #figure( table( columns:(auto,auto,auto,auto), align: (x, y) => (center, center, center,center).at(x), fill:(_,row) =>if row==0 {luma(150)} else if calc.odd(row) { luma(220)} else {white}, [*Metrica*],[*Descrizione*],[*Valore accettazione*],[*Valore ideale*], ..fornitura.flatten() ), caption: [Tabella metriche per il processo di fornitura.] ) === Sviluppo ==== Codifica #figure( table( columns:(auto,auto,auto,auto), align: (x, y) => (center, center, center,center).at(x), fill:(_,row) => if row==0 {luma(150)} else if calc.odd(row) { luma(220)} else {white}, [*Metrica*],[*Descrizione*],[*Valore accettazione*],[*Valore ideale*], [MPC-ATC], [Attributi per Classe], [≤ 6], [≤ 4], [MPC-PM], [Parametri per Metodo], [≤ 5], [≤ 4], [MPC-LCM], [Linee di Codice per Metodo], [≤ 25], [≤ 20] ), caption: [Tabella metriche per l'attività di codifica.]) #pagebreak(); == Processi di supporto ==== Documentazione #figure( table( columns:(auto,auto,auto,auto), align: (x, y) => (center, center, center,center).at(x), fill:(_,row) =>if row==0 {luma(150)} else if calc.odd(row) { luma(220)} else {white}, [*Metrica*],[*Descrizione*],[*Valore accettazione*],[*Valore ideale*], [MPC-IG], [Indice Gulpease], [≥ 60], [100], [MPC-CO], [Correttezza Ortografica], [0], [0] ), caption: [Tabella metriche per il processo di documentazione.] ) ==== Gestione della qualità #figure( table( columns:(auto,auto,auto,auto), align: (x, y) => (center, center, center,center).at(x), fill:(_,row) =>if row==0 {luma(150)} else if calc.odd(row) { luma(220)} else {white}, [*Metrica*],[*Descrizione*],[*Valore accettazione*],[*Valore ideale*], [MPC-MNS], [Metriche Non Soddisfatte], [≤3], [0], ), caption: [Tabella metriche per il processo di gestione della qualità.] ) #pagebreak() = Qualità di prodotto La qualità di prodotto è volta alla valutazione del software realizzato: l'attenzione è rivolta ad attributi quali usabilità, funzionalità, affidabilità, manutenibilità, ma più in generale alle prestazioni del prodotto. L'obiettivo è, dunque, assicurare che il software non solo implementi le funzionalità volute dal cliente e funzioni correttamente, ma che lo faccia seguendo le indicazioni di precisi standard di qualità. Di seguito vengono presentate le metriche che il team si impegna a soddisfare nel contesto della qualità di prodotto. Come presentato nel documento _Norme di Progetto v2.0_ la sigla MPD sta ad indicare le metriche di prodotto. == Funzionalità #figure( table( columns:(auto,auto,auto,auto), align: (x, y) => (center, center, center,center).at(x), fill:(_,row) => if row==0 {luma(150)} else if calc.odd(row) { luma(220)} else {white}, [*Metrica*],[*Descrizione*],[*Valore accettazione*],[*Valore ideale*], [MPD-ROS], [Requisiti Obbligatori Soddisfatti], [100%], [100%], [MPD-RDS], [Requisiti Desiderabili Soddisfatti], [≥ 0%], [≥ 75%], [MPD-ROPS], [Requisiti Opzionali Soddisfatti], [≥ 0%], [≥ 50%], ), caption: [Tabella metriche per la funzionalità del prodotto.]) == Manutenibilità #figure( table( columns:(auto,auto,auto,auto), align: (x, y) => (center, center, center,center).at(x), fill:(_,row) => if row==0 {luma(150)} else if calc.odd(row) { luma(220)} else {white}, [*Metrica*],[*Descrizione*],[*Valore accettazione*],[*Valore ideale*], [MPD-SFIN], [Structure Fan In], [massimizzare], [massimizzare], [MPD-SFOUT], [Structure Fan Out], [minimizzare], [minimizzare], [MPD-CCM], [Complessità Ciclomatica per Metodo], [≤ 5], [≤ 4], ), caption: [Tabella metriche per la manutenibilità del prodotto. ]) /*SFIN e SFOUT sono da determinare ancora, ma non ho idea di quali potrebbero essere i valori più adatti e quindi lascio volentieri al prossimo la decisione*/ == Usabilità #figure( table( columns:(auto,auto,auto,auto), align: (x, y) => (center, center, center,center).at(x), fill:(_,row) => if row==0 {luma(150)} else if calc.odd(row) { luma(220)} else {white}, [*Metrica*],[*Descrizione*],[*Valore accettazione*],[*Valore ideale*], [MPD-FU], [Facilità di Utilizzo], [≤ 7 click], [≤ 5 click], [MPD-TA], [Tempo di Apprendimento], [≤ 10 minuti], [≤ 5 minuti] ), caption: [Tabella metriche per l'usabilità del prodotto.]) == Affidabilità #figure( table( columns:(auto,auto,auto,auto), align: (x, y) => (center, center, center,center).at(x), fill:(_,row) => if row==0 {luma(150)} else if calc.odd(row) { luma(220)} else {white}, [*Metrica*],[*Descrizione*],[*Valore accettazione*],[*Valore ideale*], [MPD-PTCP], [Passed Test Cases Percentage], [≥ 80%], [100%], [MPD-BC], [Branch Coverage], [≥80%], [100%], [MPD-SC], [Statement Coverage], [≥80%], [100%], ), caption: [Tabella metriche per l'affidabilità del prodotto.]) #pagebreak() == Efficienza #figure( table( columns:(auto,auto,auto,auto), align: (x, y) => (center, center, center,center).at(x), fill:(_,row) => if row==0 {luma(150)} else if calc.odd(row) { luma(220)} else {white}, [*Metrica*],[*Descrizione*],[*Valore accettazione*],[*Valore ideale*], [MPD-CPUU],[Maximum CPU Usage],[\≤ 20%],[\≤ 15%], [MPD-RAMU],[Maximum RAM Usage],[\≤ 3 GB],[\≤ 2GB], [MPD-TDE],[Tempo Di Elaborazione],[\≤ 6s], [\≤ 4s], ), caption: [Tabella metriche per l'efficienza del prodotto.]) #pagebreak() = Strategie di testing In questa sezione viene esposto il piano di testing che verrà utilizzato per garantire la correttezza finale del prodotto. Come enunciato nel documento _Norme di Progetto v2.0_, il piano segue il #glossary("modello a V"), il quale associa ad ogni fase di sviluppo una corrispondente tipologia di testing. Tali tipologie sono le seguenti: - *Test di unità*: si verifica il corretto funzionamento delle unità componenti il #glossary[sistema]. Un'unità rappresenta un elemento indivisibile e indipendente del #glossary[sistema]\; - *Test di integrazione*: si verifica il corretto funzionamento di più unità che cooperano per svolgere uno specifico compito (tali unità devono certamente aver superato i loro test di unità precedentemente); - *Test di #glossary[sistema]*: si verifica il corretto funzionamento del #glossary[sistema] nella sua interezza. I requisiti funzionali obbligatori, di vincolo, di qualità e di prestazione, precedentemente concordati con la Proponente mediante stipulazione del contratto, devono essere soddisfatti per intero; - *Test di accettazione*: si verifica il soddisfacimento della Proponente rispetto al prodotto software. Il loro superamento permette di procedere con il rilascio del prodotto. Per le procedure necessarie all'esecuzione di test di unità e di integrazione si rimanda al documento _Norme di Progetto v2.0_ nella sezione relativa al processo di verifica. == Test di accettazione In questa sezione vengono descritti i test di accettazione del prodotto software, eseguiti sia dal gruppo #team che dalla Proponente sotto la supervisione del gruppo. Si vuole, con tali test, andare a validare il prodotto prima del suo rilascio. #let test_di_accettazione = ( ([ Verificare che l'#glossary("amministratore pubblico") senza autenticazione possa: 1. Usufruire dell'applicazione senza doversi autenticare. ],"S",[ UC1\ UC2\ UC3\ UC4\ UC5\ UC6\ UC7\ UC8 ]), ([ Verificare che l'#glossary("amministratore pubblico"), una volta entrato nell'applicazione, possa: 1. Aprire il menu di selezione delle #glossary("dashboard")\; 2. Selezionare la #glossary("dashboard") dei dati grezzi; 3. Visualizzare la relativa #glossary("dashboard")\; 4. Visualizzare un #glossary("pannello") con una tabella che mostra i dati grezzi, in particolare il nome del #glossary[sensore], la tipologia del #glossary[sensore], il timestamp della rilevazione e il valore della misurazione (se composta da più dati, tutti i valori devono essere elencati nella colonna corrispondente); 5. Visualizzare un messaggio di avvertenza di dati mancanti, all'interno del #glossary("pannello"), nel caso il #glossary[sistema] non riesca a reperire i dati. ],"S",[ UC0\ UC1\ UC1.1\ UC9 ]), ([ Verificare che l'#glossary("amministratore pubblico"), una volta entrato nell'applicazione, possa: 1. Aprire il menu di selezione delle #glossary("dashboard")\; 2. Selezionare la #glossary("dashboard") per visualizzare i dati ambientali; 3. Visualizzare la relativa #glossary("dashboard")\; 4. Visualizzare un #glossary("pannello") contenente un grafico in formato #glossary("serie storica") che mostri i risultati delle rilevazioni delle temperatura, espressa in gradi Celsius (°C), effettuate dai singoli sensori e aggregati tramite media aritmetica per intervalli di 1 minuto e i risultati delle rilevazioni della temperatura effettuate da tutti i sensori e aggregati tramite media aritmetica per intervalli di 5 minuti; 5. Visualizzare un #glossary("pannello") contenente un grafico in formato #glossary("serie storica") che mostri i risultati delle rilevazioni dell'umidità, espressa in percentuale, effettuate dai singoli sensori e aggregati tramite media aritmetica per intervalli di 1 minuto e i risultati delle rilevazioni dell'umidità effettuate da tutti i sensori e aggregati tramite media aritmetica per intervalli di 5 minuti; 6. Visualizzare un #glossary("pannello") con una mappa mostrante la direzione del vento, rilevata da ciascun #glossary("sensore"), tramite delle frecce con origine la posizione del #glossary("sensore")\; 7. Visualizzare un #glossary("pannello") con una tabella che mostri l'ultima rilevazione della velocità del vento, espressa in chilometri orari (km/h), e la sua direzione, espressa in gradi (con gli 0° a Est e i 180° a Ovest), effettuata da ciascun #glossary("sensore")\; 8. Visualizzare un #glossary("pannello") contenente un grafico in formato #glossary("serie storica") che mostri i risultati delle rilevazioni delle quantità di precipitazioni, espressa in millimetri orari (mm/h), effettuate dai singoli sensori e aggregati tramite media aritmetica per intervalli di 1 minuto e i risultati delle rilevazioni delle quantità di precipitazioni effettuate da tutti i sensori e aggregati tramite media aritmetica per intervalli di 5 minuti; 9. Visualizzare un #glossary("pannello") contenente un indice numerico relativo alle precipitazioni, espresse in millimetri orari (mm/h), indicante la media dell'intensità delle precipitazioni tra tutti i dati raccolti dai sensori nell'intervallo di tempo impostato all'interno della #glossary[dashboard]; 10. Visualizzare un #glossary("pannello") contenente un grafico in formato #glossary("serie storica") che mostri i risultati delle rilevazioni della concentrazione di inquinanti dell'aria (#glossary("PM10")), espressa in $#sym.mu g\/m^3$,effettuate dai singoli sensori e aggregati tramite media aritmetica per intervalli di 1 minuto e i risultati delle rilevazioni della concentrazioni di inquinanti effettuate da tutti i sensori e aggregati tramite media aritmetica per intervalli di 5 minuti; 11. Visualizzare un #glossary("pannello") contenente la media della concentrazione di inquinanti dell'aria (#glossary("PM10")), espressa in $#sym.mu g\/m^3$, che consideri le rilevazioni di tutti i sensori attivi nell'ultimo minuto, e sia presentata in formato numerico; 12. Visualizzare un #glossary("pannello") contenente un grafico in formato #glossary("serie storica") che mostri i risultati delle rilevazioni della percentuale di riempimento dei bacini idrici, effettuate dai singoli sensori e aggregate tramite media aritmetica per intervalli di 1 minuto e i risultati delle rilevazioni della percentuale di riempimento effettuate da tutti i sensori e aggregati tramite media aritmetica per intervalli di 5 minuti; 13. Visualizzare un #glossary("pannello") contenente la media della temperatura, espressa in gradi Celsius (°C), considerando tutti i sensori attivi nell'intervallo di tempo impostato all'interno della #glossary[dashboard], e presentata in formato numerico; 14. Visualizzare un #glossary("pannello") contenente il massimo coefficiente di inquinamento dell'aria (#glossary("PM10")) registrato tra tutti i sensori negli ultimi 5 minuti, espresso in $#sym.mu g\/m^3$, presentato in formato numerico; 15. Visualizzare un #glossary("pannello") con una mappa che indichi, mediante icone collocate presso le coordinate di ciascun #glossary[sensore], la posizione dei sensori; 16. Visualizzare un messaggio di avvertenza di dati mancanti, nei vari #glossary("pannelli"), nel caso di assenza di dati da mostrare. ],"S",[ UC0\ UC2\ UC2.1\ UC2.2\ UC2.3\ UC2.4\ UC2.5\ UC2.6\ UC2.7\ UC2.8\ UC2.9\ UC2.10\ UC2.11\ UC2.12\ UC2.13\ UC9 ]), ([ Verificare che l'#glossary("amministratore pubblico"), una volta entrato nell'applicazione, possa: 1. Aprire il menu di selezione delle #glossary("dashboard")\; 2. Selezionare la #glossary("dashboard") per visualizzare i dati urbanistici; 3. Visualizzare la relativa #glossary("dashboard")\; 4. Visualizzare un #glossary("pannello") con una mappa che indichi, mediante indicatori numerici, collocati presso le coordinate di ciascun #glossary("sensore"), la quantità di posti liberi nel parcheggio corrispondente; 5. Visualizzare un #glossary("pannello") contenente una mappa che indichi, mediante indicatori booleani collocati presso le coordinate di ciascun #glossary("sensore"), la disponibilità della colonna corrispondente; 6. Visualizzare un #glossary("pannello") che esprima, tramite una tabella indicizzata tramite il nome del #glossary("sensore"), l'erogazione energetica, espressa in watt per ora (kWh); 7. Visualizzare un #glossary("pannello") contenente una mappa che indichi, tramite gli stati "LOW", "MEDIUM", "HIGH" e "BLOCKED", lo stato di congestione delle strade; 8. Visualizzare un #glossary("pannello") contenente una mappa che indichi, mediante degli indicatori numerici che indicano la percentuale di batteria, la posizione in tempo reale delle biciclette elettriche; 9. Visualizzare un #glossary("pannello") contenente una mappa indicante lo stato di riempimento delle zone ecologiche, espresse in valori percentuali, posizionate nelle coordinate delle zone; 10. Visualizzare un messaggio di avvertenza di dati mancanti, nei vari #glossary("pannelli"), nel caso di assenza di dati da mostrare. ],"S",[ UC0\ UC3\ UC3.1\ UC3.2\ UC3.3\ UC3.4\ UC3.5\ UC3.6\ UC3.7\ UC9 ]), ([ Verificare che l'#glossary("amministratore pubblico"), una volta entrato nell'applicazione, possa: 1. Aprire il menu di selezione delle #glossary("dashboard")\; 2. Selezionare la #glossary("dashboard") per visualizzare il superamento delle soglie; 3. Visualizzare la relativa #glossary("dashboard")\; 4. Visualizzare un #glossary("pannello") contenente una tabella, la quale mostra tutte le anomalie rilevate, mostrando il valore dell'anomalia, il #glossary("sensore") che l'ha rilevata e il relativo #glossary("timestamp")\; 5. Visualizzare un #glossary("pannello") contenente una tabella, la quale mostra tutti i dati superanti la soglia dei 40° Celsius (40°C) di temperatura, mostrando il valore superante la soglia, il #glossary("sensore") che ha rilevato tale valore e il relativo #glossary("timestamp")\; 6. Visualizzare un #glossary("pannello") contenente una tabella, la quale mostra tutti i dati superanti la soglia dei 50 millimetri di pioggia all'ora (50 mm/h), mostrando il valore superante la soglia, il #glossary("sensore") che ha rilevato tale valore e il relativo #glossary("timestamp")\; 7. Visualizzare un #glossary("pannello") contenente una tabella, la quale mostra tutti i dati superanti la soglia di 80#[#sym.mu]g su metro cubo ($80#sym.mu g\/m^3$) di livello di polveri sottili nell'aria (#glossary[PM10]), mostrando il valore superante la soglia, il #glossary("sensore") che ha rilevato tale valore e il relativo #glossary("timestamp")\; 8. Visualizzare un #glossary("pannello") contenente una tabella, la quale mostra tutti i dati superanti la soglia del 70% di capienza dei bacini idrici, mostrando il valore superante la soglia, il #glossary("sensore") che ha rilevato tale valore e il relativo #glossary("timestamp")\; 9. Visualizzare un #glossary("pannello") contenente una tabella, la quale mostra tutti i dati superanti la soglia dell'80% di capienza delle zone ecologiche, mostrando il valore superante la soglia, il #glossary("sensore") che ha rilevato tale valore e il relativo #glossary("timestamp")\; 10. Visualizzare un messaggio di avvertenza di dati mancanti, nei #glossary("pannelli"), nel caso di assenza di dati da mostrare. ],"S",[ UC0\ UC4\ UC4.1\ UC4.2\ UC4.3\ UC4.4\ UC4.5\ UC4.6\ UC4.7\ UC9 ]), ([ Verificare che l'#glossary("amministratore pubblico"), una volta avviata l'applicazione, possa: 1. Visualizzare una notifica che denoti il superamento dei 40° Celsius (°C); 2. Visualizzare una notifica che denoti il superamento dei 50 millimetri di pioggia all'ora (50 mm/h); 3. Visualizzare una notifica relativa all'inquinamento dell'aria (#glossary("PM10")) che denoti il superamento di 80#[#sym.mu]g su metro cubo ($ 80#sym.mu g\/m^3$); 4. Visualizzare una notifica che denoti il superamento del 70% della capienza di un bacino; 5. Visualizzare una notifica che denoti il superamento dell'80% della capienza di una zona ecologica. ],"S",[ UC5\ UC5.1\ UC5.2\ UC5.3\ UC5.4\ UC5.5\ UC5.6 ]), ([ Verificare che l'#glossary("amministratore pubblico"), una volta entrato nell'applicazione, possa: 1. Scegliere una #glossary("dashboard") da visualizzare; 2. Applicare dei filtri, per visualizzare solo i dati provenienti dal sottoinsieme di sensori selezionato, nel caso di #glossary("pannelli") di tipo #glossary("serie storica")\; 3. Applicare dei filtri, per visualizzare solo i dati provenienti dai sensori delle tipologie selezionate, nel caso di #glossary("pannelli") contenenti tabelle, le quali comprendono più tipologie di sensori al loro interno; 4. Applicare dei filtri, per selezionare solo particolari sensori, mediante il nome, nel caso di #glossary("pannelli") contenenti tabelle; 5. Applicare dei filtri, per selezionare solo i dati relativi ad un definito intervallo di tempo, all'interno di un'intera #glossary("dashboard")\; ],"S",[ UC0\ UC6\ UC6.1\ UC6.2\ UC6.3\ UC6.4\ ]), ([ Verificare che l'#glossary("amministratore pubblico"), una volta entrato nell'applicazione, possa: 1. Scegliere una tabella da ordinare; 2. Ordinare le righe di tale tabella secondo uno dei suoi campi. ],"S",[ UC7 ]), ([ Verificare che l'#glossary("amministratore pubblico"), una volta entrato nell'applicazione, possa: 1. Scegliere una #glossary("dashboard") di cui modificare il layout; 2. Modificare il layout dei #glossary("pannelli") in termini di posizione di tali #glossary("pannelli") e della loro dimensione. ],"N/I",[ UC8\ UC8.1\ UC8.2 ]), ([ Verificare che un #glossary("sensore"), una volta connesso al sistema, possa: 1. Inserire il risultato della rilevazione della temperatura, espressa in gradi Celsius (°C), con annesso il #glossary("timestamp") di rilevazione e le proprie coordinate geografiche. ],"S",[ U10 ]), ([ Verificare che un #glossary("sensore"), una volta connesso al sistema, possa: 1. Inserire il risultato della rilevazione dell'umidità, espressa in percentuale, con annesso il #glossary("timestamp") di rilevazione e le proprie coordinate geografiche. ],"S",[ U11 ]), ([ Verificare che un #glossary("sensore"), una volta connesso al sistema, possa: 1. Inserire il risultato della rilevazione della direzione e della velocità del vento, espresse rispettivamente in gradi (con gli 0° a Est e i 180° a Ovest) e in chilometri orari (km/h), con annesso il #glossary("timestamp") di rilevazione e le proprie coordinate geografiche. ],"S",[ U12 ]), ([ Verificare che un #glossary("sensore"), una volta connesso al sistema, possa: 1. Inserire il risultato della rilevazione della quantità di precipitazioni, espressa in millimetri all'ora (mm/h), con annesso il #glossary("timestamp") di rilevazione e le proprie coordinate geografiche. ],"S",[ U13 ]), ([ Verificare che un #glossary("sensore"), una volta connesso al sistema, possa: 1. Inserire il risultato della rilevazione dell'inquinamento dell'aria (#glossary("PM10")), espresso in $#sym.mu g\/m^3$, con annesso il #glossary("timestamp") di rilevazione e le proprie coordinate geografiche. ],"S",[ U14 ]), ([ Verificare che un #glossary("sensore"), una volta connesso al sistema, possa: 1. Inserire il risultato della rilevazione del livello di riempimento del bacino idrico presso cui è installato, espressa in percentuale, con annesso il #glossary("timestamp") di rilevazione e le proprie coordinate geografiche. ],"S",[ U15 ]), ([ Verificare che un #glossary("sensore"), una volta connesso al sistema, possa: 1. Inserire il risultato della rilevazione del numero di auto presenti all'interno del parcheggio controllato e del numero di posti auto totali a disposizione, con annesso il #glossary("timestamp") di rilevazione e le proprie coordinate geografiche. ],"S",[ U16 ]), ([ Verificare che un #glossary("sensore"), una volta connesso al sistema, possa: 1. Inserire il risultato della rilevazione della disponibilità della colonna di ricarica e della quantità di energia erogata, espressa in chilowatt all'ora (kWh), con annesso il #glossary("timestamp") di rilevazione e le proprie coordinate geografiche. ],"S",[ U17 ]), ([ Verificare che un #glossary("sensore"), una volta connesso al sistema, possa: 1. Inserire il risultato della rilevazione della percentuale di batteria della bicicletta a cui è associato e le relative coordinate geografiche, con annesso il #glossary("timestamp") di rilevazione. ],"S",[ U18 ]), ([ Verificare che un #glossary("sensore"), una volta connesso al sistema, possa: 1. Inserire il risultato della rilevazione del livello di riempimento della zona ecologica presso cui è installato, espressa in percentuale, con annesso il #glossary("timestamp") di rilevazione e le proprie coordinate geografiche. ],"S",[ U19 ]), ([ Verificare che un #glossary("sensore"), una volta connesso al sistema, possa: 1. Inserire il risultato della rilevazione del numero di auto circolanti nella strada controllata, dello stato della congestione stradale, espresso nei seguenti stati (ordinati per ordine di congestione crescente) "LOW", "MEDIUM", "HIGH", "BLOCKED" e del tempo medio necessario per percorrere la strada, con annesso il #glossary("timestamp") di rilevazione e le proprie coordinate geografiche. ],"S",[ U20 ]), ).enumerate(start:1).map(test => ("TA"+ str(test.at(0)),test.at(1).at(0),test.at(1).at(1),test.at(1).at(2))); #show figure: set block(breakable: true) #figure( table( columns: (2fr,7fr,1fr), align: (center,left,center), fill:(_,row) =>if row==0 {luma(150)} else if calc.odd(row) { luma(220)} else {white}, [*Codice test*],[*Descrizione*],[*Stato*], ..test_di_accettazione.map(item => (item.at(0),item.at(1),item.at(2))).flatten().map(item => [#item]) ),caption: "Test di accettazione.") === Tracciamento dei test di accettazione #show figure: set block(breakable: true) #figure( table( columns: (80pt,80pt), align: (center,center), fill:(_,row) =>if row==0 {luma(150)} else if calc.odd(row) { luma(220)} else {white}, [*Codice test*],[*Codice caso d'uso*], ..test_di_accettazione.map(item => (item.at(0),item.at(3))).flatten().map(item => [#item]) ),caption: "Tracciamento dei test di accettazione.") == Test di sistema #let test_di_sistema = ( ([ Verificare che l'#glossary("amministratore pubblico") possa accedere all'applicazione senza dover effettuare l'autenticazione. ],"S","ROF"), ([ Verificare che l'#glossary("amministratore pubblico") possa visualizzare un menù di selezione delle #glossary[dashboard], che permetta di selezionare una #glossary("dashboard") Dati grezzi, Ambientale, Urbanistica e Superamento soglie. ],"S","ROF"), ([ Verificare che l'#glossary("amministratore pubblico") possa visualizzare una #glossary("dashboard") dedicata a fornire una panoramica generale dei dati grezzi. ],"S","ROF"), ([ Verificare che l'#glossary("amministratore pubblico") possa visualizzare, in forma tabellare, i dati grezzi inviati da tutti i sensori con il nome del #glossary[sensore], la tipologia del #glossary[sensore], il timestamp della rilevazione e il valore della misurazione (nel caso in cui la misurazione sia composta da più dati, tutti i valori devono essere elencati ed etichettati opportunamente all'interno della stessa entrata nella colonna corrispondente), all'interno della #glossary("dashboard") relativa ai dati grezzi. ],"S","ROF"), ([ Verificare che l'#glossary("amministratore pubblico") possa monitorare i dati provenienti dai sensori relativi ai dati ambientali in una #glossary("dashboard") apposita. ],"S","ROF"), ([ Verificare che l'#glossary("amministratore pubblico") possa visualizzare un #glossary("pannello") contenente un grafico in formato #glossary("time series") rappresentante la media aritmetica della temperatura, espressa in gradi Celsius (°C), per ciascun #glossary("sensore"), che aggreghi i dati per intervalli di 1 minuto, nella #glossary("dashboard") relativa ai dati ambientali. ],"S","ROF"), ([ Verificare che l'#glossary("amministratore pubblico") possa visualizzare un #glossary("pannello") contenente un grafico in formato #glossary("time series") rappresentante la media aritmetica della temperatura, espressa in gradi Celsius (°C), per tutti i sensori, che aggreghi i dati per intervalli di 5 minuti, nella #glossary("dashboard") relativa ai dati ambientali. ],"S","ROF"), ([ Verificare che l'#glossary("amministratore pubblico") possa visualizzare un #glossary("pannello") contenente un grafico in formato #glossary("time series") rappresentante la media aritmetica dell'umidità, espressa in percentuale, per ciascun #glossary("sensore"), che aggreghi i dati per intervalli di 1 minuto, nella #glossary("dashboard") relativa ai dati ambientali. ],"S","ROF"), ([ Verificare che l'#glossary("amministratore pubblico") possa visualizzare un #glossary("pannello") contenente un grafico in formato #glossary("time series") rappresentante la media aritmetica dell'umidità, espressa in percentuale, per tutti i sensori, che aggreghi i dati per intervalli di 5 minuti, nella #glossary("dashboard") relativa ai dati ambientali. ],"S","ROF"), ([ Verificare che l'#glossary("amministratore pubblico") possa visualizzare un #glossary("pannello") contenente una mappa che evidenzi la direzione del vento, mediante frecce aventi origine nelle coordinate del #glossary("sensore"), nella #glossary("dashboard") relativa ai dati ambientali. ],"S","RDF"), ([ Verificare che l'#glossary("amministratore pubblico") possa visualizzare un #glossary("pannello") contenente una tabella la quale riporta l'ultima velocità del vento, espressa in chilometri all'ora (km/h), per ciascun #glossary("sensore"), nella #glossary("dashboard") relativa ai dati ambientali. ],"S","ROF"), ([ Verificare che l'#glossary("amministratore pubblico") possa visualizzare un #glossary("pannello") contenente un grafico in formato #glossary("time series") rappresentante la media aritmetica dell'intensità delle precipitazioni, espresse in millimetri all'ora (mm/h), per ciascun #glossary("sensore"), che aggreghi i dati per intervalli di 1 minuto, nella #glossary("dashboard") relativa ai dati ambientali. ],"S","ROF"), ([ Verificare che l'#glossary("amministratore pubblico") possa visualizzare un #glossary("pannello") contenente un grafico in formato #glossary("time series") rappresentante la media aritmetica dell'intensità delle precipitazioni, espresse in millimetri all'ora (mm/h), per tutti i sensori, che aggreghi i dati per intervalli di 5 minuti, nella #glossary("dashboard") relativa ai dati ambientali. ],"S","ROF"), ([ Verificare che l'#glossary("amministratore pubblico") possa visualizzare un #glossary("pannello") contenente un indice numerico, che esprime l'intensità media delle precipitazioni, espressa in millimetri all'ora (mm/h), nell'intervallo di tempo impostato all'interno della #glossary[dashboard], facendo la media dei dati raccolti tra tutti i sensori, nella #glossary("dashboard") relativa ai dati ambientali. ],"S","RDF"), ([ Verificare che l'#glossary("amministratore pubblico") possa visualizzare un #glossary("pannello") contenente un grafico in formato #glossary("time series") rappresentante la media aritmetica del livello di polveri sottili nell'aria (#glossary("PM10")), espressa in $#sym.mu g\/m^3$, per ciascun #glossary("sensore"), aggregando i dati per intervalli di 1 minuto, nella #glossary("dashboard") relativa ai dati ambientali. ],"S","ROF"), ([ Verificare che l'#glossary("amministratore pubblico") possa visualizzare un #glossary("pannello") contenente un grafico in formato #glossary("time series") rappresentante la media aritmetica del livello di polveri sottili nell'aria (#glossary("PM10")), espressa in $#sym.mu g\/m^3$, per tutti i sensori, aggregando i dati per intervalli di 5 minuti, nella #glossary("dashboard") relativa ai dati ambientali. ],"S","ROF"), ([ Verificare che l'#glossary("amministratore pubblico") possa visualizzare un #glossary("pannello") contenente un indice numerico, che esprime l'inquinamento dell'aria medio (#glossary("PM10")), espresso in $#sym.mu g\/m^3$, nell'ultimo minuto, facendo la media dei dati raccolti tra tutti i sensori, nella #glossary("dashboard") relativa ai dati ambientali. ],"S","RDF"), ([ Verificare che l'#glossary("amministratore pubblico") possa visualizzare un #glossary("pannello") contenente un grafico in formato #glossary("time series") rappresentante la percentuale di riempimento dei bacini idrici, per ciascun #glossary("sensore"), aggregando i dati per intervalli di 1 minuto, nella #glossary("dashboard") relativa ai dati ambientali. ],"S","ROF"), ([ Verificare che l'#glossary("amministratore pubblico") possa visualizzare un #glossary("pannello") contenente un grafico in formato #glossary("time series") rappresentante la percentuale di riempimento dei bacini idrici, per tutti i sensori, aggregando i dati per intervalli di 5 minuti, nella #glossary("dashboard") relativa ai dati ambientali. ],"S","ROF"), ([ Verificare che l'#glossary("amministratore pubblico") possa visualizzare un #glossary("pannello") contenente un indice numerico, che esprime la temperatura media, espressa in gradi Celsius (°C), nell'intervallo di tempo impostato all'interno della #glossary[dashboard], facendo la media dei dati raccolti tra tutti i sensori, nella #glossary("dashboard") relativa ai dati ambientali. ],"S","RDF"), ([ Verificare che l'#glossary("amministratore pubblico") possa visualizzare un #glossary("pannello") contenente un indice numerico, che esprime l'inquinamento dell'aria massimo (#glossary("PM10")), espresso in $#sym.mu g\/m^3$, negli ultimi 5 minuti, tra i dati registrati da tutti i sensori, nella #glossary("dashboard") relativa ai dati ambientali. ],"S","RDF"), ([ Verificare che l'#glossary("amministratore pubblico") possa visualizzare un #glossary("pannello") contenente una mappa che mostri le posizioni dei sensori che monitorano i dati ambientali, mediante icone colorate in base al tipo di #glossary[sensore], nella #glossary("dashboard") relativa ai dati ambientali. ],"S","ROF"), ([ Verificare che l'#glossary("amministratore pubblico") possa monitorare i dati provenienti dai sensori relativi ai dati urbanistici in una #glossary("dashboard") apposita. ],"S","ROF"), ([ Verificare che l'#glossary("amministratore pubblico") possa visualizzare un #glossary("pannello") contenente una mappa che evidenzi il numero di posti liberi nei vari parcheggi, mediante indicatori numerici posti nelle coordinate del #glossary("sensore"), nella #glossary("dashboard") relativa ai dati urbanistici. ],"S","ROF"), ([ Verificare che l'#glossary("amministratore pubblico") possa visualizzare un #glossary("pannello") contenente una mappa che evidenzi la posizione delle colonne di ricarica per auto, mediante icone poste nelle coordinate dei sensori che ne indicano la disponibilità, nella #glossary("dashboard") relativa ai dati urbanistici. ],"S","ROF"), ([ Verificare che l'#glossary("amministratore pubblico") possa visualizzare un #glossary("pannello") contenente una tabella che riporti l'erogazione delle colonne di ricarica, espressa in Watt all'ora, nella #glossary("dashboard") relativa ai dati urbanistici. ],"S","RDF"), ([ Verificare che l'#glossary("amministratore pubblico") possa visualizzare un #glossary("pannello") contenente una mappa che evidenzi lo stato di congestione delle strade, mediante gli stati "LOW", "MEDIUM", "HIGH", "BLOCKED", presso le coordinate dei sensori che hanno effettuato la rilevazione, nella #glossary("dashboard") relativa ai dati urbanistici. ],"S","ROF"), ([ Verificare che l'#glossary("amministratore pubblico") possa visualizzare un #glossary("pannello") contenente una mappa che mostri, in tempo reale, la posizione delle biciclette elettriche, mediante degli indicatori numerici, indicanti la percentuale della batteria, nella #glossary("dashboard") relativa ai dati urbanistici. ],"S","ROF"), ([ Verificare che l'#glossary("amministratore pubblico") possa visualizzare un #glossary("pannello") contenente una mappa che mostri la percentuale di riempimento delle zone ecologiche, mediante degli indicatori percentuali, posizionati nelle coordinate della zona, nella #glossary("dashboard") relativa ai dati urbanistici. ],"S","ROF"), ([ Verificare che l'#glossary("amministratore pubblico") possa visualizzare una #glossary("dashboard") dedicata a monitorare i dati superanti delle soglie. ],"S","RDF"), ([ Verificare che l'#glossary("amministratore pubblico") possa visualizzare un #glossary("pannello") contenente una tabella che mostri i #glossary("dati anomali"), il #glossary("sensore") che li ha rilevati e il #glossary("timestamp") del rilevamento, nella #glossary("dashboard") relativa al superamento delle soglie. ],"S","RPF"), ([ Verificare che l'#glossary("amministratore pubblico") possa visualizzare un #glossary("pannello") contenente una tabella che mostri i dati relativi alla temperatura i cui valori superano la soglia dei 40° Celsius (40°C), il #glossary("sensore") che li ha rilevati e il #glossary("timestamp") del rilevamento, nella #glossary("dashboard") relativa ai dati superanti le soglie. ],"S","RDF"), ([ Verificare che l'#glossary("amministratore pubblico") possa visualizzare un #glossary("pannello") contenente una tabella che mostri i dati relativi alle precipitazioni i cui valori superano la soglia dei 50 millimetri di pioggia all'ora (50 mm/h), il #glossary("sensore") che li ha rilevati e il #glossary("timestamp") del rilevamento, nella #glossary("dashboard") relativa ai dati superanti le soglie. ],"S","RDF"), ([ Verificare che l'#glossary("amministratore pubblico") possa visualizzare un #glossary("pannello") contenente una tabella che mostri i dati relativi al livello di polveri sottili nell'aria (#glossary[PM10]) i cui valori superano la soglia di 80#[#sym.mu]g su metro cubo ($80#sym.mu g\/m^3$), il #glossary("sensore") che li ha rilevati e il #glossary("timestamp") del rilevamento, nella #glossary("dashboard") relativa ai dati superanti le soglie. ],"S","RDF"), ([ Verificare che l'#glossary("amministratore pubblico") possa visualizzare un #glossary("pannello") contenente una tabella che mostri i dati relativi ai bacini idrici i cui valori superano la soglia del 70% di capienza, il #glossary("sensore") che li ha rilevati e il #glossary("timestamp") del rilevamento, nella #glossary("dashboard") relativa ai dati superanti le soglie. ],"S","RDF"), ([ Verificare che l'#glossary("amministratore pubblico") possa visualizzare un #glossary("pannello") contenente una tabella che mostri i dati relativi alle zone ecologiche i cui valori superano la soglia dell'80% di capienza, il #glossary("sensore") che li ha rilevati e il #glossary("timestamp") del rilevamento, nella #glossary("dashboard") relativa ai dati superanti le soglie. ],"S","RDF"), ([ Verificare che l'#glossary("amministratore pubblico") possa visualizzare delle notifiche che denotano il superamento di una soglia impostata. ],"S","RDF"), ([ Verificare che l'#glossary("amministratore pubblico") possa visualizzare delle notifiche riguardo a rilevazioni di tipo temperatura, superanti una soglia di 40° Celsius (°C). ],"S","RDF"), ([ Verificare che l'#glossary("amministratore pubblico") possa visualizzare delle notifiche riguardo rilevazioni di tipo precipitazioni, superanti una soglia di 50 millimetri all'ora (50 mm/h). ],"S","RDF"), ([ Verificare che l'#glossary("amministratore pubblico") possa visualizzare delle notifiche riguardo rilevazioni dell' inquinamento dell'aria (#glossary("PM10")), superanti una soglia di 80 microgrammi su metro cubo ($80#sym.mu g\/m^3$). ],"S","RDF"), ([ Verificare che l'#glossary("amministratore pubblico") possa visualizzare delle notifiche riguardo rilevazioni del livello di riempimento dei bacini idrici, superanti una soglia corrispondente al 70% della capienza del bacino idrico corrispondente. ],"S","RDF"), ([ Verificare che l'#glossary("amministratore pubblico") possa visualizzare delle notifiche riguardo rilevazioni del livello di riempimento delle zone ecologiche, superanti una soglia corrispondente all'80% della capienza della zona corrispondente. ],"S","RDF"), ([ Verificare che l'#glossary("amministratore pubblico") possa filtrare i dati, visualizzati all'interno di un grafico di tipo #glossary("time series"), in base ad un sottoinsieme di sensori da lui selezionato. ],"S","ROF"), ([ Verificare che che l'#glossary("amministratore pubblico") possa filtrare i dati, visualizzati all'interno di una tabella, in base alla tipologia di #glossary("sensore"). ],"S","ROF"), ([ Verificare che l'#glossary("amministratore pubblico") possa filtrare i dati, visualizzati all'interno di una tabella, in base ad un sotto-insieme di sensori, selezionando i nomi dei sensori di interesse. ],"S","ROF"), ([ Verificare che l'#glossary("amministratore pubblico") possa filtrare i dati in base ad un intervallo temporale. Di conseguenza la #glossary("dashboard") interessata deve, nella sua totalità, mostrare solamente i dati aventi un #glossary("timestamp") in tale intervallo. ],"S","ROF"), ([ Verificare che l'#glossary("amministratore pubblico"), nei #glossary("pannelli") tabellari, possa ordinare i dati in base a tutti i campi presenti, sia in ordine crescente che decrescente. ],"S","RDF"), ([ Verificare che l'#glossary("amministratore pubblico"), riceva un messaggio di errore qualora, il sistema di visualizzazione non riesca a reperire i dati necessari per un determinato #glossary("pannello"). ],"S","ROF"), /*da qui iniziano i requisiti relativi ai sensori*/ ([ Verificare che un #glossary("sensore") possa inserire nel sistema le rilevazioni della temperatura, espresse in gradi Celsius (°C), effettuate dal #glossary("sensore"), con annesso coordinate e #glossary("timestamp") della rilevazione. ],"S","ROF"), ([ Verificare che un #glossary("sensore") possa inserire nel sistema le rilevazioni all'umidità, espresse in percentuale, effettuate dal #glossary("sensore"), con annesso coordinate e #glossary("timestamp") della rilevazione. ],"S","ROF"), ([ Verificare che un #glossary("sensore") possa inserire nel sistema le rilevazioni della velocità e della direzione del vento, espresse rispettivamente in chilometri all'ora (km/h) e in gradi (con gli 0° a Est e i 180° a Ovest), effettuate dal #glossary("sensore"), con annesso coordinate e #glossary("timestamp") della rilevazione. ],"S","ROF"), ([ Verificare che un #glossary("sensore") possa inserire nel sistema le rilevazioni della quantità di precipitazioni, espresse in millimetri orari (mm/h), con annesso coordinate e #glossary("timestamp") della rilevazione. ],"S","ROF"), ([ Verificare che un #glossary("sensore") possa inserire nel sistema le rilevazioni dell'inquinamento (#glossary("PM10")), espresse in microgrammi al metro cubo ($#sym.mu g\/m^3$), effettuate dal #glossary("sensore"), con annesso coordinate e #glossary("timestamp") della rilevazione. ],"S","ROF"), ([ Verificare che un #glossary("sensore") possa inserire nel sistema le rilevazioni del livello di riempimento del bacino idrico presso cui è installato, espresse in percentuale, effettuate dal #glossary("sensore"), con annesso coordinate e #glossary("timestamp") della rilevazione. ],"S","ROF"), ([ Verificare che un #glossary("sensore") possa inserire nel sistema le rilevazioni del numero di auto presenti all'interno del parcheggio controllato e del numero di posti auto totali a disposizione, effettuate dal #glossary("sensore"), con annesso coordinate e #glossary("timestamp") della rilevazione. ],"S","ROF"), ([ Verificare che un #glossary("sensore") possa inserire nel sistema le rilevazioni della disponibilità della colonna di ricarica controllata e della potenza di erogazione, espressa in chilowatt all'ora (kWh), effettuate dal #glossary("sensore"), con annesso coordinate e #glossary("timestamp") della rilevazione. ],"S","ROF"), ([ Verificare che un #glossary("sensore") possa inserire nel sistema le rilevazioni delle coordinate geografiche e della percentuale di batteria della bicicletta elettrica controllata, effettuate dal #glossary("sensore"), con annesso il #glossary("timestamp") della rilevazione. ],"S","ROF"), ([ Verificare che un #glossary("sensore") possa inserire nel sistema le rilevazioni del livello di riempimento della zona ecologica presso cui è installato, espresse in percentuale, effettuate dal #glossary("sensore"), con annesso coordinate e #glossary("timestamp") della rilevazione. ],"S","ROF"), ([ Verificare che un #glossary("sensore") possa inserire nel sistema le rilevazioni del numero di auto circolanti nella strada controllata, dello stato della congestione stradale nella strada, espresso in stati (in ordine di crescente congestione sono: "LOW", "MEDIUM", "HIGH", "BLOCKED") del tempo medio necessario per percorrere la strada, effettuate dal #glossary("sensore"), con annesso coordinate e #glossary("timestamp") della misurazione. ],"S","ROF"), ([ Verificare che sia stato implementato almeno un simulatore almeno una tipologia di #glossary("sensore"). ],"S","ROF"), ([ Verificare che i dati prodotti dalle simulazioni siano realistici. ],"S","ROF"), ([ Verificare che il sistema possa rilevare eventuali relazioni tra sorgenti di dati diverse. ],"N/I","RPF"), ([ Verificare che il sistema possa effettuare previsioni di eventi futuri, sulla base di dati storici e attuali. ],"N/I","RPF"), ).enumerate(start:1).map(test => ("TS"+ str(test.at(0)),test.at(1).at(0),test.at(1).at(1),test.at(1).at(2))).enumerate(start:1).map(test => (test.at(1).at(0),test.at(1).at(1),test.at(1).at(2),test.at(1).at(3) + str(test.at(0)))); #show figure: set block(breakable: true) #figure( table( columns: (2fr,7fr,1fr), align: (center,left,center), fill:(_,row) =>if row==0 {luma(150)} else if calc.odd(row) { luma(220)} else {white}, [*Codice test*],[*Descrizione*],[*Stato*], ..test_di_sistema.map(item => (item.at(0),item.at(1),item.at(2))).flatten().map(item => [#item]) ),caption: "Test di sistema.") === Tracciamento dei test di sistema #show figure: set block(breakable: true) #figure( table( columns: (80pt,80pt), align: (center,center), fill:(_,row) =>if row==0 {luma(150)} else if calc.odd(row) { luma(220)} else {white}, [*Codice test*],[*Codice Requisito*], ..test_di_sistema.map(item => (item.at(0),item.at(3))).flatten().map(item => [#item]) ),caption: "Tracciamento dei test di sistema.") == Test di integrazione In questa sezione vengono descritti i test di integrazione del prodotto software. #let test_di_integrazione = ( ([ Verificare che i dati generati dal sensore di inquinamento atmosferico siano correttamente memorizzati nel database. ],"S",[]), ([ Verificare che i dati generati dal sensore di inquinamento atmosferico siano correttamente aggregati per intervalli di 1 minuto e memorizzati nel database. ],"S",[]), ([ Verificare se i dati della media aritmetica generata dal sensore di inquinamento atmosferico siano correttamente inseriti nel database. ],"S",[ ]), ([ Verificare che i dati generati dal sensore delle colonne di ricarica siano correttamente memorizzati nel database. ],"S",[]), ([ Verificare che i dati generati dal sensore delle biciclette elettriche siano correttamente memorizzati nel database. ],"S",[]), ([ Verificare che i dati generati dal sensore di riempimento delle zone ecologiche siano correttamente memorizzati nel database. ],"S",[]), ([ Verificare che i dati generati dal sensore di umidità siano correttamente memorizzati nel database. ],"S",[]), ([ Verificare che i dati generati dal sensore di umidità siano correttamente aggregati per intervalli di 1 minuto e memorizzati nel database. ],"S",[]), ([ Verificare se i dati della media aritmetica generati dal sensore di umidità siano correttamente inseriti nel database. ],"S",[ ]), ([ Verificare che i dati generati dal sensore dei parcheggi siano correttamente memorizzati nel database. ],"S",[]), ([ Verificare che i dati generati dal sensore di precipitazioni atmosferiche siano correttamente memorizzati nel database. ],"S",[]), ([ Verificare che i dati generati dal sensore di precipitazioni atmosferiche siano correttamente aggregati per intervalli di 1 minuto e memorizzati nel database. ],"S",[]), ([ Verificare se i dati della media aritmetica generati dal sensore di precipitazioni atmosferiche siano correttamente inseriti nel database. ],"S",[ ]), ([ Verificare che i dati generati dal sensore del livello di riempimento dei bacini idrici siano correttamente memorizzati nel database. ],"S",[]), ([ Verificare che i dati generati dal sensore del livello di riempimento dei bacini idrici siano correttamente aggregati per intervalli di 1 minuto e memorizzati nel database. ],"S",[]), ([ Verificare se i dati della media aritmetica generati dal sensore del livello di riempimento dei bacini idrici siano correttamente inseriti nel database. ],"S",[ ]), ([ Verificare che i dati generati dal sensore di temperatura siano correttamente memorizzati nel database. ],"S",[]), ([ Verificare che i dati generati dal sensore di temperatura siano correttamente aggregati per intervalli di 1 minuto e memorizzati nel database. ],"S",[]), ([ Verificare se i dati della media aritmetica generati dal sensore di temperatura siano correttamente inseriti nel database. ],"S",[ ]), ([ Verificare che i dati generati dal sensore del traffico siano correttamente memorizzati nel database. ],"S",[]), ([ Verificare che i dati generati dal sensore del vento siano correttamente memorizzati nel database. ],"S",[]) ).enumerate(start:1).map(test => ("TI"+ str(test.at(0)),test.at(1).at(0),test.at(1).at(1),test.at(1).at(2))); #show figure: set block(breakable: true) #figure( table( columns: (2fr,7fr,1fr), align: (center,left,center), fill:(_,row) =>if row==0 {luma(150)} else if calc.odd(row) { luma(220)} else {white}, [*Codice test*],[*Descrizione*],[*Stato*], ..test_di_integrazione.map(item => (item.at(0),item.at(1),item.at(2))).flatten().map(item => [#item]) ),caption: "Test di integrazione.") == Test di unità In questa sezione vengono descritti i test di unità del prodotto software. #let test_di_unità =( ([ Verificare che il metodo `produce()` della classe `AdapterProducer` si comporti come atteso sia in situazioni in cui il producer di #glossary[Kafka] funziona senza problemi, sia in caso di errori. ], "S", [ ]), ([ Verificare che la classe `KafkaSimulatorExecutorFactory` sia in grado di creare correttamente un'istanza di `SimulatorExecutor` utilizzando una configurazione data. ],"S",[]), ([ Verificare che il metodo `write()` della classe `KafkaWriter` chiami correttamente il metodo `produce()` del suo oggetto `TargetProducer` con il messaggio appropriato e la funzione di conferma acked. ], "S",[ ]), ([ Verificare che il metodo `run_all()` della classe `SimulatorExecutor` avvii correttamente tutti i simulatori associati ad esso. ],"S",[ ]), ([ Verificare che il metodo `stop_all()` della classe `SimulatorExecutor` fermi correttamente tutti i simulatori associati ad esso. ],"S",[ ]), ([ Verificare che il metodo `run()` della classe `SimulatorThread` chiami correttamente il metodo `simulate()` del simulatore di sensore. ],"S",[ ]), ([ Verificare che il metodo `run()` della classe `SimulatorThread` chiami correttamente il metodo `write()` del writer durante l'esecuzione del thread. ],"S",[ ]), ([ Verificare che il metodo `write()` della classe `StdoutWriter` scriva correttamente un messaggio sullo standard output. ],"S",[ ]), ([ Verificare che la classe `StdoutSimulatorExecutorFactory` sia in grado di creare correttamente un'istanza di `SimulatorExecutor`. ],"S",[ ]), ([ Verificare il comportamento della funzione `acked()` del modulo `utility_functions`, verificando che stampi correttamente i messaggi di errore sullo standard output. ],"S",[ ]), ([ Verificare che il sensore delle colonne di ricarica fornisca i dati attesi nel formato prestabilito. ],"S",[ ]), ([ Verificare che i dati sulla potenza erogata dalle colonne di ricarica simulate rimangano all'interno di un intervallo specifico (0-100). ],"S",[ ]), ([ Verificare la correttezza del recupero delle coordinate della destinazione del sensore di biciclette elettriche. ],"S",[ ]), ([ Verificare la correttezza del recupero delle coordinate del percorso delle biciclette elettriche simulate. ],"S",[ ]), ([ Verificare che il sensore delle biciclette elettriche fornisca i dati attesi nel formato prestabilito. ],"S",[ ]), ([ Verificare che il livello di batteria del sensore delle biciclette elettriche rimanga all'interno di un intervallo specifico (0-100). ],"S",[ ]), ([ Verificare che il sensore delle zone ecologiche fornisca i dati attesi nel formato prestabilito. ],"S",[ ]), ([ Verificare che il livello di riempimento del sensore delle zone ecologiche rimanga all'interno di un intervallo specifico (0-100). ],"S",[ ]), ([ Verificare che il sensore di umidità fornisca i dati attesi nel formato prestabilito. ],"S",[ ]), ([ Verificare che la percentuale generata dal sensore di umidità rimanga all'interno di un intervallo specifico (5-100). ],"S",[ ]), ([ Verificare che il sensore delle precipitazioni atmosferiche fornisca i dati attesi nel formato prestabilito. ],"S",[ ]), ([ Verificare che l'intensità di pioggia generata dal sensore delle precipitazioni atmosferiche rimanga all'interno di un intervallo specifico (0-100). ],"S",[ ]), ([ Verificare che il sensore dei bacini idrici fornisca i dati attesi nel formato prestabilito. ],"S",[ ]), ([ Verificare che la percentuale generata dal sensore dei bacini idrici rimanga all'interno di un intervallo specifico (0-100). ],"S",[ ]), ([ Verificare che il sensore della temperatura fornisca i dati attesi nel formato prestabilito. ],"S",[ ]), ([ Verificare che il valore generato dal sensore della temperatura rimanga all'interno di un intervallo specifico (3-19). ],"S",[ ]), ([ Verificare che il sensore del vento fornisca i dati attesi nel formato prestabilito. ],"S",[ ]), ([ Verificare che il valore generato dal sensore del vento rimanga all'interno di un intervallo specifico (1-9). ],"S",[ ]), ([ Verificare che il sensore dell'inquinamento atmosferico fornisca i dati attesi nel formato prestabilito. ],"S",[]), ([ Verificare che il valore generato dal sensore dell'inquinamento atmosferico rimanga all'interno di un intervallo specifico (0-100). ],"S",[ ]), ([ Verificare che il sensore della congestione stradale fornisca i dati attesi nel formato prestabilito. ],"S",[ ]), ([ Verificare che i livelli di traffico generati siano tra quelli previsti (LOW, MEDIUM, HIGH, BLOCKED). ],"S",[ ]), ([ Verificare che il sensore dei parcheggi fornisca i dati attesi nel formato prestabilito. ],"S",[ ]) ).enumerate(start:1).map(test => ("TU"+ str(test.at(0)),test.at(1).at(0),test.at(1).at(1),test.at(1).at(2))); #show figure: set block(breakable: true) #figure( table( columns: (2fr,7fr,1fr), align: (center,left,center), fill:(_,row) =>if row==0 {luma(150)} else if calc.odd(row) { luma(220)} else {white}, [*Codice test*],[*Descrizione*],[*Stato*], ..test_di_unità.map(item => (item.at(0),item.at(1),item.at(2))).flatten().map(item => [#item]) ),caption: "Test di unità.") #pagebreak() == Liste di controllo Le liste di controllo sono uno strumento che il Verificatore può utilizzare al fine di individuare errori ricorrenti nella #glossary[documentazione] o nel codice. Tali liste prevedono anche una descrizione del problema al fine di poter fornire una spiegazione della richiesta di cambiamenti durante la fase di revisione. Le liste di controllo possono essere aggiornate durante tutto il corso del progetto dal Verificatore, man mano che vengono notati errori ricorrenti. === Struttura dei documenti #figure( table( columns: (1fr, 2fr), inset: 10pt, align: (center, left), [*Aspetto*],[*Spiegazione*], [Vuoti documentativi],[Non devono essere presenti sezioni senza contenuto.], [Didascalia assente],[Tutte le tabelle e le immagini devono avere una didascalia descrittiva.], [Ripetizione di elementi ricorrenti],[Ogni elemento che viene usato più di una volta, soprattutto se si sa a priori che verrà usato più volte, deve essere creato da una funzione #glossary("Typst").], [Ordine non alfabetico],[I nomi dei componenti devono essere riportati in ordine alfabetico, in qualsiasi documento dove compaiono come elenco non numerato.], [Aggiornamento fantasma],[Ad ogni insieme di modifiche ai documenti che devono essere aggiunte assieme, deve corrispondere una riga nella tabella del changelog, con un univoco numero di versione.], [Titolo principale],[Tutti i titoli principali devono iniziare la pagina nella quale vengono inseriti.], ), caption: [Lista di controllo per la struttura dei documenti.] ) #pagebreak() === Errori ortografici, di lingua italiana e di forma #figure( table( columns: (1fr, 2fr), inset: 10pt, align: (center, left), [*Aspetto*],[*Spiegazione*], [Errori di sintassi],[Gli errori di sintassi (battitura o distrazione) devono essere rimossi.], [Errori di coniugazione],[Gli errori di coniugazione devono essere rimossi.], [Forma verbale],[Il presente indicativo è da preferire.], [Forma non concisa],[Le espressioni troppo verbose, ove possibile, devono essere ridotte a forme più concise.], [Non formalità],[Le espressioni non formali devono essere sostituite con le corrispondenti espressioni formali.], [Richiamo errato al documento],[Ogni richiamo ai documenti, in una loro particolare versione, deve seguire la seguente forma: _NomeDocumento vVersioneMajor.VersioneMinor_ (e.g. _Piano di Progetto v1.0_).], [Termini impropriamente in maiuscolo],[I termini di glossario non godono della proprietà di avere la prima lettera maiuscola, rispetto alle parole tradizionali. Seguono le stesse regole delle parole non di glossario in quanto alla forma (ovviamente non riguardo allo stile).], [Acronimi non in maiuscolo],[Gli acronimi devono essere completamente in maiuscolo (e.g. #glossary[ITS] - acronimo per Issue Tracking System).], ), caption: [Lista di controllo per gli errori ortografici, di lingua italiana e di forma.] ) #pagebreak() === Non conformità con le _Norme di Progetto_ #figure( table( columns: (1fr, 2fr), inset: 10pt, align: (center, left), [*Aspetto*],[*Spiegazione*], [Formato date errato],[Il formato delle date deve essere *dd-mm-aaaa* all'interno dei documenti, oppure *aa-mm-dd* all'interno dei nomi dei documenti.], [Punteggiatura scorretta negli elenchi],[Ogni elemento di un elenco, numerato o non, deve terminare con un "*;*", ad eccezione dell'ultima riga, la quale deve terminare con "*.*".], ["*:*" in grassetto negli elenchi],[Gli elenchi nella forma "*termine*: testo", non devono includere il ":" nel grassetto.], [Maiuscole nei titoli],[La prima lettera di ogni titolo deve essere maiuscola. Il resto del titolo dovrebbe essere in minuscolo (tolte particolari eccezioni, come ad esempio nomi di documenti o lettere che compaiono all'interno di acronimi).], [Maiuscole negli elenchi],[Le prime lettere di ogni elenco devono essere maiuscole.], [Ruoli in minuscolo],[Tutti i ruoli del progetto devono avere la prima lettera in maiuscolo.], [Termine non presente nel glossario],[Ogni termine segnato con la formattazione da glossario deve essere effettivamente presente nel glossario con la relativa descrizione.], ), caption: [Lista di controllo per le non conformità con le _Norme di Progetto_.] ) #pagebreak() === _Analisi dei Requisiti_ #figure( table( columns: (1fr, 2fr), inset: 10pt, align: (center, left), [*Aspetto*],[*Spiegazione*], [Tracciamento caso d'uso - requisito],[Per ciascun caso d'uso deve corrispondere almeno un requisito.], [Struttura errata dei requisiti],[I requisiti devono essere scritti nella forma: "\<soggetto\> deve/devono \<verbo all'infinito\>"], [Numerazione errata dei casi d'uso],[La numerazione dei casi d'uso deve seguire la crescita dei numeri interi naturali. Se si tratta di un sotto-caso d'uso, il sotto-caso deve ereditare, come prefisso del proprio codice, il codice del caso d'uso a cui appartiene, e ne aggiunge una cifra. Fare riferimento alle _Norme di Progetto v2.0_ per una descrizione più approfondita.], [#glossary[UML] dei casi d'uso],[Le estensioni e le inclusioni di un caso d'uso vanno nello stesso diagramma #glossary[UML] del caso d'uso stesso.], ), caption: [Lista di controllo per l’_Analisi dei Requisiti_.] ) #pagebreak() = Cruscotto della qualità == Qualità di processo - fornitura === Estimate At Completion #figure( image("./assets/valutazione-metriche/EAC.png", width: 85%), caption: [ Valutazione Estimate At Completion. ], ) *#glossary[RTB]* L'EAC rappresenta una revisione del valore stimato per la realizzazione del progetto, ossia il BAC (Budget At Completion) rivisto allo stato corrente del progetto; il fattore che incide maggiormente sull'andamento dell'EAC è il rapporto tra EV (Earned Value) e AC (Actual Cost), per cui tanto più queste metriche sono vicine l'una all'altra, tanto più l'EAC risulterà vicino al BAC pianificato inizialmente. Concluso il secondo #glossary[sprint], il team ha rilevato che il valore associato all'EAC non rientrava all'interno della soglia accettabile: ci si è dunque attivati al fine di rimodulare la quantità di lavoro netta associata al concetto di ora produttiva. Dal grafico si può rilevare che la curva delineata dal valore dell'EAC, pur essendo rimasta sempre al di sopra del valore di accettazione, ha, già a partire dal secondo #glossary[sprint] e dunque a seguito dell'azione correttiva intrapresa, mostrato un trend decrescente; il team si aspettava che nel corso degli #glossary[sprint] successivi l'andamento avrebbe continuato la sua discesa fino a che i valori fossero rientrati nella fascia accettabile. Nelle ultime rilevazioni effettuate, la metrica ha comunque continuato la sua discesa, senza però raggiungere la soglia accettabile: la misurazione della metrica è stata di certo inflazionata dalle attività previste per gli ultimi #glossary[sprint]. Il team si è occupato infatti di ultimare tutta la #glossary[documentazione] necessaria alla revisione #glossary("RTB") e ciò ha fatto impennare i costi, causa il costo orario più elevato dei ruoli attivi (specie dell'Amministratore). Questo risultato, nonostante la correlazione causale individuata, suggerisce ugualmente che qualcosa nel progetto non è stato gestito al meglio: la forte attenzione posta sulla #glossary[documentazione] nell'ultimo #glossary[sprint] è una manifestazione del tentativo del team di rincorrere gli obiettivi di una pianificazione poco rigorosa. Ne deriva che il team, in vista della seconda revisione, dovrà impegnarsi a migliorare il processo relativo alla gestione di progetto, in modo da poter essere sempre sicuri che gli obiettivi fissati siano effettivamente raggiunti nei termini dettati dalla pianificazione. *#glossary[PB]* L'analisi del grafico rivela un trend interessante nell'EAC a partire dal nono #glossary[sprint]. Durante tale #glossary[sprint], infatti, l'EAC mostra una leggera tendenza al rialzo, che si intensifica fino al suo picco nel decimo #glossary[sprint]. Questo aumento è attribuibile alla decisione del team di prendere una breve pausa, motivata dalla necessità di affrontare la sessione degli esami e partecipare ai colloqui previsti dalla prima revisione #glossary[RTB]. La pausa, sebbene necessaria, ha inevitabilmente influenzato il ritmo e la produttività del team negli #glossary[sprint] immediatamente successivi all'#glossary[RTB], causando un rallentamento nelle attività del progetto e un aumento dei costi associati alla gestione delle risorse durante questo periodo. In altre parole, questa interruzione temporanea ha comportato un leggero incremento nei costi previsti per il completamento del progetto, evidenziato dall'aumento dell'EAC; dato che il team ha utilizzato meno risorse negli #glossary[sprint] 9 e 10, l'EV è risultato considerevolmente più basso rispetto all'AC, il che ha portato l'EAC a crescere e a discostarsi dal BAC pianificato inizialmente. Tuttavia, è interessante notare che nonostante questo rialzo nell'EAC fino al decimo #glossary[sprint], il suo valore è diminuito in modo ripido nel corso degli #glossary[sprint] successivi fino a raggiungere il valore ottimale verso la fine dell'ultimo #glossary[sprint] previsto. Questa tendenza al ribasso può essere attribuita alla ripresa del ritmo di lavoro, all'ottimizzazione delle risorse e alla migliore gestione delle attività del progetto da parte del team. Infatti, il numero delle ore produttive effettivamente impiegate dal team è mediamente raddoppiato rispetto a quelle che hanno caratterizzato gli #glossary[sprint] 9 e 10, segno indiscutibile del fatto che il team ha avuto successo nell'aumentare il valore del lavoro svolto e, di conseguenza, nell'avvicinare l'EV all'AC, facendo sì che L'EAC diminuisse fino a raggiungere il BAC. In definitiva, sebbene la pausa abbia temporaneamente influenzato i costi previsti per il completamento del progetto, il team è riuscito a recuperare il terreno perso, riducendo l'EAC e portando il progetto verso il raggiungimento dei suoi obiettivi entro la fine degli #glossary[sprint] previsti prima della seconda revisione #glossary[PB]. #pagebreak() === Budget Variance e Schedule Variance #figure( image("./assets/valutazione-metriche/BV_SV.png", width: 85%), caption: [ Valutazione Budget Variance e Schedule Variance. ], ) *#glossary[RTB]* La metrica BV indica se alla data corrente si è speso di più o di meno rispetto a quanto inizialmente previsto nel budget; la metrica SV indica se si è in linea, in anticipo o in ritardo rispetto alla schedulazione delle attività di progetto pianificate. Nonostante inizialmente le due metriche si stessero allontanando rapidamente dal valore di accettazione, a partire dal secondo #glossary[sprint] queste sembrano stabilizzarsi, segno che le azioni correttive adottate all'epoca hanno prodotto gli effetti desiderati quasi immediatamente. Il cambiamento più significativo si è verificato durante il quinto #glossary[sprint], in occasione del quale è stata osservata un'inversione di tendenza: entrambe le metriche hanno iniziato a riavvicinarsi al valore desiderato. Il team si aspetta che il #glossary[way of working] consolidato nel corso del progetto permetta di recuperare quanto perso nel corso dei primi #glossary[sprint]. Durante il settimo e l'ottavo #glossary[sprint] le due metriche hanno mantenuto il gradiente che ci si aspettava. *#glossary[PB]* La metrica SV ha continuato a decrescere fino a raggiungere lo 0% circa (0.18% con esattezza) al termine dello #glossary[sprint] 13. Il raggiungimento di questo traguardo per l'SV è un segnale positivo che indica un'efficace gestione del tempo e delle risorse all'interno del progetto. Si può affermare che il team sia riuscito a lavorare in modo efficiente e a mantenere il progetto in linea con la pianificazione prevista. Il continuo miglioramento della SV nel corso degli #glossary[sprint] dimostra un impegno costante; è interessante notare come, rispetto all'andamento della SV negli #glossary[sprint] antecedenti all'#glossary[RTB], che è risultato essere piuttosto altalenante, questa si sia stabilizzata nel suo andamento linearmente decrescente nel corso del periodo antecedente alla #glossary[PB]. Evidentemente il team è riuscito nel suo intento di effettuare una pianificazione più realistica e di aderirvi rigorosamente, con un ritmo di lavoro pressochè invariato negli ultimi #glossary[sprint]. Per quanto riguarda la Budget Variance (BV), si nota un significativo cambiamento di tendenza tra gli #glossary[sprint] 9 e 10. Durante questo intervallo, la linea subisce un calo negativo, evidenziando una discrepanza tra il budget pianificato e le spese effettive. Come affermato precedentemente, questo decremento è principalmente attribuibile al ritmo di lavoro poco sostenuto che ha caratterizzato i primi due #glossary[sprint] successivi alla pausa programmata. Tuttavia, dallo #glossary[sprint] 11 in poi, la linea che descrive la BV inizia a risalire rapidamente, indicando un miglioramento nella gestione delle spese e una riduzione della discrepanza tra il budget previsto e quello effettivo. Alla fine del periodo considerato, la metrica BV raggiunge il -0.56%, un valore ben al di sotto della soglia di accettazione costituita dalla variazione del ±10% dal BAC. #pagebreak() === Actual Cost e Estimate To Complete #figure( image("./assets/valutazione-metriche/AC_ETC.png", width: 85%), caption: [ Valutazione Actual Cost e Estimate To Complete. ], ) *#glossary[RTB]* L'AC rappresenta il costo effettivo sostenuto fino a un dato momento, mentre l'ETC rappresenta la stima del costo aggiuntivo necessario per completare il progetto; di conseguenza, ci si aspetta che l'AC cresca e che l'ETC diminuisca in modo sostanzialmente lineare, segno che il progetto sta mantenendo un ritmo regolare di avanzamento. Il grafico mostra che effettivamente il team ha mantenuto un ritmo di avanzamento pressoché costante durante tutto il periodo che precede la revisione #glossary[RTB], il che è apprezzabile: nonostante la sessione d'esame il team ha continuato a occuparsi con impegno delle attività di progetto, per quanto possibile. Tuttavia, si può evincere anche che il progetto risulta essere leggermente in ritardo rispetto alle tempistiche inizialmente previste. Considerando che gli otto #glossary[sprint] effettuati corrispondono ad un periodo temporale di 10 settimane, esattamente la metà del periodo di tempo previsto per il completamento dell'intero progetto, ci si aspettava che le due metriche delineate nel grafico si fossero già incrociate giunti a questo punto. *#glossary[PB]* Dal grafico si può notare come l'AC sia continuato a salire fino a fermarsi poco al di sotto dell'EAC. Questo indica che i costi effettivamente sostenuti sono stati inferiori alle stime previste per completare il progetto, il che suggerisce un'efficace gestione dei costi. Bisogna sottolineare, inoltre, che, come illustrato nell'ultimo consuntivo all'interno del _Piano di Progetto v2.0_, il team si è ritrovato ad avere a disposizione un budget leggermente più ampio rispetto a quanto preventivato per lo svolgimento del progetto sino alla #glossary[PB] a causa della rinuncia alla #glossary[CA]\; il team ha dunque portato a termine gli obiettivi del periodo pre-#glossary[PB] disponendo ancora di alcune risorse inutilizzate, per quanto limitate. Inoltre, l'ETC è continuato a diminuire nel corso degli #glossary[sprint], indicando una riduzione progressiva nella stima dei costi necessari per completare il progetto. #pagebreak() === Earned Value e Planned Value #figure( image("./assets/valutazione-metriche/EV_PV.png", width: 85%), caption: [ Valutazione Earned Value e Planned Value. ], ) *#glossary[RTB]* L'EV rappresenta il valore prodotto dal progetto ossia il valore dei #glossary[deliverable] rilasciati fino al momento della misurazione in seguito alle attività svolte; il PV rappresenta invece il valore del lavoro pianificato fino a un dato momento. Nonostante sia ancora prematuro confrontare le due metriche con l'EAC, si può notare che il PV si mantiene al di sotto dell'EV, seppur di poco, segno che i preventivi fatti finora sono stati leggermente ottimistici rispetto alla spesa effettiva. Si può notare come le due metriche a partire dal sesto #glossary[sprint] tendano ad avvicinarsi: ciò denota che il team sta iniziando effettivamente a produrre dei preventivi di periodo che rispecchiano maggiormente la realtà effettiva, anche per come viene fotografata nei consuntivi di periodo. *#glossary[PB]* Durante lo sviluppo del progetto, le metriche EV e PV hanno mostrato un costante avvicinamento, quasi fino a coincidere intorno allo #glossary[sprint] 12. Questo progressivo avvicinamento suggerisce che i preventivi pianificati sono diventati sempre più precisi man mano che il progetto è avanzato. Il fatto che queste due metriche si siano avvicinate sempre di più suggerisce che le previsioni iniziali sono state riviste e adattate in modo accurato sulla base dell'andamento effettivo del progetto. Ciò indica anche una maggiore solidità nella pianificazione e una migliore comprensione dei requisiti e delle risorse necessarie per il completamento del progetto. Inoltre, il quasi coincidere delle due metriche intorno allo #glossary[sprint] 12 indica che il progetto è stato eseguito in modo conforme alle previsioni e che la gestione del progetto è stata efficace nel monitorare e mantenere il progresso in linea con il piano stabilito. // == Qualità di Processo - Codifica TODO: non ha senso in questa fase del progetto #pagebreak() == Qualità di processo - documentazione === Indice Gulpease #figure( image("./assets/valutazione-metriche/IG.png", width: 85%), caption: [ Valutazione Indice Gulpease. ], ) *#glossary[RTB]* Al termine del secondo #glossary[sprint], tutti i documenti in corso di preparazione in vista della revisione #glossary("RTB") possiedono un IG al di sopra del limite accettabile inferiore di 60; in particolare, l'_Analisi dei Requisiti_ ha raggiunto il valore ideale. Si rileva che nel corso dell'ultimo #glossary[sprint] tutti i documenti hanno subito un abbassamento del loro indice di leggibilità, perciò nel corso del periodo che precede la seconda revisione #glossary[PB] il team dovrà impegnarsi ad utilizzare una scrittura più semplice. *#glossary[PB]* Tutti i documenti hanno il valore di IG al di sopra del limite accettabile. Si nota che il documento _Piano di Qualifica_ ha subito una notevole diminuzione dell'indice, dovuta principalmente all'utilizzo di parole più lunghe e frasi più complesse. Il documento _Analisi Dei Requisiti_, da grafico, ha l'indice più elevato tra tutti i documenti. Durante lo #glossary[sprint] 10, si può notare un significativo aumento dell'IG, infatti il documento è stato arricchito con correzioni suggerite dal Professore Cardin e con ulteriori dettagli nei casi d'uso e nei requisiti. Tuttavia, negli ultimi due #glossary[sprint] finali si è verificato un nuovo calo dell'Indice Gulpease, suggerendo possibili variazioni nella complessità del testo. #pagebreak() === Correttezza Ortografica #figure( image("./assets/valutazione-metriche/CO.png", width: 85%), caption: [ Valutazione Correttezza Ortografica. ], ) *#glossary[RTB]* A seguito dei primi due #glossary[sprint] sono stati rilevati parecchi errori ortografici, per far fronte ai quali si è scelto di adottare uno strumento di controllo dell'ortografia sia in fase di stesura che in fase di revisione della #glossary[documentazione]. Tuttavia, nonostante l'uso di questo strumento, si è notato che il processo di #glossary[documentazione] continua ad essere afflitto da errori ortografici. Questo indica che il problema non è tanto la mancanza di strumenti adeguati, quanto più un approccio disattento da parte del team durante la redazione dei documenti, e nel processo di verifica che ne consegue. Fare in modo che non vi siano errori nei documenti prima della revisione #glossary("RTB") rimane comunque un obiettivo di qualità che il team vuole raggiungere. Per ovviare al problema il team ha deciso di introdurre una checklist incentrata sugli errori ortografici, in modo tale che i responsabili del processo di verifica possano avvalersene nel correggere eventuali errori. Questa checklist è pensata non solo come uno strumento pratico, ma principalmente come un promemoria costante per il Verificatore. Tale strumento ha mostrato immediatamente i suoi effetti benefici: gli errori nel corso dell'ottavo #glossary[sprint] sono calati a zero. *#glossary[PB]* Nella revisione dei documenti _Specifica Tecnica v1.0_ e _Manuale Utente v1.0_, è emerso un certo numero di errori grammaticali e formali. Questa situazione è stata principalmente causata dal fatto che il team ha inizialmente concentrato i propri sforzi principalmente sulla revisione del codice e sui test, posticipando temporaneamente la revisione approfondita dei documenti citati. D'altra parte, gli altri documenti non presentano errori grammaticali evidenti, suggerendo un'efficace applicazione delle checklist di controllo e dei vari strumenti di revisione. #pagebreak() == Qualità di processo - codifica Nella seguente tabella si mostrano il numero di infrazioni delle metriche prese in esame riguardanti la qualità del processo di codifica. /*da vedere se lasciare la tabella o mettere il grafico*/ /* #figure( table( columns:(auto,auto,auto), align: (x, y) => (center, center, center).at(x), fill:(_,row) => if row==0 {luma(150)} else if calc.odd(row) { luma(220)} else {white}, [*Metrica*],[*Valore*],[*Valore accettazione*], [*MPC-ATC*], [2], [≤ 6], [*MPC-PM*], [0], [≤ 5], [*MPC-LCM*], [0], [≤ 25] ), caption: [Metriche della codifica per lo sprint 12.])*/ #figure( image("./assets/valutazione-metriche/ATC_PM_LCM.png", width: 85%), caption: [ Valutazione Metriche Codifica, in particolare il numero delle violazioni riscontrate. ], ) Nell'ambito delle metriche di codifica, si sono verificate esclusivamente due infrazioni della metrica ATC (Attributi per Classe), le quali sono state risolte nel corso del penultimo #glossary[sprint]. È importante sottolineare che, al termine dell'ultimo #glossary[sprint], gli attributi di classe, i parametri per metodo (PM) e il numero di righe per funzione (LCM) sono tutti conformi ai limiti accettabili. #pagebreak() == Qualità di processo - gestione della qualità === Metriche Non Soddisfatte #figure( image("./assets/valutazione-metriche/MNS.png", width: 85%), caption: [ Valutazione Metriche Non Soddisfatte. ], ) *#glossary[RTB]* Le Metriche Non Soddisfatte corrispondono alle metriche MPC-CO, MPC-CPI, MPC-EAC. In concomitanza con l'ottavo #glossary("sprint"), la misurazione di MPC-CO è rientrata all'interno del valore di accettazione. Per quanto riguarda MPC-CPI e MPC-EAC, essendo estremamente legate tra loro, si rimanda alle considerazioni relative a MPC-EAC. *#glossary[PB]* Verso il termine dello #glossary[sprint] 12, la metrica CPI si è collocata entro il suo intervallo accettabile, determinando di conseguenza un posizionamento adeguato anche per la metrica EAC. Tuttavia, le MNS sono rimaste due perché le metriche riconducibili ai requisiti obbligatori soddisfatti e all'ATC (ovvero il numero di attributi per classe), valutate a partire dal dodicesimo #glossary[sprint], sono risultate essere non soddisfatte. Al termine dello #glossary[sprint] 13 si è risolta la violazione della metrica CO (Correttezza Ortografica), portando il numero di MNS a uno. Infine, a partire dallo #glossary[sprint] 14, tutte le metriche hanno raggiunto i valori desiderati e il numero di MNS è calato a 0. // == Qualità di prodotto #pagebreak() == Qualità di prodotto === Funzionalità #figure( image("./assets/valutazione-metriche/ROS.png", width: 85%), caption: [ Valutazione requisiti obbligatori, desiderabili e opzionali. ], ) Dall'analisi del grafico emerge che tutti i requisiti obbligatori sono stati soddisfatti nel corso dello #glossary[sprint] 13. Inoltre, si è registrato un notevole progresso anche per quanto riguarda i requisiti desiderabili, con una percentuale finale di soddisfacimento pari al 92%. Tuttavia, risulta evidente che i requisiti opzionali sono stati realizzati solo parzialmente, raggiungendo il 33% della loro totalità. === Manutenibilità #figure( table( columns:(auto,auto), align: (x, y) => (center, center, center).at(x), fill:(_,row) => if row==0 {luma(150)} else if calc.odd(row) { luma(220)} else {white}, [*Metrica*],[*Valore*], [*MPC-SFIN*], [12], [*MPC-SFOUT*], [1] ), caption: [Massimo e minimo delle metriche SFIN e SFOUT]) SFIN rappresenta il numero di moduli o componenti direttamente collegati o dipendenti da un modulo o una funzione specifica. SFOUT rappresenta il numero di dipendenze o connessioni che un componente o modulo particolare ha con altri componenti o moduli. Misura quanti altri elementi dipendono o interagiscono con un dato elemento all'interno di un #glossary[sistema]. L'analisi dei valori numerici evidenzia che il valore massimo dell'SFIN si attesta a 12, indicando che un modulo o componente specifico ha 12 altre parti del sistema che dipendono direttamente da esso. Il valore minimo di SFOUT è 1, suggerendo che almeno un modulo ha solo una dipendenza o connessione con un altro modulo o componente all'interno del sistema. Questo potrebbe indicare una minore interdipendenza tra alcuni moduli, sebbene altri moduli possano avere un numero maggiore di connessioni. #pagebreak() === Usabilità #figure( image("./assets/valutazione-metriche/FU.png", width: 85%), caption: [ Valutazione facilità di utilizzo. ], ) Durante il corso degli #glossary[sprint], il numero massimo di click necessari per accedere a tutte le funzionalità del prodotto è rimasto costante a cinque. Questo rappresenta il valore ideale, confermando l'efficacia dell'interfaccia utente nel garantire un accesso rapido e diretto alle varie funzionalità del prodotto. #figure( table( columns:(auto,auto,auto), align: (x, y) => (center, center, center).at(x), fill:(_,row) => if row==0 {luma(150)} else if calc.odd(row) { luma(220)} else {white}, [*Metrica*],[*Valore*],[*Valore accettazione*], [*MPC-TA*], [8min], [10 min] ), caption: [Tempo di apprendimento del prodotto]) /*#figure( image("./assets/valutazione-metriche/TA.png", width: 85%), caption: [ Valutazione tempo di apprendimento. ], )*/ Per valutare la complessità del prodotto, si è proceduto a condurre un test sul tempo di apprendimento (TA), affidandolo a un individuo esterno al progetto. I risultati hanno evidenziato che il tempo medio necessario per comprendere e familiarizzare con il prodotto è stato di circa 8 minuti. Questo dato fornisce un'indicazione preziosa sulla facilità di apprendimento del sistema o del servizio in questione, suggerendo che il processo di acquisizione delle competenze necessarie è relativamente agevole. #pagebreak() === Affidabilità #figure( image("./assets/valutazione-metriche/SC_BC.png", width: 85%), caption: [ Valutazione metriche statement e branch coverage. ], ) Nel grafico, osserviamo che lo statement coverage (SC) rimane costantemente elevato intorno al 93%, mentre il branch coverage (BC), sebbene sia sceso dal 83% all'81%, si mantiene comunque sopra l'80%, che rappresenta il minimo accettabile per una valutazione positiva della copertura del codice. Il fatto che entrambe le metriche siano superiori all'80% indica che il codice è soggetto a un buon livello di copertura dai test. Una copertura dello statement così elevata suggerisce che la maggior parte del codice è stata eseguita durante i test, mentre un branch coverage superiore all'80% indica che la maggior parte dei rami decisionali del codice è stata attraversata dai test. In conclusione, nonostante una leggera diminuzione nel branch coverage, entrambe le metriche rimangono ben al di sopra del minimo richiesto per una valutazione positiva della copertura del codice. Questo suggerisce che il codice è soggetto ad un livello adeguato di testing e che la sua qualità complessiva è solida e affidabile. #figure( image("./assets/valutazione-metriche/PTCP.png", width: 85%), caption: [ Valutazione metrica passed test. ], ) Tutti i test prodotti sono stati superati con successo, senza alcun test fallito. Questo conferma ulteriormente la solidità del codice e l'efficacia dei test eseguiti. === Efficienza Le metriche di efficienza sono state calcolate utilizzando un elaboratore con le seguenti caratteristiche: - 16 GB RAM LPDDR5; - CPU M1 PRO 10 Core 3.2GHz. È stato valutato il rendimento del #glossary[sistema] a pieno carico, con più di quaranta simulatori di sensori attivi, ognuno generante una scrittura al secondo, per più di sei ore, senza che si verificassero rallentamenti significativi. I risultati sono rimasti invariati durante il corso del progetto, dato che le componenti sono rimaste le stesse e sono in grado di gestire una mole di dati molto superiore a quella richiesta per il progetto. #figure( table( columns:(auto,auto,auto), align: (x, y) => (center, center, center,center).at(x), fill:(_,row) => if row==0 {luma(150)} else if calc.odd(row) { luma(220)} else {white}, [*Metrica*],[*Valore Medio Rilevato*],[*Valore accettazione*], [MPD-CPUU],[\~12%],[\≤ 20%], [MPD-RAMU],[~ 2,7 GB],[\≤ 3GB], [MPD-TDE],[\~ 3s], [\≤ 6s], ), caption: [Tabella delle metriche di efficienza a massimo carico]) == Considerazioni finali in vista della revisione #glossary[RTB] Il team ha tentato fin da subito di adottare un #glossary[way of working] che consentisse di rispettare gli obiettivi e le scadenze impostate all'inizio dello svolgimento del progetto, ma ci si è presto resi conto che quest'ultimo sarebbe dovuto essere gradualmente ampliato e raffinato con il passare del tempo; infatti, nonostante il #glossary[way of working] sia progressivamente migliorato con l'avanzare del progetto, alcune aree necessitano di essere meglio definite o migliorate affinché la qualità di processo si rifletta positivamente sulla qualità di prodotto. Volendo ripercorrere brevemente la progressione del modo di lavorare del team, si possono riportare alcune considerazioni sulle difficoltà incontrate inizialmente e su come si sia tentato di superarle. In generale, il team non ha avuto difficoltà nel fissare incontri interni settimanali per discutere dell'avanzamento del progetto a cui tutti i componenti partecipassero attivamente; tuttavia, per una buona parte del periodo antecedente la prima revisione #glossary[RTB] (sostanzialmente fino allo #glossary[sprint] 5 incluso), gli incontri hanno avuto una durata eccessiva, ossia oltre le 1,5 ore. Dunque, il team ha cominciato a stilare un #glossary[ordine del giorno] nel corso dello #glossary[sprint] in modo da poter strutturare meglio gli incontri e limitarne la durata. Nonostante questa lista abbia un contenuto piuttosto variabile, si può migliorare la sua applicazione prestabilendo quanto tempo si dovrebbe dedicare a ciascun punto di discussione nel corso dell'incontro, cosa che il team ha intenzione di fare dopo la prima revisione per renderli più efficienti. Si nota che gli incontri si protraggono ancora per più di quanto previsto, il che in parte è dovuto al fatto che si investe del tempo per assistere gli Amministratori nella creazione delle issue e assegnazione dei relativi campi. Tuttavia il fenomeno va riducendosi, segno che il team sta imparando a svolgere queste attività in modo più efficiente. Si è menzionato il processo di creazione e assegnazione delle issue: fortunatamente tale processo è stato messo a punto e applicato in modo consistente fin dal principio, ma si può migliorare la sua applicazione per agevolare ulteriormente la creazione del preventivo che precede ogni #glossary[sprint] e la pianificazione a breve termine. In particolare, come spiegato nelle _Norme di Progetto v1.0_, ad ogni issue viene assegnata una dimensione (in base alle ore produttive che si stima siano necessarie per il suo completamento) e una priorità, pensate per aiutare il team a dimensionare gli #glossary[sprint] e a gestire la catena di dipendenze tra le varie issue in modo corretto; tuttavia, il fatto di conoscere (e aggiornare in corso d'opera se necessario) la dimensione di tutte le issue previste per un determinato #glossary[sprint] e, di conseguenza, la dimensione dello #glossary[sprint] stesso non è stato preso in considerazione nella creazione del preventivo rilevante. Non c'è dubbio sul fatto che creare un preventivo "informato" da questo genere di stima sia più efficace che crearne uno inserendo ore non vincolate in alcun modo, solo in base alle esigenze del momento. Allo stesso modo il team si era prefissato di esplicitare sempre le date di inizio e fine di ogni singola issue, in modo da agevolare la pianificazione; anche in questo caso l'idea iniziale non è stata applicata in modo soddisfacente, perciò è risultato difficile eseguire una pianificazione dettagliata di ogni #glossary[sprint], che consistesse anche di un diagramma di Gantt. In futuro, dunque, il team ha intenzione di sfruttare queste procedure in modo concreto per migliorare le attività di creazione di pianificazione e preventivo di ogni #glossary[sprint]. Sarebbe utile dunque monitorare la dimensione di ogni #glossary[sprint] come viene descritta sopra tramite una metrica apposita da inserire tra quelle di gestione dei processi; idealmente si avrebbe anche una metrica che misura il tasso di completamento delle attività per ogni #glossary[sprint], così da potersi regolare nella pianificazione di quelli futuri. Quest'ultima non è stata utilizzata perché nel momento in cui il team ha cominciato ad utilizzare le metriche scelte in modo appropriato, si è reso conto di non possedere una traccia delle issue aperte e chiuse al termine di ogni #glossary[sprint]\; attualmente, nel momento in cui si hanno delle issue ancora aperte alla fine dello #glossary[sprint] corrente, queste vengono "trasportate" allo #glossary[sprint] successivo assegnandole alla #glossary[milestone] appena creata. In futuro, sarebbe bene fare uno "screenshot" dello stato della Kanban board al termine dello #glossary[sprint] in modo da poter calcolare questa metrica aggiuntiva prima di riadattarla allo #glossary[sprint] in procinto di iniziare. L'applicazione di una routine più rigorosa per quanto riguarda l'aggiornamento del _Piano di Progetto_ e del _Piano di Qualifica_ con i dati rilevanti è di importanza vitale, soprattutto dopo la revisione #glossary[RTB] quando ci saranno documenti aggiuntivi che richiederanno attenzione; pianificazione, preventivo, consuntivo e metriche dovranno essere aggiornati in modo metodico e rigoroso in modo da essere sfruttati come strumenti utili ed evitare problemi come l'impiego di più ore produttive in un determinato ruolo (Amministratore, ad esempio) di quante non ce ne siano effettivamente a disposizione (anche questo da considerare nella creazione dei preventivi appunto, assieme alla dimensione dello #glossary[sprint]). In quanto alla rendicontazione delle ore produttive effettivamente utilizzate dai membri del team nel corso di ciascuno #glossary[sprint], lo #glossary[spreadsheet] "Time & Resource Manager" su Google Drive si è rivelato estremamente utile (se aggiornato tempestivamente da tutti i membri senza ritardo); tuttavia, l'utilizzo delle ore produttive preventivate ed effettive riportate nel _Piano di Progetto v1.0_ per calcolare la percentuale di lavoro preventivato e svolto nell'ottica di PV ed EV è ancora un punto di discussione all'interno del team; infatti, come descritto dal grafico, L'EAC è ancora al di sopra del limite di accettazione superiore nonostante l'andamento decrescente. Questo è in un certo senso in linea con l'utilizzo che il team ha fatto del BAC, utilizzando più ore da Amministratore (tra le più costose, tra l'altro) del previsto, ma è anche un prodotto del modo in cui il team ha scelto di calcolare la percentuale di lavoro menzionata sopra; non essendoci altre alternative valide per eseguire il calcolo, con ogni probabilità il team continuerà ad adottare l'approccio delineato, utilizzando però le ore in modo più consapevole rispetto a quanto già speso per fare in modo che l'EAC continui ad avere un andamento decrescente. La comunicazione all'interno del team è stata stabile fin dall'inizio del progetto e non ha subito grosse variazioni se non durante il periodo coincidente con la sessione di esami invernale e poco oltre (lo stesso vale per la comunicazione esterna con la Proponente); tuttavia, il team dovrebbe imparare a gestire meglio (e quindi stabilire una procedura per) le situazioni in cui uno o più documenti necessitano di una revisione o di modifiche critiche da effettuare con urgenza (senza dover necessariamente attendere il termine dello #glossary[sprint] corrente) tramite discussioni dedicate su Discord o meeting di emergenza. Tali misure sono state predisposte recentemente visto l'andamento del progetto nel corso della sessione, ma non sempre utilizzate quando necessario. Complessivamente, il #glossary[way of working] del team è migliorato notevolmente dall'inizio del progetto, in particolare grazie a tutti gli strumenti, le procedure e le automazioni descritte nelle _Norme di Progetto v 1.0_ e alle misure di prevenzione dei rischi descritte nel _Piano di Progetto v1.0_, ma ciò non significa che sia privo di imperfezioni e che non possa essere migliorato ulteriormente in seguito alla revisione #glossary[RTB]. #pagebreak() == Considerazioni finali in vista della revisione #glossary[PB] Rispetto al #glossary[way of working] che ha caratterizzato lo svolgimento del progetto da parte del team sino alla prima revisione #glossary[RTB], il periodo antecedente la seconda revisione #glossary[PB] ha visto dei miglioramenti gradualmente apportati al modo di lavorare ma, al contempo, anche l'emergere di nuove difficoltà, alcune delle quali non previste. Per quanto riguarda la comunicazione interna, il team è effettivamente riuscito nell'intento di ridurre la durata degli incontri interni settimanali; questo grazie non solo ad un utilizzo più consapevole dell'#glossary[ordine del giorno] e alla maggior esperienza degli Amministratori nel creare e assegnare le issue previste in modo opportuno, ma anche grazie allo svolgimento di #glossary[stand-up meeting] da remoto ogni due giorni. Infatti, l'adozione di questa pratica ha portato ad un miglioramento significativo della comunicazione e della coordinazione tra i componenti del team, che sono stati in grado di portare a termine determinate task spesso in tempi più brevi del previsto. Eventuali decisioni prese nel corso degli #glossary[stand-up meeting] sono comunque state riportate all'interno del verbale steso in occasione dell'incontro settimanale previsto, come sempre, a fine #glossary[sprint]. Le attività di creazione di pianificazione e preventivo di ogni #glossary[sprint] sono di fatto state agevolate da alcune pratiche adottate dal team dopo l'#glossary[RTB], ovvero la stesura di verbali con un'attenzione maggiore al tracciamento di decisioni e relativi compiti assegnati e l'approccio utilizzato per determinare le risorse da impiegare per ogni #glossary[sprint]. Infatti, se prima dell'#glossary[RTB] il Responsabile determinava le risorse da preventivare in base alle esigenze del momento e alla disponibilità dei membri del team, in vista della #glossary[PB] si è deciso di valutare attentamente tutti gli obiettivi da soddisfare per completare il progetto procedendo retroattivamente a partire dalla data di consegna prevista; la definizione di obiettivi chiari e la volontà di utilizzare tutte le risorse a disposizione (specie dopo aver deciso di non sostenere la #glossary[CA]) hanno fornito al Responsabile una linea guida per stabilire le risorse appropriate di volta in volta e hanno spinto il team a lavorare con maggiore intensità, specie dallo #glossary[sprint] 11 in poi, come evidenziato dal _Piano di Progetto v2.0_. La maggior attenzione alle risorse nella creazione dei preventivi ha anche consentito al team di evitare di ripetere l'errore commesso in passato, ovvero l'utilizzo di più ore da Amministratore di quante non fossero disponibili. Il ritmo di lavoro sostenuto di all'incirca 10 ore produttive settimanali per membro si è dimostrato arduo da implementare efficaciemente in un primo momento, ma è divenuto via via più sostenibile grazie anche alla creazione di issue più piccole e facilmente gestibili, che hanno consentito una distribuzione più equa del carico di lavoro con una rotazione più rapida dei ruoli. Infatti, se in precedenza il team si era ritrovato più volte "bloccato" in una situazione in cui erano state aperte delle issue sostanzialemente troppo grandi e, di conseguenza, il componente incaricato era stato costretto ad assumere il ruolo rilevante per più #glossary[sprint] consecutivamente fino alla chiusura di quest'ultima, ciò non si è più verificato dopo l'#glossary[RTB]. Il modo in cui sono stati designati i ruoli di Progettista e Programmatore è stato di importanza cruciale per portare a termine lo sviluppo del #glossary[MVP] in modo rapido; anche la scelta di ruotare i Verificatori il più spesso possibile ha beneficiato il processo di verifica, facendo in modo che le responsabilità dei membri che erano soliti verificare il codice e, di contro, la #glossary[documentazione] fossero invertite. Il fatto che, immediatamente prima della #glossary[PB], tutte le metriche che monitorano la qualità di processo e di prodotto siano soddisfatte indica che il prodotto realizzato soddisfa le aspettative di qualità prestabilite in tutte le sue parti; le metriche utilizzate per monitorare l'affidabilità del software tramite i test di unità e integrazione (Branch Coverage e Statement Coverage) sono risultate particolarmente utili nel guidare il team allo sviluppo di test di qualità. Infatti, una delle difficoltà riscontrate e superate dal team è stata proprio la creazione dei test adatti al prototipo di prodotto richiesto dalla Proponente, visto che questo richiedeva relativamente poco sviluppo. In questo senso le metriche hanno fornito un aiuto sostanziale nel determinare l'approccio corretto al testing dei simulatori e di come le varie componenti infrastrutturali della pipeline comunicassero tra loro. Nel complesso, il #glossary[way of working] del team è decisamente migliorato rispetto al periodo pre-#glossary[RTB]; il focus dedicato alla progettazione, descritta nella _Specifica Tecnica v1.0_, e allo sviluppo del #glossary[MVP] ha consentito al team di portare a termine il progetto senza particolari intoppi, mantenendo un ritmo di lavoro regolare fino all'ultimo #glossary[sprint].
https://github.com/polarkac/MTG-Stories
https://raw.githubusercontent.com/polarkac/MTG-Stories/master/stories/001%20-%20Magic%202013/004_Krenko%2C%20Mob%20Boss.typ
typst
#import "@local/mtgstory:0.2.0": conf #show: doc => conf( "Krenko, Mob Boss", set_name: "Magic 2013", story_date: datetime(day: 18, month: 07, year: 2012), author: "<NAME>", doc ) #figure(image("004_Krenko, Mob Boss/01.png", height: 40%), caption: [], supplement: none, numbering: none) Krenko had a strong stomach from a childhood of eating out of gutters, but Mr. Taz made him uneasy. This was the third time they'd met to discuss business, and Taz's strange appearance was always the same. He #emph[looked] human, but his face fit too loosely on his skull, and his skin didn't seem attached to his skeleton. When Krenko thought about it too hard, he could imagine Taz's entire epidermis slithering off and sliding down into a fleshy puddle around his feet. "How is your lamb, <NAME>?" Taz asked. They were in a smoky pub near the Smelting District—Taz's choice. Not in bloodwitch territory, but just by a smidge. This was good because Krenko despised the Rakdos thugs. Too unpredictable, and not in the way Krenko liked. "Umm, yum," Krenko took an obligatory bite and considered his options. Taz wasn't a lich or necro-thing, or Krenko's exceptional goblin nose would have detected it. In fact, Taz smelled quite expensive, like almonds and clean rabbits. Krenko analyzed how the skin wobbled beneath Taz's eyeballs and bunched up around his knuckles. Oh, it was so obviously a skin-suit—and not a very tailored one at that. "I trust you find the task appealing?" Taz continued. His neck was straight down—no bump at the throat—like a female human. But his voice was low and gravelly. "It's gutsy," Krenko said approvingly. "Yes, but you have proved yourself to be a master of bold maneuvers." #figure(image("004_Krenko, Mob Boss/02.jpg", width: 100%), caption: [Krenko, Mob Boss | Art by Karl Kopinski], supplement: none, numbering: none) "Thanks to you, Mr. Taz," Krenko said. He fondly remembered the last job, the one with the exploding Azorius statue and flaming saprolings. Yes, Krenko liked this slippery-face man who kept offering him delicious jobs. As a young goblin just getting his start, a well-connected patron was a gift Krenko never expected. Besides, Krenko had a healthy respect for anything that could claim itself ugly and not give a rat's tail what the rest of the world saw. "The Boros, huh," Krenko said, stalling for time. He wanted the job, but it would complicate things. He had rounds to make along Foundry Street. Azzik and Pondl were loyal but could barely count past ten. More goblins appeared at his warehouse daily. They followed Krenko around like he was some honey basket, which would be useful if he found things for them to do. Maybe with the capital from Taz's new job... #figure(image("004_Krenko, Mob Boss/03.jpg", width: 100%), caption: [Krenko's Command | Art by Karl Kopinski], supplement: none, numbering: none) "All right," Krenko said finally. Krenko had no doubt in his ability to carry off the heist, but he marveled again that Taz trusted a lowly goblin with such a task. Most thought goblins were pests at worst and pack animals at best. "I'll do it." "I have no doubt you will," the man said mildly. He slid a velvet bag across the table. Light escaped through the seams. "Here is a special tool to help you in your endeavor." Krenko peeped inside, grinning when he saw the glowing shiv nestled against the velvet. "Aw, you know me so well." "Brilliance recognizes brilliance," Mr. Taz said mildly. "And you're sure about what you want me to bring back?" Krenko asked. "Maybe there's something more valuable I can pick up for you?" "No, Mr. Krenko. The item I requested will make me quite happy." Taz smiled with his ill-fitting lips and disappeared into the crowded pub. #figure(image("004_Krenko, Mob Boss/04.jpg", width: 100%), caption: [Boros Garrison | Art by John Avon], supplement: none, numbering: none) With Taz's enchanted shiv tucked in his boot, Krenko began his surveillance on Sunhome, the imposing Boros guildhall. After an hour on a rooftop with a spyglass, Krenko was hot and bored, and had learned little new: the Boros still loved straight lines and hard work. And Krenko still couldn't believe that goblins joined the guild willingly, but there they were: Digging trenches, washing barracks, and loading corpses onto a Golgari corpse-hauler. Krenko wondered if an average day resulted in that many dead soldiers or if something had happened beyond the scope of his eyeglass. The next morning, Krenko swaggered into Sunhome's mess hall like he owned the place. The cavernous hall fed a thousand soldiers at a time. They sat in front of platters of hot food on long tables that seemed to stretch for miles. It was noisy and hot, but the abundance of free food answered one of Krenko's longstanding questions. Suddenly, goblins in Boros made a lot more sense. Krenko slid onto the end of a bench, helped himself to the duck eggs, and settled down for a good listen to the dull roar of voices around him. The soldiers behind him were talking about a fight in Keyhole Downs—Krenko concluded it was about a girl and turned his keen ears elsewhere. Then, a few seats down, a young man with black hair said something that caught his ear: "It's come down to a duel," he informed the woman seated across the table. She had a bandage on her forehead. "Who drew the line? Aurelia?" she asked. She kept her voice low like she didn't want to be easily heard. But the man spoke louder than necessary. "No, the nosy Azorius found it in the fine print," he said. "I find that hard to believe," the woman said doubtfully. "Aurelia let it stand?" "Why shouldn't she?" the man practically shouted. "She could crush Vinrenn in a heartbeat." Suddenly, Krenko's bench tipped dangerously and several soldiers clambered to their feet. "Shut your mouth, grunt!" someone shouted and a fistfight erupted between the tables. Krenko picked up his plate and headed to the other end of the hall. Such undisciplined hot-headedness seemed very un-Boros. Krenko took a deep breath, enjoying the tension seething in the room. Yes, this was going to be as fun as it was lucrative. #figure(image("004_Krenko, Mob Boss/05.jpg", width: 100%), caption: [Boros Recruit | Art by <NAME>ts], supplement: none, numbering: none) The next day, Krenko went looking for trouble. And he found it everywhere. In Sunhome, tempers were high, and the rank and file were more interested in squabbling than their daily chores. Krenko joined a goblin maintenance crew on one of the gigantic balconies that jutted from the blocky edifice. "If I want to get a look at Feather, where should I go?" he whispered to the hook-nosed goblin next to him. He'd been polishing the wall for nearly an hour and nothing useful had happened. The goblin had a couple of patches on his uniform, but apparently they weren't enough to get him out of manual labor. "Shhhh! She says you got to call her Guildmaster Vinrenn now," he spoke very slowly as if Krenko was an idiot child. "Whatever her name is, where do I find her?" Krenko asked. "Where you from, some Gruul outhouse? Top floor, but you better stay away." "What is going on?" Krenko asked. "I just got here from the Rubblebelt." The goblin looked smug. "Yeah, I knew you were Gruul. Well, it's crazy around here. Aurelia's gonna be our new master, 'cause she says that no disgraced angel's got the right to rule. Vinrenn's gonna be banished. As long as she makes no trouble, she'll keep her life. Now, no more talking or I'll report you. Got it?" The goblin's self-importance filled Krenko with loathing. This place was teetering on the edge. All it needed was a little push. #figure(image("004_Krenko, Mob Boss/06.jpg", width: 100%), caption: [Firemane Angel | Art by <NAME>], supplement: none, numbering: none) Chaos is the best cover, and Krenko went about setting fires and kicking down doors. Floor 1: an incendiary rumor in a willing ear; Floor 2: punched yesterday's pompous goblin on his fat nose; Floor 3: spark bombs; Floor 4: actual bombs. By the time he reached the top tier, the halls were filled with the sound of thudding boots and alarmed shouts. Outside, swords clashed on the balcony. And no one noticed a snaggletooth goblin enter the chambers of Vinrenn, aka Feather, the guildmaster who apparently lacked control. Krenko found himself in an empty room under an open skylight. Harsh sunlight shone down on a glassy detention sphere, which hovered above the blood-red fist emblazoned on the tile floor. A white-winged angel was in magical stasis inside the cell. Her wings tucked around herself like a baby bird, she appeared to be sleeping. After a cursory look around the chamber, Krenko took his glowing shiv from his boot and poked at the sphere. Nothing happened, so he stabbed it again. And again. Nothing. Ugh, why would Taz give him a glowy shiv unless it was better for smashing than a regular shiv? At first, the sphere seemed like it was made out of light and mist, but when Krenko traced the surface with his palms, he felt something solid near the top. He took the shiv and slammed its handle against the invisible piece. There was a sucking sound and blue lighting zinged across the room. With another good smash, the sphere dissipated, sending the angel tumbling unceremoniously to the floor. Hearing footsteps approaching in the corridor, Krenko quickly plucked two feathers from the angel's wings just as she began to stir. "Help!" Krenko screamed, running for the door. "She tried to escape! She's free. She attacked me!" #figure(image("004_Krenko, Mob Boss/07.jpg", width: 100%), caption: [Breath of Fury | Art by Kev Walker], supplement: none, numbering: none) Suddenly, broad-shouldered guards crowded the room, and Krenko dodged legs to get to the door. As he scampered out, an armored minotaur dragged the angel to her feet, her protests falling on deaf ears. Just as Krenko reached the front gate, a large explosion rocked Sunhome. Not one of his, Krenko thought gleefully. Yes indeed, chaos was the best tool of all. #figure(image("004_Krenko, Mob Boss/08.jpg", width: 100%), caption: [Plains | Art by <NAME>], supplement: none, numbering: none) At sunset, Krenko met Taz on the Millennial, an aerial platform with the most coveted views in all of Ravnica. You had to #emph[be] someone to get a ticket to come up here. Some Ravnicans waited their entire lifetimes. Most would never get the chance. Taz was waiting for him by the appointed marker, staring out at the eye-boggling maze of buildings and streets. "Sometimes I forget to look at the sky," Taz said as Krenko handed him a wooden box. Inside was a white angel's feather. It seemed to glow red under the setting sun. "Entire days go by, and I never see the sun at all." Krenko grunted in agreement. He knew what it felt like to be a rat in the darkness. "I'm exceptionally pleased," Taz said. "Your payment is being delivered to your establishment as we speak. Krenko beamed. With coin like that, he could buy Azzik and Pondl breakfast every day if he wanted to. Not that he did. Krenko extended his hand to close the deal, but instead of shaking it, Taz handed him a silver key with the Orzhov symbol carved into the shaft. "An Orzhov safebox," he said. "This key is all you need to retrieve the money." Krenko's ears perked up. "Whose money?" "Feather's, actually. She earned a salary as a Wojek for a time. But she won't need it anymore." "Why don't you keep it for yourself?" Krenko asked. "Consider it a bonus payment. For a job well done." Mr. Taz smiled, and the skin on his face sagged beneath his jaw bone. "You have management skills, Mr. Krenko. I can see you as the boss of something grand." Krenko pocketed the key and cocked his head. "What else, <NAME>?" "Oh, just a trifle. While you're in the Orzhova, perhaps you could pick up a little something for me?"
https://github.com/SWATEngineering/Docs
https://raw.githubusercontent.com/SWATEngineering/Docs/main/src/3_PB/VerbaliInterni/VerbaleInterno_240308/content.typ
typst
MIT License
#import "meta.typ": inizio_incontro, fine_incontro, luogo_incontro #import "functions.typ": glossary, team #let participants = csv("participants.csv") = Partecipanti / Inizio incontro: #inizio_incontro / Fine incontro: #fine_incontro / Luogo incontro: #luogo_incontro #table( columns: (3fr, 1fr), [*Nome*], [*Durata presenza*], ..participants.flatten() ) /*************************************/ /* INSERIRE SOTTO IL CONTENUTO */ /*************************************/ = Sintesi Elaborazione Incontro Nell'incontro si è discussa l'organizzazione del lavoro futuro, di seguito se ne riportano i momenti salienti. == Nuovi ruoli Vengono stabiliti i seguenti i nuovi incarichi relativi allo sprint corrente: - <NAME>: Progettista, Programmatore; - <NAME>: Programmatore, Verificatore; - <NAME>: Responsabile, Programmatore; - <NAME>: Programmatore, Verificatore; - <NAME>: Programmatore, Amministratore; - <NAME>: Programmatore, Amministratore. Per questo sprint il team ha deciso di continuare la codifica di quanto progettato. A differenza dello sprint precedente, l'attività di progettazione ricopre al momento un ruolo più marginale. Di conseguenza, si è valutato opportuno assegnare a tutti i membri il ruolo di Programmatore. == Aggiornamento metriche PdQ Nonostante in precedenza si fosse deciso di adottare delle nuove metriche per il processo di fornitura, durante l'incontro odierno il team #team ne ha discusso nuovamente e ha ritrattato tale decisione. Il team ha infatti considerato che, allo stato attuale del progetto, sarebbe bene spostare l'attenzione dedicata al processo di gestione della qualità al prodotto vero e proprio e, più in generale, alla codifica dello stesso; inoltre, le metriche di fornitura attualmente utilizzate e valutate sembrano comportarsi come ci si aspetta. Si è anche considerato che, alla luce dell'attuale pianificazione, tali metriche risulterebbero utili solo per la pianificazione dei pochi sprint mancanti e che, tra l'altro, il team avrebbe poco tempo per imparare ad utilizzarle in maniera efficace. Infine, si è deciso che le metriche per la qualità di codifica e quelle per la qualità di prodotto saranno calcolate ufficialmente a partire dallo sprint attuale, utilizzando gli strumenti configurati secondo le modalità normate nelle _Norme di Progetto_. == Codifica della componente di simulazione Durante lo sprint attuale il team vuole completare la codifica del componente di simulazione compresi i test corrispondenti. Si elencano di seguito i simulatori mancanti e i membri dei team che se ne occupano: - Colonne di ricarica: <NAME>; - Biciclette elettriche: <NAME>; - Zone ecologiche: <NAME>; - Parcheggi: <NAME>; - Congestione stradale: <NAME>. == Inizio stesura del _Manuale Utente_ Il Responsabile ha indirizzato l'attenzione del team sulla necessità di iniziare la stesura del documento _Manuale Utente_ durante questo sprint. Si è deciso che la stesura del documento inizierà a partire da lunedì. Durante il weekend ogni Programmatore si informerà sui contenuti che ci si aspetta vengano illustrati in tale documento. == Rimozione di Pydantic Nel corso della valutazione delle librerie e strumenti attualmente in uso, il team ha preso in considerazione la complessità associata all'utilizzo di Pydantic per la componente di simulazione scritta in Python. Di conseguenza, si è deciso di rimuovere Pydantic dallo stack tecnologico e se ne occupa Riccardo Toniolo. == Incontri con la Proponente Il team ha riconosciuto l'importanza di riprendere un contatto più stretto con l'azienda proponente. A seguito della decisione di non intraprendere la terza revisione CA, risulta di fondamentale importanza per il team arrivare alla seconda revisione PB con un MVP che soddisfi le esigenze della Proponente; è chiaro che per raggiungere tale obiettivo, ricevere più feedback da parte di quest'ultima risulta fondamentale. == Incontro con il professor Cardin Altro requisito fondamentale per essere pronti a sostenere la PB entro quando pianificato è che l'architettura presentata nel documento _Specifiche Tecniche_ incontri il favore del professor Cardin. Perciò si è deciso di organizzare un incontro in cui mostrare i progressi del documento e ottenere un feedback a riguardo. Si spera di poter effettuare tale incontro durante lo sprint corrente, così da avere due sprint per poter applicare eventuali correzioni.
https://github.com/OtaNix-ry/typst-packages
https://raw.githubusercontent.com/OtaNix-ry/typst-packages/main/board-meeting/0.1.0/example.typ
typst
MIT License
#import "lib.typ": * #show: meeting.with( title: "OtaNix ry hallituksen kokous", subtitle: "Mallidokumentti" ) #opening( // start-time: "12.00", attendees: ("<NAME>", "<NAME>", lorem(2)) )[] #lawfulness( board-members-present: 3 )[] #agenda( // accepted: true // format: false )[ + Google workspaces for non-profits haku - palvelun käytöstä pitää myös sopia, saako esim. kaikki jäsenet \@otanix.fi spostin? + AYY yhdistysrekisteriin haku + Järjestettävät tapahtumat - Neomutt/email workshop - Agenix workshop - GPG-agent SSH integraatio YubiKey workshop - Ferris-pehmolelu workshop + Seuraavat tapaamiset - Säännölliset hallituksen kokoukset? + Typst template pöytäkirjoille ja muille dokumenteille (w/logo, etc.) + #lorem(5) #lorem(20) ] = #lorem(5) #lorem(100) #closing( // end-time: "12.30", )[]
https://github.com/yanisurbis/typst-action-test
https://raw.githubusercontent.com/yanisurbis/typst-action-test/main/main.typ
typst
#import "template.typ": * #show: project.with( title: "CS 6400 – Fall 2023, Phase 1 Report", authors: ( "Team 059", ), ) #set page(header: align(center)[ Phase 1 Report | CS 6400 – Fall 2023 | Team 059 ]) #let datatype_table(..x) = { box([ #table( columns: (1fr, auto, auto), inset: 10pt, align: horizon, [*Attribute*], [*Datatype*], [*Nullable*], ..x ) ], width: 70%) } #outline(indent: auto) #pagebreak() = Data Types == Customer #datatype_table( [Phone number], [String], [Not null] ) = Business Logic Constraints #lorem(10) = Task Decomposition with Abstract Code #lorem(10)
https://github.com/augustebaum/petri
https://raw.githubusercontent.com/augustebaum/petri/main/tests/fletcher/transitions/test.typ
typst
MIT License
#import "/src/lib.typ": * #set page(width: auto, height: auto, margin: 1cm) #import "@preview/fletcher:0.4.2" as fletcher /// % Transition 1 /// \node[transition, /// minimum size=1cm, /// label=$T_1$] (Trans1) at (0,0) {}; /// /// % Transition 2 /// \node[transition, /// minimum width=2mm, /// minimum height=12mm, /// label=$T_2$] (Trans2) at (2,0) {}; /// /// % Transition 3 /// \node[transition, /// minimum width=12mm, /// minimum height=2mm, /// label=$T_3$] (Trans3) at (4,0) {}; #fletcher.diagram( node-stroke: 0.5pt, t((0,0), $T_1$, width: 1cm, height: 1cm), t((2,0), $T_2$, width: 2mm, height: 12mm), t((4,0), $T_3$, width: 12mm, height: 2mm), t((6,0), $T_4$), t((0,2), $T_1$, width: 1cm, height: 1cm, fill: black), t((2,2), $T_2$, width: 2mm, height: 12mm, fill: black), t((4,2), $T_3$, width: 12mm, height: 2mm, fill: black), t((6,2), $T_4$, fill: black), )
https://github.com/deadManAlive/ui-thesis-typst-template
https://raw.githubusercontent.com/deadManAlive/ui-thesis-typst-template/master/primer/pre.typ
typst
#import "cover.typ": cover #import "title.typ": title #import "auth.typ": auth #import "valid.typ": valid #import "intro.typ": intro #import "publ.typ": publ #let pre = [ #set par(leading: 1em) #set page(numbering: "i") #set outline(title: none, depth: 3, indent: auto) #show heading.where(level: 1): head => context [ #set align(center) #upper(head.body) #v(1.5em) ] #set page(footer: []) #cover #pagebreak(weak: true) #counter(page).update(1) #title #pagebreak(weak: true) // roman numbering start after title page #set page( footer: context [ #set align(center) #counter(page).display("i") ] ) #auth #pagebreak(weak: true) #valid #pagebreak(weak: true) #intro #pagebreak(weak: true) #publ // with Footer (from abstract) #set page( footer: context [ #set align(center) #counter(page).display("i") \ #set align(right) #text("Universitas Indonesia", font: "Arial", size: 10pt, weight: "bold") ] ) = Daftar Isi #[ #show outline.entry.where( level: 1 ): it => { strong(it) } #outline() ] #pagebreak(weak: true) = Daftar Gambar #outline(target: figure.where(kind: image)) ]
https://github.com/YabusameHoulen/Statistics
https://raw.githubusercontent.com/YabusameHoulen/Statistics/main/Template/pset.typ
typst
#let pset(class: "默认类", title: "魔改PSET", student: "<NAME>", date: datetime.today(), subproblems: "1.1.1.i", collaborators: (), doc ) = {[ /* Convert collaborators to a string if necessary */ #let collaborators=if type(collaborators) == array {collaborators.join(", ")} else {collaborators} /* Problem + subproblem headings */ #set heading(numbering: (..nums) => { nums = nums.pos() if nums.len() == 1 { [#nums.at(0)] } else { numbering(subproblems, ..nums) } }) /* Set metadata */ #set document( title: [#class - #title], author: student, date: date, ) /* Set up page numbering and continued page headers */ #set page( numbering: "1", header: context { if counter(page).get().first() > 1 [ #set text(style: "italic") #class -- #title #h(1fr) #student #if collaborators != none {[w/ #collaborators]} #block(line(length: 100%, stroke: 0.5pt), above: 0.6em) ] }) /* Add numbering and some color to code blocks */ #show raw.where(block: true): it => { block[ #h(1fr) #align(center, box( width: 75%, radius: 0.5em, stroke: luma(50%), inset: 0.5em, fill: luma(95%) )[ #show raw.line: l => { box(width:measure([#it.lines.last().count]).width, align(left, text(fill: luma(30%))[#l.number])) h(1em) l.body h(60%) } #it ] ) ] } /* Make the title */ #align(center, { text(size: 1.6em, weight: "semibold")[#class -- #title \ ] text(size: 1.2em)[#student \ ] [#date.display("[year]-[month]-[day]") ] // emph[ // #date.display("[year]-[month]-[day]") // #if collaborators != none {[ // \ Collaborators: #collaborators // ]} // ] // box(line(length: 100%, stroke: 1pt)) }) #show heading: it => { it text()[#v(1em, weak: true)] text()[#h(1.5em)] } // 两端对齐,段前缩进2字符 #doc ]}
https://github.com/AU-Master-Thesis/thesis
https://raw.githubusercontent.com/AU-Master-Thesis/thesis/main/sections/5-discussion/study-2.typ
typst
MIT License
#import "../../lib/mod.typ": * // #pagebreak(weak: true) == #study.H-2.full.n <s.d.study-2> This part discusses, and evaluates the results of the contribution, which pertains to the second hypothesis, #study.H-2.box. This hypothesis specifically concerns the testing of an enhancement to the original `gbpplanner`, which have been implemented in the #acr("MAGICS") tool. Further, the effect of varying the number of both internal and external iterations in the #acr("GBP") inference process is discussed. The deliberations take place in the following sections; #numref(<s.d.iteration-amount>), #numref(<s.d.iteration-schedules>). === Iteration Amount <s.d.iteration-amount> The analysis of the results from the @s.r.iteration-amount-plots highlights the significance of the number of internal iterations $M_I$ and external message passing steps $M_E$ per simulated timestep on performance. It is evident that performing 8 to 10 iterations of each yields satisfactory results, with improvements beyond this range being marginal. This is due to the iterative nature of optimization on a factor graph, where each pass within a timestep yields diminishing returns in terms of certainty, as the amount of new information introduced is limited and much of it has already been incorporated in earlier steps. Consequently, the choice of $M_I = 50$ and $M_E = 10$ in the scenarios used by the #gbpplanner@gbpplanner paper appears to be unnecessary and redundant. This excessive iteration count does not translate to substantial performance gains. Moreover, in highly connected cases, such as when robots converge at the center of a circle, the exponential increase in information from neighbors becomes detrimental if $M_I <= 3$. It overwhelms the dynamic factors of the robots leading to highly sporadic planned movement, that are infeasible for robots with holonomic constraints. An approach with $M_I > M_E$ and both $M_I$ and $M_E$ being at least 10 iterations is generally optimal for achieving good performance without unnecessary computational overhead. // - Looking at the results in @s.r.iteration-amount-plots the choice of how many internal iterations $M_I$ and external $M_E$ message passing steps are performed per simulated timestep does have an effect on the performance. // // - demonstrates that 8 to 10 iterations of each is enough to get good results, and that anything above quickly results in very slight improvements. // // - As such the choice of $M_I = 50, and M_E = 10$ in all of the scenarios used by the gpbplanner@gbpplanner paper is unnecessary/redundant. // // - Exponentially more information from neighbours in highly connected cases such as when the robots all meet in the center of the circle, is detrimental, and overrules the dynamics factors, // of the robots. // // - Not as clear of a direct correlation for the _Finished at Difference_ metric. This might be due to randomness present in the scenario with robots not having the same radius. The distribution of how robots are placed around the circle could affect this as the radius affect at which point the interrobot factors start to affect the joint factorgraph between two neighbours. // // - In general a good choice is for $M_I > M_E$ and both $M_I >= 10 and M_E >= 10$. === Iteration Schedules <s.d.iteration-schedules> The results from the @s.r.schedules experiment indicate that the choice of scheduling strategy appears to have little to no significant impact on any of the three metrics considered. This observation broadly supports the given hypothesis regarding the robustness and convergence of the algorithm, irrespective of the relative order in which external messages update the joint factor graph. The expectation that the _Interleave Evenly_ strategy would perform slightly better than the others is not present in the measurements. Instead the _Half end, Half Beginning_ strategy performs modestly better than the others across all three metrics. This marginal improvement could be attributed to the balanced approach of distributing updates at both the start and end of the iteration process, potentially stabilizing the information flow and aiding convergence. However, the exact reason for this slight advantage remains unclear and warrants further investigation. As it was further expected that _Centered_ would perform on par with it, given them being similar except for a phase offset. The lack of noticeable differences might be due to differences not appearing with the other parameters chosen, or due to limitations of how network communication is simulated. With a more sophisticated network model that better captures the latency variability and time delay between messages, a more clear difference could emerge. // Finally // // to stipulate that // // One hypotheses // // // #note.k[Do we think this would be more relevant when there is more drops in communication?] // The current setup may not be sophisticated enough to capture the nuances of real-world stochastic processes. A more detailed model incorporating timed networking and random noise could provide deeper insights and more accurately simulate real-world conditions. // // - Choice of schedule appears to be of little to no importance. // - This broadly supports to given hypothesis about the outcome of the enhancement. // - Half end, Half beginning showcases a slight edge over the others. Why that is, is... Not interleave evenly as expected // // - Given the apparent variance in the measurements, it is diffecult to conclude that there are any difference. // - Either there is no noticeable difference, or the simulated environment is not able to test it. More insight would need to be able to be retrieved by a more sophisticated modelling of timed networking, with random noise to more broadly simulate real world stochastic processes.
https://github.com/Myriad-Dreamin/typst.ts
https://raw.githubusercontent.com/Myriad-Dreamin/typst.ts/main/fuzzers/corpora/meta/footnote_01.typ
typst
Apache License 2.0
#import "/contrib/templates/std-tests/preset.typ": * #show: test-page // Test space collapsing before footnote. A#footnote[A] \ A #footnote[A]
https://github.com/FurryAcetylCoA/sgu-thesis-typst
https://raw.githubusercontent.com/FurryAcetylCoA/sgu-thesis-typst/main/nju-thesis/layouts/appendix.typ
typst
MIT License
#import "@preview/i-figured:0.2.2" #import "../utils/custom-numbering.typ": custom-numbering #import "../utils/style.typ": 字号, 字体 // 后记,重置 heading 计数器 #let appendix( fonts: (:), numbering: custom-numbering.with(first-level: "", depth: 3, "A.1 "), // figure 计数 show-figure: i-figured.show-figure.with(numbering: "A.1"), // equation 计数 show-equation: i-figured.show-equation.with(numbering: "(A.1)"), // 其他参数 title: "附录", outlined: true, twoside: false, body, ) = { fonts = 字体 + fonts set heading(numbering: numbering) counter(heading).update(0) // 设置 figure 的编号 show figure: show-figure // 设置 equation 的编号 show math.equation.where(block: true): show-equation pagebreak(weak: true, to: if twoside { "odd" }) // 显示标题 [ #set text(font: fonts.黑体, size: 字号.小四, weight: "bold") #set align(center) #heading(level: 1, numbering: numbering, outlined: outlined, title) <no-auto-pagebreak> ] text(font: fonts.宋体, size: 字号.五号)[#body] }
https://github.com/tingerrr/subpar
https://raw.githubusercontent.com/tingerrr/subpar/main/src/lib.typ
typst
MIT License
#import "util.typ" as _util #import "_pkg.typ" #import "default.typ" #let _numbering = numbering #let _label = label #let _grid = grid /// The counter used for sub figures. #let sub-figure-counter = counter("__subpar:sub-figure-counter") /// Creates a figure which may contain other figures, a #emph[super]figure. For /// the meaning of parameters take a look at the regular figure documentation. /// /// See @@grid() for a function which places its sub figures in a grid. /// /// - kind (str, function): The image kind which should be used, this is mainly /// relevant for introspection and defaults to `image`. This cannot be /// automatically resovled like for normal figures and must be set. /// - numbering (str, function): This is the numbering used for this super /// figure. /// - numbering-sub (str, function): This is the numbering used for the sub /// figures. /// - numbering-sub-ref (str, function): This is the numbering used for /// _references_ to the sub figures. If this is a function, it receives both /// the super and sub figure numbering respectively. /// - supplement (content, function, auto, none): The supplement used for this /// super figure _and_ the sub figures when referenced. /// - propagate-supplement (bool): Whether the super figure's supplement should /// propagate down to its sub figures. /// - caption (content): The caption of this super figure. /// - placement (alignment, auto, none): The float placement of this super /// figure. /// - gap (length): The gap between this super figure's caption and body. /// - outlined (bool): Whether this super figure should appear in an outline of /// figures. /// - outlined-sub (bool): Whether the sub figures should appear in an outline /// of figures. /// - label (label, none): The label to attach to this super figure. /// - show-sub (function, auto): A show rule override for sub figures. Recevies /// the sub figure. /// - show-sub-caption (function, auto): A show rule override for sub figure's /// captions. Receives the realized numbering and caption element. /// -> content #let super( kind: image, numbering: "1", numbering-sub: "(a)", numbering-sub-ref: "1a", supplement: auto, propagate-supplement: true, caption: none, placement: none, gap: 0.65em, outlined: true, outlined-sub: false, label: none, show-sub: auto, show-sub-caption: auto, body, ) = { _pkg.t4t.assert.any-type(str, function, kind) let assert-numbering = _pkg.t4t.assert.any-type.with(str, function) assert-numbering(numbering) assert-numbering(numbering-sub) assert-numbering(numbering-sub-ref) // adjust numberings to receive either both or the sub number numbering-sub = _util.sparse-numbering(numbering-sub) numbering-sub-ref = _util.sparse-numbering(numbering-sub-ref) _pkg.t4t.assert.any-type(str, content, function, type(auto), type(none), supplement) _pkg.t4t.assert.any-type(bool, propagate-supplement) _pkg.t4t.assert.any-type(str, content, type(none), caption) _pkg.t4t.assert.any(top, bottom, auto, none, placement) _pkg.t4t.assert.any-type(length, gap) _pkg.t4t.assert.any-type(bool, outlined) _pkg.t4t.assert.any-type(bool, outlined-sub) _pkg.t4t.assert.any-type(_label, type(none), label) _pkg.t4t.assert.any-type(function, type(auto), show-sub) _pkg.t4t.assert.any-type(function, type(auto), show-sub-caption) let function-kinds = ( image: "figure", table: "table", raw: "raw", ) // NOTE: if we use no propagation, then we can fallback to the normal auto behavior, fixing #4. if propagate-supplement and supplement == auto { if repr(kind) in function-kinds { supplement = context _util.i18n-kind(function-kinds.at(repr(kind))) } else { panic("Cannot infer `supplement`, must be set.") } } show-sub = _pkg.t4t.def.if-auto(it => it, show-sub) show-sub-caption = _pkg.t4t.def.if-auto((num, it) => it, show-sub-caption) context { let n-super = counter(figure.where(kind: kind)).get().first() + 1 [#figure( kind: kind, numbering: n => _numbering(numbering, n), supplement: supplement, caption: caption, placement: placement, gap: gap, outlined: outlined, { // TODO: simply setting it for all doesn't seem to work show: _util.apply-for-all( _util.gather-kinds(body), kind => inner => { show figure.where(kind: kind): set figure(numbering: _ => _numbering( numbering-sub-ref, n-super, sub-figure-counter.get().first() + 1 )) inner }, ) set figure(supplement: supplement) if propagate-supplement set figure(outlined: outlined-sub, placement: none) show figure: show-sub show figure: it => { let n-sub = sub-figure-counter.get().first() + 1 let num = _numbering(numbering-sub, n-super, n-sub) show figure.caption: it => { num [ ] it.body } show figure.caption: show-sub-caption.with(num) sub-figure-counter.step() it counter(figure.where(kind: it.kind)).update(n => n - 1) } sub-figure-counter.update(0) body }, )#label] } } /// Provides a convenient wrapper around @@super() which puts sub figures in a /// grid. /// /// - columns (auto, int, relative, fraction, array): Corresponds to the grid's /// `columns` parameter. /// - rows (auto, int, relative, fraction, array): Corresponds to the grid's /// `rows` parameter. /// - gutter (auto, int, relative, fraction, array): Corresponds to the grid's /// `gutter` parameter. /// - column-gutter (auto, int, relative, fraction, array): Corresponds to the /// grid's `column-gutter` parameter. /// - row-gutter (auto, int, relative, fraction, array): Corresponds to the /// grid's `row-gutter` parameter. /// - align (auto, array, alignment, function): Corresponds to the grid's /// `align` parameter. /// - inset (relative, array, dictionary, function): Corresponds to the grid's /// `inset` parameter. /// - kind (str, function): Corressponds to the super figure's `kind`. /// - numbering (str, function): Corressponds to the super figure's /// `numbering`. /// - numbering-sub (str, function): Corressponds to the super figure's /// `numbering-sub`. /// - numbering-sub-ref (str, function): Corressponds to the super figure's /// `numbering-sub-ref`. /// - supplement (content, function, auto, none): Corressponds to the super /// figure's `supplement`. /// - propagate-supplement (bool): Corressponds to the super figure's /// `propagate-supplement`. /// - caption (content): Corressponds to the super figure's `caption`. /// - placement (alignment, auto, none): Corressponds to the super figure's /// `placement`. /// - gap (length): Corressponds to the super figure's `gap`. /// - outlined (bool): Corressponds to the super figure's `outlined`. /// - outlined-sub (bool): Corressponds to the super figure's `outlined-sub`. /// - label (label, none): Corressponds to the super figure's `label`. /// - show-sub (function): Corressponds to the super figure's `show-sub`. /// - show-sub-caption (function): Corressponds to the super figure's /// `show-sub-caption`. /// -> content #let grid( columns: auto, rows: auto, gutter: 1em, column-gutter: auto, row-gutter: auto, align: bottom, inset: (:), kind: image, numbering: "1", numbering-sub: "(a)", numbering-sub-ref: "1a", supplement: auto, propagate-supplement: true, caption: none, placement: none, gap: 0.65em, outlined: true, outlined-sub: false, label: none, show-sub: auto, show-sub-caption: auto, ..args, ) = { let assert-arg = _pkg.t4t.assert.any-type.with(type(auto), int, length, relative, fraction, array) assert-arg(columns) assert-arg(rows) assert-arg(gutter) assert-arg(column-gutter) assert-arg(row-gutter) _pkg.t4t.assert.any-type(type(auto), array, alignment, function, align) _pkg.t4t.assert.any-type(length, relative, array, dictionary, function, inset) if args.named().len() != 0 { panic("Unexpectd arguments: `" + repr(args.named()) + "`") } let figures = args.pos() // NOTE: the mere existence of an argument seems to change how grid behaves, so we discard any that are auto ourselves let grid-args = ( columns: columns, rows: rows, align: align, inset: inset, ) if gutter != auto { grid-args.gutter = gutter } if column-gutter != auto { grid-args.column-gutter = column-gutter } if row-gutter != auto { grid-args.row-gutter = row-gutter } super( kind: kind, numbering: numbering, numbering-sub: numbering-sub, numbering-sub-ref: numbering-sub-ref, supplement: supplement, propagate-supplement: propagate-supplement, caption: caption, placement: placement, gap: gap, outlined: outlined, outlined-sub: outlined-sub, label: label, show-sub: show-sub, show-sub-caption: show-sub-caption, _grid( .._util.stitch-pairs(figures).map(((f, l)) => if type(f) == content and f.func() == _grid.cell { assert.eq( l, none, message: "When using `grid.cell` in `subpar.grid`, place labels inside the cell itself", ) f } else if type(f) == content and f.func() in ( _grid.hline, _grid.vline, _grid.header, _grid.footer, ) { f } else { [#f#l] }), ..grid-args, ), ) }
https://github.com/EpicEricEE/typst-marge
https://raw.githubusercontent.com/EpicEricEE/typst-marge/main/tests/container/figure/test.typ
typst
MIT License
#import "/src/lib.typ": sidenote #set par(justify: true) #set page(width: 8cm, height: auto, margin: (outside: 4cm, rest: 5mm)) #let sidenote = sidenote.with(numbering: "1") #lorem(5) #sidenote[A note before the figure.] #figure(rect(), caption: [ // Counter is not stepped because of a Typst bug! (Fixed in 0.12) A rectangle #sidenote[A note from the caption.] ]) #lorem(5) #sidenote[A note after the figure.] #lorem(5)
https://github.com/Error-418-SWE/Documenti
https://raw.githubusercontent.com/Error-418-SWE/Documenti/src/1%20-%20Candidatura/Verbali/Interni/17-10-23/17-10-23.typ
typst
ERROR\_418 \ Verbale 17/10/23 #figure( align(center)[#table( columns: 2, align: (col, row) => (left,left,).at(col), inset: 6pt, [Mail:], [<EMAIL>], [Redattori:], [<NAME>, <NAME>], [Verificatori:], [<NAME>, <NAME>, <NAME>], [Amministratori:], [<NAME>, <NAME>], [Destinatari:], [<NAME>, <NAME>], )] ) #figure( align(center)[#table( columns: 2, align: (col, row) => (center,center,).at(col), inset: 6pt, [Inizio Meeting: 16:00 Fine Meeting: 17:30 Durata:1:30h], [], [Presenze:], [], )] ) #block[ #figure( align(center)[#table( columns: 5, align: (col, row) => (center,center,center,center,center,).at(col), inset: 6pt, [Nome], [Durata Presenza], [], [Nome], [Durata Presenza], [Antonio], [1:30h], [], [Alessio], [1:30h], [Riccardo], [1:30h], [], [Giovanni], [1:30h], [Rosario], [1:30h], [], [Silvio], [1:30h], [Mattia], [1:30h], [], [], [], )] ) ] = Discussione Capitolati <discussione-capitolati> I punti principali discussi durante il meeting sono due: - scelta dei capitolati per il progetto; - scelta del nome del gruppo. I vari membri del gruppo hanno raccolto le loro proposte per il nome del gruppo in un file condiviso, dopodiché il nome è stato scelto tramite votazione: Error\_418. Il seguente passo è stato quello di discutere i vari capitolati, procedendo, sempre tramite utilizzo di un file condiviso, a raccogliere una valuazione di ogni membro del gruppo nei confronti di ogni proposta. A seguito di un confronto poi, è stata effettuata una scrematura e sono state selezionate 3 proposte tra le 9 totali. \ Le proposte scelte sono: - \(prima scelta) C9 ChatSQL: creare frasi SQL da linguaggio naturale: Scelto poichè abbiamo ritenuto molto interessante il progetto e la possibilità di lavorare con le IA; - \(seconda scelta) C3 Easy Meal: Scelto in quanto discutendo delle possibilità di sviluppo abbiamo elaborato molte idee sui modi di implementare le varie componenti software e le eventuali tecnologie; - \(terza scelta) C5 Wharehouse management 3D: Scelto in quanto abbiamo trovato molto stimolante la possibilità di lavorare con la modellazione 3D. \ Vengono evidenziati alcuni punti poco chiari sulla presentazione dell’azienda che ci promettiamo di risolvere al più presto tramite comunicazione diretta con la stessa.
https://github.com/Myriad-Dreamin/tinymist
https://raw.githubusercontent.com/Myriad-Dreamin/tinymist/main/crates/tinymist-query/src/fixtures/type_check/annotation_var.typ
typst
Apache License 2.0
/// #let m = `(x, y) => x`; /// /// -> function, m #let mapper = (x, f) => x.map(f);
https://github.com/bennyhandball/PA1_LoB_Finance
https://raw.githubusercontent.com/bennyhandball/PA1_LoB_Finance/main/PA/acronyms.typ
typst
#let acronyms = ( API: "Application Programming Interface (Deutsch: Programmierschnittstelle)", HTTP: "Hypertext Transfer Protocol", REST: "Representational State Transfer", ERP : "Enterprise Resource-Planning", BTP : "Business Technology Platform", PSP: "Projektstrukturplan", PS: "SAP Projekt-System", KI: "Künstliche Intelligenz", FI: "Finanzwesen", CO: "Controlling", MM: "Materialwirtschaft", SaaS: "Software as a Service", )
https://github.com/dyc3/senior-design
https://raw.githubusercontent.com/dyc3/senior-design/main/lib/glossary.typ
typst
// copied from: https://github.com/typst/typst/issues/755#issuecomment-1542595624 // modified to taste #import "@preview/in-dexter:0.0.5": * // Generate a regex that matches all the words in glossary named filename #let glossaryWords(filename) = { let pipeList = "(?i:" // Match case insensitively for word in yaml("../" + filename).keys() { pipeList += "\b" + word + "\b|" // Stop at word boundaries to not match inside other words } return regex(pipeList.slice(0, pipeList.len()-1) + ")") // Remove trailing pipe & close parenthesis } // Return the position of the word word in the glossary filename as dictionaries don't implement find-like methods #let glossaryPosition(filename, word) = { let count = 0 for key in yaml("../" + filename).keys() { count += 1 if lower(key) == lower(word) {return count} // Search case-insensitively by lowering everything } assert(false, message: word + " not found in glossary but matched in regex") // Debug } // For a given word and glossary file, return the word augmented with a link to the glossary #let glossaryShow(filename, word) = { word = repr(word) word = word.trim(regex("\s|\[|\]")) // Trim brackets generated by repr() and whitespaces // allow for enabling/disabling glossary links with metadata return locate(loc => { let metas = query(selector(metadata).before(loc), loc).filter(meta => meta.value.starts-with("!glossary:")) let enabled = false for meta in metas { let command = meta.value.split(":").at(1) if command == "enable" {enabled = true} else if command == "disable" {enabled = false} else { panic("Unknown glossary command: " + command) } } // Insert an invisible char into the word to prevent show from looping on itself let printableWord = word.first() + "‎" + word.slice(1) if enabled { return { show link: set underline(stroke: 0pt) link(label("glossary"), text(style: "italic", fill: rgb("#00612d"), printableWord)) index(lower(printableWord)) } } else { return { text(printableWord) index(lower(printableWord)) } } }) } // Display the words of the glossary with their definition & their eventual web links #let glossary(filename, title: "Glossary") = { let data = yaml("../" + filename) if data.len() > 0 [ #heading(title) #label("glossary") ] terms(..data.pairs().map(((word,info)) => terms.item(word, [#info.definition#if "link" in info {[\ → #link(info.link)]}]))) }
https://github.com/Hennzau/cv
https://raw.githubusercontent.com/Hennzau/cv/main/example/enzo.le-van.en.typ
typst
#import "../lib.typ": cv #let gray = rgb("#303848") #let orange = rgb("#BF9268") #let light_gray = rgb("#F2F2F2") #let cadre_photo() = { align(right + bottom)[ #box(width: auto, height: 85%, stroke: gray + 4pt,)[ #image("enzo.le-van.photo.jpg") ] ] } #let cadre_nom() = { align(center + bottom)[ #box(width: 85%, height: 80%, stroke: orange + 4pt, fill: white)[ #align(center + top)[ #move(dy: 25pt)[ #text(size: 30pt, weight: "extralight", spacing: 100%, tracking: 4pt)[ <NAME> ] #linebreak() #move(dy: 10pt)[ #text(size: 15pt, weight: "bold", tracking: 4pt)[ 2#super[nd] year student at ] #linebreak() #text(size: 15pt, weight: "bold", tracking: 4pt)[ CentraleSupélec ] ] ] ] ] ] } #let cadre_contact() = { align(center + horizon)[ #move(dy: 6pt)[ #text(size: 9pt, weight: "semibold")[ e-mail : <EMAIL> | #link("https://github.com/Hennzau")[GitHub : \@Hennzau] | #link("www.linkedin.com/in/enzo-le-van")[Linkedin : \@enzo-le-van] ] ] ] } #let cadre_recherche() = { move(dx: 5%, dy: 14pt)[ #line(length: 90%, stroke: orange + 2pt) ] align(center)[ #move(dy: 18pt)[ #text(size: 10pt, weight: "semibold")[ #par(justify: true)[ I am looking for a 6-month gap year internship starting in July/August 2024 in the field of computer science, #linebreak(justify: true) where I can develop software applications for robotics and/or embedded systems. ] ] ] ] } #let cadre_divers() = { let langues() = { move(dx: 5%, dy: 15pt)[ #line(length: 90%, stroke: orange + 2pt) ] align(center)[ #move(dx: 0pt, dy: -5pt)[ #highlight(fill: light_gray, extent: 8pt)[ #text(size: 15pt, weight: "semibold", tracking: 2pt)[ Languages ] ] ] ] align(center)[ #move(dy: 0pt)[ #text(size: 11pt, weight: "semibold")[ English : C1 ] #linebreak() #text(size: 11pt, weight: "semibold")[ Spanish : B2 ] #linebreak() #text(size: 11pt, weight: "semibold")[ Japanese : A1 ] #linebreak() #linebreak() ] ] } let loisirs() = { move(dx: 5%, dy: 15pt)[ #line(length: 90%, stroke: orange + 2pt) ] align(center)[ #move(dx: 0pt, dy: -5pt)[ #highlight(fill: light_gray, extent: 8pt)[ #text(size: 15pt, weight: "semibold", tracking: 2pt)[ Hobbies ] ] ] ] align(center)[ #move(dy: 0pt)[ #text(size: 11pt, weight: "semibold")[ Piano for 6 years #linebreak() Guitar for 7 years ] #linebreak() #linebreak() #text(size: 11pt, weight: "semibold")[ Wing Chun in a club #linebreak() Climbing at school ] #linebreak() #linebreak() #text(size: 11pt, weight: "semibold")[ Java & C++ for 10 years #linebreak() Rust for 2 years ] #linebreak() #linebreak() ] ] } let competences() = { move(dx: 5%, dy: 15pt)[ #line(length: 90%, stroke: orange + 2pt) ] align(center)[ #move(dx: 0pt, dy: -5pt)[ #highlight(fill: light_gray, extent: 8pt)[ #text(size: 15pt, weight: "semibold", tracking: 2pt)[ Skills ] ] ] ] align(center)[ #move(dy: 0pt)[ #text(size: 11pt, weight: "semibold")[ Electronic #linebreak() Rust C++ Python #linebreak() JetBrains IDE #linebreak() GitHub CI/CD #linebreak() Projects structuration ] #linebreak() #linebreak() ] ] } align(right)[ #block(fill: light_gray, width: 90%, height: 100%)[ #align(left)[ #grid( columns: (100%), rows: (auto, auto, auto), langues(), loisirs(), competences() ) ] ] ] } #let cadre_formation() = { align(left + top)[ #box(fill: gray, width: 150pt, height: 30pt)[ #align(center + horizon)[ #text(size: 14pt, weight: "semibold", fill: white, tracking: 2pt)[ Education ] ] ] ] move(dx: 150pt, dy: -30pt)[ #line(length: 225pt, stroke: orange + 2pt) ] move(dy: -16pt)[ #list( indent: 15pt, tight: false, [ #text(size: 10pt, weight: "extralight")[ #text(weight: "semibold")[Exchange Studies] : Computer Science, 15/01/2025 - 7/06/2025 #linebreak() #text(weight: "semibold")[Linköpings Universitet | Suède] ] ], [ #text(size: 10pt, weight: "extralight")[ #text(weight: "semibold")[2nd year Engineer] : Electrical energy, electronic systems, wave physics, thermodynamics, thermal, autonomous vehicles #linebreak() #text(weight: "semibold")[CentraleSupélec | Gif-sur-Yvette] ] ], [ #text(size: 10pt, weight: "extralight")[ #text(weight: "semibold")[MPSI/PSI\*] : Mathematics, Physics, 30/08/2021 - 1/09/2023 #linebreak() #text(weight: "semibold")[Lycée Privé Sainte-Geneviève | Versailles] ] ] ) ] } #let cadre_projet() = { align(left + top)[ #box(fill: gray, width: 150pt, height: 30pt)[ #align(center + horizon)[ #text(size: 14pt, weight: "semibold", fill: white, tracking: 2pt)[ Projects ] ] ] ] move(dx: 150pt, dy: -30pt)[ #line(length: 225pt, stroke: orange + 2pt) ] move(dy: -16pt)[ #list( indent: 15pt, tight: false, [ #text(size: 10pt, weight: "extralight")[ #text(weight: "semibold", size: 12pt)[`MarcsRover`] : Building a mini autonomous car in team, 09/2024 #linebreak() #text(weight: "semibold")[CoVAPSy | Python & Zenoh & Electronique] ] ], [ #text(size: 10pt, weight: "extralight")[ #text(weight: "semibold", size: 12pt)[`fastformat`] : Library for converting real data (sensors) #linebreak(justify: true) to a generic format used by other libraries #linebreak() #text(weight: "semibold")[Organization #text(weight: "semibold", size: 12pt)[`dora-rs`] | Rust & Python] ] ], [ #text(size: 10pt, weight: "extralight")[ #text(weight: "semibold", size: 12pt)[`dora-rs`] : Contribution to a library for robotics #linebreak() #text(weight: "semibold")[Organization #text(weight: "semibold", size: 12pt)[`dora-rs`] | Rust & Python] ] ], [ #text(size: 10pt, weight: "extralight")[ #text(weight: "semibold", size: 12pt)[`dora-lerobot`] : Integration of a robotics and AI library #linebreak(justify: true) on articulated arms #linebreak() #text(weight: "semibold")[HuggingFace | Python] ] ], [ #text(size: 10pt, weight: "extralight")[ #text(weight: "semibold", size: 12pt)[`RoverCS`] : Building a mini autonomous car in team, 02/2024 - 06/2024 #linebreak() #text(weight: "semibold")[NXP Cup | ROS2 & Python & C & Zephyr RTOS] ] ], ) ] } #let cadre_experience() = { move(dx: 5%, dy: 28pt)[ #line(length: 90%, stroke: orange + 2pt) ] move(dx: 50% - 75pt, dy: 0pt)[ #box(fill: gray, width: 150pt, height: 30pt)[ #align(center + horizon)[ #text(size: 14pt, weight: "semibold", fill: white, tracking: 2pt)[ Experience ] ] ] ] let pad = 3pt let pad2 = 12pt grid( columns: (50%, 50%), rows: (100%), grid.cell( x: 0, y: 0, rowspan: 1, colspan: 1, )[ #move(dy: pad, dx: pad2)[ #par(justify: true)[ #list( indent: 15pt, tight: false, [ #text(size: 10pt, weight: "extralight")[ #text(weight: "semibold")[Anti-SGBV Staff Member], 09/2023 - 01/2025 #linebreak() Anti-SGBV supervision during student parties #linebreak() #text(weight: "semibold")[Gif-sur-Yvette] • Association Çapèse ] ], [ #text(size: 10pt, weight: "extralight")[ #text(weight: "semibold")[Order Handler], 09/2023 - 01/2025 #linebreak() Preparing orders of local products #linebreak() #text(weight: "semibold")[Gif-sur-Yvette] • Association Impact - Pépin ] ], [ #text(size: 10pt, weight: "extralight")[ #text(weight: "semibold")[Homework Assistant], 09/2021 - 06/2022 #linebreak() Tutoring middle school students #linebreak() #text(weight: "semibold")[Versailles] • ARPEJ ] ] ) ] ] ], grid.cell( x: 1, y: 0, rowspan: 1, colspan: 1, )[ #move(dy: pad, dx: -pad2)[ #par(justify: true)[ #list( indent: 15pt, tight: false, [ #text(size: 10pt, weight: "extralight")[ #text(weight: "semibold")[Robotics and AI Contributor], 05/2024 - 09/2024 #linebreak() Creation of #text(weight: "semibold", size: 12pt)[`dora-lerobot`]: programming of #linebreak() low- and high-budget articulated arms for learning #linebreak() through teleoperation #linebreak() #text(weight: "semibold")[Paris] • 1ms.ai & HuggingFace ] ], [ #text(size: 10pt, weight: "extralight")[ #text(weight: "semibold")[Operator Intern], 06/2024 - 07/2024 #linebreak() Production of low-voltage surge arresters #linebreak() #text(weight: "semibold")[Lyon] • Eurotect Electrical ] ], ) ] ] ] ) } #show: cv.with( author: "<NAME>", title: "CV de Enzo Le Van", date: datetime(year: 2024, month: 9, day: 23), main_color: gray, secondary_color: orange, third_color: light_gray, frames: ( cadre_photo(), cadre_nom(), cadre_contact(), cadre_recherche(), cadre_divers(), cadre_formation(), cadre_projet(), cadre_experience() ) )
https://github.com/TypstApp-team/typst
https://raw.githubusercontent.com/TypstApp-team/typst/master/tests/typ/layout/list.typ
typst
Apache License 2.0
// Test bullet lists. --- _Shopping list_ #list[Apples][Potatoes][Juice] --- - First level. - Second level. There are multiple paragraphs. - Third level. Still the same bullet point. - Still level 2. - At the top. --- - Level 1 - Level #[ 2 through content block ] --- - Top-level indent - is fine. --- - A - B - C - D --- // This works because tabs are used consistently. - A with 1 tab - B with 2 tabs --- // This doesn't work because of mixed tabs and spaces. - A with 2 spaces - B with 2 tabs --- // Edge cases. - Not in list -Nope --- // Alignment shouldn't affect marker #set align(horizon) - ABCDEF\ GHIJKL\ MNOPQR
https://github.com/typst/packages
https://raw.githubusercontent.com/typst/packages/main/packages/preview/acrotastic/0.1.0/README.md
markdown
Apache License 2.0
# Acrotastic (0.1.0) Manages all your acronyms for you. Acrotastics main features are clickable abbreviations that auto-expand on the first occurence, manual short and long forms, implicit or manual plural form support, and customizable index printing. ## Quick Start ``` #import "@preview/acrotastic:0.1.0": * #init-acronyms(( "WTP": ("Wonderful Typst Package","Wonderful Typst Packages"), )) Acrotastic is a #acr("WTP")! This #acr("WTP") enables easy acronym manipulation. ``` ## Usage ### Define acronyms First, define the acronyms in a dictionary, with the keys being the acronyms and the values being arrays of their definitions. If there is only a singular version of the definition, the array contains only one value. If there are both singular and plural versions, define the definition as an array where the first item is the singular definition and the second item is the plural. Then, initialize Acrotastic by passing the dictionay you just defined to the `#init-acronyms(...)` function. Here is a example of the `acronyms.typ` file: ``` #import "@preview/acrotastic:0.1.0": * #init-acronyms(( "NN": ("Neural Network"), "OS": ("Operating System",), "BIOS": ("Basic Input/Output System", "Basic Input/Output Systems"), )) ``` ### Call Acrotastic functions There is a large number of different functions to fit every use case. You will find an overview of all functions and their descriptions in the table below. | Function | Description | | ---------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | `#acr(...)` | On the first occurrence the long version of the abbreviation and the abbreviation itself are displayed in brackets. The next time only the abbreviation is displayed. | | `#acrpl(...)` | Same as `#acr(...)` but the plural will be diplayed. If no plural is defined, an 's' is added to the singular form. | | `#acrf(...)` | The acronym will be displayed as if it is the first time. This means that it is again shown in the long form and the abbreviation in brackets. | | `#acrfpl(...)` | Same as `#acrf(...)` but the plural will be displayed. If no plural is defined, an 's' is added to the singular form. | | `#acrs(...)` | Always displays the short form of the acronym. | | `#acrspl(...)` | Same as `#acrs(...)` but adds an 's' to the acronym for the plural form. | | `#acrl(...)` | Always displays the long form of the acronym. | | `#acrlpl(...)` | Same as `#acrl(...)` but the plural will be displayed. If no plural is defined, an 's' is added to the singular form. | | `#reset-acronym(...)` | Resets a specific acronym. The acronym will be expanded on the next use. | | `reset-all-acronyms()` | Resets all acronyms. The acronyms will be expanded on their next use. | You can alternatively use `#acr(...)`, `#acrf(...)`, `#acrs(...)` and `#acrl(...)` with `plural: true` to display the plural form. ``` #acr("BIOS", plural: true) ``` To deactivate the link to the abbreviations directory (for whatever reason), you can set `link: false`. ``` #acr("BIOS", link: false) ``` ### Print Abbreviations directory You can also print an index of all acronyms used in the document with the `#print-index()` function. There are some parameters for customization. | parameter | values | default | description | | ------------ | -------------------- | ----------------------- | ------------------------------------------------------------------------------------------------------------- | | title | string | "List of Abbreviations" | Heading of the acronym index | | level | number | 1 | Level of the heading | | sorted | "up", "down", "keep" | "up" | "Up" sorts alphabetically, "Down" sorts reversed alphabetically and "keep" uses the order from initialization | | delimiter | string | ":" | String to place after the acronym in the list | | acr-col-size | percentage | 20% | Size of the acronym column in percent | ## Possible Errors | Error | Solution | | ---------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------- | | Acronym is not a key in the acronyms dictionary. | Make sure that the acronym is defined in the dictionary passed to `#init-acronyms(dict)` | | No definitions found for acronym. Make sure it is defined in the dictionary passed to #init-acronyms(dict) | The acronym is in the dictionary, but has no correct definition. | | Definitions should be arrays of one or two strings. Definition of acronym is: | The acronym has a definition, but the definition doesn't have the right type. Make sure it's an array of one or two strings. | Moreover you have to be careful when using states. - For every acronym "ABC" that you define, the state named "acronym-state-ABC" is initialized and used. To avoid errors, do not try to use this state manually for other purposes. Similarly, the state named "acronyms" is reserved to Acrotastic. Please avoid using it. - The functions above are leveraging the state `display` function and only works if the return value is actually printed in the document. For more information on states, see the [Typst documentation on states](https://typst.app/docs/reference/introspection/state/). ## Contributing If you notice any bug or want to contribute a new feature, please open an issue or a pull request on the fork [Julian702/typst-packages](https://github.com/Julian702/typst-packages?tab=readme-ov-file) ## Acknowledgement Thanks to @Grisely who developed the [acrostiche package](https://typst.app/universe/package/acrostiche/) which was the basis for acrotastic.
https://github.com/Pablo-Gonzalez-Calderon/chic-header-package
https://raw.githubusercontent.com/Pablo-Gonzalez-Calderon/chic-header-package/main/lib/props.typ
typst
MIT License
/* * Chic-header - A package for Typst * <NAME> (c) 2023 * * props.typ -- The package's file for handling properties * given to the main function. * * This file is under the MIT license. For more * information see LICENSE on the package's main folder. */ #import "types.typ": * /* * chic-generate-props * * Obtains the correct properties to apply for a * particular type of pages (or all pages). * * Parameters: * - width: Width of the header and the footer * - options: Options given to apply into the header and footer */ #let chic-generate-props(width, options) = { // Set page props to default let props = ( header: none, footer: none, margin: (:), header-ascent: 30%, footer-descent: 30% ) // Set page additions. These are exclusive values used by chic package, // and not required by the ``#set page()`` instruction let additions = ( header-sep: none, footer-sep: none ) // Process each option and modify the page properties according to them for option in options { if chic-valid-type(option) { /* * Footer and Header */ if option.chic-type in ("header", "footer") { props.at(option.chic-type) = option.value /* * Separator */ } else if option.chic-type == "separator" { if option.on == "both" { additions.header-sep = option.value additions.footer-sep = option.value } else if option.on == "header" { additions.header-sep = option.value } else if option.on == "footer" { additions.footer-sep = option.value } /* * Height of footer and header */ } else if option.chic-type == "margin" { if option.on == "both" { props.margin.insert("top", option.value) props.margin.insert("bottom", option.value) } else if option.on == "header" { props.margin.insert("top", option.value) } else if option.on == "footer" { props.margin.insert("bottom", option.value) } /* * Offset of text inside footer and header */ } else if option.chic-type == "offset" { if option.on == "both" { props.header-ascent = option.value props.footer-descent = option.value } else if option.on == "header" { props.header-ascent = option.value } else if option.on == "footer" { props.footer-descent = option.value } } } } // Since we only have set the text of the footer and/or header, // if we have a separator to add, we must put it after that // text --ideally in a proper block element. And also we must // align and set all elements properly in the header and footer // If there's header text, apply the styles and separator if props.header != none { props.header = align( center, block( width: width )[ #props.header #if additions.header-sep != none { additions.header-sep } ] ) } // If there's footer text, apply the style and separator if props.footer != none { props.footer = align( center, block( width: width )[ #if additions.footer-sep != none { additions.footer-sep } #props.footer ] ) } return props }
https://github.com/noahjutz/AD
https://raw.githubusercontent.com/noahjutz/AD/main/uebungen/1/matrix_mult.typ
typst
#import "/config.typ": theme #import "@preview/cetz:0.2.2" #let m = 4 #let n = 2 #let p = 5 #let i = 1 #let j = 1 #cetz.canvas(length: 20pt, { import cetz.draw: * stroke(none) rect( (0, 0), (rel: (n, m)), name: "a" ) rect( (n + 1, m + 1), (rel: (p, n)), name: "b" ) rect( (n + 1, 0), (rel: (p, m)), name: "c" ) for elem in ("a", "b", "c") { group({ stroke(black) line( (rel: (.2, .2), to: elem + ".north-west"), (rel: (-.2, .2), to: elem + ".north-west"), (rel: (-.2, -.2), to: elem + ".south-west"), (rel: (.2, -.2), to: elem + ".south-west") ) line( (rel: (-.2, .2), to: elem + ".north-east"), (rel: (.2, .2), to: elem + ".north-east"), (rel: (.2, -.2), to: elem + ".south-east"), (rel: (-.2, -.2), to: elem + ".south-east") ) }) stroke(gray) grid(elem + ".north-west", elem + ".south-east") } group({ stroke(none) fill(theme.primary_trans) rect( (rel: (0, -i), to: "a.north-west"), (rel: (n, -1)), ) rect( (rel: (j, 0), to: "b.north-west"), (rel: (1, -n)), ) rect( (rel: (j, -i), to: "c.north-west"), (rel: (1, -1)), ) }) group({ stroke(black) cetz.decorations.flat-brace( (rel: (.2, -.6), to: "a.south-east"), (rel: (-.2, -.6), to: "a.south-west"), name: "brace_n1" ) content("brace_n1.content")[$n$] cetz.decorations.flat-brace( (rel: (.6, .2), to: "b.north-east"), (rel: (.6, -.2), to: "b.south-east"), name: "brace_n2" ) content("brace_n2.content")[$n$] cetz.decorations.flat-brace( (rel: (.6, .2), to: "c.north-east"), (rel: (.6, -.2), to: "c.south-east"), name: "brace_m" ) content("brace_m.content")[$m$] cetz.decorations.flat-brace( (rel: (.2, -.6), to: "c.south-east"), (rel: (-.2, -.6), to: "c.south-west"), name: "brace_p" ) content("brace_p.content")[$p$] content((rel: (0, .6), to: "a.north"))[$A$] content((rel: (-.6, 0), to: "b.west"))[$B$] content((rel: (j + .5, -i - .5), to: "c.north-west"))[$c_(i j)$] line( (rel: (-.6, -i - .5), to: "a.north-west"), (rel: (-.6, 0)), mark: (start: "straight"), name: "i" ) content((rel: (-.2, 0), to: "i.end"))[$i$] line( (rel: (j + .5, .6), to: "b.north-west"), (rel: (0, .6)), mark: (start: "straight"), name: "j" ) content((rel: (0, .2), to: "j.end"), anchor: "south")[$j$] }) })
https://github.com/miliog/typst-penreport
https://raw.githubusercontent.com/miliog/typst-penreport/master/main.typ
typst
MIT No Attribution
#import "./typst-penreport/penreport.typ": * #show: body => penreport( title: "Test Webseite", client: "Die Organisation", sharing: TLP.CLEAR, targets: ( ( name: "Test Website", additionalInfo: [ - https://example.org ] ), ), authors: ( ( name: "<NAME>", ), ), versions: ( ( date: datetime(year: 2020, month: 10, day: 4), name: "<NAME>", comment: "First draft", ), ( major: true, date: datetime(year: 2020, month: 10, day: 4), name: "<NAME>", comment: "Release", ), ), draft: true, body, ) #vuln( title: "Cross-Site Scripting", target: "Test Website", severity: Severity.High, type: 79 )[ The "Test Website" allows unfiltered user input to be rendered on its search results page, leading to a persistent Cross-Site Scripting (XSS) vulnerability. Specifically, when a user submits a search query, the input is echoed back on the page without proper sanitization. An attacker can craft a malicious link containing a script payload, and once clicked by an unsuspecting user, it can lead to session hijacking, defacement, or potentially more severe actions. To demonstrate: + Visit https://example.org/search + In the search bar, input ```js <script>alert('XSS')</script>``` and submit. + The alert box pops up, indicating the vulnerability. This poses a risk as it can be exploited to run any arbitrary JavaScript code in the context of the victim's browser session. ][ - Always validate and sanitize user input. Ensure that any user-provided data is treated as untrusted and is sanitized properly before rendering it on the page. - Use Content Security Policy (CSP) headers to reduce the risk of XSS attacks. This can limit the sources and types of content that can be executed in the web page context. - Ensure that all user input is properly encoded when being output to the page. This will prevent special characters from being interpreted as code. - Adopt web application firewalls (WAFs) or other security mechanisms that can detect and block malicious input. Regularly review and update web applications to patch any vulnerabilities and to stay ahead of potential security threats. ] #vuln( title: "SQLi", target: "Test Website", severity: Severity.High, type: 89 )[][] #vuln( title: "CSP not implemented", target: "Test Website", severity: Severity.Informational, type: 1021, )[][] #vuln( title: "Huh", target: "Test Website", )[][]
https://github.com/piepert/grape-suite
https://raw.githubusercontent.com/piepert/grape-suite/main/README.md
markdown
MIT License
# Grape Suite The grape suite is a suite consisting of following templates: * exercises (for exams, homework, etc.) * seminar papers * slides (using polylux) ## Exercises ### Setup ```typ #import "@preview/grape-suite:1.0.0": exercise #import exercise: project, task, subtask #show: project.with( title: "Lorem ipsum dolor sit", university: [University], institute: [Institute], seminar: [Seminar], abstract: lorem(100), show-outline: true, author: "<NAME>", show-solutions: false ) ``` ### API-Documentation | `project` | | | :--------------------------------------- | :----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | | `no` | optional, number, default: `none`, number of the sheet in the series | | `type` | optional, content, default: `[Exam]`, type of the series, eg. exam, homework, protocol, ... | | `title` | optional, content, default: `none`, title of the document: if none, then generated from no, type and suffix-title | | `suffix-title` | optional, content, default: `none`, used if title is none to generate the title of the document | | `show-outline` | optional, bool, default: `false`, show outline after title iff true | | `abstract` | optional, content, default: `none`, show abstract between outline and title | | `document-title` | optional, content, default: `none`, shown in the upper right corner of the page header: if none, `title` is used | | `show-hints` | optional, bool, default: `false`, generate hints from tasks iff true | | `show-solutions` | optional, bool, default: `false`, generate solutions from tasks iff true | | `show-namefield` | optional, bool, default: `false`, show namefield at the end of the left header iff true | | `namefield` | optional, content, default: `[Name:]`, content shown iff `show-namefield` | | `show-timefield` | optional, bool, default: `false`, show timefield at the end of right header iff true | | `timefield` | optional, function, default: `(time) => [Time: #time min.]`, to generate the content shown as the timefield iff `show-timefield` is true | | `max-time` | optional, number, default: `0`, time value used in the `timefield` function generateor | | `show-lines` | optional, bool, default: `false`, draw automatic lines for each task, if `lines` parameter of `task` is set | | `show-point-distribution-in-tasks` | optional, bool, default: `false`, show point distribution after tasks iff true | | `show-point-distribution-in-solutions` | optional, bool, default: `false`, show point distributions after solutions iff true | | `solutions-as-matrix` | optional, bool, default: `false`, show solutions as a matrix iff true, **mind that**: now the solution parameter of task expects a list of 2-tuples, where the first element of the 2-tuple is the amount of points, a number and the second element is content, how to achieve all points | | `university` | optional, content, default: `none` | | `faculty` | optional, content, default: `none` | | `institute` | optional, content, default: `none` | | `seminar` | optional, content, default: `none` | | `semester` | optional, content, default: `none` | | `docent` | optional, content, default: `none` | | `author` | optional, content, default: `none` | | `date` | optional, datetime, default: `datetime.today()` | | `header` | optional, content, default: `none`, overwrite page header | | `header-right` | optional, content, default: `none`, overwrite right header part | | `header-middle` | optional, content, default: `none`, overwrite middle header part | | `header-left` | optional, content, default: `none`, overwrite left header part | | `footer` | optional, content, default: `none`, overwrite footer part | | `footer-right` | optional, content, default: `none`, overwrite right footer part | | `footer-middle` | optional, content, default: `none`, overwrite middle footer part | | `footer-left` | optional, content, default: `none`, overwrite left footer part | | `task-type` | optional, content, default: `[Task]`, content shown in task title box before numbering | | `extra-task-type` | optional, content, default: `[Extra task]`, for tasks where the `extra` parameter is true, content shown in title box before numbering | | `box-task-title` | optional, content, default: `[Task]`, shown as the title of a task box used by the `slides` library | | `box-hint-title` | optional, content, default: `[Hint]`, shown as the title of a tasks colored hint box | | `box-solution-title` | optional, content, default: `[Solution]`, shown as the title of a tasks colored solution box | | `box-definition-title` | optional, content, default: `[Definition]`, shown as the title of a definition box used by the `slides` library | | `box-notice-title` | optional, content, default: `[Notice]`, shown as the title of a notice box used by the `slides` library | | `box-example-title` | optional, content, default: `[Example]`, shown as the title of a example box used by the `slides` library | | `hint-type` | optional, content, default: `[Hint]`, title of a tasks hint version | | `hints-title` | optional, content, default: `[Hints]`, title of the hints section | | `solution-type` | optional, content, default: `[Suggested solution]`, title of a tasks solution version | | `solutions-title` | optional, content, default: `[Suggested solutions]`, title of the solutions section | | `solution-matrix-task-header` | optional, content, default: `[Tasks]`, first column header of solution matrix, column contains the reasons on how to achieve the points | | `solution-matrix-achieved-points-header` | optional, content, default: `[Points achieved]`, second column header of solution matrix, column contains the points the one achieved | | `show-solution-matrix-comment-field` | optional, bool, default: `false`, show comment field in solution matrix | | `solution-matrix-comment-field-value` | optional, content, default: `[*Note:* #v(0.5cm)]`, value of solution matrix comment fields | | `distribution-header-point-value` | optional, content, default: `[Point]`, first row of point distribution, used to indicate the points needed to get a specific grade | | `distribution-header-point-grade` | optional, content, default: `[Grade]`, second row of point distribution | | `message` | optional, function, default: `(points-sum, extrapoints-sum) => [In sum #points-sum + #extrapoints-sum P. are achievable. You achieved #box(line(stroke: purple, length: 1cm)) out of #points-sum points.]`, used to generate the message part above the point distribution | | `grade-scale` | optional, array, default: `(([excellent], 0.9), ([very good], 0.8), ([good], 0.7), ([pass], 0.6), ([fail], 0.49))`, list of grades and percentage of points to reach that grade | | `page-margins` | optional, margins, default: `none`, overwrite page margins | | `fontsize` | optional, size, default: `11pt`, overwrite font size | | `show-todolist` | optional, bool, default: `true`, show list of usages of the `todo` function after the outline | | `body` | content, document content | `task` creates a task element in an exercise project. | `task` | | | :----------------- | :------------------------------------------------------------------------------------------------------------------------------------------ | | `lines` | optional, number, default: `0`, number of lines to draw if `show-lines` in exercise's `project` is set to `true` | | `points` | optional, number, default: `0`, number of points achievable | | `extra` | optional, bool, default: `false`, determines if the task is obligatory (`false`) or additional (`true`) | | `numbering-format` | optional, function, default: `none`, | | `title` | content, title of the task | | `instruction` | content, instruction of the task, highlighted | | `..args` | 1: content, task body; 2: content, task solution, not highlighted (see `solution-as-matrix` of exercise's `project`), 3: content, task hint | `subtask` creates a part of a task. Its points are added to the parent task. ***Subtasks are to be use inside of the task's body or inside of another subtask's body.*** | `subtask` | | | :------------ | :-------------------------------------------------------------------------------------------------------------------------------------- | | `points` | optional, number, default: `0`, points achievable, adds to a tasks point | | `tight` | optional, bool, default: `false`, enum style | | `markers` | optional, array, default: `("1.", "a)")`, numbering format for each level, fallback is `i.` | | `show-points` | optional, bool, default: `true`, show points next to subtask's body iff `true` | | `counter` | optional, counter, default: `none`, change number styled by the numbering format; if `none`, each level has an incrementel auto counter | | `content` | content, subtask body | ## Seminar paper ### Setup ```typ #import "@preview/grape-suite:1.0.0": seminar-paper #show: seminar-paper.project.with( title: "Die Intensionalität von dass-Sätzen", subtitle: "Intensionale Kontexte in philosophischen Argumenten", university: [Universität Musterstadt], faculty: [Exemplarische Fakultät], institute: [Institut für Philosophie], docent: [Dr. phil. <NAME>], seminar: [Beispielseminar], submit-to: [Eingereicht bei], submit-by: [Eingereicht durch], semester: german-dates.semester(datetime.today()), author: "<NAME>", email: "<EMAIL>", address: [ 12345 Musterstadt \ Musterstraße 67 ] ) ``` ### Documentation | `project` | | | :------------------------------------- | :-------------------------------------------------------------------------------------------- | | `title` | optional, content, default: `none`, title used on the title page | | `subtitle` | optional, content, default: `none`, subtitle used on title page | | `submit-to` | optional, content, default: `"Submitted to"`, title for the assignees's section | | `submit-by` | optional, content, default: `"Submitted by"`, title for the assigned's section | | `university` | optional, content, default: `"UNIVERSITY"` | | `faculty` | optional, content, default: `"FACULTY"` | | `institute` | optional, content, default: `"INSTITUTE"` | | `seminar` | optional, content, default: `"SEMINAR"` | | `semester` | optional, content, default: `"SEMESTER"` | | `docent` | optional, content, default: `"DOCENT"` | | `author` | optional, content, default: `"AUTHOR"` | | `email` | optional, content, default: `"EMAIL"` | | `address` | optional, content, default: `"ADDRESS"` | | `title-page-part` | optional, content, default: `none`, overwrite date, assignee and assigned section | | `title-page-part-submit-date` | optional, content, default: `none`, overwrite date section | | `title-page-part-submit-to` | optional, content, default: `none`, overwrite assignee section | | `title-page-part-submit-by` | optional, content, default: `none`, overwrite assigned section | | `date` | optional, datetime, default: `datetime.today()` | | `date-format` | optional, function, default: `(date) => date.display("[day].[month].[year]")` | | `header` | optional, content, default: `none`, overwrite page header | | `header-right` | optional, content, default: `none`, overwrite right header part | | `header-middle` | optional, content, default: `none`, overwrite middle header part | | `header-left` | optional, content, default: `none`, overwrite left header part | | `footer` | optional, content, default: `none`, overwrite footer part | | `footer-right` | optional, content, default: `none`, overwrite right footer part | | `footer-middle` | optional, content, default: `none`, overwrite middle footer part | | `footer-left` | optional, content, default: `none`, overwrite left footer part | | `show-outline` | optional, bool, default: `true`, show outline | | `show-declaration-of-independent-work` | optional, bool, default: `true`, show German declaration of independent work | | `page-margins` | optional, margins, default: `none`, overwrite page margins | | `fontsize` | optional, size, default: `11pt`, overwrite fontsize | | `show-todolist` | optional, bool, default: `true`, show list of usages of the `todo` function after the outline | | `body` | content, document content | | `sidenote` | | | :--------- | :------------------------------------------------------------------------------------------------------ | | `body` | sidenote content, which is a block with 3cm width and will be displayed in the right margin of the page | ## Slides ### Setup ```typ #import "@preview/grape-suite:1.0.0": slides #import slides: * #show: slides.with( no: 1, series: [Logik-Tutorium], title: [Organisatorisches und Einführung in die Logik], author: "<NAME>", email: link("mailto:<EMAIL>"), ) ``` ### Documentation | `slides` | | | :--------------------- | :------------------------------------------------------------------------------------------------------------------------------------------------ | | `no` | optional, number, default: `0`, number in the series | | `series` | optional, content, default: `none`, name of the series | | `title` | optional, content, default: `none`, title of the presentation | | `topics` | optional, array, default: `()`, topics of the presentation | | `author` | optional, content, default: `none`, author | | `email` | optional, content, default: `none`, author's email | | `head-replacement` | optional, content, default: `none`, replace head on title slide with given content | | `title-replacement` | optional, content, default: `none`, replace title below head on title slide with given content | | `footer` | optional, content, default: `none`, replace footer on slides with given content | | `page-numbering` | optional, function, default: `(n, total) => {...}`, function that creates the page numbering (where `n` is the current, `total` is the last page) | | `show-semester` | optional, bool, default: `true`, show name of the semester (e.g. "SoSe 24") | | `show-date` | optional, bool, default: `true`, show date in german format | | `show-outline` | optional, bool, default: `true`, show outline on the second slide | | `box-task-title` | optional, content, default: `[Task]`, shown as the title of a slide's task box | | `box-hint-title` | optional, content, default: `[Hint]`, shown as the title of a slide's tasks colored | | `box-solution-title` | optional, content, default: `[Solution]`, shown as the title of a slide's tasks colored | | `box-definition-title` | optional, content, default: `[Definition]`, shown as the title of a slide's definition box | | `box-notice-title` | optional, content, default: `[Notice]`, shown as the title of a slide's notice box | | `box-example-title` | optional, content, default: `[Example]`, shown as the title of a slide's example box | | `date` | optional, datetime, default: `datetime.today()` | | `show-todolist` | optional, bool, default: `true`, show list of usages of the `todo` function after the outline | | `show-title-slide` | optional, bool, default: `true`, show title slide | | `show-author` | optional, bool, default: `true`, show author name on title slide | | `show-footer` | optional, bool, default: `true`, show footer on slides | | `show-page-numbers` | optional, bool, default: `true`, show page numbering | | `outline-title-text` | optional, content, default: `"Outline"`, title for the outline | | `body` | content, document content | * `slide`, `pause`, `only`, `uncover`: imported from polylux ### Todos The following functions can be imported from `slides`, `exercise` and `seminar-paper`: - `todo(content, ...)` - create a highlighted inline todo-note - `list-todos()` - create list of all todo-usages with page of usage and content - `hide-todos()` - hides all usages of `todo()` in the document ### Elements The following functions can be imported from `slides`, `exercise` and `seminar-paper`: `definition` # Changelog ## 1.0.0 New: - `todo`, `list-todos`, `hide-todos` in `todo.typ`, importable from `slides`, `exercise.project` and `seminar-paper.project` - `show-todolist` attribute in above templates - `ignore-points` attribute in `task` and `subtask` of exercises, so that their points won't be shown in the solution matrix or point distribution - comment field and a standard-value for solution matrix via `show-solution-matrix-comment-field` and `solution-matrix-comment-field-value` options in `exercise.project` - optional parameter `type` in `slides.task` - new parameters in `sllides.slides`: - `head-replacement` - `title-replacement` - `footer` - `page-numbering` - `show-title-slide` - `show-author` (on title slide) - `show-date` - `show-footer` - `show-page-numbers` - optional parameter `show-outline` in `seminar-paper.project` Changes: - `dates.typ` becomes `german-dates.typ` Fixes: - remove forced German from the slides template - long headings are now properly aligned - subtask counter now resets for each part of task **Breaking Changes:** - `dates` becomes `german-dates` - changed all `with-outline` to `show-outline`
https://github.com/LauHuiQi0920/3007DataVisualizationTeamCyan
https://raw.githubusercontent.com/LauHuiQi0920/3007DataVisualizationTeamCyan/main/_extensions/_extensions/poster/typst-template.typ
typst
#let poster( // The poster's size. size: "'36x24' or '48x36''", // The poster's title. title: "Paper Title", // A string of author names. authors: "Author Names (separated by commas)", // Department name. departments: "Department Name", // University logo. univ_logo: "Logo Path", // Footer text. // For instance, Name of Conference, Date, Location. // or Course Name, Date, Instructor. footer_text: "Footer Text", // Any URL, like a link to the conference website. footer_url: "Footer URL", // Email IDs of the authors. footer_email_ids: "Email IDs (separated by commas)", // Color of the footer. footer_color: "Hex Color Code", // Text color of the footer. footer_text_color: "Hex Color Code", // DEFAULTS // ======== // For 3-column posters, these are generally good defaults. // Tested on 36in x 24in, 48in x 36in, and 36in x 48in posters. // For 2-column posters, you may need to tweak these values. // See ./examples/example_2_column_18_24.typ for an example. // Any keywords or index terms that you want to highlight at the beginning. keywords: (), // Number of columns in the poster. num_columns: "3", // University logo's scale (in %). univ_logo_scale: "50", // University logo's column size (in in). univ_logo_column_size: "10", // Title and authors' column size (in in). title_column_size: "20", // Poster title's font size (in pt). title_font_size: "48", // Authors' font size (in pt). authors_font_size: "36", // Footer's URL and email font size (in pt). footer_url_font_size: "30", // Footer's text font size (in pt). footer_text_font_size: "40", // The poster's content. body ) = { // Set the body font. set text(font: "STIX Two Text", size: 16pt) let sizes = size.split("x") let width = int(sizes.at(0)) * 1in let height = int(sizes.at(1)) * 1in univ_logo_scale = int(univ_logo_scale) * 1% title_font_size = int(title_font_size) * 1pt authors_font_size = int(authors_font_size) * 1pt num_columns = int(num_columns) univ_logo_column_size = int(univ_logo_column_size) * 1in title_column_size = int(title_column_size) * 1in footer_url_font_size = int(footer_url_font_size) * 1pt footer_text_font_size = int(footer_text_font_size) * 1pt // Configure the page. // This poster defaults to 36in x 24in. set page( width: width, height: height, margin: (top: 1in, left: 2in, right: 2in, bottom: 2in), footer: [ #set align(center) #set text(32pt, white) #block( fill: rgb(228,51,44), width: 100%, inset: 20pt, radius: 10pt, [ //#text(font: "Courier", size: footer_url_font_size, footer_url) //#h(1fr) #text(size: footer_text_font_size, smallcaps(footer_text)) #h(1fr) #text(font: "Courier", size: footer_url_font_size, footer_email_ids) ] ) ] ) // Configure equation numbering and spacing. set math.equation(numbering: "(1)") show math.equation: set block(spacing: 0.65em) // Configure lists. set enum(indent: 10pt, body-indent: 9pt) set list(indent: 10pt, body-indent: 9pt) // Configure headings. //set heading(numbering: "I.A.1.") show heading: it => locate(loc => { // Find out the final number of the heading counter. let levels = counter(heading).at(loc) let deepest = if levels != () { levels.last() } else { 1 } set text(24pt, weight: 400) if it.level == 1 [ // First-level headings are centered smallcaps. #set align(center) #set text({ 32pt }) #show: smallcaps #v(50pt, weak: true) #if it.numbering != none { numbering("I.", deepest) h(7pt, weak: true) } #it.body #v(35.75pt, weak: true) #line(length: 100%) ] else if it.level == 2 [ // Second-level headings are run-ins. #set text(style: "italic") #v(32pt, weak: true) #if it.numbering != none { numbering("i.", deepest) h(7pt, weak: true) } #it.body #v(10pt, weak: true) ] else [ // Third level headings are run-ins too, but different. #if it.level == 3 { numbering("1)", deepest) [ ] } _#(it.body):_ ] }) // Arranging the logo, title, authors, and department in the header. align(center, grid( rows: 2, columns: (title_column_size, univ_logo_column_size), column-gutter: 0pt, row-gutter: 50pt, text(title_font_size, title + "\n\n") + text(authors_font_size, emph(authors) + " (" + departments + ") "), image(univ_logo, width: univ_logo_scale), ) ) // Start three column mode and configure paragraph properties. show: columns.with(num_columns, gutter: 64pt) set par(justify: true, first-line-indent: 0em) show par: set block(spacing: 0.65em) // Display the keywords. if keywords != () [ #set text(24pt, weight: 400) #show "Keywords": smallcaps *Keywords* --- #keywords.join(", ") ] // Display the poster's contents. body }
https://github.com/typst/packages
https://raw.githubusercontent.com/typst/packages/main/packages/preview/unichar/0.1.0/ucd/block-1380.typ
typst
Apache License 2.0
#let data = ( ("ETHIOPIC SYLLABLE SEBATBEIT MWA", "Lo", 0), ("ETHIOPIC SYLLABLE MWI", "Lo", 0), ("ETHIOPIC SYLLABLE MWEE", "Lo", 0), ("ETHIOPIC SYLLABLE MWE", "Lo", 0), ("ETHIOPIC SYLLABLE SEBATBEIT BWA", "Lo", 0), ("ETHIOPIC SYLLABLE BWI", "Lo", 0), ("ETHIOPIC SYLLABLE BWEE", "Lo", 0), ("ETHIOPIC SYLLABLE BWE", "Lo", 0), ("ETHIOPIC SYLLABLE SEBATBEIT FWA", "Lo", 0), ("ETHIOPIC SYLLABLE FWI", "Lo", 0), ("ETHIOPIC SYLLABLE FWEE", "Lo", 0), ("ETHIOPIC SYLLABLE FWE", "Lo", 0), ("ETHIOPIC SYLLABLE SEBATBEIT PWA", "Lo", 0), ("ETHIOPIC SYLLABLE PWI", "Lo", 0), ("ETHIOPIC SYLLABLE PWEE", "Lo", 0), ("ETHIOPIC SYLLABLE PWE", "Lo", 0), ("ETHIOPIC TONAL MARK YIZET", "So", 0), ("ETHIOPIC TONAL MARK DERET", "So", 0), ("ETHIOPIC TONAL MARK RIKRIK", "So", 0), ("ETHIOPIC TONAL MARK SHORT RIKRIK", "So", 0), ("ETHIOPIC TONAL MARK DIFAT", "So", 0), ("ETHIOPIC TONAL MARK KENAT", "So", 0), ("ETHIOPIC TONAL MARK CHIRET", "So", 0), ("ETHIOPIC TONAL MARK HIDET", "So", 0), ("ETHIOPIC TONAL MARK DERET-HIDET", "So", 0), ("ETHIOPIC TONAL MARK KURT", "So", 0), )
https://github.com/td-org-uit-no/assignment-template-typst
https://raw.githubusercontent.com/td-org-uit-no/assignment-template-typst/main/main.typ
typst
#import "template.typ": * #show: template.with( title: [Assignment template], abstract: [ This document presents a number of guidelines to use when writing a report for assignments at UiT and may serve as a template for how to write it using Typst for typesetting. The template is meant to give some general tips on what you should and should not be writing in your report. You may move or cut sections and/or subsections depending on the given assignment or your needs. While writing this report template, I enjoyed reading <NAME>'s "The Craft of Scientific Writing". I recommend having it by your side when you are stuck writing- it happens to all of us @AlleyMichael2018TCoS. #v(9pt) Make sure you clean up the template text before submitting your report. ;) #v(9pt) ], header: [INF-XXXX Assignment X #datetime.today().display()], authors: ( ( name: "Firstname Middlename(s) Lastname", organization: [UiT Arctic University of Norway], location: [Tromsø, Norway], email: "<EMAIL>", git: "abc", ), ( name: "Firstname Middlename(s) Lastname", organization: [UiT Arctic University of Norway], location: [Tromsø, Norway], email: "<EMAIL>", git: "def", ), ), index-terms: ( "Assignment submission", "Scientific writing", "Typesetting", "Template", ), bibliography-file: "refs.bib", ) = Introduction <sec:introduction> This section should be brief. Describe the assignment and the requirements in your own words. Avoid listing the requirements directly. There are many opinions on first person speaking when writing a technical report. In general a: + First person report is good at: - Expressing individual work, personal opinions and ideas. - Creates an informal and personal tone. - Reduces cluttering of your writing + An objective report is good at: - Emphasizing your work It's not uncommon to mix these in your reports, and people like Einstein, Feynman, and Curie frequently used both forms in their texts. #v(9pt) Here are some examples on how to start your introduction: + This report describes the design and implementation of a list ADT using a linked list. It will go into detail about the design choices made, and discuss benefits and tradeoffs of those choices. + Boids is a computer model created by <NAME> that simulates the flocking behavior of birds @TanenbaumAndrewS.2024Mos. In this report, we present an implementation of the model using the Python programming language. + SQL is a widely used querying language used to process queries into table-based databases. This text details the implementation of a simplified server that implements a subset of the SQL language built over SQLite. == Outline <subsec:outline> The rest of this paper is organized as follows: *@sec:technical_background* outlines concepts and background information relevant to the rest of the paper. *@sec:design* is a high-level description of your solution to the assignment. *@sec:implementation* goes into a detailed explanation of your implementation that you described in Section *@sec:design*. *@sec:experiments_and_results* discusses the methodology for your experiments and includes results from your experiments. *@sec:discussion* is the most important section in a report; this is where you show that you understand the theory behind your solution and can reflect on it with the choices you made. *@sec:conclusion* concludes and summarizing possible future work. = Theoretical Background <sec:technical_background> This section is where you provide information on the technical aspects of your design. You can usually assume that the theory required to solve the assignment is know to the reader, but if you want to clarify terms or go into detail about specific points in the theory (if you are doing something slightly different, or a detail of it is of notable importance to your implementation), consider writing a few words about it here. #v(9pt) We want you to write a short section explaining the most important background information required to read and understand the rest of the report. #v(12pt) == Virtual Memory <subsec:virtualmemory> The basic concept of virtual memory is that you map the virtual address the processes use to a unique physical address in physical memory. This means that two processes can access the same virtual address in their address space but get two different results since the addresses point to different places in the physical memory. This again means that each process can use all of its 32-bit address space while still ensuring that no other processes can access its data @TanenbaumAndrewS.2024Mos. #v(9pt) Using figures in technical backgrounds is encouraged, if that makes the concept easier to explain. Usually, you want figures/images as scaleable vector graphics\(SVG), especially for your graphs. Sometimes that is not doable, and you can use portable network graphics\(PNG) or similar. #v(9pt) The following snippet shows how to import figures. #v(9pt) #figure( image("figures/jetson_nx.png", width: 90%), caption: [Block diagram of the Jetson Xavier NX], ) <fig:block_diagram> #figure( image("figures/NVSD_VDD_IN.svg", width: 90%), caption: [Total power consumption compared between NAS and SD-Card. / _Note_ the NAS-experiment did not complete in time, and the measurements for the NAS is fit to the SD-card measurements], ) <fig:local_nas_sd_compare> = Design <sec:design> This is where you describe how you solved the assignment, at least on paper. Give a high-level view of your design.This is where you describe how you solved the assignment, at least on paper. Give a high-level view of your design. As a rule of thumb, if you find yourself describing code, you need to go to a higher abstraction level. If you for some reson want to write code you can use the `raw` block as seen in the following example. ```c /* Simple copy from src to dest */ char *strcpy(char *restrict dest, const char *restrict src) { char *destorig = dest; for (;; dest++, src++) { char copiedchar = *dest = *src; if (!copiedchar) break; } printf("Strings are green\n"); return destorig; } ``` #v(12pt) This section is also a good place to put illustrations to enhance the text. There are multiple tools out there to create good illustrations. draw.io is a strong tool that can be run in a browser. There are stronger, free tools, such as Yed Graph Editor, for more advanced users. #v(12pt) While illustrations are good at making your report clearer and look more polished, avoid using them to fill up space if you can convey the same information clearly using just text. #v(12pt) Examples of what the design section should cover: - The interface of the list ADT supports six methods. These are ```c create_list()```, ```c destroy_list()```, ```c add_list()```, ```c remove_list()```, ```c iterate_list()``` and ```c sort_list()```. When a list is created, it is provided with a comparator method that is used to handle sorting. - The Boids simulation consists of a set of entities called Boids, Each boid moves independently according to a set of criteria, specified in three rules. Firstly, boids avoid crashing into obstacles, including other boids. Secondly, boids attempt to maintain the same speed and heading as nearby boids. Finally, all boids attempt to move closer to each other to form a cohesive flock. - The server parses incoming data requests into an SQL query and runs them on its database. The result is then processed into JSON and returned to the client. #v(12pt) Remember to avoid low-level details! An expert should in theory be able to implement your design in any programming language based on what you write in this section. = Implementation <sec:implementation> This is where you go into detail about your specific implementation. Questions you should answer here are things such as ``How does your implementation match your design?'' and ``Are there any bugs, and do you have any ideas about what may be causing them?''. What sort of difficulties did you experience when working, and how did you overcome them? If you found a clever solution to the problem, this is also the place to write about that. == Technical Details <subsec:technical_details> You may want to include a short section giving high-level details about your implementation, such as the programming language used and other information you find relevant for your report. In most cases however, this section is unnecessary, as the assignment usually decides those details for you. Even if you have the freedom of choice, consider whether this information is really relevant to the report, which should avoid low-level implementation details most of the time. = Experiments and Results <sec:experiments_and_results> A core pillar of computer science is testing. In this section, you should include your methodology for testing your implementation. How do you know your implementation meets the requirements? What sort of performance metrics have you chosen to benchmark your solution, and how did you go about performing tests to gather those metrics? #v(12pt) You should present the results of your tests here, either using an illustration and/or a table of results. These will be valuable in the discussion section. The following is an example for how to format a table of results in Typst. #v(12pt) #figure( table( columns: 7, align: center + horizon, /* --- header --- */ table.header( table.cell([*Classifier*], rowspan: 2), table.cell([*Precision*], colspan: 6), [1], [2], [3], [1&2], [1&3], [All], ), /* -------------- */ /* --- body --- */ [Perceptron], [0.78], [0.82], [0.24], [0.81], [0.77], [0.83], [Decision Tree], [0.65], [0.79], [0.56], [0.75], [0.65], [0.73], [One-Class SVM], [0.74], [0.72], [0.50], [0.80], [0.73], [0.85], [Isolation Forest], [0.54], [0.51], [0.52], [0.53], [0.54], [0.53], /* -------------- */ ), caption: [Precision results of classifiers for different feature sets], ) = Discussion <sec:discussion> The discussion section is the most important section in a report, This is where you show that you understand the theory behind the solution, and also a chance to argue the pros and cons of your solution. You should discuss about the results of your measurements and why you think they are the way they are. Also bring up tradeoffs, and why you made the choices you did; show that you understand the alternatives, and why they may be a good idea (or not) for the particular problem the assignment asked you to solve. #v(12pt) Here is an example of a discussion subsection: == Recovery of a simulated crash <subsec:recovery_simulated_crash> When a node recovers from a simulated crash, it will check if its neighbors are still connected to it. If not, it will try to start an internal join to its previous successor. This works as long as the previous successor is still active in the network. The case where the previous successor is not active is not dealt with, and will result in the node not being able to recover. = Conclusion <sec:conclusion> Here you sum up the report and reiterate the results. Does not need to be very long, a few sentences is fine.
https://github.com/Myriad-Dreamin/tinymist
https://raw.githubusercontent.com/Myriad-Dreamin/tinymist/main/crates/tinymist-query/src/fixtures/type_check/fn_named3.typ
typst
Apache License 2.0
#let fun() = { return 2 } #let foo(b: fun()) = b #let x = foo()
https://github.com/chen-qingyu/Typst-Code
https://raw.githubusercontent.com/chen-qingyu/Typst-Code/master/complex_power.typ
typst
Calculate $u = a + b i$ to the $v = c + d i$ power: $z=u^v$. $ z =& u^v \ \ =& (a + b i)^(c + d i) \ \ & "let" m = sqrt(a^2 + b^2) = abs(u), space w = arctan(b / a) = arg(u) \ \ =& (m e^(i w))^(c + d i) \ \ =& (e^(ln m) e^(i w))^(c + d i) \ \ =& e^((ln m + i w)(c + d i)) \ \ =& e^((c ln m - d w) + i(c w + d ln m)) \ \ & "let" theta = c w + d ln m \ \ =& e^((c ln m - d w) + i theta) \ \ =& e^(c ln m - d w) e^(i theta) \ \ =& e^(c ln m - d w)(cos theta + i sin theta) \ \ =& (m^c e^(-d w))(cos theta + i sin theta) \ \ & "let" r = m^c e^(-d w) \ \ =& r(cos theta + i sin theta) \ \ =& underbrace(r cos theta, "real part") + underbrace(r sin theta, "imag part") space i \ \ & r = abs(u)^c e^(-d arg(u)), space theta = c arg(u) + d ln abs(u) $
https://github.com/ufodauge/master_thesis
https://raw.githubusercontent.com/ufodauge/master_thesis/main/src/template/utils/theorems.typ
typst
MIT License
#import "@preview/ctheorems:1.1.0": * // theorems #let theorem = thmbox( "theorem", "定理", fill: rgb("#eeffee") ) #let corollary = thmplain( "corollary", "系", base : "theorem", titlefmt: strong ) #let definition = thmbox( "definition", "定義", inset: ( x: 1.2em, top: 1em ) ) #let example = thmplain( "example", "例" ).with(numbering: none) #let proof = thmplain( "proof", "証明", base: "theorem", bodyfmt: body => [#body #h(1fr) $square$], ).with(numbering: none)
https://github.com/Myriad-Dreamin/tinymist
https://raw.githubusercontent.com/Myriad-Dreamin/tinymist/main/docs/tinymist/frontend/common-finding-executable.typ
typst
Apache License 2.0
== Finding Executable <finding-executable> To enable LSP, you must install `tinymist`. You can find `tinymist` by: - Night versions available at #link("https://github.com/Myriad-Dreamin/tinymist/actions")[GitHub Actions]. - Stable versions available at #link("https://github.com/Myriad-Dreamin/tinymist/releases")[GitHub Releases]. \ If you are using the latest version of #link("https://codeberg.org/meow_king/typst-ts-mode")[typst-ts-mode], then you can use command `typst-ts-lsp-download-binary` to download the latest stable binary of `tinymist` at `typst-ts-lsp-download-path`. - Build from source by cargo. You can also compile and install *latest* `tinymist` by #link("https://www.rust-lang.org/tools/install")[Cargo];. ```bash cargo install --git https://github.com/Myriad-Dreamin/tinymist --locked tinymist ```
https://github.com/ren-ben/typst-notes
https://raw.githubusercontent.com/ren-ben/typst-notes/master/math/mehrere_variablen/mehrerevariablen.typ
typst
#import "@preview/sourcerer:0.2.1": code #import "@preview/physica:0.9.3": * #align(center, text(24pt)[ *Definition und Visualisierung* ]) #align(center)[ <NAME> \ Technologisches Gewerbemuseum \ #link("mailto:<EMAIL>") ] #set heading(numbering: "1.") #show par: set block(spacing: 0.65em) #set par( first-line-indent: 1em, justify: true, ) #pagebreak() #outline() #pagebreak() #show: rest => columns(2, rest) = Definition und Visualisierung == Def. n unabhängige Variablen Unter einer reellen Funktion $f$ in $n$ unabhängigen Variablen versteht man eine Zuordnungsvorschrift $f$, die jedem geordneten n-tupel $(x_1, x_2, ..., x_n)$ reeller Zahlen aus einer Definitionsmenge D *genau eine* reelle Zahl $z$ aus einer Wertemenge W zuordnet: $ f: (x_1, x_2, ..., x_n) |-> z=f(x_1,x_2, ..., x_n) $ == Def. zwei unabhängige Variablen Unter einer reellen Funktionen $f$ in zwei unabhängigen Variablen vesteht man eine Zuordnungsvorschrift $f$, die jedem geordneten Zahlenpaar $(x,y)$ reeller Zahlen *genau eine* reele Zahl $z$ zuordnet: $ f: (x,y) |-> z ) f(x,y) $ x und y heißen unabhängige Variablen oder Argumente der Funktion, $z$ heißt abhängige Variable oder Funktionswert. Man schreibt auch: $z=f(x,y)$ == Visualisierung in zwei Variablen #image( "./imgs/3d_function.png" ) Wenn im dreidimensionalen Raum jedem Punkt der x-y Ebene eine Höhe und daher einen Raumpunkt zugeordnet wird, erhält man insgesamt eine *Ebene* === Aufgabe 2.11) ==== a) $ f(a,b) = a times b^2 +c $ Die unabhängigen Variablen sind $a$ und $b$ ==== b) $ s(v,t) = - g/2 times t^2 + v times t + s_0 $ Die unabhängigen Variablen sind $v$ und $t$ === Aufgabe 2.19) 1) $arrow$ C), 2) $arrow$ B), 3) $arrow$ D), 4) $arrow$ A) = 2.4 Partielle Ableitung erster Ordnung == Definition Unter einer *Partiellen Ableitung* einer reellen Funktion in 2 Variablen $f(x,y)$ versteht man die Ableitung nach einer der Variablen. Es wird (unter Anwendung der üblichen Ableitungsregeln) nach dieser Variable abgeleitet, die andere Variable wird als Konstante aufgefasst. $ pdv(,x) f(x,y) = pdv(f(x,y),x) = pdv(f,x) = pdv(z,x) = f_x(x,y) $ == Aufgabe 2.21) $ f(x,y) = x^2 times cos(y) + y^2 $ Lösung: $ f_x(x,y) = 2x times cos(y) $ $ f_y(x,y) = -x^2 times sin(y) + 2y $ == Aufgabe 2.24) === c) $ z= 5 x y + 3 y^4 - 6x^2 y^2 $ $ f_x = 5y - 12x y^2 $ $ f_y = 5x + 12y^3 - 12x^2y $ == Aufgabe 2.25) === c) $ z = 4x + y^2/x - 6/y + 4 $ $ f_x = 4 - y^2/x^2 $ $ f_y = (2y)/x + 6/y^2 $ == Aufgabe 2.27 === c) $ z = sqrt(3x^2y + 2x y^2) $ $ f_x = (2y^2 + 6 x y)/(2 sqrt(2 x y^2 + 3 x^2 y)) $ $ f_y = (4 x y + 3 x^2)/(2 sqrt(2 x y^2 + 3 x^2 y)) $ = 2.5 Partielle Ableitung zweiter Ordnung $ pdv(,y) f_x (x,y) = pdv(f_x(x,y),y) = pdv(,y) (pdv(f,x)) = f_(x y) (x,y)$ == <NAME> Sind die gemischt-partiellen Ableitungen in einer Umgebung der Stelle $(x_0,y_0)$ stetig, so sind sie in dieser Umgebung *einander gleich*. = Extremwertberechnung Am Anfang einer Kurvendiskussion ist die erste und zweite Ableitung vernünftig. Danach bestimmt man die *Definitionsmenge* von $y=f(x)$. Der nächste Schritt ist die bestimmung der *Nullstellen* $f(x)=0 arrow N_1(x_(N 1)|0), N_2(N_(N 1)|0)$. Danach kommt die Berechnung der *lokalen Extremwerten*: $ f'(x) = 0 arrow x_(E 1), x_(E 2), ... $ $ f'' (x_E) < 0 arrow text("Maxmium") $ $ f'' (x_E) > 0 arrow text("Minimum") $ Zuletzt kommen Globale Extrema, Wendepunkte und Wendetangenten
https://github.com/xsro/xsro.github.io
https://raw.githubusercontent.com/xsro/xsro.github.io/zola/typst/Control-for-Integrator-Systems/part1.typ
typst
#import "template.typ": template #show: template.with( title:[*Sliding Mode Control for Integrator Systems*], part:[*part 1*: SMC for single integrators and double integrators] ) #include "1linear.typ" #include "4PTC.typ" #include "2single.typ" #include "3double.typ"
https://github.com/jgm/typst-hs
https://raw.githubusercontent.com/jgm/typst-hs/main/test/typ/visualize/shape-aspect-03.typ
typst
Other
// Test square that is limited by region size. #set page(width: 20pt, height: 10pt, margin: 0pt) #stack(dir: ltr, square(fill: red), square(fill: green))
https://github.com/Vanille-N/mpri2-edt
https://raw.githubusercontent.com/Vanille-N/mpri2-edt/master/mpri.typ
typst
#import "typtyp.typ" #let tt = typtyp #import "time.typ" #import "classes.typ" // Re-exports for backwards compatibility #let Class = classes.Class #let verif = rgb("b8bb26").lighten(70%) #let prog = rgb("fe8019").lighten(60%) #let logic = rgb("fabd2f").lighten(60%) #let algos = rgb("d3869b").lighten(50%) #let data = rgb("fb4934").lighten(50%) #let fmt(name, uid, teacher, room) = [ #{ // UID is mandatory for MPRI classes assert(uid != none) } #text(size: 11pt, weight: "bold")[#name] \ #text(size: 11pt)[Room #room] #text(size: 8pt)[(#teacher)] #text(size: 8pt, weight: "bold")[[#uid]] ] // List of classes #let proof_asst = classes.new(verif, fmt, [Proof Assistants], [2.7.2], [Winterhalter]) #let automata_mod = classes.new(logic, fmt, [Automata Modelling], [2.16], [Picantin]) #let symbolic_dyn = classes.new(logic, fmt, [Symbolic Dynamics], [2.20.2], [Berthé]) #let advanced_verif = classes.new(verif, fmt, [Technics of Verification], [2.8], [Bouyer]) #let proof_systems = classes.new(verif, fmt, [Foundations of Proof Systems], [2.7.1], [Dowek]) #let algo_wqo = classes.new(verif, fmt, [Well Quasi-Order Theory], [2.9.1], [Finkel]) #let network_mod = classes.new(logic, fmt, [Network Models], [2.17.1], [Mairesse]) #let biochem_prog = classes.new(prog, fmt, [Biochemical Programming], [2.19], [Fages]) #let sync_sys = classes.new(prog, fmt, [Synchronous Systems], [2.23], [Pouzet]) #let sec_protocols = classes.new(verif, fmt, [Security Protocols], [2.30], [Blanchet]) #let lang_mod = classes.new(data, fmt, [Natural Language Modelling], [2.27.1], [Schmitz]) #let graph_mining = classes.new(data, fmt, [Graph Mining], [2.29.2], [Sozio]) #let param_compl = classes.new(algos, fmt, [Parameterized Complexity], [2.11.1], [Mitsou]) #let quantum_crypto = classes.new(algos, fmt, [Quantum Cryptography], [2.34.2], [Chailloux]) #let linear_logic = classes.new(logic, fmt, [Linear Logic], [2.1], [Kesner]) #let poly_sys = classes.new(algos, fmt, [Polynomial Systems], [2.13.1], [Faugère]) #let cryptanalysis = classes.new(algos, fmt, [Cryptanalysis], [2.12.1], [Minaud]) #let error_corr = classes.new(algos, fmt, [Error Correcting Codes], [2.13.1], [Faugère]) #let da_networks = classes.new(algos, fmt, [DA on Networks], [2.18.1], [Fraigniaud]) #let fp_and_types = classes.new(prog, fmt, [FP and Type Systems], [2.4], [Pottier]) #let combinatorics = classes.new(algos, fmt, [Combinatorics], [2.10], [Schaeffer]) #let analysis_algo = classes.new(algos, fmt, [Analysis of Algorithms], [2.15], [Ravelomanana]) #let abstract_interp = classes.new(verif, fmt, [Abstract Interpretation], [2.6], [Miné]) #let search_heuristics = classes.new(data, fmt, [Search Heuristics], [2.24.2], [Doerr]) #let geometric_graphs = classes.new(algos, fmt, [Geometric Graphs], [2.38.1], [Laplante]) #let topology = classes.new(data, fmt, [Topology], [2.14.1], [Glisse]) #let quantum_info = classes.new(algos, fmt, [Quantum Information], [2.34.1], [Laplante]) #let proba_prog = classes.new(logic, fmt, [Probabilistic PL], [2.40], [Tasson]) #let rand_compl = classes.new(algos, fmt, [Randomness in Complexity], [2.11.2], [Magniez]) #let comp_algebra = classes.new(algos, fmt, [Computer Algebra], [2.22], [Chyzak]) #let graph_theory = classes.new(data, fmt, [Graph Theory], [2.29.1], [Naserasr]) #let arith_crypto = classes.new(algos, fmt, [Arithmetic for Cryptology], [2.12.2], [Smith]) #let concurrency = classes.new(logic, fmt, [Concurrency], [2.3.1], [Haucourt]) #let uncertainty = classes.new(data, fmt, [Alg. and Uncertainty], [2.24.1], [Angelopoulos]) #let proof_of_prog = classes.new(verif, fmt, [Proof of Programs], [2.36.1], [Marché]) #let da_shared = classes.new(algos, fmt, [DA on Shared Memory], [2.18.2], [Delporte]) #let game_theory = classes.new(logic, fmt, [Game Theory], [2.20.1], [Zielonka]) #let categories = classes.new(logic, fmt, [Domains, Categories, Games], [2.2], [Melliès]) #let algo_verif = classes.new(verif, fmt, [Algorithmic Verification], [2.9.2], [Bouajjani]) #let data_analysis = classes.new(data, fmt, [Data Analysis], [2.39], [Tierny]) #let starting-times = ((8,45), (10,15), (12,45), (14,15), (16,15), (17,45)).map(t => time.from-hm(..t)) #let full(period, descr, room, sem: (1,2)) = classes.slot( descr, room, sem: sem, start: starting-times.at((period - 1) * 2), len: time.from-hm(3, 0), ects: 3 * sem.len(), ) #let short(period, slot, descr, room, sem: (1,2)) = classes.slot( descr, room, sem: sem, start: starting-times.at((period - 1) * 2 + slot - 1), len: time.from-hm(1, 30), ects: 3, ) #let later(minutes, class) = { tt.is(classes.TimeClass, class) class.start = time.offset(class.start, time.from-hm(0, minutes)) class } // Static timetable #let week = tt.ret(classes.Week, ( mon: ( full(1, sem:(1,), proof_asst)[1002], full(1, automata_mod)[1004], short(2, 1, symbolic_dyn)[1002], full(2, advanced_verif)[1004], full(3, sem:(1,), proof_systems)[1004], full(3, sem:(1,), algo_wqo)[1002], full(3, sem:(2,), network_mod)[1002], full(3, sem:(2,), biochem_prog)[1004], ), tue: ( full(1, sem:(1,), sync_sys)[1004], full(1, sec_protocols)[1002], full(2, sem:(1,), lang_mod)[1004], full(2, sem:(1,), graph_mining)[1002], full(2, sem:(2,), param_compl)[1002], full(2, sem:(2,), quantum_crypto)[1004], full(3, linear_logic)[1002], full(3, sem:(1,), poly_sys)[1004], ), wed: ( short(1, 1, cryptanalysis)[1004], short(1, 2, error_corr)[1004], later(15, short(1, 2, da_networks)[1002]), full(2, fp_and_types)[1002], full(2, combinatorics)[1004], full(3, analysis_algo)[1002], ), thu: ( full(1, abstract_interp)[1004], full(1, sem:(2,), search_heuristics)[1002], full(1, sem:(1,), geometric_graphs)[1002], full(2, sem:(1,), topology)[1002], full(2, sem:(1,), quantum_info)[1004], full(2, sem:(2,), proba_prog)[1002], full(3, sem:(1,), rand_compl)[1002], full(3, comp_algebra)[1004], full(3, sem:(2,), graph_theory)[1002], ), fri: ( full(1, sem:(1,), arith_crypto)[1004], full(1, sem:(2,), concurrency)[1002], full(1, sem:(1,), uncertainty)[1002], full(1, sem:(2,), proof_of_prog)[1004], full(2, sem:(1,), da_shared)[1002], full(2, sem:(1,), game_theory)[1004], full(3, categories)[1004], full(3, sem:(2,), algo_verif)[1002], full(3, sem:(1,), data_analysis)[1002], ), ))
https://github.com/darioglasl/Arbeiten-Vorlage-Typst
https://raw.githubusercontent.com/darioglasl/Arbeiten-Vorlage-Typst/main/Anhang/04_Projektdokumentation/05_zeitmanagement.typ
typst
#set page( flipped: true, ) === Zeitmanagement #set page( flipped: false, )
https://github.com/yomannnn/yomannnn.github.io
https://raw.githubusercontent.com/yomannnn/yomannnn.github.io/main/hello.typ
typst
#import "/book.typ": book-page #show: book-page.with(title: "2023_11_02") = <NAME> #image("./src/pic/Gaston.png") Sample page == alksdjf == alksdjf
https://github.com/qo/term
https://raw.githubusercontent.com/qo/term/main/term.typ
typst
// Colorscheme // https://www.schemecolor.com/macos-window-ui-colors.php #let width = 300pt #let inset_size = 10pt #let radius_size = 10pt #let button_size = 10pt #let button_spacing = 10pt #let button_red_color = rgb("FF605C") #let button_orange_color = rgb("FFBD44") #let button_green_color = rgb("00CA4E") #let toolbar_bg_color = rgb("F5F5F5") #let stroke_color = rgb("E1DFE1") #let main_bg_color = rgb("FFFFFF") #let font = "Roboto Mono" #show raw: set text(font: font) #let button( color: none, ) = { return box( width: button_size, height: button_size, radius: button_size, fill: color, ) } #let toolbar() = { return block( width: 100%, inset: inset_size, radius: ( top: radius_size, ), fill: toolbar_bg_color, stroke: stroke_color, stack( dir: ltr, spacing: button_spacing, button(color: button_red_color), button(color: button_orange_color), button(color: button_green_color), ) ) } #let main( content: [], ) = { return block( width: 100%, inset: inset_size, radius: ( bottom: radius_size, ), fill: main_bg_color, stroke: stroke_color, [ #content ] ) } #let term( content: [], ) = { return align( left, box( width: 300pt, stack( dir: ttb, align(left, toolbar()), main( content: content, ), ) ) ) }
https://github.com/Dherse/typst-brrr
https://raw.githubusercontent.com/Dherse/typst-brrr/master/samples/tablex/main.typ
typst
#import "@preview/tablex:0.0.4": tablex, hlinex, vlinex, colspanx, rowspanx, cellx, gridx #tablex( columns: 4, align: center + horizon, auto-vlines: false, // indicate the first two rows are the header // (in case we need to eventually // enable repeating the header across pages) header-rows: 2, // color the last column's cells // based on the written number map-cells: cell => { if cell.x == 3 and cell.y > 1 { cell.content = { let value = int(cell.content.text) let text-color = if value < 10 { red.lighten(30%) } else if value < 15 { yellow.darken(13%) } else { green } set text(text-color) strong(cell.content) } } cell }, /* --- header --- */ rowspanx(2)[*Username*], colspanx(2)[*Data*], (), rowspanx(2)[*Score*], (), [*Location*], [*Height*], (), /* -------------- */ [John], [Second St.], [180 cm], [5], [Wally], [Third Av.], [160 cm], [10], [Jason], [Some St.], [150 cm], [15], [Robert], [123 Av.], [190 cm], [20], [Other], [Unknown St.], [170 cm], [25], ) #tablex( columns: 3, colspanx(2)[a], (), [b], [c], rowspanx(2)[d], [ed], [f], (), [g] ) #tablex( columns: 3, map-hlines: h => (..h, stroke: blue), map-vlines: v => (..v, stroke: green + 2pt), colspanx(2)[a], (), [b], [c], rowspanx(2)[d], [ed], [f], (), [g] ) #pagebreak() #v(80%) #tablex( columns: 4, align: center + horizon, auto-vlines: false, repeat-header: true, /* --- header --- */ rowspanx(2)[*Names*], colspanx(2)[*Properties*], (), rowspanx(2)[*Creators*], (), [*Type*], [*Size*], (), /* -------------- */ [Machine], [Steel], [5 $"cm"^3$], [John p& Kate], [Frog], [Animal], [6 $"cm"^3$], [Robert], [Frog], [Animal], [6 $"cm"^3$], [Robert], [Frog], [Animal], [6 $"cm"^3$], [Robert], [Frog], [Animal], [6 $"cm"^3$], [Robert], [Frog], [Animal], [6 $"cm"^3$], [Robert], [Frog], [Animal], [6 $"cm"^3$], [Robert], [Frog], [Animal], [6 $"cm"^3$], [Rodbert], )
https://github.com/desid-ms/desid_report
https://raw.githubusercontent.com/desid-ms/desid_report/main/_extensions/desid_report/typst-template.typ
typst
MIT License
// margin notes #import "@preview/drafting:0.2.0" #let article( title: none, subtitle: none, authors: none, contract: none, project: none, product: none, citation: none, date: none, abstract: none, abstract-title: none, margin: (left: 1cm, top: 1.5cm, right: 7cm, bottom: 1.5cm), paper: "a4", lang: "pt", region: "BR", font: (), fontsize: 11pt, sectionnumbering: "1.1.a", cols: 1, toc: true, toc_depth: 1, toc_title: "Sumário", toc_indent: 1.5em, doc, ) = { set page( paper: "a4", margin: (left: 1cm, top: 1.5cm, right: 7cm, bottom: 1.5cm), numbering: "1", header-ascent: .5cm, footer-descent: .5cm, header: locate(loc => { if (loc.page() != 1) { block( width: 19cm, stroke: (bottom: 1pt + gray), inset: (bottom: 8pt, right: 2pt, left: 2pt), [ #set text(font: "Lato", size: 8pt, fill: gray.darken(50%)) #grid( columns: (1fr, 1fr), align(left, []), align(right, text(weight: "bold", upper[Relatório])), ) ], ) } }), footer: block( width: 19cm, stroke: (top: 1pt + gray), inset: (top: 8pt, right: 2pt), [ #set text(font: "Lato", size: 8pt, fill: gray.darken(50%)) #grid( columns: (75%, 25%), align(left)[#date - #title], align( right )[#counter(page).display() de #locate((loc) => { counter(page).final(loc).first() })], ) ], ) ) set par(justify: true, linebreaks: "optimized") set text(lang: lang, region: region, historical-ligatures: true, ligatures: true, font: "Merriweather", size: 10pt, fractions: true) set heading(numbering: sectionnumbering) show heading: it => { set par(leading: 2em) // set block(spacing: 2em) set text(font:"Lato", weight: "semibold", fractions: true) smallcaps(it) v(.54em) } if title != none { block(width:19cm)[ #text(font: "Lato", fill: gray.lighten(60%), upper[Relatório]) #v(.2cm) #text(font: "Merriweather", size: 20pt, weight: "black", title) #if subtitle != none { v(-.3cm) text(font: "Merriweather", size: 16pt, weight: "regular", subtitle) } #if abstract != none { block(inset: 1.5em)[ #text(weight: "semibold", font:"Lato")[#abstract-title] #h(1em) #text(size: 8pt)[#abstract] ] } else {v(.5cm)} #line(length: 100%, stroke: 3pt + rgb("#316E6B")) #v(.25cm) ] } if authors != none { place(dx:7cm, right, block(width: 7cm,inset: 1em,)[ #set align(left) #block(width: 5.65cm, inset:1em, fill: rgb("#316E6B").lighten(95%), radius: 6pt)[ #set text(font:"Lato", size: 8pt) #for (author) in authors [ #if author.role != none [#text(weight: "bold", author.role) \ ] #h(1em)#author.name #if author.affiliation!=none {text(font: "SF Mono")[(#author.affiliation)]} #if author.email != none [#v(-.5em)#h(1em)#text(size: 7pt, font: "SF Mono", author.email)] ] #if contract != none [ *Contrato* #h(1em)#text(size: 7pt, font: "SF Mono", contract) ] #if project != none [ *Projeto* #h(1em)#text(size: 7pt, font: "SF Mono", project) ] #if product != none [ *Produto* #h(1em)#text(size: 7pt, font: "SF Mono", product) ] #if date != none [ *Publicação* #h(1em)#text(size: 7pt, font: "SF Mono", date) ] ] #if toc { v(1cm) set text(size:.6em, font: "Lato") block(above: 0em, below: 2em)[ #outline( title: "Sumário", depth: 2, indent: 1em ); ] } ] ) } if cols == 1 { doc } else { columns(cols, doc) } } #set table( inset: 6pt, stroke: none )
https://github.com/piepert/grape-suite
https://raw.githubusercontent.com/piepert/grape-suite/main/src/todo.typ
typst
MIT License
#import "colors.typ": magenta #let todo-state = state("grape-suite-todos", ()) #let make-todo-label(loc) = { return ("todo-label-" + str(loc.page()) + "-" + repr(loc.position().x) + "-" + repr(loc.position().y) + "-" + str(todo-state.at(loc).len())) } #let hide-todos() = state("grape-suite-list-todos").update(false) #let todo(..content) = context { if state("grape-suite-list-todos", true).at(here()) == false { return } let label-name = make-todo-label(here()) highlight(fill: magenta.lighten(90%), text(fill: magenta, if content.pos().len() > 0 { strong[To do: ] + content.pos().join[] } else { strong[To do] }) ) [#label(label-name)] todo-state.update(t => { t.push((page: counter(page).at(here()).first(), label: label-name, content: content.pos().join[])) t }) } #let list-todos() = context { let todo-list = todo-state.final() show link: text.with(fill: magenta) set text(fill: magenta) if type(todo-list) == "array" and todo-list.len() > 0 { strong([To do:]) list(tight: false, ..todo-list.map(e => strong[p. #e.page] + if e.content != none { [: #e.content] })) } }
https://github.com/thornoar/hkust-courses
https://raw.githubusercontent.com/thornoar/hkust-courses/master/MATH1023-Honors-Calculus-I/homeworks/homework-1/main.typ
typst
#import "@local/common:0.0.0": * #import "@local/templates:0.0.0": * #show: math-preamble("Part 1", "Fri, Sep 13") #math-problem("1.1.3") Explain that, if $limits(lim)_(n -> oo) x_n = l$ and $p$ is a positive integer, then $limits(lim)_(n -> oo) x_n^p = l^p.$ #math-solution We will prove this statement by induction. + If $p = 1$, then the result follows trivially. + Suppose that the result holds for $p-1$. Now, with reference to the arithmetic rule, we can write $ limits(lim)_(n -> oo) x_n^p = limits(lim)_(n -> oo) (x_n^(p-1) dot x_n) = (limits(lim)_(n -> oo) x_n^(p-1)) dot (limits(lim)_(n -> oo) x_n) = l^(p-1) dot l = l^p. $ #math-problem("1.1.5 (6)") Find the limit ($n -> oo$) of $ ((n^2 + 1)(n+2))/((n+1)(n^2+2)). $ #math-solution $ ((n^2 + 1)(n+2))/((n+1)(n^2+2)) = (n^3 + p_1 n^2 + q_1 n + s_1)/(n^3 + p_2 n^2 + q_2 n + s_2) = (1 + p_1/n + q_1/(n^2) + s_1/(n^3))/(1 + p_2/n + q_2/(n^2) + s_2/(n^3)) ->_(n -> oo) 1. $ #math-problem("1.1.7 (5)") Find the limit ($n -> oo$) of $ (c n + d)/((sqrt(n) + a)(sqrt(n) + b)). $ #math-solution $ (c n + d)/((sqrt(n) + a)(sqrt(n) + b)) = (c n + d)/(n + p sqrt(n) + q) = (c + d/n)/(1 + p/sqrt(n) + q/n) ->_(n -> oo) c. $ #math-problem("1.1.9 (3)") Find the limit ($n -> oo$) of $ (5^5(2 sqrt(n) + 1)^2 - 10^10)/(10 n - 5). $ #math-solution $ (5^5(2 sqrt(n) + 1)^2 - 10^10)/(10 n - 5) = (5^5 dot 4 n + p sqrt(n) + q)/(10 n - 5) ->_(n -> oo) (5^5 dot 4)/10 = 1250. $ #math-problem("1.1.11 (1)") Find the limit ($n -> oo$) of $ (n^2 + a_1 n + a_0)/(n + b) - (n^2 + c_1 n + c_0)/(n + d). $ #pagebreak() #math-solution $ (n^2 + a_1 n + a_0)/(n + b) - (n^2 + c_1 n + c_0)/(n + d) = ((n+d)(n^2 + a_1 n + a_0) - (n+b)(n^2 + c_1 n + c_0))/((n+d)(n+b)) =\ = ((d - b + a_1 - c_1)n^2 + p_1 n + q_1)/(n^2 + p_2 n + q_2) ->_(n -> oo) d - b + a_1 - c_1. $ #math-problem("1.1.15 (8)") Find the limit ($n -> oo$) of $ cos(n)/sqrt(n + sin(sqrt(n))). $ #math-solution It is trivial to see that $ 0 <-_(n -> oo) (-1)/sqrt(n - 1) <= cos(n)/sqrt(n + sin(sqrt(n))) <= 1/sqrt(n - 1) ->_(n -> oo) 0, $ which implies that the the limit in question is equal to 0, by the sandwich rule. #math-problem("1.1.15 (16)") Find the limit ($n -> oo$) of $ (n + sin(n))/(n - cos(n)). $ #math-solution The answer is 1 by the sandwich rule, since $ 1 <-_(n -> oo) (n - 1)/(n + 1) <= (n + sin(n))/(n - cos(n)) <= (n + 1)/(n - 1) ->_(n -> oo) 1. $ #math-problem("1.1.21 (11)") Find the limit ($n -> oo$) of $sqrt(n^2 + a n + b) - sqrt(n^2 + c n + d)$.\ #math-solution Consider two real numbers $alpha, beta > 0$. From the algebraic rule $x^2 - y^2 = (x-y)(x+y)$, it follows that $ sqrt(alpha) - sqrt(beta) = (alpha - beta)/(sqrt(alpha) + sqrt(beta)). $ Now assume that $alpha >= beta$. Then, since $2 sqrt(beta) <= sqrt(alpha) + sqrt(beta) <= 2 sqrt(alpha)$, we can bound the difference $sqrt(alpha) - sqrt(beta)$ in the following way: #[ #set math.equation(numbering: "(1)") $ (alpha - beta)/(2 sqrt(alpha)) <= sqrt(alpha) - sqrt(beta) <= (alpha - beta)/(2 sqrt(beta)). $ <ab> ] With respect to the original problem, we first note that for all $a, b in RR$, the expression $n^2 + a n + b$ will become positive as $n$ goes to infinity, and thus the square roots can be considered to be well-defined. Further, it is clear by exhausting the relative positions of $a$, $b$, $c$, and $d$ that one of the expressions\ $n^2 + a n + b$ and $n^2 + c n + d$ will not exceed the other, starting at some point. This is explained by the fact that their difference is an affine function of $n$, and it acquires a constant sign as $n$ approaches infinity. In other words, without loss of generality, we can assume that #[ #set math.equation(numbering: "(1)") $ (n^2 + a n + b) >= (n^2 + c n + d)" as " n -> oo. $ <btoet> ] (In case the sign is $<=$, we switch the expressions, moving into an analogous situation)\ Now, in view of @ab and @btoet, we can write that $ ((a - c) n + (b - d))/(2 sqrt(n^2 + a n + b)) <= sqrt(n^2 + a n + b) - sqrt(n^2 + c n + d) <= ((a-c) n + (b-d))/(2 sqrt(n^2 + c n + d)). $ By squaring the non-negative sequences on the left and the right, we see that they both approach $(a-c)/2$, meaning that, by the sandwich rule, the sequence in the middle also approaches $(a-c)/2$. #math-problem("1.1.24 (3)") Find the limit ($n -> oo$) of $ ((n-2)/(n+1))^(-sqrt(2)). $ #math-solution $ 1 <= ((n-2)/(n+1))^(-sqrt(2)) = ((n+1)/(n-2))^sqrt(2) <= ((n+1)/(n-2))^2 = (1 + 3/(n-2))^2 ->_(n -> oo) 1, $ and therefore the limit is 1. #math-problem("1.1.27") Suppose that $limits(lim)_(n -> oo) x_n = 1$, $x_n >= 1$, and $y_n$ is bounded. Prove that $limits(lim)_(n -> oo) x_n^(y_n) = 1.$\ #math-solution Let $a >= 1$. Then, if $b_1 <= b_2$, we have $a^(b_1) <= a^(b_2)$. Now, since $y_n$ is bounded, there exist numbers $mu, nu in RR$ such that $mu <= y_n <= nu$ for all $n$. Consequently, we have $ 1 <-_(n -> oo) x_n^mu <= x_n^(y_n) <= x_n^nu ->_(n -> oo) 1, $ and we are done.
https://github.com/lsacienne/UTBM-Internship-Report-Typst
https://raw.githubusercontent.com/lsacienne/UTBM-Internship-Report-Typst/main/README.md
markdown
MIT License
# UTBM-Internship-Report-Typst UTBM Typst template for internship report. ![Cover](readme/cover.png) ## How to use it ? Few steps are required : - Download the `utbm.typ` file. - Drop the template in your project - Add the following line to your project : ```typst #import "/utbm.typ": cover, fourth-cover ``` - Use `cover` and `fourth-cover` respectively at the beginning and the end of your report. ## How to use the functions ### `cover` function #### Parameters | Parameter | type | Goal | Default Value | | ----------- | ------ | ------ | --------------- | | title | string | Title of the report | "Analyse de durabilité des systèmes de propulsion par microcontrôleurs externe" | | report-type | string | Type of UTBM internship | "STXX" | | report-year | string | UTBM internship date | "P20XX" | | picture | picture path | Cover picture | "assets/images/background.jpg" | | student | dictionary(first-name: string, last-name: string, speciality: string, sector: string) | informations about the student | (first-name: "Prénom", last-name: "NOM", specialty: "Nom de la spécialité d'ingénieur", sector: "Nom de la filière") | | company | dictionary(name: string, address: string, postal-code: string, city: string, website: string) | informations about the company | (name: "Entreprise DEMO-Contrôleurs", address: "8 rue de la Fierté", postal-code: "75013", city: "Paris", website: "www.democontroleurs.com") | | tutor | dictionary(first-name: string, last-name: string) | Informations about the tutor in the company | (first-name: "Prénom", last-name: "NOM") | | supervisor | dictionary(first-name: string, last-name: string) | Informations about the UTBM supervisor | (first-name: "Prénom", last-name: "NOM") | #### example : ```typst #cover( title: "My internship", report-type: "ST54", report-year: "P2024", picture: "assets/images/utbm_logo.png", student: ( first-name: "Alexandre", last-name: "Viala", specialty: "Ingénieur en Informatique", sector: "Mondes Virtuels, UX & UI", ), company: ( name: "Mon entreprise", address: "Adresse de mon entreprise", postal-code: "Code postal de mon entreprise", city: "Ville de mon entreprise", website: "www.site-web-de-mon-entreprise.com", ), tutor: ( first-name: "Jean", last-name: "DUPOND", ), supervisor: ( first-name: "Pierre", last-name: "SCHMIDT", ) ) ``` <div align=center> <img src="https://github.com/lsacienne/UTBM-Internship-Report-Typst/blob/dev/readme/example_cover.png" width=50% center> </div> ### `fourth-cover` function #### Parameters | Parameter | type | Goal | Default Value | | ----------- | ------ | ------ | --------------- | | subject | string | Subject of your internship | "Sujet de stage et description du travail réalisé" | | report-type | string | Type of UTBM internship | "STXX" | | report-year | string | UTBM internship date | "P20XX" | | picture | picture path | Cover picture | "assets/images/background.jpg" | | student | dictionary(first-name: string, last-name: string) | Informations about the student | (first-name: "Prénom", last-name: "NOM") | | company | dictionary(name: string, address: string, postal-code: string, city: string, website: string) | informations about the company | (name: "Entreprise DEMO-Contrôleurs", address: "8 rue de la Fierté", postal-code: "75013", city: "Paris", website: "www.democontroleurs.com") | | abstract | none (body content) | Summary of your intership | none | #### example : ```typst #fourth-cover( subject: "Discovering new ways to fromat text", report-type: "ST54", report-year: "P2024", student: ( first-name: "Alexandre", last-name: "Viala", ), company: ( name: "Mon entreprise", address: "Adresse de mon entreprise", postal-code: "Code postal de mon entreprise", city: "Ville de mon entreprise", website: "www.site-web-de-mon-entreprise.com", ), )[#lorem(248)] ``` <div align=center> <img src="https://github.com/lsacienne/UTBM-Internship-Report-Typst/blob/dev/readme/example_fourth-cover.png" width=50% center> </div> ## Modifications Feel free to modify the template as you wish. Typst is easy to learn if you already have some LaTeX and Markdown notions.
https://github.com/typst/packages
https://raw.githubusercontent.com/typst/packages/main/packages/preview/chordx/0.1.0/chordx-native.typ
typst
Apache License 2.0
// typst-chordx using native primitives #let new-graph-chords-native(strings: 6, font: "Linux Libertine") = { return ( frets: 5, fret-number: none, capos: (), fingers: (), notes, chord-name ) => { let vertical-space = 18pt if fingers.len() == 0 { vertical-space = 13pt } let step = 5pt let size-x = strings - 1 let size-y = frets let bx = 0pt let by = -(frets * step + vertical-space) let stroke = black + 0.5pt let mute(col) = { let offset = col * step place( dx: bx, dy: by, line( start: (offset - 1.5pt, -2.5pt), end: (offset + 1.5pt, -5.5pt), stroke: stroke ) ) place( dx: bx, dy: by, line( start: (offset - 1.5pt, -5.5pt), end: (offset + 1.5pt, -2.5pt), stroke: stroke ) ) } let draw-grid(row, col) = { // shows or hides guitar nut if fret-number == none or fret-number == 1 { place( dx: bx, dy: by - 1.1pt, rect( width: col * step, height: 1.2pt, stroke: stroke, fill: black ) ) } place( dx: bx, dy: by, rect( width: col * step, height: row * step, stroke: stroke ) ) let i = 1 while i < col { let x = i * step place( dx: bx, dy: by, line( start: (x, 0pt), end: (x, row * step), stroke: stroke ) ) i += 1 } let i = 1 while i < row { let y = i * step place( dx: bx, dy: by, line( start: (0pt, y), end: (col * step, y), stroke: stroke ) ) i += 1 } } // draws notes: (x) for mute, (0) for air notes and (number) for finger notes let draw-notes(size, points) = { for (row, col) in points.zip(range(size)) { if row == "x" { mute(col) } else if row == 0 { let radius = 1.7pt place( dx: bx + step * col - radius, dy: by - 4pt - radius, circle(radius: radius, stroke: black + 0.5pt) ) } else if type(row) == "integer" { let radius = 1.7pt place( dx: bx + step * col - radius, dy: by + step * row - radius - 2.5pt, circle(radius: radius, stroke: none, fill: black ) ) } } } // draws a capo list let draw-capos(size, points) = { for (fret, start, end) in points { if start > size { start = size } if end > size { end = size } place( dx: bx, dy: by + fret * step - 2.5pt, line( start: ((size - start) * step, 0pt), end: ((size - end) * step, 0pt), stroke: (paint: black, thickness: 3.4pt, cap: "round") ) ) } } // draws the finger numbers let draw-fingers(size, points) = { for (finger, col) in points.zip(range(size)) { if type(finger) == "integer" and finger > 0 and finger < 6 { place( dx: bx + col * step - 1.3pt, dy: by + frets * step + 1pt, text(6pt)[#finger]) } } } let chord-name = text(12pt, font: font)[#chord-name] let fret-number = text(8pt)[#fret-number] style(styles => { let chord-name-size = measure(chord-name, styles) let fret-number-size = measure(fret-number, styles) let grid-size = ( width: size-x * step + step, height: size-y * step ) let graph-size = ( width: grid-size.width + fret-number-size.width + 2.5pt, height: grid-size.height + 18pt + 5pt ) let canvas-size = ( width: 0pt, height: graph-size.height ) let chord-name-offset = 0pt let graph-offset = 0pt let fret-number-offset = 0pt if chord-name-size.width < grid-size.width { canvas-size.width = graph-size.width chord-name-offset = graph-size.width - grid-size.width / 2 - chord-name-size.width / 2 - 2.5pt } if chord-name-size.width > grid-size.width and chord-name-size.width < graph-size.width { canvas-size.width = graph-size.width + (chord-name-size.width - grid-size.width) / 2 chord-name-offset = graph-size.width - (fret-number-size.width + grid-size.width / 2 + 2.5pt) } if chord-name-size.width > graph-size.width { canvas-size.width = chord-name-size.width graph-offset = (chord-name-size.width - grid-size.width) / 2 - fret-number-size.width } box(..canvas-size, align(left + bottom, { place(left + bottom , dx: graph-offset, { place(left, dx: fret-number-size.width + 2.5pt, dy: 0pt, { draw-grid(size-y, size-x) draw-notes(strings, notes) draw-capos(strings, capos) draw-fingers(strings, fingers) }) place( left + top, dx: 0pt, dy: by - 0.25pt, fret-number ) }) place( left + bottom, dx: chord-name-offset, dy: 0pt, chord-name ) }) ) }) } } #let new-single-chords-native(..text-style) = { return (body, chord-name, body-char-pos) => { box( style(styles => { align(left + bottom, { let offset = 0pt let anchor = center let canvas-size = (width: 0pt, height: 0pt) let body-size = measure(body, styles) let chord-size = measure(text(..text-style)[#chord-name], styles) let content-to-array(content) = { if content.has("text") { return content.at("text").clusters() } if content.has("double") { return (content,) } if content.has("children") { for item in content.at("children") { content-to-array(item) } } if content.has("body") { content-to-array(content.at("body")) } if content.has("base") { content-to-array(content.at("base")) } if content.has("equation") { content-to-array(content.at("equation")) } } let body-array = content-to-array(body) if body-char-pos.has("text") and int(body-char-pos.at("text")) != 0 { let body-chars-offset = 0pt let pos = int(body-char-pos.at("text")) - 1 for i in range(pos) { body-chars-offset += measure([#body-array.at(i)], styles).width } anchor = left // gets the char-offset to center the first character of the chord // with the selected character of the body let chord-char = content-to-array(chord-name).at(0) let chord-char-width = measure(text(..text-style)[#chord-char], styles).width let body-char-width = measure([#body-array.at(pos)], styles).width let char-offset = (chord-char-width - body-char-width) / 2 // final offset offset = body-chars-offset - char-offset } if offset > 0pt and chord-size.width + offset >= body-size.width { canvas-size.width = chord-size.width + offset } else if offset <= 0pt and chord-size.width >= body-size.width { canvas-size.width = chord-size.width } else { canvas-size.width = body-size.width } box( width: canvas-size.width, height: body-size.height + 16pt, { place(anchor + bottom, dx: offset, dy: -16pt, text(..text-style)[#chord-name]) place(anchor + bottom, box(..body-size, body)) } ) }) }) ) } }
https://github.com/mrcinv/nummat-typst
https://raw.githubusercontent.com/mrcinv/nummat-typst/master/julia.typ
typst
#let readlines(file, start, end) = { let content = read(file) let lines = content.split(regex("\n\r{0,1}")) lines.slice(start - 1, end).join("\n") } #let jl(code) = raw( lang: "jl", code ) #let jlblk(code) = raw( lang: "jl", block: true, code ) // print a part of a julia file as a code block #let jlf(file, start, end) = raw( readlines(file, start, end), block: true, lang: "jl" ) // create a virtual box for Julia code and other code #let code_box(content) = box(width:100%, inset: 1em, content) #let prompt_jl = text(green)[*`julia>`* #h(0.6em)] #let prompt_pkg(env) = text(blue, weight: "bold")[#raw("("+env +") pkg>") #h(0.6em)] // a single line for REPL #let repl_line(command, block, prompt: prompt_jl, lang:"jl") = stack( dir: ltr, prompt, raw(lang: lang, block: block, command) ) // write a single entry to Julia REPL #let repl(command, out, block: false) = stack( dir: ttb, spacing: 0.6%, repl_line(command, block, prompt: prompt_jl), if out != none { raw(out) } else { v(-9pt) } ) // A single line of REPL in package mode #let pkg(command, out, env: "@v1.10") = stack( dir: ttb, spacing: 0.6%, repl_line(command, false, prompt: prompt_pkg(env), lang: none), if out != none{ raw(out) } else { v(-9pt) } ) #let blk(file, start) = { let content = read(file) let r = regex("(?s)" + start + "[\r\n]*(.*?)" + start) let match = content.match(r) if match == none { "No match for " + start + " in " + file } else { match.captures.first() } } #let jlfb(file, start) = jlblk(blk(file, start)) #let out(file) = raw(read(file))
https://github.com/polarkac/MTG-Stories
https://raw.githubusercontent.com/polarkac/MTG-Stories/master/stories/004_Dragon's%20Maze.typ
typst
#import "@local/mtgset:0.1.0": conf #show: doc => conf("Dragon's Maze", doc) #include "./004 - Dragon's Maze/001_Ruric Thar.typ" #include "./004 - Dragon's Maze/002_Teysa Karlov.typ" #include "./004 - Dragon's Maze/003_Barrin's Tall Tale.typ" #include "./004 - Dragon's Maze/004_Expectations.typ" #include "./004 - Dragon's Maze/005_The Pursuit, Part 1.typ" #include "./004 - Dragon's Maze/006_Life in the Ring.typ" #include "./004 - Dragon's Maze/007_The Pursuit, Part 2.typ" #include "./004 - Dragon's Maze/008_The One Hundred Steps.typ" #include "./004 - Dragon's Maze/009_Last Day.typ" #include "./004 - Dragon's Maze/010_Paper Trail.typ" #include "./004 - Dragon's Maze/011_Battle for the Ninth.typ"
https://github.com/TGM-HIT/typst-diploma-thesis
https://raw.githubusercontent.com/TGM-HIT/typst-diploma-thesis/main/template/assets/mod.typ
typst
MIT License
#let logo = image.with("logo.png")
https://github.com/Myriad-Dreamin/typst.ts
https://raw.githubusercontent.com/Myriad-Dreamin/typst.ts/main/fuzzers/corpora/layout/out-of-flow-in-block_04.typ
typst
Apache License 2.0
#import "/contrib/templates/std-tests/preset.typ": * #show: test-page // Counter update and placed item in the first region. #set page(height: 5cm, margin: 1cm) Counter update + place. #block(breakable: true, above: 1cm, stroke: 1pt, inset: 0.5cm)[ #counter("dummy").step() #place(dx: -0.5cm, dy: -0.75cm, box([OOF])) #rect(height: 2cm, fill: gray) ]
https://github.com/EpicEricEE/typst-equate
https://raw.githubusercontent.com/EpicEricEE/typst-equate/master/tests/boxed/test.typ
typst
MIT License
#import "/src/lib.typ": equate #set page(width: 6cm, height: auto, margin: 1em) #show: equate.with(breakable: true) // Test equation sizing when given constraints. // Unnumbered #block(width: 50%, fill: yellow, $ a + b $) #block(width: 50%, fill: yellow, $ c + d \ e + f $) #h(1cm) #box(width: 40%, fill: yellow, $ g + h $) #h(1cm) #box(fill: yellow, $ g + h $) // Numbered #set math.equation(numbering: "(1)") #block(width: 50%, fill: yellow, $ a + b $) #block(width: 50%, fill: yellow, $ c + d \ e + f $) #h(1cm) #box(width: 40%, fill: yellow, $ g + h $) #h(1cm) #box(fill: yellow, $ g + h $) // Columns #block(height: 2cm, columns(2)[ $ a + b \ c + d \ e + f \ g + h \ i + j $ ])
https://github.com/jamesrswift/springer-spaniel
https://raw.githubusercontent.com/jamesrswift/springer-spaniel/main/src/lib.typ
typst
The Unlicense
#import "impl.typ": template #import "package/ctheorems.typ" as ctheorems #import "package/gentle-clues.typ" as gentle-clues #import "package/dining-table.typ" as dining-table #import "package/board-n-pieces.typ" as board-n-pieces #import "package/drafting.typ" as drafting #import "package/codly.typ" as codly #import "models/asterism.typ" #import "models/sidecaption.typ": sidecaption
https://github.com/typst/packages
https://raw.githubusercontent.com/typst/packages/main/packages/preview/canonical-nthu-thesis/0.1.0/lib.typ
typst
Apache License 2.0
#import "pages/zh-cover.typ": zh-cover-page #import "pages/en-cover.typ": en-cover-page #import "pages/outlines.typ": outline-pages #import "layouts/preface.typ": preface-impl #import "layouts/body.typ": body-impl #let cover-pages-impl(info: (:)) = { zh-cover-page(info: info) en-cover-page(info: info) } #let setup-thesis( info: (:), style: (:), ) = { // The default values for info. info = ( degree: "master", title-zh: [一個標題有點長的 \ 有趣的研究], title-en: [An Interesting Research \ With a Somewhat Long Title], department-zh: "某學系", department-en: "Mysterious Department", id: "012345678", author-zh: "張三", author-en: "<NAME>", supervisor-zh: "<NAME>", supervisor-en: "Prof. <NAME>", // TODO: Revisit this when Typst support displaying datetime in non-English languages. year-zh: "一一三", month-zh: "七", date-en: "July 2024", keywords-zh: ("關鍵詞", "列表", "範例"), keywords-en: ("example", "keywords", "list"), ) + info // The default values for style. style = ( // Margin sizes for all non-cover pages. margin: (top: 1.75in, left: 2in, right: 1in, bottom: 2in), ) + style let doc(it) = { set document( title: info.title-en + " " + info.title-zh, author: info.author-en + " " + info.author-zh, keywords: info.keywords-en + info.keywords-zh, ) it } return ( doc: doc, cover-pages: cover-pages-impl.with(info: info), preface: preface-impl.with(margin: style.margin), outline-pages: outline-pages, body: body-impl.with(margin: style.margin), ) }
https://github.com/fiit-community/base-typst-template
https://raw.githubusercontent.com/fiit-community/base-typst-template/main/README.md
markdown
MIT License
# STU FIIT Typst Template > Author: <NAME> @ic-it ## Preview ![Preview](./thumbnail.png)
https://github.com/maxgraw/bachelor
https://raw.githubusercontent.com/maxgraw/bachelor/main/apps/document/src/3-state/applications.typ
typst
Im Folgenden werden verschiedene Anwendungen von Augmented Reality im Online-Handel vorgestellt. === IKEA Wie in @current-studies-chapter gezeigt, bietet Augmented Reality im Online-Handel neue Möglichkeiten zur Kundeninteraktion und -bindung. Auf Grundlage dieser Informationen wird im Folgenden auf die Augmented-Reality-Strategie von IKEA eingegangen. IKEA ist ein multinationaler Einzelhandelskonzern, der sich auf den Verkauf von Möbeln und Wohnaccessoires spezialisiert hat. Historisch verfügte das Unternehmen vor allem über stationäre Geschäfte, hat jedoch in den letzten Jahren auch den Online-Handel ausgebaut. Nach einem Starken Anstieg des Online-Handels während der Pandemie, ist der Umsatz nach Abschluss der Pandemie zwar leicht eingebrochen, hat sich jedoch im Vergleich zu den Vorjahren stabilisiert @ikea-sales-overview, @ikea-year-review-2023. ==== IKEA Katalog Im Jahr 2013 führte IKEA seine erste Augmented-Reality-Anwendung ein. Diese Anwendung ermöglichte es, ausgewählte Produkte aus dem gedruckten IKEA-Katalog interaktiv zu erleben. Um die Augmented-Reality-Funktionalität zu nutzen, mussten die Produktseite im Katalog gescannt werden. Anschließend diente der zugeklappte Katalog als Raummarker, der die Positionierung und Skalierung des virtuellen Möbelstücks im Raum ermöglichte @ikea-catalogue-ar. Rese et al. untersuchten die Akzeptanz von Augmented-Reality-Anwendungen bei Konsumenten. Hierbei wurden markierungslose Anwendungen mit markerbasierten Anwendungen verglichen. Innerhalb der Studie wurde die Ikea Katalog App als Beispiel für eine markerbasierte Anwendung herangezogen und untersucht. Die Studie kam zu der Schlussfolgerung, dass sowohl markierungslose als auch markerbasierte Anwendungen von den Konsumenten akzeptiert wurden, jedoch eine Präferenz für markierungslose Anwendungen bestand @augmented-reality-apps-accepted. Eine zusätzliche Studie beleuchtete die IKEA Catalog App im Hinblick auf ihren Einfluss auf Kaufentscheidungen. Im Vergleich zum Einkauf über die Webseite stellte sich heraus, dass die AR-Anwendung die Kaufentscheidung positiv beeinflusste @influence-ar-purchase. Dies deutet darauf hin, dass die Möglichkeit, Produkte virtuell im eigenen Raum zu platzieren und zu betrachten, den Kunden ein überzeugenderes Einkaufserlebnis bietet. ==== IKEA Place Nach der Einstellung der IKEA Katalog Anwendunge im Jahr 2017 führte IKEA die neue Anwendung IKEA Place ein. Wie bei der vorherigen Anwendung ermöglicht IKEA Place es Benutzern, Möbelstücke virtuell in ihrem eigenen Raum zu platzieren. Im Gegensatz zur vorherigen App, die auf markierungsbasierter Augmented Reality basierte, funktioniert IKEA Place markierungslos und ermöglicht eine direkte Interaktion mit der Umgebung. Dies wird durch die Nutzung der ARKit-Technologie von Apple ermöglicht, einem Framework, das speziell für die Entwicklung von Augmented-Reality-Anwendungen auf iOS-Geräten konzipiert wurde @ikea-launch-place-app. Eine Studie zur Nutzung von IKEA Place zeigt, dass die Anwendung das Vertrauen der Benutzer beim Online-Kauf erheblich stärkt. Es wurde festgestellt, dass, Nutzer beim Einsatz der IKEA Place-Anwendung ein größeres Vertrauen und eine höhere Kaufbequemlichkeit empfanden. Zudem unterstreicht die Studie, dass die Vertrautheit mit IKEA nicht notwendig ist, um ein Produkt über die IKEA Place-Anwendung zu kaufen @intention-ar-purchase. ==== Ikea Kreativ IKEA Kreativ ist eine weitere Augmented-Reality-Anwendung von IKEA, die es ermöglicht, Möbelstücke virtuell im eigenen Raum zu platzieren. Der Prozess unterscheidet sich jedoch stark von vorherigen Anwendungen: Zunächst wird mithilfe mehrerer Fotoaufnahmen des Raumes ein 3D-Modell erstellt. Anschließend können die Möbelstücke in das Modell integriert und positioniert werden. Der Fokus der Anwendung liegt hierbei auf der Visualisierung einer kompletten Raumgestaltung @ikea-kreativ. Aufgrund dieses Prozesses ist die Anwendung für diese Arbeit nicht relevant und wird daher nicht weiter betrachtet. ==== Ikea App Die zuvor genannten Anwendungen wurden in der IKEA-App zusammengeführt. Hierbei handelt es sich um eine mobile Anwendung, die zunächst grundlegende Funktionen eines Online-Shops bereitstellt. Die Funktionalität der IKEA Place Anwendung kann hierbei auf den meisten Produktseiten aufgerufen werden und benötigt somit keine separate Anwendung. Funktionalitäten wie IKEA Kreativ befinden sich auf speziellen Unterseiten der App @ikea-mobile-app. Durch die Integration der Augmented-Reality-Funktionen in die Haupt Anwendung wird die Zugänglichkeit sowie Benutzerfreundlichkeit der Anwendung gesteigert. === Wayfair Wayfair ist ein US-amerikanisches E-Commerce-Unternehmen, das sich auf den Verkauf von Möbeln und Wohnaccessoires spezialisiert. Das Unternehmen bietet eine breite Palette von Produkten an und gehört zu den führenden Online-Händlern für Möbel @wayfair-revenue, @wayfair-website. Wayfair hat Augmented Reality als Bestandteil seiner E-Commerce-Strategie eingeführt und bietet verschiedene AR-Anwendungen an, um das Einkaufserlebnis der Kunden zu verbessern @wayfair-ar-blog. ==== WayfairView Wayfair führte seine Augmented-Reality-Technologie erstmals im Jahr 2016 mit der App WayfairView ein. Die Anwendung wurde mithilfe der mittlerweile eingestellten Google-Tango-Plattform entwickelt @wayfairview-google-blog. Die Tango-Plattform stellt ein Augmented-Reality-SDK bereit, das es ermöglicht, virtuelle Objekte in der realen Welt zu platzieren und mit ihnen zu interagieren @google-tango. WayfairView ermöglichte es den Nutzern, den Produktkatalog von Wayfair zu durchsuchen und Möbelstücke virtuell in ihrem eigenen Raum zu platzieren. Anschließend konnte die Positionierung der Möbelstücke angepasst werden @wayfairview-apk. Es handelte sich um eine markerlose Augmented-Reality-Anwendung. Es lassen sich keine speziellen Studien im Bezug auf die WayfairView-App finden, jedoch lassen sich Parallelen zur IKEA-Place-Anwendung ziehen. Beide Anwendungen ermöglichen ein markerlose Platzieren von ausgewählten Möbelstücken im eigenen Raum. Dementsprechend lassen sich die Vorteile und der Nutzen der IKEA-Place-Anwendung auch auf die WayfairView-App übertragen. ==== Wayfair App Durch die Einführung von ARCore sowie ARKit wurde die Entwicklung der WayfairView-Anwendung eingestellt, und die Google-Tango-Plattform wurde durch ARCore ersetzt. Dadurch konnte eine plattformübergreifende Funktionalität gewährleistet werden. Die AR-Funktionalität wurde in die Haupt-Wayfair-App integriert, wodurch die Nutzer direkt aus der App heraus Möbelstücke virtuell in ihrem Raum platzieren können. Die Integration der AR-Funktionalität in die Hauptanwendung ermöglicht eine nahtlose Interaktion und verbessert das Einkaufserlebnis der Kunden @wayfair-ar-blog.
https://github.com/polarkac/MTG-Stories
https://raw.githubusercontent.com/polarkac/MTG-Stories/master/stories/023%20-%20Oath%20of%20the%20Gatewatch/004_The%20Blight%20We%20Were%20Born%20For.typ
typst
#import "@local/mtgstory:0.2.0": conf #show: doc => conf( "The Blight We Were Born For", set_name: "Oath of the Gatewatch", story_date: datetime(day: 13, month: 01, year: 2016), author: "<NAME>", doc ) #emph[Zendikar nears its final hours. The machinations of Ob Nixilis, the demon Planeswalker, have freed the Eldrazi titan Ulamog from its prison and summoned its fellow titan Kozilek from Zendikar's depths. Both titans now ravage the land with their innumerable broods, and the Planeswalkers dedicated to stopping the Eldrazi—Gideon, Nissa, Jace, Kiora, and Chandra—have either been defeated or gone missing.] #emph[The remnants of Gideon's army are now left in the hands of Tazri, a human soldier who served as the right hand of the previous commander-general of the Zendikari army, Vorik, and has been serving Gideon in the same capacity. Tazri has been a brave and loyal soldier, and yet was unable to inspire the Zendikari the way the outsider Gideon Jura has. Now the vanishingly small chances Zendikar has in the wake of the combined Eldrazi assault rest in Tazri's hands.] #v(0.35em) #line(length: 100%, stroke: rgb(90%, 90%, 90%)) #v(0.35em) #emph[Your hope cannot be betrayed when you have none to lose. ] That thought was Tazri's consolation these many years, and especially during the rise of the Eldrazi. Each setback and disaster in the long, slow defeat had been received without distress. What point suffering in a war you never thought you could win? But she hadn't counted on Gideon. Just minutes ago, Tazri and her troops had watched in amazement as Gideon delivered the impossible. Ulamog, the great titan of destruction, now shackled and contained. #emph[Have we really won?] It was the closest Tazri had come to feeling delight in a long time, the closest she #emph[could] come. #emph[Vorik was right. He was right to choose Gideon over me. ] That thought was painful, but she was still stunned at the new, improbable futures opening up in front of them. They were going to win. Zendikar was going to survive. Gideon had willed them to victory. Until Kozilek had risen. Until the god of tricksters had played the biggest trick of all. He had waited for Tazri to experience hope before destroying everything. #figure(image("004_The Blight We Were Born For/01.jpg", width: 100%), caption: [Aligned Hedron Network | Art by <NAME>], supplement: none, numbering: none) With Kozilek's arrival, Ulamog had been freed. Both titans were now loose and amok amidst the Zendikari army. Tazri rallied her soldiers away from the collapsing Sea Gate, a reaction more reflexive than strategic. #emph[We are going to die here.] All the preparations, all the victories and sacrifices, all the tales the soldiers told themselves of hope and redemption, all now reduced to the stark truth they knew in their bones. #emph[The end is always faster and bloodier than you expect.] Kozilek had risen, and many horrific ends followed his wake. They fled down the desiccated slope outside of Sea Gate, her soldiers keeping the barest semblance of discipline in their devastation and fear. Tazri aimed them toward the cover of thick-wooded hills inland, to regroup and plan. Hordes of Eldrazi still harried them from the sky, sea, and land, but the biggest threats to continued existence were the two titans loose at Sea Gate. A loud rumbling bellowed behind them. Tazri and the soldiers turned to see what the rumbling announced. The towering obsidian figure of Kozilek filled the horizon. Impossibly gigantic, the titan ate up the light from the sky. It hurt to look at him directly for more than a few seconds, causing a sharp jab of pain behind the eyes for any who dared. Kozilek was striding at an angle toward them, and Tazri was relieved to see he would miss them by a few hundred feet. #figure(image("004_The Blight We Were Born For/02.jpg", width: 100%), caption: [Kozilek, the Great Distortion | Art by <NAME>], supplement: none, numbering: none) But as Kozilek moved over the horizon, a shimmering wave of #emph[something] roamed over the land, a pulsating, translucent ripple emanating outward in all directions from the great titan. The wave rushed toward them, and Tazri didn't even have time to scream as it crashed upon them. Time slowed. Insanity blossomed. Romoe's skin inverted itself, ripping and shredding on the sides of his body as he turned inside out, screaming only for a moment before mercifully dying. As the wave passed over Magain, he visibly became younger, transforming into a young stripling, then a child, then a baby, and then a small mote before vanishing, all in the space of several seconds. Debins turned to run and suddenly the left side of his body was gone. Half of him sheared away in a flat square pressed to the ground, a bloody stain where some invisible force had ground him into the bare earth. The other half of Debins floated free in the air, seemingly no longer tethered to the ground or reality. The half of his face that had not been squished had a look of profound surprise and horror, even as it floated higher into the air. #figure(image("004_The Blight We Were Born For/03.jpg", width: 100%), caption: [Reality Hemorrhage | Art by <NAME>], supplement: none, numbering: none) The wave hit Tazri. The angel's halo around Tazri's collar glowed with golden heat. Time, previously slowed, now #emph[stretched] . Events and actions from her past and future flickered in her mind, became her mind, became her #emph[now] . All her previous life, flickering, flickering into existence. All her #emph[future] life, flickering, flickering into existence. Time and space stretched further, straining. Snapping. Reality stopped. #emph[flicker] #v(0.35em) #line(length: 100%, stroke: rgb(90%, 90%, 90%)) #v(0.35em) "Halt!" Tazri raised her hand, and the wagons in the merchant caravan rumbled to a stop. The guards had all seen the crows circling the hills to the west. Mahir would want her to press on, but something felt wrong. #emph[That's why he pays me. To yell at me when I delay his precious cargo. ] Mahir raised a flap from inside a tented wagon, but when he saw her face he sighed and let the flap drop. This was her seventh caravan trip with Mahir, and he had already made her captain of his guard two trips ago, though she had not yet seen a full twenty years of life. The youngest he had ever had, though of course he wouldn't tell her that. But she knew anyway. And she knew to slow down and pay attention when something was wrong. "Golamin, Rillem, ride out wide, north and south, one each. Use horns if anything looks remotely funny and then right back here. Don't be heroes. Something's wrong. Romoe, you're with me." The men nodded and Golamin rode north on the trail as Rillem rode south. One of Mahir's nameless twin bodyguards was driving his wagon. Tazri never could tell the twins apart, and they didn't speak her language anyway, so she just pointed at the tall cliffs to the east and mimed looking out. Neither twin was the brightest of men, but she expected he understood enough. She made sure the rest of the caravan drivers had their horns at the ready. She headed west on her horse, Romoe just behind her. The middle of the Tazeem run was usually the easy part. The merfolk mostly kept to themselves, and while vampires made raids on the coast of Tazeem over from Guul Draz, they rarely came this far inland. Usually the only excitement in this part of the run was a rampaging baloth or the ground falling away into a pit cave. But the crows knew something exciting was happening. Or had already happened. Tazri ignored the acid in her stomach and pressed on. #figure(image("004_The Blight We Were Born For/04.jpg", width: 100%), caption: [Needle Spires | Art by <NAME>], supplement: none, numbering: none) They came upon the first corpse after they crested a large hill onto a flat grassy plain. The corpse had been split in half lengthwise. A very, very dead vampire. The edges of each half of the corpse were jagged and burnt. #emph[A sword, a large sword, and presumably on fire. ] Tazri didn't know who she hoped had won the fight, the vampires or the other side. There were more corpses, and Tazri and Romoe dismounted, though they still held their reins. The horses were skittish. Five more vampire corpses, though the deaths were less violent; mere decapitations and bleed-outs instead of sundered corpses, with burnt flesh marking each jagged cut. Tazri had only fought against a vampire once, and she would have easily died were it not for the fact it was four versus one. The vampire had been faster than her, and stronger than her, and killed with sickening ease. She did not want to fight whatever was able to kill six vampires with a flaming sword. They heard a female voice humming a strange melody before they saw the body the voice belonged to. The angel was lying against a tall outcrop of rocks, her body half-turned and twisted. Both wings on one side were ripped off entirely, the others bent and torn. Blood and a faint white glow gushed from her side. It was a lot of blood. There were bites and gashes on her arms and torso, and even more blood leaked from her neck. Three more vampires lay dead around her, one with a giant sword through his chest and one with his neck nearly snapped off. The angel turned her head to look at them, and though every part of her was ravaged, her halo still glowed a beautiful, lustrous gold. The angel coughed, blood and more of the white glow sputtering up from her breath onto her chest. #emph[How is she still alive?] Tazri had never before beheld an angel, and regarded her beauty and power in stunned silence. "Can you...can you help me?" Each faint word haltingly uttered caused more coughing, more blood, more dying. Tazri, who had killed and seen friends killed often in her young life, who had never before shed tears during a fight, began crying. "We have no healer." Mahir would never splurge for something so expensive. "Can we move you? Can you heal yourself?" Tazri knew the question was ridiculous, but the thought of someone killing nine vampires was ridiculous. Who knew what an angel could do? The angel shook her head. "I am. I am dying. Might...days. Help." The angel stared at the sword at Tazri's side, still in its scabbard. #emph[No] . #emph[No!] "If you can last, we can get you help, we can go back to Sea Gate or Coralhelm, find someone..." One, two, three horns blared in the distance. #emph[No!] "Tazri..." Romoe's voice, pulling her back. "You can heal, we can find someone..." Tazri's mind raced, desperate for answers. The angel's voice, weak and reedy, still cut her off. "The vampires...coming back. There are more. They have healers. They will keep me...alive, a...long time. Please. Help me. End. Me." The angel gazed once more at Tazri's sword, and then back at Tazri. Their eyes met, and Tazri beheld the pain and the longing there. The longing to be safe from fear and pain. The horns sounded again, all of them. "Tazri, we have to go back, right? Tazri!" The panic grew in Romoe's voice. Tazri wiped away her tears. She drew her sword. "Tazri? Killing an angel is bad. Don't do it. It's a curse. Everyone knows that. Tazri, we have to go. We have to leave her." Romoe sounded like the child he nearly was. The angel grimaced, still staring up at her. Blood trickled out of her mouth. "He is...right. There is a...price. Killing me will cost...you. I cannot...cannot stop it. I am...sorry. Please...do it. Please do not...abandon." The horns, a third time. Tazri raised her sword. The angel's halo glowed a candescent white, a blinding, burning glow, and Tazri heard a beautiful voice inside her head, though she could not make out any of the words. Then the halo dimmed, and the glow died. The voice inside her head abruptly ceased. The hilt of Tazri's sword became cold to the touch, and she left it embedded in the chest of the angel. There was a small, still smile on the angel's face. The acid and anxiety were gone from Tazri's stomach, but something else was gone, too. Something she couldn't quite name. She reached down to take the dull gray halo from the angel's eyes. It parted easily from the corpse with her touch. #emph[All things beautiful tear so easily.] Tazri and Romoe mounted their horses and turned around amidst the cry of the horns. #emph[flicker] #v(0.35em) #line(length: 100%, stroke: rgb(90%, 90%, 90%)) #v(0.35em) Tazri kept her head down, waiting to be called. She didn't expect to be here long. Word spread fast along the caravan roads. The last few attempts to get work had ended without them even letting her speak. Now she was reduced to asking for a #emph[militia] position. Once upon a time she would have been enraged at the thought. Now she just sat on the bench, and waited. "Tazri." She looked up at the deep voice. He was medium height but with a broad, strong build, with thick legs and arms. A fighter's build. Even the way he stood bespoke a natural balance and strength she associated with good fighters. Most militia she had come across were fat or old and could only dream of being caravan guards. It spoke well of this Vorik that he had such a capable soldier in his retinue. "Yes. I'm here to see Vorik." She hated the tinge of desperation in her voice, hated that she was eager to join a bunch of sedentary bureaucrats who probably regarded their plans for lunch as a major adventure. But she hated even more the thought of not getting the work. Of being alone. #figure(image("004_The Blight We Were Born For/05.jpg", width: 100%), caption: [Fortified Rampart | Art by David Gaillet], supplement: none, numbering: none) The man smiled. A broad, easy smile that a few years ago might have quickened her heart. "I'm Vorik. Why are you here, Tazri?" She hesitated, unsure of where to begin. Even #emph[how] to begin. She just looked at him, and remained silent. There were other jobs, certainly, right? There were other militias besides Sea Gate. She thought furiously about who else she knew, who else could... "Four years ago, you were the youngest caravan captain on the Tazeem roads, the prized jewel of Mahir, who so covets his talented workers. You were wicked with a sword..." he looked down briefly at her side, "...hmm, a mace? A brutal weapon, and difficult to wield well." A spark flared in Tazri and she rose to look Vorik in the eye. "I'm wicked with a mace, too. You can find out if you'd like. I don't use swords anymore." "Fair enough." There was the smile again, though this time she just found it annoying. She didn't need to be reminded of the life she had, of what she had lost. "And then Mahir fired you. As did the next five merchants who thought they were getting such a great bargain. The amazing Tazri, who was no longer quite so amazing. So again, Tazri. Why are you here?" She wanted to tell him,#emph[ I no longer dream. It's not that I don't remember them. I just don't have them anymore. I used to dream of places I had seen as a guard, of my parents, of fights and loves and fears. And now there's an emptiness between when I go to sleep and when I wake up, and the emptiness is still there after I rise. It's there right now, it's always there, and I don't know how to fill it. How do you replace something for which you no longer know the name?] She wanted to say all those things, but she couldn't, so she didn't. She waited instead. "As it happens, I like soldiers who don't talk much. And I understand soldiers who need time to work through things. We all do, Tazri. I could use a fighter like you. And a leader like you. I know what you can be. Can you be that leader again, Tazri?" Tazri nodded her head mutely. If she had been able to cry, she'd be bawling. But instead she just continued to nod, hoping desperately she could be that person again, while a part of her knew that Tazri was gone forever. #emph[flicker] #v(0.35em) #line(length: 100%, stroke: rgb(90%, 90%, 90%)) #v(0.35em) "...hope. I have hope that that is not true. I have hope that there is still a chance for Zendikar. <NAME>, you have given me hope." Each time Vorik spoke the word, it was like a sword through her chest. #emph[Hope] . Was this life's revenge for her inability to help him? #emph[You saved me, and now I cannot save you.] And he had saved her. She had worked for him for fifteen years. Fifteen good years where she had risen to truly be his right hand. She would never again be the leader she was back when she was young and everything was easy. Back before the angel. But with Vorik's help, and Vorik's patience, and Vorik's trust, she had found other ways of being valuable. Of being valued. #figure(image("004_The Blight We Were Born For/06.jpg", width: 100%), caption: [Stone Haven Medic | Art by <NAME>], supplement: none, numbering: none) She was lost inside the morass of her own grief when Vorik's words broke through her despair. "...when I am gone, you will lead these people. You will reclaim Sea Gate, Commander-General Jura." "No." Tazri gasped, her mind whirling. She felt betrayed, by Vorik and herself. #emph[How could you not choose me as your successor?] #emph[Why could I not figure out how to be the person I was? How could I let you down, over and over?] Both thoughts hit her simultaneously. Vorik had continued speaking, but she could not parse any of his words in her tumult. Automatically her mouth worked independent from her mind, carrying on a token display of resistance while she crumbled inside in grief and anger. #emph[He's dying. He's dying and soon he will be gone. And then what will you have? Whom will you love?] And then, #emph[Zendikar will follow. Vorik will die. Zendikar will die. The only person who will not die is you. You died a long time ago. Soon everything will be empty and void, just like you.] The horrifying thought warmed her, filling her emptiness, if only for a moment. #emph[flicker flicker flicker] #v(0.35em) #line(length: 100%, stroke: rgb(90%, 90%, 90%)) #v(0.35em) #figure(image("004_The Blight We Were Born For/07.jpg", width: 100%), caption: [Spatial Contortion | Art by Daarken], supplement: none, numbering: none) Tazri screamed as reality crumbled. Each memory, no, the #emph[actual living ] of her past was being experienced #emph[now] , all moments occurring simultaneously, a kaleidoscopic display infinitely unfolding. The halo around her neck, the angel's halo, was now a candescent white, and the heat burned. Even as her mind sought refuge from the flickering onslaught of the past, it was assaulted by the future... #emph[flicker] #v(0.35em) #line(length: 100%, stroke: rgb(90%, 90%, 90%)) #v(0.35em) Tazri smiled widely as her master held Gideon in the clench of his fist. Gideon screamed, and a golden shield flickered into existence briefly around him before failing. Her master was the lord of time and space, and he would not permit such improprieties. #figure(image("004_The Blight We Were Born For/08.jpg", width: 100%), caption: [Call the Gatewatch | Art by <NAME>], supplement: none, numbering: none) The corpses of the other interlopers lay nearby. Here they had decided to make their final stand, and the stand was brief and laughable. There were the ashy remains of the fire mage, burning herself out in a futile attempt to harm Tazri's master. There was the drained husk of the elf, who had sought to meld her essence with the world and shared the world's fate as a result. And there was the mutilated corpse of the mind mage. He had conjured up hundreds of illusions as his final trick, and could only watch in horror as his own illusions turned on him, wielding their illusionary swords and puncturing his body through and through. As each one struck they spoke the name, "Kozilek." #emph[Kozilek] . The name filled her mind, filled her emptiness, had finally made her complete. She could barely recall the shimmering translucent wave that had hit her, that had killed all her false friends but left her alive, remembering nothing. All she had known as she regained consciousness was the name pealing like the sweetest bells in her mind. #emph[Kozilek. Kozilek. Kozilek] . Everything had become so clear. She had fought for Kozilek and watched as her master's army had swept before them, culminating in this victorious day. #figure(image("004_The Blight We Were Born For/09.jpg", width: 100%), caption: [Kozilek's Return | Art by <NAME>], supplement: none, numbering: none) Ulamog and his ilk were nowhere to be found. Perhaps they had been slain or departed; it mattered not. All that remained on the battlefield were the loyal armies of her master. And the last enemy. The last foreign invader to be eliminated, <NAME>. She had not liked <NAME> in her previous life, before Kozilek had saved her. But there was even more reason to hate him now. The mere presence of his opposition offended. How could such a puny, frail vessel have the temerity to challenge the lord of reality himself? <NAME> needed to be punished. Kozilek squeezed, and no mortal frame could withstand such pressure. <NAME> burst, and a bloody bag of ruptured flesh and broken bones fell limply to the ash-white earth below, there to join the corpses of his friends. Tazri cheered and leaped, ecstatic to be witness to such glory. A strange thrumming grew in Tazri's ears. It was not coming from the air, or through the ground. It was coming from inside her. The thrumming grew and deepened, and only gradually did Tazri guess at the sound. It sounded like laughter. The laughter of Kozilek. The thrumming resonated throughout the sphere. Tazri shared in her master's joy, but could not perceive the cause of such mirth. Kozilek raised an arm, and there was a #emph[ripple] in space, and <NAME> appeared once more before them, whole and resurrected. He was once more clenched in Kozilek's fist, but in his terror and screams it was apparent that <NAME> #emph[remembered] . Remembered dying, and now he was to die again. Kozilek squeezed and <NAME> once more found the embrace of death. Tazri squealed in delight. Now she understood her master's mirth. Her master wielded time and space. What consequence to manipulate a small part of such materials to ensure an impudent enemy be made to suffer? Again, and again, and again. Another twitch, another #emph[ripple] , and <NAME> was reborn again, and his terrified cries were delicious. #emph[flicker] #v(0.35em) #line(length: 100%, stroke: rgb(90%, 90%, 90%)) #v(0.35em) The storm raged. Fractal bismuth clouds burst charmed hedrons, while strangularities drizzled onto top-heavy asymmetries. It wasn't working. None of it was working. For the first ten thousand years after Kozilek's disappearance, Tazri had used her new powers to attempt the reconstruction. But Kozilek was a poor creator, nothing like his eldest sibling, and Tazri's gifts were a pale, stunted imitation of her master's. At first she thought it was just a problem of talent, of improvement. Of course she couldn't re-create every detail of Zendikar the first time. It was impossible. But the hundredth time? The thousandth? If she kept improving each time, eventually, inevitably, she would create Zendikar, perfectly, utterly. #figure(image("004_The Blight We Were Born For/10.jpg", width: 100%), caption: [Wastes | Art by Raymond Swanland], supplement: none, numbering: none) And then he would come back. Zendikar re-formed would call to him, just like it did the first time. It had to. It would just take time, and all the time there was was for her. Eventually she came to realize the flaw in her logic. She was still too human, even after millennia. While she had undergone major transformations of body and mind during Kozilek's glorious reign, too much of her remained flawed, weak. In the wake of Kozilek's disappearance, her power and control was immense, all the strata of automatons were hers to control. But of course she couldn't achieve her quest with her will alone...she was human. Humans should never aspire to ambitions of the gods. #figure(image("004_The Blight We Were Born For/11.jpg", width: 100%), caption: [Essence Depleter | Art by Chase Stone], supplement: none, numbering: none) But what if instead of seeking to direct the change, she merely provided the right environment for change? If she could just provide the right starting conditions, then eventually the materials would form into the right Zendikar, perhaps just the way the original Zendikar formed. Again, all it should take was time. Her latest obsession was with weather. But even her simplest experimentations did nothing like she expected. And any foray she made into more complex systems quickly spiraled into chaotic randomness. There were no patterns, no beauty, no chance of Zendikar reappearing. She took a deep breath #emph[why are you are still so human, stop breathing, you don't need to breathe ] and went back to work. She wanted him back. #emph[Why did you leave me? Was I not a good soldier? We had won. Where are you now? Do you miss me? ] She wanted his laughter again, his comforting presence. She wanted her emptiness to once more be filled. She would keep on trying, keep on improving, keep on understanding. She turned her face to the strange rain, feeling it fall on her simulated cheeks. #emph[flicker] #v(0.35em) #line(length: 100%, stroke: rgb(90%, 90%, 90%)) #v(0.35em) The stars and sun were long black and dead, and nothing moved nor stirred. Tazri lay deep in the earth, wrapped in cocoons of energy and pattern. She had stored all the energy she could billions of years ago, determined to wait as long as she could. Kozilek would come back. This she knew. She just had to be there when he did. Most of the time she slept, but she needed to wake for periods of time to readjust her cocoons and make sure she did not perish during her next long sleep. She needed to conserve all the energy she could; to keep entertained, she told herself stories. Eventually she settled on her favorite story: the day Gideon died. She would tell the story over and over, lingering on the deaths of each outsider, and then each and every death Gideon suffered on that near-endless day. The story took so, so long to tell, and when she was done she would tell it again. Each time she said the words she would remember the warmth of Kozilek's laugh, how complete his presence made her feel. Though she had not seen him for trillions of years, she knew she would. And then all would be right. And in the void between, she had her sleep and her stories. They were all she needed until Kozilek returned. "This is the story of the day Gideon died." #emph[flicker flicker flicker] #v(0.35em) #line(length: 100%, stroke: rgb(90%, 90%, 90%)) #v(0.35em) Tazri's mind was disintegrating under the pressure. What mortal could withstand a glimpse of infinity? A part of her, deep inside her ravaged mind, wondered how she had not already crumbled, surrendered to the vast void. The glow of the angel's halo brightened. There was something...#emph[soothing] in that glow. Something buffering the horror, a salve removing the bitterest stings of insanity. But for the warmth and power of the angel's halo, she would have plunged into the gibbering abyss from which there was no return. The halo around her neck pulsed and thickened, its light shining ever brighter, a near-infinite whiteness to fill the void. The white light flashed, and the rest of the world disappeared. Tazri stood? Floated? Existed. Existed in a featureless white plane. All her soldiers, all the Eldrazi, all Zendikar, all were gone. Memories retreated from her mind. There had been a future, something...horrific. Like a fever dream from which there was no return, dark, never-ending, and terror throughout. She tried to hold on to the dream, but it disintegrated as she sought its reclamation. She was relieved at the loss. A small part of the endless white in front of her #emph[wrinkled] , coalesced. She saw a face first, a perfect face, and then below the face a body formed with arms and legs and four wondrous wings, two on a side, unfurled and wide. #figure(image("004_The Blight We Were Born For/12.jpg", width: 100%), caption: [Angelic Gift | Art by <NAME>], supplement: none, numbering: none) It was the angel she had killed twenty years ago. #emph[An infinity ago] , some errant thought whispered. To her great surprise, Tazri started crying. "Where am I? How is..." she gestured around at the expanse of white, "any of this possible?" The angel smiled, and Tazri basked in its glow. More horror and memories receded from her brain, melting away in the warmth and love of that smile. Though neither the angel's face nor lips moved, Tazri heard a gentle voice in her mind. "We are outside of time, Tazri. Outside of the domain of Kozilek. In the throes of Kozilek's field, for you all time was compressed to #emph[now] . It was just the shortest motion to come outside of #emph[now] , to be free of time. You are safe here." At the mention of the word #emph[Kozilek] , Tazri flinched, though she could no longer remember why. The name struck a chord in her, a ringing of dark bells that thrummed not just through her head but through her entire body, the deepest parts of her bones. She could not tell whether the feeling was great horror or great delight. It was both. An abyss threatened to open up again before her, one into which she could plunge and never return... The angel's face was once more in front of her, smiling, bringing her back to herself. "You have been gravely injured, Tazri, for many years. It is time for you to be restored, past time." She remembered her crime. She was plunging the sword into the angel, delivering death to a creature of such purity and beauty—how could that not be punished? "You should be healed..." "No!" The ferocity of Tazri's response took her by surprise. When was the last time she had felt anything so clearly, so strongly? So #emph[purely] . "The sacrifice was mine to give! You told me there were consequences, and I did it anyway. I paid the price, and I paid it willingly! You cannot take that away from me!" The immensity of what Tazri had lost these twenty years became fully realized. Never to know confidence, or desire, or joy. Never to be fully engaged in the present, striving toward a better future. Never to know #emph[hope] . She had lost so much. #emph[It was my choice to make!] "Tazri, you have suffered for an eternity. You have suffered #emph[enough] . You are forgiven." "I don't need your forgiveness!" Tazri snarled. "Not my forgiveness. Yours." Twenty years ago, Tazri had killed an angel and something had broken inside. Now something was #emph[connecting] . Re-forming. Becoming whole. Tears flowed freely from Tazri, and more than tears—all the emotions dormant for years rushed back. She buckled under the onslaught. #emph[How can I survive this?] A pause, and then, #emph[You have survived through much worse.] She took strength from the confidence in that voice, only slowly realizing the voice was hers. "Kozilek's field is passing through you, Tazri. Time will resume. You will resume." #figure(image("004_The Blight We Were Born For/13.jpg", width: 100%), caption: [Make a Stand | Art by Magali Villeneuve], supplement: none, numbering: none) Reality was starting to intrude in the white space of Tazri's mind. Kozilek. Ulamog. The titans freed and running amok. Gideon and his friends lost or dead. #emph[How could Zendikar win? How could Zendikar survive?] "Kozilek can influence time and space, Tazri. This is true. This is its purpose. But time and space are merely two dimensions in all the panoply of what is." The voice was starting to fade, as was the white light pervading her senses. Reality, true reality, was beginning to appear on the outskirts of her perception. "I don't understand. Please, help me." "Kozilek, for all his power, for all his dominion, could never do what you did twenty years ago. Such dimensions are unmasterable, unknowable, by him and his ilk. But not by you. You, who loved. You, who sacrificed so much for a sentient being you never knew. You, who had mercy for a dying angel and were willing to pay the price. Time and space are meager domains compared to the kingdoms of love and mercy." The voice was merely a whisper now, and the whiteness reduced to a small sphere around them. The form of the angel was dissipating. "You will not remember much from your interlude here. You cannot and still remain whole. But remember this. #emph[You can win. ] You will win. There is no other option." And then that beautiful voice was gone, and reality reasserted itself with rolling thunder and flame. #v(0.35em) #line(length: 100%, stroke: rgb(90%, 90%, 90%)) #v(0.35em) Lightning and fire struck from the skies into hordes of Eldrazi surrounding the ruined dam of Sea Gate. Everywhere Tazri looked she saw dead friends, corpses that a second ago were alive and running; now they were strewn like debris in the wake of a storm. Tazri couldn't understand what had happened. She had been running away from catastrophe, and turned to see the dread figure of Kozilek...and then there was a blank space, a momentary blink, and now her soldiers were dead, and only she was alive. She scanned for Kozilek, but he was already far in the distance walking away from them, as if he had somehow teleported a great distance in an instant. #figure(image("004_The Blight We Were Born For/14.jpg", width: 100%), caption: [Witness the End | Art by <NAME>], supplement: none, numbering: none) The fire and lightning were joined by ambuscades of earth, rising up out of once-even ground to crush and pulverize Eldrazi. Tazri saw four figures behind her, with the lead figure a familiar merfolk. #emph[Noyan Dar] . Noyan raised his arms and wind-funneled fire swept from surrounding infernos, channeled into incinerating blasts against large Eldrazi. One of the large Eldrazi twitched and a shimmering field interposed between itself and the earth's fury. The sweeping earth and fire disappeared into the shimmering field only to reappear from another shimmering gateway that sprang into existence behind Noyan and his roilmages. Tazri didn't have time to shout a warning as the fire and earth swept through the roilmages, obliterating them. #figure(image("004_The Blight We Were Born For/15.jpg", width: 100%), caption: [Maw of Kozlikek | Art by Daarken], supplement: none, numbering: none) Obliterating them all except one. A spur of rock and earth launched up from the carnage, carrying Noyan Dar with it. It catapulted him hundreds of feet into the air, and despite his prodigious powers, Tazri could not imagine anything but a fatal end to his flight. He plummeted, flailing, attempting to weave a final spell, when a dark figure swooped in and intercepted his flight close to the ground. With the dark figure came hundreds more, waves of troops flying and running, slaughtering Eldrazi spawn in scores. Tazri could make out the terrifying figures of vampires, but also humans, kor, elves, and merfolk. She saw Munda and several others she recognized. And the flying figure who had saved Noyan was... #figure(image("004_The Blight We Were Born For/16.jpg", width: 100%), caption: [Drana, Liberator of Malakir | Art by Mike Bierek], supplement: none, numbering: none) #emph[Drana] . Tazri had never liked the vampire queen. Cold, imperious, her presence reminded Tazri of a crocodile. Calm and placid until it was all teeth and aggression and you were dead. Tazri did not trust Drana, but she was ecstatic the vampire lord was here now. Drana dropped Noyan onto the ground and landed in front of Tazri. The anger on both their faces was plain, but there was something different there, too. They both were uncertain, hesitant. #emph[Kozilek] . #emph[Kozilek upsets all equilibrium.] Tazri couldn't imagine anyone else being struck by the same shimmering wave that had struck her. Otherwise they would be dead, presumably in some horrific way, though Tazri still could not fathom how she had survived, or why she couldn't remember anything about the experience. But one didn't need to have been directly in the wake of Kozilek to feel its effect. All of reality trembled before Kozilek. The arrival of Drana's and Munda's troops had temporarily turned the tide of battle. For the first time since Ulamog had broken his chains, the Zendikari were not beset by Eldrazi horrors. But the situation was still dire. They were nearly surrounded, and more than half of them had already perished. Without a clear plan, one in ten would be lucky to survive. Then Zendikar would be truly lost. Amidst this chaos and loss, someone needed to take charge. There was a brief moment of doubt. #emph[Who am I to be that leader?] And then the doubting voice was silent, replaced by a voice twenty years gone, but intimately familiar despite all that time. #emph[I am Tazri. I have bled and battled for Zendikar. I have trained under Vorik for fifteen years, learning the shape and sweep of high command. I am here for my people and my land. I am Tazri, and that is enough.] Somewhere deep in her mind echoed the sound of a sweet, pure voice, and Tazri felt giddy as she assumed command. "Drana, how many people do you have left?" Drana looked at her and said nothing, either still stunned at the events of today, or unwilling to acknowledge Tazri's lead. Perhaps both. "Drana!" Tazri's voice lashed out, without anger, but with clear imperious command. Drana's eyes narrowed, and a hint of a predatory smile returned, but she answered. "A thousand. Strong warriors, but fighting Kozilek spawn is not easy. Power and strength alone are not...sufficient." That same haunted look appeared in Drana's eyes again, though the unnerving smile did not leave her face. "Noyan, how many roilmages are there?" If Drana looked uncomfortable, then the powerful mage <NAME> looked truly lost. "They...they are dead. Almost all of them. And the ones who survive cannot do much. I..." <NAME> broke down sobbing. Tazri wanted to cry with him, to mourn all the dead, but the living needed a different response. "Noyan, you cannot do anything for them now. I promise you vengeance for the dead and hope for the living. Noyan!" Noyan looked up. "Yes, Tazri. Yes. What do you need from me?" Noyan's grief was replaced by anger. Anger and purpose. #emph[Perfect] . "I need a rift, a big rift between us and the Eldrazi swarming around Sea Gate. Everyone still at Sea Gate is either dead or dying. We can't do anything for them. But there are still thousands of us here." "Yes, I can do this. But I will need time, especially doing it alone." "You won't be alone, but get started. Munda, prepare the troops. We are getting out of here. If they can't move, we're leaving them." Munda did not hide his anger or anguish. "You cannot..." #figure(image("004_The Blight We Were Born For/17.jpg", width: 100%), caption: [Allied Reinforcements | Art by <NAME>], supplement: none, numbering: none) "I can. I will. If we stay here, we die. The gravely injured face the same fate no matter what we do. We need to live. Zendikar's only hope rests with us." Munda stopped, peering closely at her. He was unused to a forceful Tazri. But he had served alongside her. He knew her. He nodded and went off to prepare everyone else. "Drana!" The vampire queen had been giving her own orders to her vampires, but she slowly turned, smiling languidly the entire time. "Send flying scouts and see if there are any large groups of capable fighters still left. And be on the lookout for Gideon. We need him and the others back." "Bah. The warrior is dead. Or will be soon." Drana's voice dripped with scorn. "No, he's alive. And we will find him." Several soldiers around her perked up, hope flaring in their eyes where before had been despair. Tazri was amazed at how confident she was. But she was certain Gideon was alive. She needed Gideon for them to have a reasonable chance of winning this war. Therefore, Gideon was alive. The logic would have struck her as bizarre and faulty just yesterday. #emph[Irrational confidence is the greatest gift a leader can give her people.] "Get those scouts moving, Drana." "My my, such the little general. Yes, General Tazri, but of course! One question, though...why should I listen? If I wanted to listen to random opinions, I promise I find mine the most compelling." #emph[General Tazri] ...said in scorn, but Tazri admitted she liked the sound of it. #emph[Time to roll the dice. ] She approached Drana close, put her lips to the vampire's ear, and whispered. "You are more powerful than I am, Drana. More powerful than probably all of us." Drana's smile turned coy. "Your people talk, Drana. We know what you did, what you can do. But you know while the vampires of <NAME> follow you, the rest of Zendikar never will. There's too much fear of vampires. Too much fear of #emph[you] . So I will lead. Think of me as a figurehead if you want. We can kill each other later, once all the Eldrazi are dead. But until the Eldrazi are dead, I #emph[am] going to lead this army. I need your help, though. #emph[Zendikar] needs your help. Please." Tazri realized she was holding her breath in, and slowly released it. #emph[No more fear. ] Not ever again. Drana moved away from Tazri and stared at her, her smile gone. In Drana's eyes Tazri felt the presence of something ancient and alien, an intimidating look that would have had her on her knees in terror an hour ago. #emph[I have lived for an eternity, little vampire. Your brief interlude of existence is the merest morning dew.] Tazri didn't know where the thought came from, didn't even understand what it meant, but the thought comforted her, and she smiled. Drana's face grew uneasy, and she looked away. When Drana looked back, she was all smugness and superiority again, her wicked smile once more in full display. But Tazri knew it was an act. #emph[Time to push.] "One more thing, Drana. I need you to funnel energy to <NAME>. He doesn't have any roilmages to help him, so you need to be his energy source. I need you to make it happen." Tazri could feel the anger from Drana, could see reality unfolding in many different ways, some of them quite short and bloody ends for herself. But she focused on the outcome she wanted, the outcome she #emph[needed] . After a long pause, when Drana said simply, "As you command, General Tazri," both of them knew Drana meant it. #emph[At least for now.] The Eldrazi were beginning to mass again along the Sea Gate front. Although both Ulamog and Kozilek were occupied elsewhere, there were enough spawn here to make life increasingly difficult. "Noyan! I need that spell now!" Ulamog and Kozilek loose and rampant. Half of the Zendikari army destroyed. Gideon's whereabouts unknown. And Tazri had lost near half of her life in a dormant fog that only today had been lifted, all due to an act of mercy that had cost her near everything. Tazri thought about all of it, and discarded it. #emph[This is where I want to be. This is what I was meant to do.] The battle for Zendikar had not been lost. The battle for Zendikar was now truly beginning. And Zendikar was going to win. She heard the beautiful voice of an angel sing, and <NAME> smiled. #figure(image("004_The Blight We Were Born For/18.jpg", width: 100%), caption: [General Tazri | Art by <NAME>], supplement: none, numbering: none)
https://github.com/PmaFynn/cv
https://raw.githubusercontent.com/PmaFynn/cv/master/src/content/en/interests.typ
typst
The Unlicense
#import "../../template.typ": * #cvSection("Personal Interests") #cvInterestTags( tags: ("Literature", "Bouldering", "FOSS", "GNU/Linux", "Autodidacticism", "Vim Key Bindings", "Music"), ) /* #divider() #cvInterestDescription( description: list( [#lorem(15)] ) ) */
https://github.com/ljgago/typst-chords
https://raw.githubusercontent.com/ljgago/typst-chords/main/docs/assets/template.typ
typst
MIT License
#let acent(body) = box( fill: luma(85%), radius: 2pt, outset: (y: 4pt, x: 2pt) )[#body] #let design( title: "", subtitle: "", authors: (), url: none, date: none, version: none, body, ) = { // Set the document's basic properties. set document(author: authors, title: title) set text(font: "Linux Libertine", lang: "en") set heading(numbering: numbering("1.", 1)) show heading.where(): it => { if it.level in (1, 2, 3) { block(it, above: 1.2em, below: 1.2em) } else { block(it.body, above: 1.2em, below: 1.2em) } } show link: set text(fill: rgb("#1e8f6f")) v(4em) // Title row. align(center)[ #v(10em) #block(text(weight: 700, 5em, title)) #v(4em, weak: true) #block(text(1.0em, subtitle)) #v(30em, weak: true) v#version #h(2.6cm) #date #v(1.5em, weak: true) #block(link(url)) #v(1.5em, weak: true) ] // Author information. pad( top: 0.5em, x: 2em, grid( columns: (1fr,) * calc.min(3, authors.len()), gutter: 1em, ..authors.map(author => align(center, strong(author))), ), ) v(3cm, weak: true) // Main body. set par(justify: true) v(10em) // Configure page properties. set page( numbering: "1 / 1", header: locate(loc => { let i = counter(page).at(loc).first() if i in (1, 2) { return } if calc.odd(i) { h(1fr) + text(0.95em, smallcaps(title)) } else { text(0.95em, smallcaps(title)) } }), ) body } // Custom syntax highlighting for "typ" #let custom(source) = { set raw(theme: "halcyon.tmTheme") show raw: it => block( width: 100%, fill: rgb("#24292e"), inset: 8pt, radius: 5pt, text(fill: rgb("#f6f8fa"), it), ) source }
https://github.com/felsenhower/kbs-typst
https://raw.githubusercontent.com/felsenhower/kbs-typst/master/examples/template.typ
typst
MIT License
#import "../typst-modules/typst-physics/physics.typ": * #set text( lang: "de" ) #set page( width: 80mm, height: auto, margin: 1mm )
https://github.com/devraza/warehouse
https://raw.githubusercontent.com/devraza/warehouse/main/blog/server-hardware-selection.typ
typst
MIT License
#import "template.typ": conf #show: doc => conf( title: [ Selecting hardware for a (home) server ], doc, ) = Introduction I see a lot of people worryingly mistaken about what a server needs \(specifically, a home server). Some think that a bland and incredibly ignorant '20% budget for CPU, 30% for GPU, and the rest for the rest' plan for selecting hardware is good enough \(at least, before choosing specific items) - you can’t exactly be #emph[wrong] when choosing hardware, but this is very, #emph[very] far from right. = Requirements Server hardware needs to be low-power and resource-efficient - so as not to waste any money unnessarily, obviously. Your budget will strongly impact the specifications you can get your hands on, but I would think that even \$200 is enough for a decent home server - depending on what you want to do with it. Keep in mind that you could always repurpose an old laptop or desktop lying around; it’s cheap, and you get what may be a surprisingly decent machine. == Power consumption The difference between low #emph[peak] and low #emph[idle] power should be noted in particular. Running costs can get very high if you don’t work to moderate power consumption, and probably wouldn’t be something you would ignore when it comes to home servers. == Usage of the server Naturally, how a server will be used will affect pretty much everything about the hardware chosen for it. For example, if you’re looking to stream games remotely, you’d go for a \(perhaps powerful) dedicated GPU and would likely invest in some high-speed internet solution. As indicated by the above example of the GPU, you need to be #emph[very] specific with what you choose - do you #emph[need] a powerful GPU or do you not? After all, one of the last things you would want, ever, is money going to waste on something you don’t need, or failing to buy something that meets your expectations. = Conclusion I only gave two points of interest when selecting a server - looking at the numbers alone, this might seem like hardly anything to consider at all. My reasons for this are: - Power comumption is one factor that people often forego thinking about, and an extremely important one at that. - Building on top of the previous point, you \(probably) aren’t stupid. Knowing \(albeit at a very basic level) what to look out for should be enough. - It would be extremely difficult for me, or anyone else for that matter, to provide a #strong[truly] complete solution to everyone’s needs for a home server. Well, that’s it. I wish you luck in selecting your hardware.
https://github.com/alikindsys/aula
https://raw.githubusercontent.com/alikindsys/aula/master/Core/alias.typ
typst
#import "base.typ": pt_abstract, pt_error, pt_tip, pt_info, pt_question, pt_memo, pt_task, pt_conclusion, pt_success, pt_warning, pt_example, pt_quote, pt_step, color-table #let resumo = pt_abstract #let dica = pt_tip #let info = pt_info #let pergunta = pt_question #let memo = pt_memo #let tarefa = pt_task #let conclusao = pt_conclusion #let sucesso = pt_success #let advertencia = pt_warning #let exemplo = pt_example #let cita = pt_quote #let erro = pt_error #let passo = pt_step #let tabela = color-table
https://github.com/EpicEricEE/typst-marge
https://raw.githubusercontent.com/EpicEricEE/typst-marge/main/tests/basic/test.typ
typst
MIT License
#import "/src/lib.typ": sidenote #set par(justify: true) #set page(width: 8cm, height: auto, margin: (outside: 4cm, rest: 5mm)) #lorem(5) #sidenote[This is a simple unnumbered sidenote.] #lorem(13) #sidenote[Here is another one.] #lorem(11)