Skip to content

Commit

Permalink
- Updating the documentation
Browse files Browse the repository at this point in the history
- Start adding unit tests
- Add a check for stiffness matrix singularity
  • Loading branch information
AkchurinDA committed Sep 22, 2024
1 parent cbe9522 commit 8e508a5
Show file tree
Hide file tree
Showing 19 changed files with 576 additions and 107 deletions.
10 changes: 2 additions & 8 deletions Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,16 +6,10 @@ version = "0.1.0"
[deps]
DocStringExtensions = "ffbed154-4ef7-542d-bbb7-c09d3a79fcae"
LinearAlgebra = "37e2e46d-f89d-539d-b4ee-838fcccc9c8e"
Memoization = "6fafb56a-5788-4b4e-91ca-c0cea6611c73"
OrderedCollections = "bac558e1-5e72-5ebc-8fee-abe8a469f55d"
SparseArrays = "2f01184e-e22b-5df5-ae63-d93ebab69eaf"
StaticArrays = "90137ffa-7385-5640-81b9-e52037218182"
StyledStrings = "f489334b-da3d-4c2e-b8f0-e476e12c162b"
Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40"

[compat]
OrderedCollections = "1"
StyledStrings = "1"
DocStringExtensions = "0.9"
StaticArrays = "1"
Memoization = "0.2"
StyledStrings = "1"
julia = "1.10.0"
2 changes: 0 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
<img src="docs/src/assets/social-preview.svg" alt="Hephaestus.jl">

---

## Description

`Hephaestus.jl` is an auto-differentiable structural analysis package purely written in the Julia programming language.
Expand Down
9 changes: 6 additions & 3 deletions docs/make.jl
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,13 @@ makedocs(
sitename = "Hephaestus.jl",
authors = "Damir Akchurin, [email protected]",
pages = [
"Home" => "index.md",
"API" => "API.md"],
"Home" => "index.md",
"Quick Start" => "QuickStart.md",
"API" => "API.md"],
format = Documenter.HTML(
assets = ["assets/Citations.css"]),
assets = [
"assets/favicon.ico",
"assets/Citations.css"]),
plugins = [
CitationBibliography(
joinpath(@__DIR__, "src", "References.bib"),
Expand Down
14 changes: 14 additions & 0 deletions docs/src/API.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,21 @@
## Types

```@docs
Model
Node
Material
Section
Element
```

## Functions

```@docs
add_node!
add_material!
add_section!
add_element!
add_support!
add_concentrated_load!
add_distributed_load!
```
58 changes: 58 additions & 0 deletions docs/src/QuickStart.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
To quickly get you started with `Hephaestus.jl`, let us recreate a simple example of a cantilever beam subjected to a concentrated load at its free end as shown below.

```@raw html
```

```@setup QuickStart
using Hephaestus
```

To create a new model, use the [`Model()`](@ref) constructor:

```@example QuickStart
M = Model()
```

To add nodes to the model, use the [`add_node!()`](@ref) function:

```@example QuickStart
add_node!(M, 1 , 0 * 12, 0, 0)
add_node!(M, 2 , 1 * 12, 0, 0)
add_node!(M, 3 , 2 * 12, 0, 0)
add_node!(M, 4 , 3 * 12, 0, 0)
add_node!(M, 5 , 4 * 12, 0, 0)
add_node!(M, 6 , 5 * 12, 0, 0)
add_node!(M, 7 , 6 * 12, 0, 0)
add_node!(M, 8 , 7 * 12, 0, 0)
add_node!(M, 9 , 8 * 12, 0, 0)
add_node!(M, 10, 9 * 12, 0, 0)
add_node!(M, 11, 10 * 12, 0, 0)
```

To add materials to the model, use the [`add_material!()`](@ref) function:

```@example QuickStart
add_material!(M, 1, 29000, 0.3, 0.000290)
```

To add sections to the model, use the [`add_section!()`](@ref) function:

```@example QuickStart
add_section!(M, 1, 9.16, 180, 180, 359)
```

To add elements to the model, use the [`add_element!()`](@ref) function:

```@example QuickStart
add_element!(M, 1 , 1 , 2 , 1, 1)
add_element!(M, 2 , 2 , 3 , 1, 1)
add_element!(M, 3 , 3 , 4 , 1, 1)
add_element!(M, 4 , 4 , 5 , 1, 1)
add_element!(M, 5 , 5 , 6 , 1, 1)
add_element!(M, 6 , 6 , 7 , 1, 1)
add_element!(M, 7 , 7 , 8 , 1, 1)
add_element!(M, 8 , 8 , 9 , 1, 1)
add_element!(M, 9 , 9 , 10, 1, 1)
add_element!(M, 10, 10, 11, 1, 1)
```
Binary file added docs/src/assets/favicon.ico
Binary file not shown.
Binary file added docs/src/assets/logo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
193 changes: 193 additions & 0 deletions docs/src/assets/logo.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/src/assets/social-preview.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading

0 comments on commit 8e508a5

Please sign in to comment.