diff --git a/Manifest.toml b/Manifest.toml index becee80..35d4c71 100644 --- a/Manifest.toml +++ b/Manifest.toml @@ -1,16 +1,18 @@ # This file is machine-generated - editing it directly is not advised [[ADTypes]] -git-tree-sha1 = "eea5d80188827b35333801ef97a40c2ed653b081" +git-tree-sha1 = "72af59f5b8f09faee36b4ec48e014a79210f2f4f" uuid = "47edcb42-4c32-4615-8424-f2b9edc5f35b" -version = "1.9.0" +version = "1.11.0" [ADTypes.extensions] ADTypesChainRulesCoreExt = "ChainRulesCore" + ADTypesConstructionBaseExt = "ConstructionBase" ADTypesEnzymeCoreExt = "EnzymeCore" [ADTypes.weakdeps] ChainRulesCore = "d360d2e6-b24c-11e9-a2a3-2a2ae2dbcce4" + ConstructionBase = "187b0558-2788-49d3-abe0-74a17ed4e7c9" EnzymeCore = "f151be2c-9106-41f4-ab19-57ee4f262869" [[AbstractFFTs]] @@ -30,24 +32,26 @@ uuid = "1520ce14-60c1-5f80-bbc7-55ef81b5835c" version = "0.4.5" [[Accessors]] -deps = ["CompositionsBase", "ConstructionBase", "InverseFunctions", "LinearAlgebra", "MacroTools", "Markdown"] -git-tree-sha1 = "b392ede862e506d451fc1616e79aa6f4c673dab8" +deps = ["CompositionsBase", "ConstructionBase", "InverseFunctions", "MacroTools"] +git-tree-sha1 = "e93c42e833e6d4bd28be7b3b56d8deb99fd51f25" uuid = "7d9f7c33-5ae7-4f3b-8dc6-eff91059b697" -version = "0.1.38" +version = "0.1.40" [Accessors.extensions] - AccessorsAxisKeysExt = "AxisKeys" - AccessorsDatesExt = "Dates" - AccessorsIntervalSetsExt = "IntervalSets" - AccessorsStaticArraysExt = "StaticArrays" - AccessorsStructArraysExt = "StructArrays" - AccessorsTestExt = "Test" - AccessorsUnitfulExt = "Unitful" + AxisKeysExt = "AxisKeys" + DatesExt = "Dates" + IntervalSetsExt = "IntervalSets" + LinearAlgebraExt = "LinearAlgebra" + StaticArraysExt = "StaticArrays" + StructArraysExt = "StructArrays" + TestExt = "Test" + UnitfulExt = "Unitful" [Accessors.weakdeps] AxisKeys = "94b1ba4f-4ee9-5380-92f1-94cde586c3c5" Dates = "ade2ca70-3891-5945-98fb-dc099432e06a" IntervalSets = "8197267c-284f-5f27-9208-e0e47529a953" + LinearAlgebra = "37e2e46d-f89d-539d-b4ee-838fcccc9c8e" Requires = "ae029012-a4dd-5104-9daa-d747884805df" StaticArrays = "90137ffa-7385-5640-81b9-e52037218182" StructArrays = "09ab397b-f2b6-538f-b94a-2f83cf4a842a" @@ -72,13 +76,13 @@ version = "1.1.3" [[ArgTools]] uuid = "0dad84c5-d112-42e6-8d28-ef12dabb789f" -version = "1.1.1" +version = "1.1.2" [[ArrayInterface]] deps = ["Adapt", "LinearAlgebra"] -git-tree-sha1 = "d60a1922358aa203019b7857a2c8c37329b8736c" +git-tree-sha1 = "017fcb757f8e921fb44ee063a7aafe5f89b86dd1" uuid = "4fba245c-0d91-5ea0-9b3e-6abc04ee57a9" -version = "7.17.0" +version = "7.18.0" [ArrayInterface.extensions] ArrayInterfaceBandedMatricesExt = "BandedMatrices" @@ -108,9 +112,16 @@ version = "7.17.0" [[Artifacts]] uuid = "56f22d72-fd6d-98f1-02f0-08ddc0907c33" +version = "1.11.0" [[Base64]] uuid = "2a0f44e3-6c83-55bd-87e4-b1978d98bd5f" +version = "1.11.0" + +[[Bessels]] +git-tree-sha1 = "4435559dc39793d53a9e3d278e185e920b4619ef" +uuid = "0e736298-9ec6-45e8-9647-e4fc86a2fe38" +version = "0.2.8" [[Bijections]] git-tree-sha1 = "d8b0439d2be438a5f2cd68ec158fe08a7b2595b7" @@ -131,9 +142,9 @@ version = "0.2.6" [[ChainRulesCore]] deps = ["Compat", "LinearAlgebra"] -git-tree-sha1 = "3e4b134270b372f2ed4d4d0e936aabaefc1802bc" +git-tree-sha1 = "1713c74e00545bfe14605d2a2be1712de8fbcb58" uuid = "d360d2e6-b24c-11e9-a2a3-2a2ae2dbcce4" -version = "1.25.0" +version = "1.25.1" weakdeps = ["SparseArrays"] [ChainRulesCore.extensions] @@ -151,9 +162,9 @@ uuid = "861a8166-3701-5b0c-9a16-15d98fcdc6aa" version = "1.0.2" [[CommonEq]] -git-tree-sha1 = "d1beba82ceee6dc0fce8cb6b80bf600bbde66381" +git-tree-sha1 = "6b0f0354b8eb954cdba708fb262ef00ee7274468" uuid = "3709ef60-1bee-4518-9f2f-acd86f176c50" -version = "0.2.0" +version = "0.2.1" [[CommonSolve]] git-tree-sha1 = "0eee5eb66b1cf62cd6ad1b460238e60e4b09400c" @@ -207,21 +218,21 @@ uuid = "8f4d0f93-b110-5947-807f-2305c1781a2d" version = "1.10.2" [[ConstructionBase]] -deps = ["LinearAlgebra"] -git-tree-sha1 = "d8a9c0b6ac2d9081bf76324b39c78ca3ce4f0c98" +git-tree-sha1 = "76219f1ed5771adbb096743bff43fb5fdd4c1157" uuid = "187b0558-2788-49d3-abe0-74a17ed4e7c9" -version = "1.5.6" -weakdeps = ["IntervalSets", "StaticArrays"] +version = "1.5.8" +weakdeps = ["IntervalSets", "LinearAlgebra", "StaticArrays"] [ConstructionBase.extensions] ConstructionBaseIntervalSetsExt = "IntervalSets" + ConstructionBaseLinearAlgebraExt = "LinearAlgebra" ConstructionBaseStaticArraysExt = "StaticArrays" [[ControlSystemsBase]] deps = ["DSP", "ForwardDiff", "IterTools", "LaTeXStrings", "LinearAlgebra", "MacroTools", "MatrixEquations", "MatrixPencils", "Polyester", "Polynomials", "PrecompileTools", "Printf", "Random", "RecipesBase", "SparseArrays", "StaticArraysCore", "UUIDs"] -git-tree-sha1 = "8d1f12a2c45a89634aac3ba511ed565984b822d9" +git-tree-sha1 = "400d8ab689cf056e7499333b2b58339e16771b9d" uuid = "aaaaaaaa-a6ca-5380-bf3e-84a91bcd477e" -version = "1.11.1" +version = "1.12.0" [ControlSystemsBase.extensions] ControlSystemsBaseImplicitDifferentiationExt = ["ImplicitDifferentiation", "ComponentArrays"] @@ -237,10 +248,16 @@ uuid = "adafc99b-e345-5852-983c-f28acb93d879" version = "0.3.1" [[DSP]] -deps = ["Compat", "FFTW", "IterTools", "LinearAlgebra", "Polynomials", "Random", "Reexport", "SpecialFunctions", "Statistics"] -git-tree-sha1 = "0df00546373af8eee1598fb4b2ba480b1ebe895c" +deps = ["Bessels", "FFTW", "IterTools", "LinearAlgebra", "Polynomials", "Random", "Reexport", "SpecialFunctions", "Statistics"] +git-tree-sha1 = "489db9d78b53e44fb753d225c58832632d74ab10" uuid = "717857b8-e6f2-59f4-9121-6e50c889abd2" -version = "0.7.10" +version = "0.8.0" + + [DSP.extensions] + OffsetArraysExt = "OffsetArrays" + + [DSP.weakdeps] + OffsetArrays = "6fe1bfb0-de20-5000-8ca7-80f57d26f881" [[DataAPI]] git-tree-sha1 = "abe83f3a2f1b857aac70ef8b269080af17764bbe" @@ -261,6 +278,7 @@ version = "1.0.0" [[Dates]] deps = ["Printf"] uuid = "ade2ca70-3891-5945-98fb-dc099432e06a" +version = "1.11.0" [[DiffResults]] deps = ["StaticArraysCore"] @@ -277,12 +295,13 @@ version = "1.15.1" [[Distributed]] deps = ["Random", "Serialization", "Sockets"] uuid = "8ba89e20-285c-5b6f-9357-94700520ee1b" +version = "1.11.0" [[Distributions]] deps = ["AliasTables", "FillArrays", "LinearAlgebra", "PDMats", "Printf", "QuadGK", "Random", "SpecialFunctions", "Statistics", "StatsAPI", "StatsBase", "StatsFuns"] -git-tree-sha1 = "3101c32aab536e7a27b1763c0797dba151b899ad" +git-tree-sha1 = "7901a6117656e29fa2c74a58adb682f380922c47" uuid = "31c24e10-a181-5473-b8eb-7969acd0382f" -version = "0.25.113" +version = "0.25.116" [Distributions.extensions] DistributionsChainRulesCoreExt = "ChainRulesCore" @@ -318,10 +337,10 @@ uuid = "f43a241f-c20a-4ad4-852c-f6b1247861c6" version = "1.6.0" [[DynamicPolynomials]] -deps = ["Future", "LinearAlgebra", "MultivariatePolynomials", "MutableArithmetics", "Pkg", "Reexport", "Test"] -git-tree-sha1 = "30a1848c4f4fc35d1d4bbbd125650f6a11b5bc6c" +deps = ["Future", "LinearAlgebra", "MultivariatePolynomials", "MutableArithmetics", "Reexport", "Test"] +git-tree-sha1 = "9a3ae38b460449cc9e7dd0cfb059c76028724627" uuid = "7c1d4256-1411-5781-91ec-d7bc3513ac07" -version = "0.5.7" +version = "0.6.1" [[EnumX]] git-tree-sha1 = "bdb1942cd4c45e3c678fd11569d5cccd80976237" @@ -349,10 +368,11 @@ version = "1.8.0" deps = ["Artifacts", "JLLWrappers", "Libdl", "Pkg"] git-tree-sha1 = "4d81ed14783ec49ce9f2e168208a12ce1815aa25" uuid = "f5851436-0d7a-5f13-b9de-f02708fd171a" -version = "3.3.10+1" +version = "3.3.10+3" [[FileWatching]] uuid = "7b1f6079-737a-58dc-b8bc-7a2ca5c1b5ee" +version = "1.11.0" [[FillArrays]] deps = ["LinearAlgebra"] @@ -395,6 +415,7 @@ version = "0.1.3" [[Future]] deps = ["Random"] uuid = "9fa8497b-333b-5362-9e8d-4d0656e87820" +version = "1.11.0" [[GPUArraysCore]] deps = ["Adapt"] @@ -413,6 +434,11 @@ git-tree-sha1 = "debdd00ffef04665ccbb3e150747a77560e8fad1" uuid = "615f187c-cbe4-4ef1-ba3b-2fcf58d6d173" version = "0.1.1" +[[IntegerMathUtils]] +git-tree-sha1 = "b8ffb903da9f7b8cf695a8bead8e01814aa24b30" +uuid = "18e54dd8-cb9d-406c-a71d-865a43cbb235" +version = "0.1.2" + [[IntelOpenMP_jll]] deps = ["Artifacts", "JLLWrappers", "LazyArtifacts", "Libdl"] git-tree-sha1 = "10bd689145d2c3b2a9844005d01087cc1194e79e" @@ -422,6 +448,7 @@ version = "2024.2.1+0" [[InteractiveUtils]] deps = ["Markdown"] uuid = "b77e0a4c-d291-57a0-90e8-8db25a27a240" +version = "1.11.0" [[IntervalSets]] git-tree-sha1 = "dba9ddf07f77f60450fe5d2e2beb9854d9a49bd0" @@ -461,9 +488,9 @@ version = "1.0.0" [[JLLWrappers]] deps = ["Artifacts", "Preferences"] -git-tree-sha1 = "be3dc50a92e5a386872a493a10050136d4703f9b" +git-tree-sha1 = "a007feb38b422fbdab534406aeca1b86823cb4d6" uuid = "692b3bcd-3c85-4b1f-b108-f13ce0eb3210" -version = "1.6.1" +version = "1.7.0" [[JSON]] deps = ["Dates", "Mmap", "Parsers", "Unicode"] @@ -476,17 +503,6 @@ git-tree-sha1 = "dda21b8cbd6a6c40d9d02a73230f9d70fed6918c" uuid = "b964fa9f-0449-5b57-a5c2-d3ea65f4040f" version = "1.4.0" -[[LabelledArrays]] -deps = ["ArrayInterface", "ChainRulesCore", "ForwardDiff", "LinearAlgebra", "MacroTools", "PreallocationTools", "RecursiveArrayTools", "StaticArrays"] -git-tree-sha1 = "e459fda6b68ea8684b3fcd513d2fd1e5130c4402" -uuid = "2ee39098-c373-598a-b85f-a56591580800" -version = "1.16.0" - -[[LambertW]] -git-tree-sha1 = "c5ffc834de5d61d00d2b0e18c96267cffc21f648" -uuid = "984bce1d-4616-540c-a9ee-88d1112d94c9" -version = "0.4.6" - [[Latexify]] deps = ["Format", "InteractiveUtils", "LaTeXStrings", "MacroTools", "Markdown", "OrderedCollections", "Requires"] git-tree-sha1 = "ce5f5621cac23a86011836badfedf664a612cee4" @@ -512,6 +528,7 @@ version = "0.1.17" [[LazyArtifacts]] deps = ["Artifacts", "Pkg"] uuid = "4af54fe1-eca0-43a8-85a7-787d91b784e3" +version = "1.11.0" [[LibCURL]] deps = ["LibCURL_jll", "MozillaCACerts_jll"] @@ -521,16 +538,17 @@ version = "0.6.4" [[LibCURL_jll]] deps = ["Artifacts", "LibSSH2_jll", "Libdl", "MbedTLS_jll", "Zlib_jll", "nghttp2_jll"] uuid = "deac9b47-8bc7-5906-a0fe-35ac56dc84c0" -version = "8.4.0+0" +version = "8.6.0+0" [[LibGit2]] deps = ["Base64", "LibGit2_jll", "NetworkOptions", "Printf", "SHA"] uuid = "76f85450-5226-5b5a-8eaa-529ad045b433" +version = "1.11.0" [[LibGit2_jll]] deps = ["Artifacts", "LibSSH2_jll", "Libdl", "MbedTLS_jll"] uuid = "e37daf67-58a4-590a-8e99-b0245dd2ffc5" -version = "1.6.4+0" +version = "1.7.2+0" [[LibSSH2_jll]] deps = ["Artifacts", "Libdl", "MbedTLS_jll"] @@ -539,10 +557,12 @@ version = "1.11.0+1" [[Libdl]] uuid = "8f399da3-3557-5675-b5ff-fb832c97cbdb" +version = "1.11.0" [[LinearAlgebra]] deps = ["Libdl", "OpenBLAS_jll", "libblastrampoline_jll"] uuid = "37e2e46d-f89d-539d-b4ee-838fcccc9c8e" +version = "1.11.0" [[LinearMaps]] deps = ["LinearAlgebra"] @@ -558,9 +578,9 @@ weakdeps = ["ChainRulesCore", "SparseArrays", "Statistics"] [[LogExpFunctions]] deps = ["DocStringExtensions", "IrrationalConstants", "LinearAlgebra"] -git-tree-sha1 = "a2d09619db4e765091ee5c6ffe8872849de0feea" +git-tree-sha1 = "13ca9e2586b89836fd20cccf56e57e2b9ae7f38f" uuid = "2ab3a3ac-af41-5b50-aa03-7779005ae688" -version = "0.3.28" +version = "0.3.29" [LogExpFunctions.extensions] LogExpFunctionsChainRulesCoreExt = "ChainRulesCore" @@ -574,6 +594,7 @@ version = "0.3.28" [[Logging]] uuid = "56ddb016-857b-54e1-b83d-db4d58db5568" +version = "1.11.0" [[MKL_jll]] deps = ["Artifacts", "IntelOpenMP_jll", "JLLWrappers", "LazyArtifacts", "Libdl", "oneTBB_jll"] @@ -587,10 +608,9 @@ uuid = "d8e11817-5142-5d16-987a-aa16d5891078" version = "0.4.17" [[MacroTools]] -deps = ["Markdown", "Random"] -git-tree-sha1 = "2fa9ee3e63fd3a4f7a9a4f4744a52f4856de82df" +git-tree-sha1 = "72aebe0b5051e5143a079a4685a46da330a40472" uuid = "1914dd2f-81c6-5fcd-8719-6d5c9610ff09" -version = "0.5.13" +version = "0.5.15" [[ManualMemory]] git-tree-sha1 = "bcaef4fc7a0cfe2cba636d84cda54b5e4e4ca3cd" @@ -600,6 +620,7 @@ version = "0.1.8" [[Markdown]] deps = ["Base64"] uuid = "d6f4376e-aef5-505a-96c1-9c027394607a" +version = "1.11.0" [[MatrixEquations]] deps = ["LinearAlgebra", "LinearMaps"] @@ -616,7 +637,7 @@ version = "1.8.0" [[MbedTLS_jll]] deps = ["Artifacts", "Libdl"] uuid = "c8ffd9c3-330d-5841-b78e-0817d7145fa1" -version = "2.28.2+1" +version = "2.28.6+0" [[Missings]] deps = ["DataAPI"] @@ -626,10 +647,11 @@ version = "1.2.0" [[Mmap]] uuid = "a63ad114-7e13-5084-954f-fe012c677804" +version = "1.11.0" [[MozillaCACerts_jll]] uuid = "14a3606d-f60d-562e-9121-12d972cd8159" -version = "2023.1.10" +version = "2023.12.12" [[MultivariatePolynomials]] deps = ["ChainRulesCore", "DataStructures", "LinearAlgebra", "MutableArithmetics"] @@ -639,15 +661,15 @@ version = "0.5.7" [[MutableArithmetics]] deps = ["LinearAlgebra", "SparseArrays", "Test"] -git-tree-sha1 = "90077f1e79de8c9c7c8a90644494411111f4e07b" +git-tree-sha1 = "a2710df6b0931f987530f59427441b21245d8f5e" uuid = "d8a4904e-b15c-11e9-3269-09a3773c0cb0" -version = "1.5.2" +version = "1.6.0" [[NaNMath]] deps = ["OpenLibm_jll"] -git-tree-sha1 = "0877504529a3e5c3343c6f8b4c0381e57e4387e4" +git-tree-sha1 = "030ea22804ef91648f29b7ad3fc15fa49d0e6e71" uuid = "77ba4419-2d1f-58cd-9bb1-8ffee604a2e3" -version = "1.0.2" +version = "1.0.3" [[NetworkOptions]] uuid = "ca575930-c2e3-43a9-ace4-1e988b2c1908" @@ -656,7 +678,7 @@ version = "1.2.0" [[OpenBLAS_jll]] deps = ["Artifacts", "CompilerSupportLibraries_jll", "Libdl"] uuid = "4536629a-c528-5b80-bd46-f80d51c5b363" -version = "0.3.23+4" +version = "0.3.27+1" [[OpenLibm_jll]] deps = ["Artifacts", "Libdl"] @@ -664,15 +686,15 @@ uuid = "05823500-19ac-5b8b-9628-191a04bc5112" version = "0.8.1+2" [[OpenSpecFun_jll]] -deps = ["Artifacts", "CompilerSupportLibraries_jll", "JLLWrappers", "Libdl", "Pkg"] -git-tree-sha1 = "13652491f6856acfd2db29360e1bbcd4565d04f1" +deps = ["Artifacts", "CompilerSupportLibraries_jll", "JLLWrappers", "Libdl"] +git-tree-sha1 = "1346c9208249809840c91b26703912dff463d335" uuid = "efe28fd5-8261-553b-a9e1-b2916fc3738e" -version = "0.5.5+0" +version = "0.5.6+0" [[OrderedCollections]] -git-tree-sha1 = "dfdf5519f235516220579f949664f1bf44e741c5" +git-tree-sha1 = "12f1439c4f986bb868acda6ea33ebc78e19b95ad" uuid = "bac558e1-5e72-5ebc-8fee-abe8a469f55d" -version = "1.6.3" +version = "1.7.0" [[PDMats]] deps = ["LinearAlgebra", "SparseArrays", "SuiteSparse"] @@ -687,9 +709,15 @@ uuid = "69de0a69-1ddd-5017-9359-2bf0b02dc9f0" version = "2.8.1" [[Pkg]] -deps = ["Artifacts", "Dates", "Downloads", "FileWatching", "LibGit2", "Libdl", "Logging", "Markdown", "Printf", "REPL", "Random", "SHA", "Serialization", "TOML", "Tar", "UUIDs", "p7zip_jll"] +deps = ["Artifacts", "Dates", "Downloads", "FileWatching", "LibGit2", "Libdl", "Logging", "Markdown", "Printf", "Random", "SHA", "TOML", "Tar", "UUIDs", "p7zip_jll"] uuid = "44cfe95a-1eb2-52ea-b672-e2afdf69b78f" -version = "1.10.0" +version = "1.11.0" + + [Pkg.extensions] + REPLExt = "REPL" + + [Pkg.weakdeps] + REPL = "3fa0cd96-eef1-5676-8a61-b3b8758bbffb" [[Polyester]] deps = ["ArrayInterface", "BitTwiddlingConvenienceFunctions", "CPUSummary", "IfElse", "ManualMemory", "PolyesterWeave", "Static", "StaticArrayInterface", "StrideArraysCore", "ThreadingUtilities"] @@ -704,10 +732,10 @@ uuid = "1d0040c9-8b98-4ee7-8388-3f51789ca0ad" version = "0.2.2" [[Polynomials]] -deps = ["LinearAlgebra", "RecipesBase", "Requires", "Setfield", "SparseArrays"] -git-tree-sha1 = "1a9cfb2dc2c2f1bd63f1906d72af39a79b49b736" +deps = ["LinearAlgebra", "OrderedCollections", "RecipesBase", "Requires", "Setfield", "SparseArrays"] +git-tree-sha1 = "adc25dbd4d13f148f3256b6d4743fe7e63a71c4a" uuid = "f27b6e38-b328-58d1-80ce-0feddd5e7a45" -version = "4.0.11" +version = "4.0.12" [Polynomials.extensions] PolynomialsChainRulesCoreExt = "ChainRulesCore" @@ -721,18 +749,6 @@ version = "4.0.11" MakieCore = "20f20a25-4f0e-4fdf-b5d1-57303727442b" MutableArithmetics = "d8a4904e-b15c-11e9-3269-09a3773c0cb0" -[[PreallocationTools]] -deps = ["Adapt", "ArrayInterface", "ForwardDiff"] -git-tree-sha1 = "6c62ce45f268f3f958821a1e5192cf91c75ae89c" -uuid = "d236fae5-4411-538c-8e31-a6e3d9e00b46" -version = "0.4.24" - - [PreallocationTools.extensions] - PreallocationToolsReverseDiffExt = "ReverseDiff" - - [PreallocationTools.weakdeps] - ReverseDiff = "37e2e3b7-166d-5795-8a7a-e32c996b4267" - [[PrecompileTools]] deps = ["Preferences"] git-tree-sha1 = "5aa36f7049a63a1528fe8f7c3f2113413ffd4e1f" @@ -745,9 +761,16 @@ git-tree-sha1 = "9306f6085165d270f7e3db02af26a400d580f5c6" uuid = "21216c6a-2e73-6563-6e65-726566657250" version = "1.4.3" +[[Primes]] +deps = ["IntegerMathUtils"] +git-tree-sha1 = "cb420f77dc474d23ee47ca8d14c90810cafe69e7" +uuid = "27ebfcd6-29c5-5fa9-bf4b-fb8fc14df3ae" +version = "0.5.6" + [[Printf]] deps = ["Unicode"] uuid = "de0858da-6303-5e67-8744-51eddeeeb8d7" +version = "1.11.0" [[PtrArrays]] git-tree-sha1 = "77a42d78b6a92df47ab37e177b2deac405e1c88f" @@ -772,13 +795,10 @@ version = "2.11.1" [QuadGK.weakdeps] Enzyme = "7da242da-08ed-463a-9acd-ee780be4f1d9" -[[REPL]] -deps = ["InteractiveUtils", "Markdown", "Sockets", "Unicode"] -uuid = "3fa0cd96-eef1-5676-8a61-b3b8758bbffb" - [[Random]] deps = ["SHA"] uuid = "9a3f8284-a2c9-5f02-9a11-845980a1fd5c" +version = "1.11.0" [[RecipesBase]] deps = ["PrecompileTools"] @@ -788,9 +808,9 @@ version = "1.3.4" [[RecursiveArrayTools]] deps = ["Adapt", "ArrayInterface", "DocStringExtensions", "GPUArraysCore", "IteratorInterfaceExtensions", "LinearAlgebra", "RecipesBase", "StaticArraysCore", "Statistics", "SymbolicIndexingInterface", "Tables"] -git-tree-sha1 = "6f4dca5fd8e97087a76b7ab8384d1c3086ace0b7" +git-tree-sha1 = "32f824db4e5bab64e25a12b22483a30a6b813d08" uuid = "731186ca-8d62-57ce-b412-fbd966d074cd" -version = "3.27.3" +version = "3.27.4" [RecursiveArrayTools.extensions] RecursiveArrayToolsFastBroadcastExt = "FastBroadcast" @@ -799,6 +819,7 @@ version = "3.27.3" RecursiveArrayToolsMonteCarloMeasurementsExt = "MonteCarloMeasurements" RecursiveArrayToolsReverseDiffExt = ["ReverseDiff", "Zygote"] RecursiveArrayToolsSparseArraysExt = ["SparseArrays"] + RecursiveArrayToolsStructArraysExt = "StructArrays" RecursiveArrayToolsTrackerExt = "Tracker" RecursiveArrayToolsZygoteExt = "Zygote" @@ -809,6 +830,7 @@ version = "3.27.3" MonteCarloMeasurements = "0987c9cc-fe09-11e8-30f0-b96dd679fdca" ReverseDiff = "37e2e3b7-166d-5795-8a7a-e32c996b4267" SparseArrays = "2f01184e-e22b-5df5-ae63-d93ebab69eaf" + StructArrays = "09ab397b-f2b6-538f-b94a-2f83cf4a842a" Tracker = "9f7883ad-71c0-57eb-9f7f-b5c9e6d3789c" Zygote = "e88e6eb3-aa80-5325-afca-941959d7151f" @@ -852,9 +874,9 @@ version = "0.1.0" [[SciMLBase]] deps = ["ADTypes", "Accessors", "ArrayInterface", "CommonSolve", "ConstructionBase", "Distributed", "DocStringExtensions", "EnumX", "Expronicon", "FunctionWrappersWrappers", "IteratorInterfaceExtensions", "LinearAlgebra", "Logging", "Markdown", "PrecompileTools", "Preferences", "Printf", "RecipesBase", "RecursiveArrayTools", "Reexport", "RuntimeGeneratedFunctions", "SciMLOperators", "SciMLStructures", "StaticArraysCore", "Statistics", "SymbolicIndexingInterface"] -git-tree-sha1 = "f9195449e0ae7e8daf9d609c9619ecfc2369f62c" +git-tree-sha1 = "3e5a9c5d6432b77a271646b4ada2573f239ac5c4" uuid = "0bca4576-84f4-4d90-8ffe-ffa030f20462" -version = "2.60.0" +version = "2.70.0" [SciMLBase.extensions] SciMLBaseChainRulesCoreExt = "ChainRulesCore" @@ -888,12 +910,13 @@ weakdeps = ["SparseArrays", "StaticArraysCore"] [[SciMLStructures]] deps = ["ArrayInterface"] -git-tree-sha1 = "25514a6f200219cd1073e4ff23a6324e4a7efe64" +git-tree-sha1 = "0444a37a25fab98adbd90baa806ee492a3af133a" uuid = "53ae85a6-f571-4167-b2af-e1d143709226" -version = "1.5.0" +version = "1.6.1" [[Serialization]] uuid = "9e88b42a-f829-5b0c-bbe9-9e923198166b" +version = "1.11.0" [[Setfield]] deps = ["ConstructionBase", "Future", "MacroTools", "StaticArraysCore"] @@ -903,6 +926,7 @@ version = "1.1.1" [[Sockets]] uuid = "6462fe0b-24de-5631-8697-dd941f90decc" +version = "1.11.0" [[SortingAlgorithms]] deps = ["DataStructures"] @@ -913,13 +937,13 @@ version = "1.2.1" [[SparseArrays]] deps = ["Libdl", "LinearAlgebra", "Random", "Serialization", "SuiteSparse_jll"] uuid = "2f01184e-e22b-5df5-ae63-d93ebab69eaf" -version = "1.10.0" +version = "1.11.0" [[SpecialFunctions]] deps = ["IrrationalConstants", "LogExpFunctions", "OpenLibm_jll", "OpenSpecFun_jll"] -git-tree-sha1 = "2f5d4697f21388cbe1ff299430dd169ef97d7e14" +git-tree-sha1 = "64cca0c26b4f31ba18f13f6c12af7c85f478cfde" uuid = "276daf66-3868-5448-9aa4-cd146d93841b" -version = "2.4.0" +version = "2.5.0" weakdeps = ["ChainRulesCore"] [SpecialFunctions.extensions] @@ -947,9 +971,9 @@ version = "1.8.0" [[StaticArrays]] deps = ["LinearAlgebra", "PrecompileTools", "Random", "StaticArraysCore"] -git-tree-sha1 = "777657803913ffc7e8cc20f0fd04b634f871af8f" +git-tree-sha1 = "47091a0340a675c738b1304b58161f3b0839d454" uuid = "90137ffa-7385-5640-81b9-e52037218182" -version = "1.9.8" +version = "1.9.10" weakdeps = ["ChainRulesCore", "Statistics"] [StaticArrays.extensions] @@ -962,9 +986,14 @@ uuid = "1e83bf80-4336-4d27-bf5d-d5a4f845583c" version = "1.4.3" [[Statistics]] -deps = ["LinearAlgebra", "SparseArrays"] +deps = ["LinearAlgebra"] +git-tree-sha1 = "ae3bb1eb3bba077cd276bc5cfc337cc65c3075c0" uuid = "10745b16-79ce-11e8-11f9-7d13ad32a3b2" -version = "1.10.0" +version = "1.11.1" +weakdeps = ["SparseArrays"] + + [Statistics.extensions] + SparseArraysExt = ["SparseArrays"] [[StatsAPI]] deps = ["LinearAlgebra"] @@ -973,10 +1002,10 @@ uuid = "82ae8749-77ed-4fe6-ae5f-f523153014b0" version = "1.7.0" [[StatsBase]] -deps = ["DataAPI", "DataStructures", "LinearAlgebra", "LogExpFunctions", "Missings", "Printf", "Random", "SortingAlgorithms", "SparseArrays", "Statistics", "StatsAPI"] -git-tree-sha1 = "5cf7606d6cef84b543b483848d4ae08ad9832b21" +deps = ["AliasTables", "DataAPI", "DataStructures", "LinearAlgebra", "LogExpFunctions", "Missings", "Printf", "Random", "SortingAlgorithms", "SparseArrays", "Statistics", "StatsAPI"] +git-tree-sha1 = "29321314c920c26684834965ec2ce0dacc9cf8e5" uuid = "2913bbd2-ae8a-5f71-8c99-4fb6c76f3a91" -version = "0.34.3" +version = "0.34.4" [[StatsFuns]] deps = ["HypergeometricFunctions", "IrrationalConstants", "LogExpFunctions", "Reexport", "Rmath", "SpecialFunctions"] @@ -1002,51 +1031,69 @@ uuid = "4607b0f0-06f3-5cda-b6b1-a6196a1729e9" [[SuiteSparse_jll]] deps = ["Artifacts", "Libdl", "libblastrampoline_jll"] uuid = "bea87d4a-7f5b-5778-9afe-8cc45184846c" -version = "7.2.1+1" +version = "7.7.0+0" [[SymPy]] -deps = ["CommonEq", "CommonSolve", "Latexify", "LinearAlgebra", "Markdown", "PyCall", "RecipesBase", "SpecialFunctions"] -git-tree-sha1 = "181ff29b83f28436a3bd5d3388751c31473726ec" +deps = ["CommonEq", "CommonSolve", "LinearAlgebra", "PyCall", "SpecialFunctions", "SymPyCore"] +git-tree-sha1 = "83ff6b72182bab93d2ca0de10b11d5d89ce1c829" uuid = "24249f21-da20-56a4-8eb1-6a02cf4ae2e6" -version = "1.2.1" -weakdeps = ["SymbolicUtils"] +version = "2.2.1" + +[[SymPyCore]] +deps = ["CommonEq", "CommonSolve", "Latexify", "LinearAlgebra", "Markdown", "RecipesBase", "SpecialFunctions"] +git-tree-sha1 = "d9772eaf485a2d9353b6ecf7fa36f8d81cb523d5" +uuid = "458b697b-88f0-4a86-b56b-78b75cfb3531" +version = "0.2.7" +weakdeps = ["TermInterface"] - [SymPy.extensions] - SymPySymbolicUtilsExt = "SymbolicUtils" + [SymPyCore.extensions] + SymPyCoreTermInterfaceExt = "TermInterface" [[SymbolicIndexingInterface]] deps = ["Accessors", "ArrayInterface", "RuntimeGeneratedFunctions", "StaticArraysCore"] -git-tree-sha1 = "6c6761e08bf5a270905cdd065be633abfa1b155b" +git-tree-sha1 = "fd2d4f0499f6bb4a0d9f5030f5c7d61eed385e03" uuid = "2efcf032-c050-4f8e-a9bb-153293bab1f5" -version = "0.3.35" +version = "0.3.37" [[SymbolicLimits]] deps = ["SymbolicUtils"] -git-tree-sha1 = "fb099adbd7504f1e68b4512828e9d94197a8b889" +git-tree-sha1 = "fabf4650afe966a2ba646cabd924c3fd43577fc3" uuid = "19f23fe9-fdab-4a78-91af-e7b7767979c3" -version = "0.2.1" +version = "0.2.2" [[SymbolicUtils]] -deps = ["AbstractTrees", "Bijections", "ChainRulesCore", "Combinatorics", "ConstructionBase", "DataStructures", "DocStringExtensions", "DynamicPolynomials", "IfElse", "LabelledArrays", "LinearAlgebra", "MultivariatePolynomials", "NaNMath", "Setfield", "SparseArrays", "SpecialFunctions", "StaticArrays", "SymbolicIndexingInterface", "TimerOutputs", "Unityper"] -git-tree-sha1 = "c84ea9bcc9d527ba86ce08191cf561f35b48f9a0" +deps = ["AbstractTrees", "ArrayInterface", "Bijections", "ChainRulesCore", "Combinatorics", "ConstructionBase", "DataStructures", "DocStringExtensions", "DynamicPolynomials", "IfElse", "LinearAlgebra", "MultivariatePolynomials", "NaNMath", "Setfield", "SparseArrays", "SpecialFunctions", "StaticArrays", "SymbolicIndexingInterface", "TermInterface", "TimerOutputs", "Unityper", "WeakValueDicts"] +git-tree-sha1 = "bca944105ac43be732e3bdc38e39a4ce17391137" uuid = "d1185830-fcd6-423d-90d6-eec64667417b" -version = "1.7.1" +version = "3.8.1" + + [SymbolicUtils.extensions] + SymbolicUtilsLabelledArraysExt = "LabelledArrays" + SymbolicUtilsReverseDiffExt = "ReverseDiff" + + [SymbolicUtils.weakdeps] + LabelledArrays = "2ee39098-c373-598a-b85f-a56591580800" + ReverseDiff = "37e2e3b7-166d-5795-8a7a-e32c996b4267" [[Symbolics]] -deps = ["ArrayInterface", "Bijections", "ConstructionBase", "DataStructures", "DiffRules", "Distributions", "DocStringExtensions", "DomainSets", "DynamicPolynomials", "ForwardDiff", "IfElse", "LaTeXStrings", "LambertW", "Latexify", "Libdl", "LinearAlgebra", "LogExpFunctions", "MacroTools", "Markdown", "NaNMath", "PrecompileTools", "RecipesBase", "Reexport", "Requires", "RuntimeGeneratedFunctions", "SciMLBase", "Setfield", "SparseArrays", "SpecialFunctions", "StaticArrays", "SymbolicIndexingInterface", "SymbolicLimits", "SymbolicUtils"] -git-tree-sha1 = "4104548fff14d7370b278ee767651d6ec61eb195" +deps = ["ADTypes", "ArrayInterface", "Bijections", "CommonWorldInvalidations", "ConstructionBase", "DataStructures", "DiffRules", "Distributions", "DocStringExtensions", "DomainSets", "DynamicPolynomials", "IfElse", "LaTeXStrings", "Latexify", "Libdl", "LinearAlgebra", "LogExpFunctions", "MacroTools", "Markdown", "NaNMath", "PrecompileTools", "Primes", "RecipesBase", "Reexport", "RuntimeGeneratedFunctions", "SciMLBase", "Setfield", "SparseArrays", "SpecialFunctions", "StaticArraysCore", "SymbolicIndexingInterface", "SymbolicLimits", "SymbolicUtils", "TermInterface"] +git-tree-sha1 = "493c70c2a94a96dff97523afd2fb4ea7fd346b93" uuid = "0c5d862f-8b57-4792-8d23-62f2024744c7" -version = "5.28.0" +version = "6.22.1" [Symbolics.extensions] + SymbolicsForwardDiffExt = "ForwardDiff" SymbolicsGroebnerExt = "Groebner" - SymbolicsLuxCoreExt = "LuxCore" - SymbolicsPreallocationToolsExt = "PreallocationTools" + SymbolicsLuxExt = "Lux" + SymbolicsNemoExt = "Nemo" + SymbolicsPreallocationToolsExt = ["PreallocationTools", "ForwardDiff"] SymbolicsSymPyExt = "SymPy" [Symbolics.weakdeps] + ForwardDiff = "f6369f11-7733-5829-9624-2563aa707210" Groebner = "0b43b601-686d-58a3-8a1c-6623616c7cd4" - LuxCore = "bb33d45b-7691-41d6-9220-0943567d0623" + Lux = "b2108857-7c20-44ae-9111-449ecde12c47" + Nemo = "2edaba10-b0f1-5616-af89-8c11ac63239a" PreallocationTools = "d236fae5-4411-538c-8e31-a6e3d9e00b46" SymPy = "24249f21-da20-56a4-8eb1-6a02cf4ae2e6" @@ -1072,9 +1119,15 @@ deps = ["ArgTools", "SHA"] uuid = "a4e569a6-e804-4fa4-b0f3-eef7a1d5b13e" version = "1.10.0" +[[TermInterface]] +git-tree-sha1 = "d673e0aca9e46a2f63720201f55cc7b3e7169b16" +uuid = "8ea1fca8-c5ef-4a55-8b96-4e9afe9c9a3c" +version = "2.0.0" + [[Test]] deps = ["InteractiveUtils", "Logging", "Random", "Serialization"] uuid = "8dfed614-e22c-5e08-85e1-65c5234f0b40" +version = "1.11.0" [[ThreadingUtilities]] deps = ["ManualMemory"] @@ -1084,16 +1137,18 @@ version = "0.5.2" [[TimerOutputs]] deps = ["ExprTools", "Printf"] -git-tree-sha1 = "3a6f063d690135f5c1ba351412c82bae4d1402bf" +git-tree-sha1 = "d7298ebdfa1654583468a487e8e83fae9d72dac3" uuid = "a759f4b9-e2f1-59dc-863e-4aeb61b1ea8f" -version = "0.5.25" +version = "0.5.26" [[UUIDs]] deps = ["Random", "SHA"] uuid = "cf7118a7-6976-5b1a-9a39-7adc72f591a4" +version = "1.11.0" [[Unicode]] uuid = "4ec0a83e-493e-50e2-b9ac-8f72acf5a8f5" +version = "1.11.0" [[Unityper]] deps = ["ConstructionBase"] @@ -1106,6 +1161,11 @@ git-tree-sha1 = "58d6e80b4ee071f5efd07fda82cb9fbe17200868" uuid = "81def892-9a0e-5fdd-b105-ffc91e053289" version = "1.3.0" +[[WeakValueDicts]] +git-tree-sha1 = "98528c2610a5479f091d470967a25becfd83edd0" +uuid = "897b6980-f191-5a31-bcb0-bf3c4585e0c1" +version = "0.1.0" + [[Zlib_jll]] deps = ["Libdl"] uuid = "83775a58-1f1d-513f-b197-d71354ab007a" @@ -1119,7 +1179,7 @@ version = "5.11.0+0" [[nghttp2_jll]] deps = ["Artifacts", "Libdl"] uuid = "8e850ede-7688-5339-a07c-302acd2aaf8d" -version = "1.52.0+1" +version = "1.59.0+0" [[oneTBB_jll]] deps = ["Artifacts", "JLLWrappers", "Libdl"] diff --git a/Project.toml b/Project.toml index b73653c..3bd58f6 100644 --- a/Project.toml +++ b/Project.toml @@ -1,7 +1,7 @@ name = "SymbolicControlSystems" uuid = "886cb795-8fd3-4b11-92f6-8071e46f71c5" authors = ["Fredrik Bagge Carlson"] -version = "0.1.6" +version = "0.2.0" [deps] ControlSystemsBase = "aaaaaaaa-a6ca-5380-bf3e-84a91bcd477e" @@ -14,9 +14,9 @@ Symbolics = "0c5d862f-8b57-4792-8d23-62f2024744c7" [compat] ControlSystemsBase = "1" Latexify = "0.14, 0.15, 0.16" -SymPy = "1" -Symbolics = "5" -julia = "1.5" +SymPy = "2" +Symbolics = "6" +julia = "1.10" [extras] Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40" diff --git a/README.md b/README.md index f2d03f9..fd277f1 100644 --- a/README.md +++ b/README.md @@ -18,10 +18,11 @@ Pkg.add(["ControlSystemsBase", "SymbolicControlSystems"]) ```julia julia> using ControlSystemsBase, SymbolicControlSystems -julia> @vars w T d # Define (SymPy) symbolic variables +julia> @syms w T d # Define (SymPy) symbolic variables (w, T, d) -julia> h = 0.01; # Sample time +julia> + # Sample time julia> G = tf([w^2], [1, 2*d*w, w^2]) * tf(1, [T, 1]) TransferFunction{Continuous, SisoRational{Sym}} @@ -71,7 +72,7 @@ Discrete-time transfer function model Get a Latex-string ```julia julia> latextf(G) -"\$\\dfrac{1.0w^2}{0.003s^3 + s^2(0.006dw + 1.0) + s(2.0dw + 0.003w^2) + 1.0w^2}\$" +"\$\\dfrac{w^2}{Ts^3 + s^2(2Tdw + 1) + s(Tw^2 + 2dw) + w^2}\$" ``` @@ -85,7 +86,7 @@ A usage example follows ```julia using ControlSystemsBase, SymbolicControlSystems -@vars w T d # Define symbolic variables +@syms w T d # Define symbolic variables h = 0.01 # Sample time G = tf([w^2], [1, 2*d*w, w^2]) * tf(1, [T, 1]) Gd = tustin(G, h) # Discretize diff --git a/src/SymbolicControlSystems.jl b/src/SymbolicControlSystems.jl index 0456503..4fb2fe4 100644 --- a/src/SymbolicControlSystems.jl +++ b/src/SymbolicControlSystems.jl @@ -10,7 +10,7 @@ export sp, sym2num, latextf, Sym, - @vars, + @syms, simplify, tustin, doubleeuler, @@ -21,21 +21,15 @@ export sp, # export symbolics2sym -const sp = SymPy.PyCall.PyNULL() +const sp = SymPy.sympy# SymPy.PyCall.PyNULL() const s = SymPy.Sym("s") const z = SymPy.Sym("z") const NumOrDiv = Union{Num, Symb.SymbolicUtils.Div, Symb.SymbolicUtils.BasicSymbolic} -function __init__() - # global const s = Sym("s") - # global const z = Sym("z") - copy!(sp, SymPy.sympy) -end - -function SymPy.Sym(sys::StateSpace{<:Any,Sym}) +function SymPy.Sym(sys::StateSpace{<:Any,<:Sym}) A, B, C, D = ControlSystemsBase.ssdata(sys) expr = if isdiscrete(sys) (C*inv(z * I(size(A, 1)) - A)*B+D) @@ -73,7 +67,7 @@ function Num(sys::TransferFunction) λ = λ[] num = sum(((i, t),) -> t * λ^(i-1), enumerate(reverse(numvec(sys)[]))) |> Symb.simplify den = sum(((i, t),) -> t * λ^(i-1), enumerate(reverse(denvec(sys)[]))) |> Symb.simplify - Symb.simplify(num/den) + num/den # |> Symb.simplify end """ @@ -116,7 +110,7 @@ function ControlSystemsBase.minreal(sys::TransferFunction{<:Any,<:ControlSystems Sym(sys) |> simplify |> tf end -function ControlSystemsBase.tf(sys::StateSpace{<:Any,Sym}) +function ControlSystemsBase.tf(sys::StateSpace{<:Any,<:Sym}) n, p = simplify.(sp.Poly.(simplify.(sp.fraction(simplify(Sym(sys)))), s)) tf(simplify(n / p)) end @@ -129,7 +123,7 @@ function ControlSystemsBase.minreal(sys::StateSpace{<:Any,NumOrDiv}) nsys = Symb.simplify_fractions.(nsys) end -function ControlSystemsBase.minreal(sys::StateSpace{<:Any,Sym}) +function ControlSystemsBase.minreal(sys::StateSpace{<:Any,<:Sym}) # sys |> Symb.Num .|> Symb.symbolics_to_sympy .|> sp.simplify nsys = Sym(sys) nsys = sp.simplify.(nsys) @@ -170,7 +164,7 @@ end Replace symbols by numbers. `h` indicates the sample rate if the system is discrete. """ function sym2num(P::Sym, h::Real, pairs::Pair...) - P.has(s) && error( + convert(Bool, P.has(s)) && error( "Found `z` in symbolic expression, provide sample time as second argument to `sym2num`", ) for (sym, val) in pairs @@ -194,10 +188,10 @@ Replace symbols by numbers. """ function sym2num(P::Sym, pairs::Pair...) # for i = 1:2 - P.has(z) && error( + convert(Bool, P.has(z)) && error( "Found `z` in symbolic expression, provide sample time as second argument to `sym2num`", ) - P.has(s) || error("Found no `s` in symbolic expression, provide") + convert(Bool, P.has(s)) || error("Found no `s` in symbolic expression, provide") for (sym, val) in pairs P = subs(P, (sym, val)) end @@ -324,8 +318,8 @@ function ccode(G::TransferFunction; simplify = identity, cse = true, static=true numT = double ? "double" : "float" (G.nu == 1 && G.ny == 1) || throw(ArgumentError("C-code generation for transfer functions does not support multiple inputs or outputs, convert the transfer function to a statespace system using ss(G) and call ccode on that instead.")) P = Sym(G) - P.has(z) || error("Did not find `z` in symbolic expression") - P.has(s) && error("Found `s` in symbolic expression, provide expression in `z`") + convert(Bool, P.has(z)) || error("Did not find `z` in symbolic expression") + convert(Bool, P.has(s)) && error("Found `s` in symbolic expression, provide expression in `z`") n, d = numvec(G)[], denvec(G)[] if d[1] != 1 @info "Denominator polynomial not monic, dividing by the leading coefficient." @@ -334,7 +328,7 @@ function ccode(G::TransferFunction; simplify = identity, cse = true, static=true end @info "Calling free_symbols" @info vars = P.free_symbols - vars.remove(z) + delete!(vars, z) vars = collect(vars) vars = sort(vars, by = string) var_str = "" @@ -518,7 +512,7 @@ end Return a latex string representing `x`. If `mon`, then the denominator polynomial will be made monic (leading coefficient = 1). """ function latextf(x::Sym, mon = false) - var = x.has(z) ? z : s + var = convert(Bool, x.has(z)) ? z : s n, d = sp.fraction(x) if mon n, d = monic(n, d) diff --git a/test/runtests.jl b/test/runtests.jl index 1a22e88..4b3f25f 100644 --- a/test/runtests.jl +++ b/test/runtests.jl @@ -57,7 +57,7 @@ end pol = 2z^3+4*z @test SymbolicControlSystems.expand_coeffs(pol, z) == [2,0,4,0] - @vars ω0 + @syms ω0 sys = ControlSystemsBase.DemoSystems.resonant(;ω0) ssys = Sym(sys) n, d = sp.fraction(simplify(ssys)) @@ -68,7 +68,7 @@ end @testset "SymPy: Sym -> tf and vice versa" begin @info "SymPy: Testing Sym -> tf and vice versa" - @vars a b c + @syms a b c @test_both tf([a], [b, c]) a/(b*s + c) @test_both tf([a], [b, c], 0.1) a/(b*z + c) @@ -99,7 +99,7 @@ end @testset "sym2num" begin @info "Testing sym2num" - @vars a b c + @syms a b c G = tf([a], [b, c]) @test sym2num(G, a=>1, b=>1, c=>1) == tf(1,[1,1]) @test sym2num(G, a=>1, b=>2, c=>1) == tf(1,[2,1]) @@ -121,15 +121,13 @@ end @test sym2num(G, 0.1, a=>1, b=>1, c=>1) == tf([1,1],[1,1,1], 0.1) @test sym2num(G, 0.1, a=>1, b=>2, c=>1) == tf([2,1],[1,1,1], 0.1) @test sym2num(G, 0.1, a=>1, b=>1, c=>2) == tf([1,1],[1,2,1], 0.1) - - end @testset "Tustin and C-code" begin @info "Testing Tustin and C-code" - @vars J c + @syms J c G = tf(1.,[J^2,c,1]) Gs = Sym(G) Gn = tf(1.,[1,1,1]) @@ -151,7 +149,7 @@ end - @vars w T d # Define symbolic variables + @syms w T d # Define symbolic variables h = 0.01 G = tf([w^2], [1, 2*d*w, w^2]) * tf(1, [T, 1]) Gd = tustin(G, h) # Discretize @@ -226,7 +224,7 @@ end @test norm(y-y_)/norm(y_) < 1e-10 # TODO: figure out why this is more sensitive ## Multiple inputs - @vars w T d # Define symbolic variables + @syms w T d # Define symbolic variables h = 0.01 G = tf([w^2], [1, 2*d*w, w^2]) * tf(1, [T, 1]) Gd = tustin(G, h) # Discretize @@ -317,7 +315,7 @@ end tf([a], [b, c]) end Gsympy = let - @vars a b c s + @syms a b c s tf([a], [b, c]) end