Skip to content

Commit

Permalink
Documentation improvements
Browse files Browse the repository at this point in the history
  • Loading branch information
kfrb committed Jul 18, 2022
1 parent e1d3084 commit f2691c6
Show file tree
Hide file tree
Showing 6 changed files with 23 additions and 24 deletions.
8 changes: 4 additions & 4 deletions docs/src/crackedplateundertension.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ Now we want the plate to have a crack from the left side to the middle.
Therefore we need to specify a [`PreCrack`](@ref) object.
A `PreCrack` is simply two `Vector{Int}`'s containing point indices.
Points in `point_id_set_a` don't interact with points in `point_id_set_b`.
So we need to specify all points above and below the crack, seen in the following image:
So we need to specify all points above and below the crack, as seen in the following image:

```@raw html
<img src="https://github.com/kfrb/Peridynamics.jl/blob/main/docs/src/assets/CrackedPlateUnderTension0.png?raw=true" width="600" />
Expand All @@ -58,8 +58,8 @@ precracks = [PreCrack(precrack_set_a, precrack_set_b)]

The `PreCrack` is then wrapped inside a `Vector` because `PDSingleBodyAnalysis` needs a `Vector{PreCrack}` in case you have multiple predefined cracks in your model.

Now we specify boundary conditions so the crack has to grow under the load that is applied to the plate.
Therefore, we want the five rows of points in the upper and lower part of the plate to have a constant velocity of $0.1\,\frac{\mathrm{m}}{\mathrm{s}}$ in positive and negative $y$-direction to pull the plate apart.
Now we specify boundary conditions, so the crack has to grow under the load applied to the plate.
Therefore, we want the five rows of points in the upper and lower part of the plate to have a constant velocity of $0.1\,\frac{\mathrm{m}}{\mathrm{s}}$ in the positive and negative $y$-direction to pull the plate apart.

```julia
bc_set_top = findall(pc.position[2,:] .> length_y / 2 - 5.1 * Δx)
Expand All @@ -76,7 +76,7 @@ Our simulation should run for 2000 time steps and the stable time step should be
td = TimeDiscretization(2000)
```

In order to save the results, we specify with `ExportSettings`, that every 10 timesteps, the results should be saved to a folder named `results/CrackedPlateUnderTension`.
To save the results, we specify with `ExportSettings` that every 10 timesteps, the results should be saved to a folder named `results/CrackedPlateUnderTension`.

```julia
simulation_name = "CrackedPlateUnderTension"
Expand Down
7 changes: 4 additions & 3 deletions docs/src/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,10 @@ Currently, only a limited feature set is supported, but many upgrades are in the
- Adaptive dynamic relaxation for quasistatic analysis, see [Kilic and Madenci (2010)](https://doi.org/10.1016/j.tafmec.2010.08.001)
- Multi-body contact analysis with short-range forces, see [Silling and Askari (2005)](https://doi.org/10.1016/j.compstruc.2004.11.026)

#### Incomplete list of upcoming features
#### An incomplete list of upcoming features
- Volume and surface correction
- Ordinary and non-ordinary state-based peridynamics, see [Silling et al. (2007)](https://link.springer.com/article/10.1007/s10659-007-9125-1)
- Continuum-kinematics-based peridynamics, see [Javili, McBride and Steinmann (2019)](https://doi.org/10.1016/j.jmps.2019.06.016)
- Continuum-kinematics-based peridynamics, see [Javili, McBride, and Steinmann (2019)](https://doi.org/10.1016/j.jmps.2019.06.016)

## Installation

Expand All @@ -45,4 +45,5 @@ We recommend looking at the [manual](@ref manual) and the [tutorials section](@r

## Acknowledgement

The authors gratefully acknowledge the support of the Deutsche Forschungsgemeinschaft (DFG) under the project WE2525-14/1.
The authors gratefully acknowledge the support of the Deutsche Forschungsgemeinschaft (DFG) under the project WE2525-14/1.

6 changes: 3 additions & 3 deletions docs/src/logo.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ dimZₚ = 0.01 # [m]
Δxₚ = dimXYₚ/50 # [m]
pcₚ = PointCloud(dimXYₚ, dimXYₚ, dimZₚ, Δxₚ)
```
To create the spheres of the logo, a cubic point cloud is created and only the points inside a specified radius are preserved.
The these points are then copied three times and moved to the right position to represent the logo.
A cubic point cloud is assembled, and only the points inside a specified radius are preserved to create the spheres of the logo.
These points are then copied three times and moved to the correct position to represent the logo.
```julia
# SPHERES OF LOGO - INDEX: s
Øₛ = 0.03 # [m]
Expand Down Expand Up @@ -92,7 +92,7 @@ sphere2 = BodySetup(pcₛ₂, matₛ; ics=icₛ, calc_timestep=false)
sphere3 = BodySetup(pcₛ₃, matₛ; ics=icₛ, calc_timestep=false)
body_setup = [plate, sphere1, sphere2, sphere3]
```
Now, contact between the plate and the three spheres needs to be specified.
Contact between the plate and the three spheres needs to be specified.
```julia
contact = [Contact((1, 2), Δxₚ), Contact((1, 3), Δxₚ), Contact((1, 4), Δxₚ)]
```
Expand Down
19 changes: 8 additions & 11 deletions docs/src/manual.md
Original file line number Diff line number Diff line change
Expand Up @@ -78,8 +78,8 @@ TimeDiscretization(500, 5e-7)

## Export settings

The results of a simulation are exported as `vtu` and `jld2` files, to make post-processing with ParaView and Julia easy.
With [`ExportSettings`](@ref), the file path and the frequency of the export can be set.
The simulation results are exported as `vtu` and `jld2` files to make post-processing with ParaView and Julia straightforward.
With [`ExportSettings`](@ref), the file path and the export frequency can be set.

#### Example 1:
Export into the directory `"results"` every 10'th time step.
Expand All @@ -99,14 +99,11 @@ Predefined cracks are defined with [`PreCrack`](@ref).
For an example, see [`CrackedPlateUnderTension.jl`](@ref cracked-plate-under-tension).


## Boundary and initial conditions
## Boundary & initial conditions

Currently, 4 different conditions can be used:
For more information, see the documentation for each type:

*Boundary conditions*
1. [`VelocityBC`](@ref): velocity boundary conditions
2. [`ForceDensityBC`](@ref): force density boundary conditions
3. [`PosDepVelBC`](@ref): position dependend velocity boundary conditions

*Initial conditions*
1. [`VelocityIC`](@ref): velocity boundary conditions
- [`VelocityBC`](@ref): velocity boundary conditions
- [`ForceDensityBC`](@ref): force density boundary conditions
- [`PosDepVelBC`](@ref): position dependend velocity boundary conditions
- [`VelocityIC`](@ref): velocity initial conditions
4 changes: 2 additions & 2 deletions docs/src/tensiletest.md
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ boundary_conditions = [
]
```
With these at hand, a `PDSingleBodyAnalysis` can be constructed and submitted for calculation.
We set the number of time steps for the explicit time integration to 500 with `TimeDiscretization(500)` and define, that the results of our calculation should be saved in the directory `"results/TensileTest"` every 10'th time step.
We set the number of time steps for the explicit time integration to 500 with `TimeDiscretization(500)` and define that the results of our analysis should be saved in the directory `"results/TensileTest"` every 10'th time step.
```julia
job = PDSingleBodyAnalysis(;
name="TensileTest",
Expand Down Expand Up @@ -111,7 +111,7 @@ Results:

As an improvement to the previous results, we can additionally set a no-fail-zone.
It is a common problem for bond-based peridynamics, that to much damage occurs next to the points where boundary conditions apply.
To disable failure of the points in the bottom and the top of the specimen, add these two lines after the definition of the `pointcloud`:
With these two lines, failure in the bottom and top of the specimen is disabled:
```julia
pointcloud.failure_flag[pointcloud.point_sets["bottom"]] .= false
pointcloud.failure_flag[pointcloud.point_sets["top"]] .= false
Expand Down
3 changes: 2 additions & 1 deletion src/AbaqusMeshConverter.jl
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,8 @@ Currently supported mesh elements: $SUPPORTED_ELEMENT_TYPES
- `PointCloud`: generated point cloud with element volume as point volume
# Examples
The specimen of the [`TensileTest.jl`](@ref) example script:
The specimen of the
[`TensileTest.jl`](https://kfrb.github.io/Peridynamics.jl/dev/tensiletest/) example script:
```julia-repl
julia> pointcloud = read_inp("examples/models/TensileTestMesh.inp")
[ Info: 21420 nodes found
Expand Down

0 comments on commit f2691c6

Please sign in to comment.