changeset 853:fe8fe3f01162 operator_storage_array_of_table

Docs touch up
author Jonatan Werpers <jonatan@werpers.com>
date Mon, 17 Jan 2022 08:34:06 +0100
parents 510f744d0876
children ff9d738c9b21 bdc718c38096
files Notes.md docs/src/operator_file_format.md src/SbpOperators/operators/standard_diagonal.toml src/SbpOperators/readoperator.jl
diffstat 4 files changed, 12 insertions(+), 7 deletions(-) [+]
line wrap: on
line diff
--- a/Notes.md	Fri Jan 14 15:39:56 2022 +0100
+++ b/Notes.md	Mon Jan 17 08:34:06 2022 +0100
@@ -53,7 +53,7 @@
 
 * Remove order as a table name and put it as a variable.
 
-### Parsing
+### Parsing of stencil sets
 At the moment the only parsing that can be done at the top level is conversion
 from the toml file to a dict of strings. This forces the user to dig through
 the dictionary and apply the correct parsing methods for the different parts,
@@ -66,6 +66,10 @@
 there could be a way to register parsing functions or object types for the
 toml.
 
+If possible the goal should be for the parsing to get all the way to the
+stencils so that a user calls `read_stencil_set` and gets a
+dictionary-structure containing stencils, tuples, scalars and other types
+ready for input to the methods creating the operators.
 
 ## Variable second derivative
 
--- a/docs/src/operator_file_format.md	Fri Jan 14 15:39:56 2022 +0100
+++ b/docs/src/operator_file_format.md	Mon Jan 17 08:34:06 2022 +0100
@@ -45,7 +45,7 @@
 ### Numbers
 Number can be represented as regular TOML numbers e.g. `1`, `-0.4` or
 `4.32e-3`. Alternatively they can be represented as strings which allows
-specifying fraction e.g. `"1/2"` or "0".
+specifying fraction e.g. `"1/2"` or `"0"`.
 
 All numbers are accurately converted to `Rational`s when using the
 [`parse_scalar`](@ref) function.
--- a/src/SbpOperators/operators/standard_diagonal.toml	Fri Jan 14 15:39:56 2022 +0100
+++ b/src/SbpOperators/operators/standard_diagonal.toml	Mon Jan 17 08:34:06 2022 +0100
@@ -36,6 +36,7 @@
 [[stencil_set]]
 
 order = 4
+
 H.inner = "1"
 H.closure = ["17/48", "59/48", "43/48", "49/48"]
 
--- a/src/SbpOperators/readoperator.jl	Fri Jan 14 15:39:56 2022 +0100
+++ b/src/SbpOperators/readoperator.jl	Mon Jan 17 08:34:06 2022 +0100
@@ -15,8 +15,8 @@
 
 Picks out a stencil set from the given toml file based on some key-value
 filters. If more than one set matches the filters an error is raised. The
-stencil set contains parsed toml intended for functions like `parse_scalar`
-and `parse_stencil`.
+returned stencil set contains parsed toml intended for functions like
+`parse_scalar` and `parse_stencil`.
 
 The stencil set is not parsed beyond the inital toml parse. To get usable
 stencils use the `parse_stencil` functions on the fields of the stencil set.
@@ -60,7 +60,7 @@
 """
     parse_stencil(parsed_toml)
 
-Accepts parsed parsed_toml and reads it as a stencil.
+Accepts parsed toml and reads it as a stencil.
 
 See also [`read_stencil_set`](@ref), [`parse_scalar`](@ref), [`parse_tuple`](@ref).
 """
@@ -79,7 +79,7 @@
 """
     parse_stencil(T, parsed_toml)
 
-Parses the stencil with element type `T`
+Parses the input as a stencil with element type `T`.
 """
 parse_stencil(T, parsed_toml) = Stencil{T}(parse_stencil(parsed_toml))
 
@@ -123,7 +123,7 @@
 """
     parse_tuple(parsed_toml)
 
-Parse `parsed_toml` as a tuple of scalars.
+Parse an array as a tuple of scalars.
 
 See also [`read_stencil_set`](@ref), [`parse_stencil`](@ref), [`parse_scalar`](@ref).
 """