Skip to content

Commit 2b4181a

Browse files
authored
Merge pull request #1014 from PowerGridModel/feature/docs-fix-typos
Documentation: fix typos in docs (also docstrings + comments in code)
2 parents 18ddd16 + 93fe1ca commit 2b4181a

File tree

12 files changed

+24
-24
lines changed

12 files changed

+24
-24
lines changed

docs/advanced_documentation/build-guide.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ Building the library in `IA-32` might be working, but is not tested.
3636

3737
The source code is written with the mindset of ISO standard C++ only, i.e. avoid compiler-extension or platform-specific
3838
features as much as possible.
39-
In this way the effort to port the library to other platform/architecture might be minimum.
39+
In this way, minimum effort should be necessary to port the library to other platform/architecture.
4040

4141
### Compiler Support
4242

@@ -434,7 +434,7 @@ brew install ninja cmake boost eigen nlohmann-json msgpack-cxx doctest
434434
435435
It is recommended to create a virtual environment.
436436
Clone repository, create and activate virtual environment, and install the build dependency.
437-
go to a root folder you prefer to save the repositories.
437+
Go to a root folder of your choice to save the repositories.
438438
439439
```shell
440440
git clone https://github.com/PowerGridModel/power-grid-model.git

docs/examples/Asymmetric Calculation Example.ipynb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -317,7 +317,7 @@
317317
"source": [
318318
"#### Accessing batch data\n",
319319
"\n",
320-
"It may be a bit unintuitive to read the `output_data` or `update_data` of a component directly as they are a dictionary of 4 dimension data, ie. $ids \\times batches \\times attributes \\times phases$. Remember that the `output_data` or `update_data` are a dictionary of numpy structured arrays. Hence the component should be indexed first. The index that follows can be [indexed with numpy structured arrays](https://numpy.org/doc/stable/user/basics.rec.html#indexing-structured-arrays).\n",
320+
"It may be a bit unintuitive to read the `output_data` or `update_data` of a component directly as they are a dictionary of 4 dimension data, i.e., $ids \\times batches \\times attributes \\times phases$. Remember that the `output_data` or `update_data` are a dictionary of numpy structured arrays. Hence the component should be indexed first. The index that follows can be [indexed with numpy structured arrays](https://numpy.org/doc/stable/user/basics.rec.html#indexing-structured-arrays).\n",
321321
"\n",
322322
"To read the result of a single batch, e.g. 1st batch,"
323323
]

docs/examples/Power Flow Example.ipynb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -934,7 +934,7 @@
934934
"source": [
935935
"##### Accessing batch data\n",
936936
"\n",
937-
"It may be a bit unintuitive to read the `output_data` or `update_data` of a component directly as they are a dictionary of 3 dimension data, ie. $ids \\times batches \\times attributes$. Remember that the `output_data` or `update_data` are a dictionary of numpy structured arrays. Hence the component should be indexed first. The index that follows can be [indexed with numpy structured arrays](https://numpy.org/doc/stable/user/basics.rec.html#indexing-structured-arrays)\n",
937+
"It may be a bit unintuitive to read the `output_data` or `update_data` of a component directly as they are a dictionary of 3 dimension data, i.e., $ids \\times batches \\times attributes$. Remember that the `output_data` or `update_data` are a dictionary of numpy structured arrays. Hence the component should be indexed first. The index that follows can be [indexed with numpy structured arrays](https://numpy.org/doc/stable/user/basics.rec.html#indexing-structured-arrays)\n",
938938
"\n",
939939
"To read the result of a single batch, lets say 1st batch,"
940940
]
@@ -1455,7 +1455,7 @@
14551455
],
14561456
"metadata": {
14571457
"kernelspec": {
1458-
"display_name": ".venv",
1458+
"display_name": "venv",
14591459
"language": "python",
14601460
"name": "python3"
14611461
},

docs/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ For an extended python interface to the the power-grid-model, refer to the
2929
```{note}
3030
Do you wish to be updated on the latest news and releases?
3131
Subscribe to the Power Grid Model mailing list by sending an (empty) email to:
32-
32+
3333
```
3434

3535
## Install from PyPI

docs/user_manual/calculations.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -390,7 +390,7 @@ The algorithm is as follows:
390390
$
391391
4. Solve linear equation: $YU_N^i = I_N^i$
392392
5. Check convergence: If maximum voltage deviation from the previous iteration is greater than the tolerance setting
393-
(ie. $u^{(i-1)}_\sigma > u_\epsilon$), then go back to step 3.
393+
(i.e., $u^{(i-1)}_\sigma > u_\epsilon$), then go back to step 3.
394394

395395
The iterative current algorithm only needs to calculate injected currents before solving linear equations.
396396
This is more straightforward than calculating the Jacobian, which was done in the Newton-Raphson algorithm.
@@ -915,7 +915,7 @@ sides.
915915

916916
In the case where the control side of the regulator and the tap side of the transformer are at the same side, the
917917
control logic of taps will be reverted (see
918-
`user_manual/calculations:Initialization and exploitation of regulated transformers`).
918+
{hoverxreftooltip}`user_manual/calculations:Initialization and exploitation of regulated transformers`).
919919
The exploitation of the neighbourhood ensures that the actual optimum is not accidentally missed due to feedback
920920
mechanisms in the grid.
921921

docs/user_manual/dataset-terminology.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -70,8 +70,8 @@ graph TD
7070
```
7171

