You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/src/connectors/sign_convention.md
+8-8Lines changed: 8 additions & 8 deletions
Original file line number
Diff line number
Diff line change
@@ -79,7 +79,7 @@ end
79
79
Here we can see that a positive input force results in an increasing velocity.
80
80
81
81
```@example sign_convention
82
-
@mtkmodel System begin
82
+
@mtkmodel Model begin
83
83
@components begin
84
84
mass = Mass(; m = 10)
85
85
force = ConstantForce(; f = 1)
@@ -88,7 +88,7 @@ Here we can see that a positive input force results in an increasing velocity.
88
88
connect(mass.flange, force.flange)
89
89
end
90
90
end
91
-
@mtkbuild sys = System()
91
+
@mtkbuild sys = Model()
92
92
full_equations(sys)
93
93
```
94
94
@@ -117,7 +117,7 @@ end
117
117
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`.
118
118
119
119
```@example sign_convention
120
-
@mtkmodel System begin
120
+
@mtkmodel Model begin
121
121
@components begin
122
122
capacitor = Capacitor(; C = 10)
123
123
current = ConstantCurrent(; i = 1)
@@ -128,14 +128,14 @@ Here we can see that a positive input current results in an increasing voltage.
128
128
connect(capacitor.n, current.p, ground.g)
129
129
end
130
130
end
131
-
@mtkbuild sys = System()
131
+
@mtkbuild sys = Model()
132
132
full_equations(sys)
133
133
```
134
134
135
135
Reversing the pins gives the same result
136
136
137
137
```@example sign_convention
138
-
@mtkmodel System begin
138
+
@mtkmodel Model begin
139
139
@components begin
140
140
capacitor = Capacitor(; C = 10)
141
141
current = ConstantCurrent(; i = 1)
@@ -146,7 +146,7 @@ Reversing the pins gives the same result
146
146
connect(capacitor.p, current.n, ground.g)
147
147
end
148
148
end
149
-
@mtkbuild sys = System()
149
+
@mtkbuild sys = Model()
150
150
full_equations(sys)
151
151
```
152
152
@@ -173,7 +173,7 @@ end
173
173
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).
174
174
175
175
```@example sign_convention
176
-
@mtkmodel System begin
176
+
@mtkmodel Model begin
177
177
@components begin
178
178
volume = FixedVolume(; vol = 10.0, p_int = 1e5)
179
179
flow = ConstantMassFlow(; dm = 1)
@@ -184,6 +184,6 @@ A positive input mass flow leads to an increasing pressure (in this case we get
0 commit comments