Skip to content

Commit b471fa3

Browse files
Merge pull request #389 from AayushSabharwal/as/fix-docs
docs: fix docs
2 parents 19b8938 + 462847d commit b471fa3

File tree

4 files changed

+11
-12
lines changed

4 files changed

+11
-12
lines changed

docs/Project.toml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22
ControlSystemsBase = "aaaaaaaa-a6ca-5380-bf3e-84a91bcd477e"
33
DataFrames = "a93c6f00-e57d-5684-b7b6-d8193f3e46c0"
44
DataInterpolations = "82cc6244-b520-54b8-b5a6-8a565e85f1d0"
5-
DifferentialEquations = "0c46a032-eb83-5123-abaf-570d42b7fbaa"
65
Documenter = "e30172f5-a6a5-5a46-863b-614d45cd2de4"
76
IfElse = "615f187c-cbe4-4ef1-ba3b-2fcf58d6d173"
87
ModelingToolkit = "961ee093-0014-501f-94e3-6117800e7a78"
@@ -14,7 +13,6 @@ Plots = "91a5bcdd-55d7-5caf-9e0b-520d859cae80"
1413
ControlSystemsBase = "1.1"
1514
DataFrames = "1.7"
1615
DataInterpolations = "6.4, 7, 8"
17-
DifferentialEquations = "7.6"
1816
Documenter = "1"
1917
IfElse = "0.1"
2018
ModelingToolkit = "9"

docs/src/connectors/connections.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ We can generate the above relationship with ModelingToolkit and the ModelingTool
8989
As can be seen, this will give a 1 equation model matching our energy dissipation relationship
9090

9191
```@example connections
92-
using ModelingToolkitStandardLibrary.Electrical, ModelingToolkit, DifferentialEquations
92+
using ModelingToolkitStandardLibrary.Electrical, ModelingToolkit, OrdinaryDiffEq
9393
using ModelingToolkit: t_nounits as t
9494
using Plots
9595

docs/src/connectors/sign_convention.md

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ end
7979
Here we can see that a positive input force results in an increasing velocity.
8080

8181
```@example sign_convention
82-
@mtkmodel System begin
82+
@mtkmodel Model begin
8383
@components begin
8484
mass = Mass(; m = 10)
8585
force = ConstantForce(; f = 1)
@@ -88,7 +88,7 @@ Here we can see that a positive input force results in an increasing velocity.
8888
connect(mass.flange, force.flange)
8989
end
9090
end
91-
@mtkbuild sys = System()
91+
@mtkbuild sys = Model()
9292
full_equations(sys)
9393
```
9494

@@ -117,7 +117,7 @@ end
117117
Here we can see that a positive input current results in an increasing voltage. Note that the electrical domain uses pins `p` and `n` at each side of the source and energy storage components. The direction of connection is not important here, only that a positive connector `p` connects with a negative connector `n`.
118118

119119
```@example sign_convention
120-
@mtkmodel System begin
120+
@mtkmodel Model begin
121121
@components begin
122122
capacitor = Capacitor(; C = 10)
123123
current = ConstantCurrent(; i = 1)
@@ -128,14 +128,14 @@ Here we can see that a positive input current results in an increasing voltage.
128128
connect(capacitor.n, current.p, ground.g)
129129
end
130130
end
131-
@mtkbuild sys = System()
131+
@mtkbuild sys = Model()
132132
full_equations(sys)
133133
```
134134

135135
Reversing the pins gives the same result
136136

137137
```@example sign_convention
138-
@mtkmodel System begin
138+
@mtkmodel Model begin
139139
@components begin
140140
capacitor = Capacitor(; C = 10)
141141
current = ConstantCurrent(; i = 1)
@@ -146,7 +146,7 @@ Reversing the pins gives the same result
146146
connect(capacitor.p, current.n, ground.g)
147147
end
148148
end
149-
@mtkbuild sys = System()
149+
@mtkbuild sys = Model()
150150
full_equations(sys)
151151
```
152152

@@ -173,7 +173,7 @@ end
173173
A positive input mass flow leads to an increasing pressure (in this case we get increasing density (`rho`), which is directly related to an increasing pressure).
174174

175175
```@example sign_convention
176-
@mtkmodel System begin
176+
@mtkmodel Model begin
177177
@components begin
178178
volume = FixedVolume(; vol = 10.0, p_int = 1e5)
179179
flow = ConstantMassFlow(; dm = 1)
@@ -184,6 +184,6 @@ A positive input mass flow leads to an increasing pressure (in this case we get
184184
connect(fluid, flow.port)
185185
end
186186
end
187-
@mtkbuild sys = System()
187+
@mtkbuild sys = Model()
188188
full_equations(sys) |> first
189189
```

test/Thermal/thermal.jl

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,8 @@ using OrdinaryDiffEq: ReturnCode.Success
2929
# Check if Relative temperature sensor reads the temperature of heat capacitor
3030
# when connected to a thermal conductor and a fixed temperature source
3131
@test SciMLBase.successful_retcode(sol)
32-
@test sol[reltem_sensor.T.u] + sol[tem_src.port.T] == sol[mass1.T] + sol[th_conductor.dT]
32+
@test sol[reltem_sensor.T.u] + sol[tem_src.port.T] ==
33+
sol[mass1.T] + sol[th_conductor.dT]
3334

3435
@info "Building a two-body system..."
3536
eqs = [connect(T_sensor1.port, mass1.port, th_conductor.port_a)

0 commit comments

Comments
 (0)