7272
- **{py:class}`Dataset <power_grid_model.data_types.Dataset>`:** Either a single or a batch dataset.
73-
It is a dictionary with keys as the component types (eg. `line`, `node`, etc) and values as **ComponentData**
74-
- **{py:class}`SingleDataset <power_grid_model.data_types.SingleDataset>`:** A data type storing input data (i.e. all
73+
It is a dictionary with keys as the component types (e.g., `line`, `node`, etc.) and values as **ComponentData**
74+
- **{py:class}`SingleDataset <power_grid_model.data_types.SingleDataset>`:** A data type storing input data (i.e., all
7575
elements of all components) for a single scenario.
7676
- **{py:class}`BatchDataset <power_grid_model.data_types.BatchDataset>`:** A data type storing update and or output
7777
data for one or more scenarios.
@@ -158,15 +158,15 @@ Exemplary datasets attributes are given in a dataset containing a `line` compone
158158

159159
- **Attribute:** The definition of `id`, `energized`, `p`, etc. of any component.
160160

161-
- **Value:** The value under an attribute, ie. id, energized, p, etc.
161+
- **Value:** The value under an attribute, i.e., id, energized, p, etc.
162162

163163
- **Array:** All elements of one specific component, for one or more scenarios.
164164
I.e. a node array or line array.
165165
An array can be one dimensional (containing all elements of a single component for one scenario), two-dimensional
166166
(containing all elements of a single component for multiple scenarios), or it can be a sparse array, which is
167167
essentially a dictionary with a data buffer and an index pointer.
168168

169-
`power-grid-model` can process many scenarios (e.g. time steps, switch states, etc.) at once, which we call a batch.
169+
`power-grid-model` can process many scenarios (e.g., time steps, switch states, etc.) at once, which we call a batch.
170170
The batch size is the number of scenarios.
171171

172172
- **Scenario:** A single time step / switch state topology.

docs/user_manual/model-validation.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -256,9 +256,9 @@ The `vision-network` case has the following characteristics:
256256
The cases are built taking into consideration the modelling differences between Vision and power-grid-model mentioned in
257257
the [power-grid-model-io documentation](https://power-grid-model-io.readthedocs.io/).
258258
The node voltages and branch power flows are validated for symmetrical calculation.
259-
For asymmetrical output only the result attributes being validated are the ones which can be exported to excel. (ie.
259+
For asymmetrical output only the result attributes being validated are the ones which can be exported to excel. (i.e.,
260260
node voltages and branch currents)
261-
The absolute tolerances here are set to the least count of the Vision result export: till ie. till V and kW level.
261+
The absolute tolerances here are set to the least count of the Vision result export: i.e., till V and kW level.
262262

263263
## Short Circuit Calculation cases
264264

power_grid_model_c/power_grid_model/include/power_grid_model/common/grouped_index_vector.hpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
#include <ranges>
1818

1919
/*
20-
A data-structure for iterating through the indptr, ie. sparse representation of data.
20+
A data-structure for iterating through the indptr, i.e., sparse representation of data.
2121
Indptr can be eg: [0, 3, 6, 7]
2222
This means that:
2323
objects 0, 1, 2 are coupled to index 0
@@ -26,8 +26,8 @@ objects 6 is coupled to index 2
2626
2727
Another intuitive way to look at this for python developers is like list of lists: [[0, 1, 2], [3, 4, 5], [6]].
2828
29-
DenseGroupedIdxVector is a vector of element to group. ie. [0, 1, 1, 4] would denote that [[0], [1, 2], [], [], [3]]
30-
The input, ie. [0, 1, 3] should be strictly increasing
29+
DenseGroupedIdxVector is a vector of element to group. I.e., [0, 1, 1, 4] would denote that [[0], [1, 2], [], [], [3]]
30+
The input, i.e., [0, 1, 3] should be strictly increasing
3131
3232
*/
3333

power_grid_model_c/power_grid_model/include/power_grid_model/common/statistics.hpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,8 @@
2222
* A random variable in PGM can have following characteristics:
2323
* - Uniform: Single total variance for all phases
2424
* - Independent: all phases are independent from each other
25-
* - Scalar: Named as `Real` in this file, a scalar value `RealValue`, eg. real axis: RealValue (* 1), imaginary axis:
26-
* RealValue (* i).
25+
* - Scalar: Named as `Real` in this file, a scalar value `RealValue`, e.g., real axis: RealValue (* 1), imaginary
26+
* axis: RealValue (* i).
2727
* - Complex: a complex value with real and imaginary parts.
2828
*
2929
* Based on these, we use combined variables in Decomposed/Polar forms:

power_grid_model_c/power_grid_model/include/power_grid_model/math_solver/iterative_current_pf_solver.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,7 @@ class IterativeCurrentPFSolver : public IterativePFSolver<sym_type, IterativeCur
116116
parameters_changed_ = false;
117117
}
118118

119-
// Prepare matrix calculates injected current ie. RHS of solver for each iteration.
119+
// Prepare matrix calculates injected current, i.e., RHS of solver for each iteration.
120120
void prepare_matrix_and_rhs(YBus<sym> const& y_bus, PowerFlowInput<sym> const& input,
121121
ComplexValueVector<sym> const& u) {
122122
std::vector<LoadGenType> const& load_gen_type = *this->load_gen_type_;

0 commit comments

Comments
 (0)