Skip to content

Commit

Permalink
Merge pull request #2309 from SciML/extend
Browse files Browse the repository at this point in the history
update docs for new extension syntax
  • Loading branch information
ChrisRackauckas authored Oct 9, 2023
2 parents 563f04f + 9e45fee commit 2c17d63
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions docs/src/tutorials/acausal_components.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ end
end
@mtkmodel Resistor begin
@extend v, i = oneport = OnePort()
@extend OnePort()
@parameters begin
R = 1.0 # Sets the default resistance
end
Expand All @@ -66,7 +66,7 @@ end
D = Differential(t)
@mtkmodel Capacitor begin
@extend v, i = oneport = OnePort()
@extend OnePort()
@parameters begin
C = 1.0
end
Expand All @@ -76,7 +76,7 @@ D = Differential(t)
end
@mtkmodel ConstantVoltage begin
@extend (v,) = oneport = OnePort()
@extend OnePort()
@parameters begin
V = 1.0
end
Expand Down Expand Up @@ -193,7 +193,7 @@ zero. This leads to our resistor equations:

```@example acausal
@mtkmodel Resistor begin
@extend v, i = oneport = OnePort()
@extend OnePort()
@parameters begin
R = 1.0
end
Expand All @@ -216,7 +216,7 @@ Using our knowledge of circuits, we similarly construct the `Capacitor`:
D = Differential(t)
@mtkmodel Capacitor begin
@extend v, i = oneport = OnePort()
@extend OnePort()
@parameters begin
C = 1.0
end
Expand All @@ -233,7 +233,7 @@ model this as:

```@example acausal
@mtkmodel ConstantVoltage begin
@extend (v,) = oneport = OnePort()
@extend OnePort()
@parameters begin
V = 1.0
end
Expand Down

0 comments on commit 2c17d63

Please sign in to comment.