Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
102 commits
Select commit Hold shift + click to select a range
398ff10
fix: loading on 1.12
avik-pal Oct 27, 2025
e6714d8
Merge pull request #314 from SciML/ap/1.12_support
ChrisRackauckas Oct 29, 2025
078dc5d
Bump actions/checkout from 4 to 6
dependabot[bot] Nov 24, 2025
6383dc2
Update dependabot.yml to add Julia ecosystem support
ChrisRackauckas-Claude Dec 2, 2025
bc20835
Remove CompatHelper.yml (replaced by Dependabot)
ChrisRackauckas-Claude Dec 2, 2025
3b7b207
Bump actions/cache from 4 to 5
dependabot[bot] Dec 15, 2025
ae89e7a
Add JET.jl static analysis tests
ChrisRackauckas Dec 29, 2025
a4f0d06
Merge pull request #319 from SciML/dependabot/github_actions/actions/…
ChrisRackauckas Dec 29, 2025
a2f12c7
Merge pull request #320 from ChrisRackauckas-Claude/static-improvemen…
ChrisRackauckas Dec 29, 2025
58932b5
Merge pull request #316 from SciML/dependabot/github_actions/actions/…
ChrisRackauckas Jan 3, 2026
ae5f31d
Switch from JuliaFormatter to Runic.jl for code formatting
claude Jan 4, 2026
9eaca95
Documentation improvements: fix typo, broken reference, and add missi…
claude Jan 7, 2026
e22a55b
Merge pull request #325 from ChrisRackauckas-Claude/docs-improvements…
ChrisRackauckas Jan 9, 2026
d96fbd9
Split tests: move JET tests to nopre group excluded on pre Julia
claude Jan 9, 2026
970a927
Merge pull request #326 from ChrisRackauckas-Claude/split-tests-nopre
ChrisRackauckas Jan 9, 2026
68b8f20
Merge branch 'main' into runic-formatting
ChrisRackauckas Jan 9, 2026
09e7a83
Merge pull request #323 from ChrisRackauckas-Claude/runic-formatting
ChrisRackauckas Jan 9, 2026
fb6e37f
Merge branch 'main' into migrate-to-dependabot
ChrisRackauckas Jan 9, 2026
06b4fe5
Merge pull request #318 from ChrisRackauckas-Claude/migrate-to-depend…
ChrisRackauckas Jan 9, 2026
f12ef15
Mark hvcat block matrix tests as broken on Julia 1.13+
claude Jan 9, 2026
507ff9b
Format with Runic and disable Reactant tests on Julia 1.13+
claude Jan 11, 2026
660ea1b
Add tracking issue reference for Reactant tests
claude Jan 11, 2026
df94698
Merge pull request #327 from ChrisRackauckas-Claude/fix-julia-113-hvc…
ChrisRackauckas Jan 11, 2026
57fb58c
Bump version from 0.15.30 to 0.15.31
ChrisRackauckas Jan 11, 2026
c0cd640
Bump actions/checkout from 4 to 6
dependabot[bot] Jan 14, 2026
c2021d9
Merge pull request #330 from SciML/dependabot/github_actions/actions/…
ChrisRackauckas Jan 14, 2026
9a74857
Bump the all-julia-packages group across 2 directories with 18 updates
dependabot[bot] Jan 16, 2026
086e5b0
Merge pull request #329 from SciML/dependabot/julia/docs/all-julia-pa…
ChrisRackauckas Jan 16, 2026
16e9401
Split tests into separate groups with independent environments
claude Feb 9, 2026
85a7e69
Fix downgrade compat conflict and relax CI performance thresholds
claude Feb 9, 2026
ffd1b7c
Further relax performance thresholds for CI stability
claude Feb 9, 2026
3b1d9a2
Remove all compat bounds from test/Project.toml
claude Feb 9, 2026
5ef5b73
Default GROUP to "All" which runs Core tests for now
claude Feb 10, 2026
338e31e
Merge pull request #333 from ChrisRackauckas-Claude/split-test-groups
ChrisRackauckas Feb 10, 2026
37f685e
Update Project.toml
ChrisRackauckas Feb 10, 2026
f9a3a22
fix handling
AstitvaAggarwal Mar 17, 2026
049c660
typo
AstitvaAggarwal Mar 17, 2026
66acfac
fin
AstitvaAggarwal Mar 17, 2026
546b509
format
AstitvaAggarwal Mar 17, 2026
32a72e8
Merge pull request #341 from AstitvaAggarwal/dev
ChrisRackauckas Mar 17, 2026
a55d010
Update Project.toml
ChrisRackauckas Mar 17, 2026
f19860c
Bump codecov/codecov-action from 5 to 6
dependabot[bot] Apr 1, 2026
29ddd04
Add friendly_tangent_cache function to Mooncake
yebai Apr 10, 2026
0f51238
Merge pull request #345 from SciML/dependabot/github_actions/codecov/…
ChrisRackauckas Apr 11, 2026
410d4b7
Merge pull request #350 from yebai/patch-1
ChrisRackauckas Apr 11, 2026
476c111
Update Project.toml
ChrisRackauckas Apr 11, 2026
edaf066
ext/Mooncake: handle ComponentArray cotangents at @from_rrule boundaries
ChrisRackauckas Apr 11, 2026
f406404
Merge pull request #352 from ChrisRackauckas-Claude/mooncake-ext-wide…
ChrisRackauckas Apr 11, 2026
d99bb07
Update Project.toml
ChrisRackauckas Apr 11, 2026
e362bf5
Bump Mooncake compat lower bound to 0.5.25
ChrisRackauckas Apr 11, 2026
29176ab
Merge pull request #353 from ChrisRackauckas-Claude/bump-mooncake-com…
ChrisRackauckas Apr 11, 2026
5c16116
Run runic for formatting
abhro Apr 13, 2026
524286e
Add setup-julia to runic workflow
abhro Apr 13, 2026
b5076d7
Merge pull request #356 from abhro/runic
ChrisRackauckas Apr 14, 2026
9c3f039
Remove repeated naming for keyword arguments
abhro Apr 13, 2026
8e68d39
Create logo for docs site
abhro Apr 13, 2026
f006134
Bump RecursiveArrayTools / SciMLBase compat to include v4 / v3
ChrisRackauckas Apr 22, 2026
6786e51
Merge pull request #361 from ChrisRackauckas-Claude/bump-rat-v4-sciml…
ChrisRackauckas Apr 22, 2026
6e65788
Bump version from 0.15.37 to 0.15.38
ChrisRackauckas Apr 22, 2026
41c9ffa
Downgrade version from 0.15.38 to 0.15.37
ChrisRackauckas Apr 22, 2026
3090f65
Bump julia-actions/setup-julia from 2 to 3
dependabot[bot] Apr 22, 2026
2caa033
Merge pull request #354 from abhro/docs-logo
ChrisRackauckas Apr 22, 2026
bd6999e
Merge pull request #355 from abhro/kwargs-naming
ChrisRackauckas Apr 30, 2026
22a7402
Fix branch name in docs.yml
abhro Apr 23, 2026
f1ea95a
Merge pull request #364 from abhro/patch-1
ChrisRackauckas May 4, 2026
4377f19
Merge pull request #362 from SciML/dependabot/github_actions/julia-ac…
ChrisRackauckas May 4, 2026
72b1a58
Make docs/src/assets/logo.png into a copy instead of a symlink
abhro May 4, 2026
90d7b82
Merge pull request #366 from abhro/logo-2
ChrisRackauckas May 5, 2026
57ebc6f
Bump the all-julia-packages group across 1 directory with 11 updates
dependabot[bot] May 5, 2026
a7a5a20
Merge pull request #365 from SciML/dependabot/julia/test/all-julia-pa…
ChrisRackauckas May 5, 2026
8804aa5
Fix master CI: import OrdinaryDiffEq sub-packages explicitly
ChrisRackauckas May 10, 2026
abc384b
Replace Bool autodiff kwarg with AutoFiniteDiff() ADType
ChrisRackauckas May 10, 2026
b1f3007
Align test compat lower bounds with root Project.toml
ChrisRackauckas May 10, 2026
8604dd8
Drop dependabot-set test/Project.toml compat that breaks downgrade CI
ChrisRackauckas May 10, 2026
4cb2abd
Retrigger CI to confirm Julia 1 Downstream perf test flake
ChrisRackauckas May 11, 2026
806a183
test: loosen Issue 36 perf threshold 10x -> 20x for self-hosted-runne…
ChrisRackauckas May 12, 2026
9dc85bc
Merge pull request #367 from ChrisRackauckas-Claude/fix-master-solver…
ChrisRackauckas May 12, 2026
ca7d9c4
Update Project.toml
ChrisRackauckas May 12, 2026
d555f57
ext/Mooncake: bridge `copyto!(::ComponentArray, ::Mooncake.Tangent)`
ChrisRackauckas May 18, 2026
6da5a9d
ext/Mooncake: also bridge SubArray-backed CV tangent + add ComponentM…
ChrisRackauckas May 20, 2026
684f8fb
Merge pull request #369 from ChrisRackauckas-Claude/mooncake-copyto-c…
ChrisRackauckas May 20, 2026
99f44b3
Update Project.toml
ChrisRackauckas May 20, 2026
2ac52fd
Downgrade version from 0.15.40 to 0.15.39
ChrisRackauckas May 20, 2026
f685344
Bump the all-julia-packages group across 1 directory with 11 updates
dependabot[bot] May 22, 2026
a22519d
Add SpellCheck workflow and clean up Dependabot config
ChrisRackauckas May 30, 2026
e8d17bf
Merge pull request #373 from ChrisRackauckas-Claude/ci/sciml-standard…
ChrisRackauckas May 30, 2026
058a993
Merge pull request #370 from SciML/dependabot/julia/test/all-julia-pa…
ChrisRackauckas May 30, 2026
859f1f4
Re-enable downgrade CI with genuine test-at-floor
ChrisRackauckas May 31, 2026
2ac6f94
Merge pull request #377 from ChrisRackauckas-Claude/downgrade-ci-test…
ChrisRackauckas May 31, 2026
f98bff5
CI: migrate to centralized SciML reusable workflows
ChrisRackauckas Jun 2, 2026
97790c7
Merge pull request #378 from ChrisRackauckas-Claude/migrate-to-centra…
ChrisRackauckas Jun 2, 2026
f981153
ci: add standard centralized workflows (auto-format, dependabot-autom…
ChrisRackauckas-Claude Jun 7, 2026
7d16f35
Drop allow-reresolve input from downgrade workflow (#380)
ChrisRackauckas-Claude Jun 7, 2026
5366b23
Canonical CI: grouped-tests.yml + root test/test_groups.toml (#382)
ChrisRackauckas-Claude Jun 8, 2026
d75cd27
Canonical CI cleanup: TagBot thin-caller + downgrade-caller cleanup (…
ChrisRackauckas-Claude Jun 8, 2026
20fd3bc
Use SciMLTesting v1.2 folder-based run_tests (#384)
ChrisRackauckas-Claude Jun 14, 2026
4e02334
Normalize nopre test group into canonical QA (#383)
ChrisRackauckas-Claude Jun 15, 2026
7c2d3ab
Restructure Core/QA test harness to SciMLTesting v1.2 folder-discover…
ChrisRackauckas-Claude Jun 16, 2026
0d84c05
Release v0.15.40 (#386)
ChrisRackauckas Jun 23, 2026
6c73939
QA: run_qa v1.6 form + ExplicitImports
ChrisRackauckas Jun 25, 2026
69f9f16
Merge pull request #387 from ChrisRackauckas-Claude/qa/run_qa-v1.6-ex…
ChrisRackauckas Jun 27, 2026
a2bfda5
Raise Mooncake compat floor to 0.5.36 (fix Downgrade resolution)
ChrisRackauckas Jul 3, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 0 additions & 3 deletions .JuliaFormatter.toml

This file was deleted.

14 changes: 11 additions & 3 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,14 @@ updates:
directory: "/" # Location of package manifests
schedule:
interval: "weekly"
ignore:
- dependency-name: "crate-ci/typos"
update-types: ["version-update:semver-patch", "version-update:semver-minor"]
- package-ecosystem: "julia"
directories:
- "/"
- "/docs"
- "/test"
schedule:
interval: "daily"
groups:
all-julia-packages:
patterns:
- "*"
16 changes: 0 additions & 16 deletions .github/workflows/CompatHelper.yml

This file was deleted.

9 changes: 9 additions & 0 deletions .github/workflows/DependabotAutoMerge.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
name: "Dependabot Auto-merge"
on: pull_request
permissions:
contents: write
pull-requests: write
jobs:
automerge:
uses: "SciML/.github/.github/workflows/dependabot-automerge.yml@v1"
secrets: "inherit"
10 changes: 10 additions & 0 deletions .github/workflows/DocPreviewCleanup.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
name: "Doc Preview Cleanup"
on:
pull_request:
types: [closed]
permissions:
contents: write
jobs:
cleanup:
uses: "SciML/.github/.github/workflows/docs-preview-cleanup.yml@v1"
secrets: "inherit"
17 changes: 17 additions & 0 deletions .github/workflows/FormatCheck.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
name: Format Check
on:
push:
branches:
- 'master'
- 'main'
- 'release-'
tags: '*'
pull_request:
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: ${{ github.ref != 'refs/heads/main' }}
jobs:
runic:
name: Format Check
uses: "SciML/.github/.github/workflows/runic.yml@v1"
secrets: "inherit"
9 changes: 9 additions & 0 deletions .github/workflows/RunicSuggestions.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
name: "Runic Suggestions"
on: pull_request
permissions:
contents: read
pull-requests: write
jobs:
runic-suggestions:
uses: "SciML/.github/.github/workflows/runic-suggestions-on-pr.yml@v1"
secrets: "inherit"
10 changes: 10 additions & 0 deletions .github/workflows/SpellCheck.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
name: Spell Check
on: [pull_request]
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: ${{ github.ref != 'refs/heads/main' }}
jobs:
typos-check:
name: Spell Check with Typos
uses: "SciML/.github/.github/workflows/spellcheck.yml@v1"
secrets: "inherit"
16 changes: 5 additions & 11 deletions .github/workflows/TagBot.yml
Original file line number Diff line number Diff line change
@@ -1,15 +1,9 @@
name: TagBot
name: "TagBot"
on:
issue_comment:
types:
- created
types: [created]
workflow_dispatch:
jobs:
TagBot:
if: github.event_name == 'workflow_dispatch' || github.actor == 'JuliaTagBot'
runs-on: ubuntu-latest
steps:
- uses: JuliaRegistries/TagBot@v1
with:
token: ${{ secrets.GITHUB_TOKEN }}
ssh: ${{ secrets.DOCUMENTER_KEY }}
tagbot:
uses: "SciML/.github/.github/workflows/tagbot.yml@v1"
secrets: "inherit"
42 changes: 6 additions & 36 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,40 +7,10 @@ on:
branches:
- main
tags: '*'
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: ${{ github.ref != 'refs/heads/main' }}
jobs:
test:
name: Julia ${{ matrix.version }} - ${{ matrix.os }} - ${{ matrix.arch }} - ${{ github.event_name }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
version:
- 'lts'
- '1' # Leave this line unchanged. '1' will automatically expand to the latest stable 1.x release of Julia.
- 'pre'
os:
- ubuntu-latest
arch:
- x64
steps:
- uses: actions/checkout@v4
- uses: julia-actions/setup-julia@v2
with:
version: ${{ matrix.version }}
arch: ${{ matrix.arch }}
- uses: actions/cache@v4
env:
cache-name: cache-artifacts
with:
path: ~/.julia/artifacts
key: ${{ runner.os }}-test-${{ env.cache-name }}-${{ hashFiles('**/Project.toml') }}
restore-keys: |
${{ runner.os }}-test-${{ env.cache-name }}-
${{ runner.os }}-test-
${{ runner.os }}-
- uses: julia-actions/julia-buildpkg@v1
- uses: julia-actions/julia-runtest@v1
- uses: julia-actions/julia-processcoverage@v1
- uses: codecov/codecov-action@v5
with:
file: lcov.info
tests:
uses: "SciML/.github/.github/workflows/grouped-tests.yml@v1"
secrets: "inherit"
28 changes: 10 additions & 18 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
@@ -1,24 +1,16 @@
name: Documentation

on:
push:
branches:
- master
branches: [main]
tags: '*'
pull_request:

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: ${{ github.ref != 'refs/heads/main' }}
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: julia-actions/setup-julia@latest
with:
version: '1.10'
- name: Install dependencies
run: julia --project=docs/ -e 'using Pkg; Pkg.develop(PackageSpec(path=pwd())); Pkg.instantiate()'
- name: Build and deploy
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # For authentication with GitHub Actions token
DOCUMENTER_KEY: ${{ secrets.DOCUMENTER_KEY }} # For authentication with SSH deploy key
run: julia --project=docs/ docs/make.jl
docs:
name: Documentation
uses: "SciML/.github/.github/workflows/documentation.yml@v1"
with:
coverage: false
secrets: "inherit"
34 changes: 13 additions & 21 deletions .github/workflows/downgrade.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,35 +2,27 @@ name: Downgrade
on:
pull_request:
branches:
- master
- main
paths-ignore:
- 'docs/**'
push:
branches:
- master
- main
paths-ignore:
- 'docs/**'
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: ${{ github.ref != 'refs/heads/main' }}
jobs:
test:
runs-on: ubuntu-latest
downgrade:
name: Downgrade
strategy:
fail-fast: false
matrix:
group:
- Core
downgrade_mode: ['alldeps']
julia-version: ['1.10']
steps:
- uses: actions/checkout@v4
- uses: julia-actions/setup-julia@v2
with:
version: ${{ matrix.julia-version }}
- uses: julia-actions/julia-downgrade-compat@v2
# if: ${{ matrix.version == '1.6' }}
with:
skip: Pkg,TOML
- uses: julia-actions/julia-buildpkg@v1
- uses: julia-actions/julia-runtest@v1
with:
ALLOW_RERESOLVE: false
env:
GROUP: ${{ matrix.group }}
uses: "SciML/.github/.github/workflows/downgrade.yml@v1"
with:
group: "${{ matrix.group }}"
julia-version: "lts"
secrets: "inherit"
3 changes: 3 additions & 0 deletions .typos.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[default.extend-words]
# `temp_noth` test variable (component array holding a `nothing` field)
noth = "noth"
17 changes: 10 additions & 7 deletions Project.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name = "ComponentArrays"
uuid = "b0b7db55-cfe3-40fc-9ded-d10e2dbeff66"
authors = ["Jonnie Diegelman <47193959+jonniedie@users.noreply.github.com>"]
version = "0.15.29"
version = "0.15.41"

[deps]
Adapt = "79e6a3ab-5dfb-504d-930d-738a2a938a0e"
Expand All @@ -16,6 +16,7 @@ StaticArraysCore = "1e83bf80-4336-4d27-bf5d-d5a4f845583c"
[weakdeps]
GPUArrays = "0c68f7d7-f131-5f86-a1c3-88cf8149b2d7"
KernelAbstractions = "63c18a36-062a-441e-b654-da1e3ab1ce7c"
Mooncake = "da2b9cff-9c12-43a0-ae48-6db2b0edb7d6"
Optimisers = "3bd65402-5787-11e9-1adc-39752487f4e2"
Reactant = "3c362404-f566-11ee-1572-e11a4b42c853"
RecursiveArrayTools = "731186ca-8d62-57ce-b412-fbd966d074cd"
Expand All @@ -27,6 +28,7 @@ Zygote = "e88e6eb3-aa80-5325-afca-941959d7151f"
[extensions]
ComponentArraysGPUArraysExt = "GPUArrays"
ComponentArraysKernelAbstractionsExt = "KernelAbstractions"
ComponentArraysMooncakeExt = "Mooncake"
ComponentArraysOptimisersExt = "Optimisers"
ComponentArraysReactantExt = "Reactant"
ComponentArraysRecursiveArrayToolsExt = "RecursiveArrayTools"
Expand All @@ -36,19 +38,20 @@ ComponentArraysTrackerExt = "Tracker"
ComponentArraysZygoteExt = "Zygote"

[compat]
Adapt = "4.1"
ArrayInterface = "7.17.1"
Adapt = "4.1.1"
ArrayInterface = "7.25.0"
ChainRulesCore = "1.25"
ConstructionBase = "1"
Functors = "0.4.12, 0.5"
ConstructionBase = "1.5.0"
Functors = "0.5.2"
GPUArrays = "10.3.1, 11"
KernelAbstractions = "0.9.29"
LinearAlgebra = "1.10"
Optimisers = "0.3, 0.4"
Mooncake = "0.5.36"
Reactant = "0.2.15"
RecursiveArrayTools = "3.8"
RecursiveArrayTools = "3.36.0, 4"
ReverseDiff = "1.15"
SciMLBase = "2"
SciMLBase = "2, 3"
StaticArrayInterface = "1"
StaticArraysCore = "1.4"
Tracker = "0.2.37"
Expand Down
1 change: 1 addition & 0 deletions docs/Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,4 @@ StaticArrays = "90137ffa-7385-5640-81b9-e52037218182"

[compat]
Documenter = "1.3"
StaticArrays = "1.9.16"
5 changes: 3 additions & 2 deletions docs/make.jl
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,10 @@ makedocs(;
"Examples" => [
"examples/DiffEqFlux.md",
"examples/adaptive_control.md",
"examples/ODE_jac.md"
"examples/ODE_jac.md",
"examples/coulomb_control.md",
],
"API" => "api.md"
"API" => "api.md",
],
repo = GitHub("SciML/ComponentArrays.jl"),
sitename = "ComponentArrays.jl",
Expand Down
Binary file added docs/src/assets/logo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions docs/src/examples/DiffEqFlux.md
Original file line number Diff line number Diff line change
Expand Up @@ -83,10 +83,10 @@ cb(θ, loss_n_ode(θ)...)

data = Iterators.repeated((), 1000)

res1 = sciml_train(loss_n_ode, θ, ADAM(0.05); cb = cb, maxiters = 100)
res1 = sciml_train(loss_n_ode, θ, ADAM(0.05); cb, maxiters = 100)
cb(res1.minimizer, loss_n_ode(res1.minimizer)...; doplot = true)

res2 = sciml_train(loss_n_ode, res1.minimizer, LBFGS(); cb = cb)
res2 = sciml_train(loss_n_ode, res1.minimizer, LBFGS(); cb)
cb(res2.minimizer, loss_n_ode(res2.minimizer)...; doplot = true)
```

Expand Down
15 changes: 6 additions & 9 deletions docs/src/examples/adaptive_control.md
Original file line number Diff line number Diff line change
Expand Up @@ -107,9 +107,9 @@ plot!(step_p, solve(ODEProblem(apply_inputs(nominal_sim!; u = 1), nominal_ic, (0
vars = 1, label = "nominal model")

u = (x, p, t) -> sin(3t)
sin_p = plot(solve(ODEProblem(apply_inputs(truth_sim!; u = u), truth_ic, (0.0, 10.0)));
sin_p = plot(solve(ODEProblem(apply_inputs(truth_sim!; u), truth_ic, (0.0, 10.0)));
vars = 1, label = "truth model")
plot!(sin_p, solve(ODEProblem(apply_inputs(nominal_sim!; u = u), nominal_ic, (0.0, 10.0)));
plot!(sin_p, solve(ODEProblem(apply_inputs(nominal_sim!; u), nominal_ic, (0.0, 10.0)));
vars = 1, label = "nominal model")

plot(step_p, sin_p; layout = (2, 1), size = (800, 800))
Expand Down Expand Up @@ -155,11 +155,11 @@ function feedback_sys!(D, vars, p, t; ym, r, n)
regressor = [r, plant_model[1]]

u = control(parameter_estimates, regressor)
yp = p.plant_fun(D.plant_model, plant_model, (), t; u = u)
yp = p.plant_fun(D.plant_model, plant_model, (), t; u)
ŷ = sensor_sim!(D.sensor, sensor, (), t; u = yp[1]) + n
e = ŷ .- ym
regressor[2] = ŷ
adapt!(D.parameter_estimates, parameter_estimates, γ, t; e = e, w = regressor)
adapt!(D.parameter_estimates, parameter_estimates, γ, t; e, w = regressor)
return yp
end
```
Expand All @@ -172,7 +172,7 @@ function system!(D, vars, p, t; r = 0.0, n = 0.0)
@unpack reference_model, feedback_loop = vars

ym = ref_sim!(D.reference_model, reference_model, (), t; u = r)
yp = feedback_sys!(D.feedback_loop, feedback_loop, p, t; ym = ym, r = r, n = n)
yp = feedback_sys!(D.feedback_loop, feedback_loop, p, t; ym, r, n)
return yp
end
```
Expand Down Expand Up @@ -219,10 +219,7 @@ function simulate(plant_fun, plant_ic;
)

# Model parameters
p = (
gamma = adapt_gain,
plant_fun = plant_fun
)
p = (; gamma = adapt_gain, plant_fun)

sim_fun = apply_inputs(system!; r = input_signal, n = deterministic_noise)

Expand Down
Loading