diff --git a/.gitignore b/.gitignore index 36868b0f..dca6a238 100644 --- a/.gitignore +++ b/.gitignore @@ -1,9 +1,38 @@ -*.jl.*.cov +# Files generated by invoking Julia with --code-coverage *.jl.cov +*.jl.*.cov + +# Files generated by invoking Julia with --track-allocation *.jl.mem -/docs/build/ + +# System-specific files and directories generated by the BinaryProvider and BinDeps packages +# They contain absolute paths specific to the host computer, and so should not be committed +deps/deps.jl +deps/build.log +deps/downloads/ +deps/usr/ +deps/src/ + +# Build artifacts for creating documentation generated by the Documenter package +docs/build/ +docs/site/ + +# File generated by Pkg, the package manager, based on a corresponding Project.toml +# It records a fixed state of all packages used by the project. As such, it should not be +# committed for packages, but should be committed for applications that require a static +# environment. +Manifest.toml +docs/Manifest.toml + +# Project specific ignores below +# generated example artifacts /examples/**/plots/ /examples/**/trajectories/ + +# external pkgs and configs pardiso.lic /.CondaPkg/ -*.code-workspace \ No newline at end of file +*.code-workspace + +# generated build folder +build/ diff --git a/Manifest.toml b/Manifest.toml deleted file mode 100644 index 5b817387..00000000 --- a/Manifest.toml +++ /dev/null @@ -1,2030 +0,0 @@ -# This file is machine-generated - editing it directly is not advised - -julia_version = "1.11.1" -manifest_format = "2.0" -project_hash = "2006237ebe2b0d8037e7b6c09aa0fa77ca004ceb" - -[[deps.ADTypes]] -git-tree-sha1 = "eea5d80188827b35333801ef97a40c2ed653b081" -uuid = "47edcb42-4c32-4615-8424-f2b9edc5f35b" -version = "1.9.0" - - [deps.ADTypes.extensions] - ADTypesChainRulesCoreExt = "ChainRulesCore" - ADTypesEnzymeCoreExt = "EnzymeCore" - - [deps.ADTypes.weakdeps] - ChainRulesCore = "d360d2e6-b24c-11e9-a2a3-2a2ae2dbcce4" - EnzymeCore = "f151be2c-9106-41f4-ab19-57ee4f262869" - -[[deps.ASL_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl", "Pkg"] -git-tree-sha1 = "6252039f98492252f9e47c312c8ffda0e3b9e78d" -uuid = "ae81ac8f-d209-56e5-92de-9978fef736f9" -version = "0.1.3+0" - -[[deps.AbstractDifferentiation]] -deps = ["ExprTools", "LinearAlgebra", "Requires"] -git-tree-sha1 = "d29ce82ed1d4c37135095e1a4d799c93d7be2361" -uuid = "c29ec348-61ec-40c8-8164-b8c60e9d9f3d" -version = "0.6.2" - - [deps.AbstractDifferentiation.extensions] - AbstractDifferentiationChainRulesCoreExt = "ChainRulesCore" - AbstractDifferentiationFiniteDifferencesExt = "FiniteDifferences" - AbstractDifferentiationForwardDiffExt = ["DiffResults", "ForwardDiff"] - AbstractDifferentiationReverseDiffExt = ["DiffResults", "ReverseDiff"] - AbstractDifferentiationTrackerExt = "Tracker" - AbstractDifferentiationZygoteExt = "Zygote" - - [deps.AbstractDifferentiation.weakdeps] - ChainRulesCore = "d360d2e6-b24c-11e9-a2a3-2a2ae2dbcce4" - DiffResults = "163ba53b-c6d8-5494-b064-1a9d43ac40c5" - FiniteDifferences = "26cc04aa-876d-5657-8c51-4c34ba976000" - ForwardDiff = "f6369f11-7733-5829-9624-2563aa707210" - ReverseDiff = "37e2e3b7-166d-5795-8a7a-e32c996b4267" - Tracker = "9f7883ad-71c0-57eb-9f7f-b5c9e6d3789c" - Zygote = "e88e6eb3-aa80-5325-afca-941959d7151f" - -[[deps.AbstractFFTs]] -deps = ["LinearAlgebra"] -git-tree-sha1 = "d92ad398961a3ed262d8bf04a1a2b8340f915fef" -uuid = "621f4979-c628-5d54-868e-fcf4e3e8185c" -version = "1.5.0" -weakdeps = ["ChainRulesCore", "Test"] - - [deps.AbstractFFTs.extensions] - AbstractFFTsChainRulesCoreExt = "ChainRulesCore" - AbstractFFTsTestExt = "Test" - -[[deps.AbstractTrees]] -git-tree-sha1 = "2d9c9a55f9c93e8887ad391fbae72f8ef55e1177" -uuid = "1520ce14-60c1-5f80-bbc7-55ef81b5835c" -version = "0.4.5" - -[[deps.Accessors]] -deps = ["CompositionsBase", "ConstructionBase", "InverseFunctions", "LinearAlgebra", "MacroTools", "Markdown"] -git-tree-sha1 = "b392ede862e506d451fc1616e79aa6f4c673dab8" -uuid = "7d9f7c33-5ae7-4f3b-8dc6-eff91059b697" -version = "0.1.38" - - [deps.Accessors.extensions] - AccessorsAxisKeysExt = "AxisKeys" - AccessorsDatesExt = "Dates" - AccessorsIntervalSetsExt = "IntervalSets" - AccessorsStaticArraysExt = "StaticArrays" - AccessorsStructArraysExt = "StructArrays" - AccessorsTestExt = "Test" - AccessorsUnitfulExt = "Unitful" - - [deps.Accessors.weakdeps] - AxisKeys = "94b1ba4f-4ee9-5380-92f1-94cde586c3c5" - Dates = "ade2ca70-3891-5945-98fb-dc099432e06a" - IntervalSets = "8197267c-284f-5f27-9208-e0e47529a953" - Requires = "ae029012-a4dd-5104-9daa-d747884805df" - StaticArrays = "90137ffa-7385-5640-81b9-e52037218182" - StructArrays = "09ab397b-f2b6-538f-b94a-2f83cf4a842a" - Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40" - Unitful = "1986cc42-f94f-5a68-af5c-568840ba703d" - -[[deps.Adapt]] -deps = ["LinearAlgebra", "Requires"] -git-tree-sha1 = "50c3c56a52972d78e8be9fd135bfb91c9574c140" -uuid = "79e6a3ab-5dfb-504d-930d-738a2a938a0e" -version = "4.1.1" -weakdeps = ["StaticArrays"] - - [deps.Adapt.extensions] - AdaptStaticArraysExt = "StaticArrays" - -[[deps.AdaptivePredicates]] -git-tree-sha1 = "7e651ea8d262d2d74ce75fdf47c4d63c07dba7a6" -uuid = "35492f91-a3bd-45ad-95db-fcad7dcfedb7" -version = "1.2.0" - -[[deps.AliasTables]] -deps = ["PtrArrays", "Random"] -git-tree-sha1 = "9876e1e164b144ca45e9e3198d0b689cadfed9ff" -uuid = "66dad0bd-aa9a-41b7-9441-69ab47430ed8" -version = "1.1.3" - -[[deps.Animations]] -deps = ["Colors"] -git-tree-sha1 = "e81c509d2c8e49592413bfb0bb3b08150056c79d" -uuid = "27a7e980-b3e6-11e9-2bcd-0b925532e340" -version = "0.4.1" - -[[deps.Aqua]] -deps = ["Compat", "Pkg", "Test"] -git-tree-sha1 = "49b1d7a9870c87ba13dc63f8ccfcf578cb266f95" -uuid = "4c88cf16-eb10-579e-8560-4a9242c79595" -version = "0.8.9" - -[[deps.ArgTools]] -uuid = "0dad84c5-d112-42e6-8d28-ef12dabb789f" -version = "1.1.2" - -[[deps.ArrayInterface]] -deps = ["Adapt", "LinearAlgebra"] -git-tree-sha1 = "d60a1922358aa203019b7857a2c8c37329b8736c" -uuid = "4fba245c-0d91-5ea0-9b3e-6abc04ee57a9" -version = "7.17.0" - - [deps.ArrayInterface.extensions] - ArrayInterfaceBandedMatricesExt = "BandedMatrices" - ArrayInterfaceBlockBandedMatricesExt = "BlockBandedMatrices" - ArrayInterfaceCUDAExt = "CUDA" - ArrayInterfaceCUDSSExt = "CUDSS" - ArrayInterfaceChainRulesCoreExt = "ChainRulesCore" - ArrayInterfaceChainRulesExt = "ChainRules" - ArrayInterfaceGPUArraysCoreExt = "GPUArraysCore" - ArrayInterfaceReverseDiffExt = "ReverseDiff" - ArrayInterfaceSparseArraysExt = "SparseArrays" - ArrayInterfaceStaticArraysCoreExt = "StaticArraysCore" - ArrayInterfaceTrackerExt = "Tracker" - - [deps.ArrayInterface.weakdeps] - BandedMatrices = "aae01518-5342-5314-be14-df237901396f" - BlockBandedMatrices = "ffab5731-97b5-5995-9138-79e8c1846df0" - CUDA = "052768ef-5323-5732-b1bb-66c8b64840ba" - CUDSS = "45b445bb-4962-46a0-9369-b4df9d0f772e" - ChainRules = "082447d4-558c-5d27-93f4-14fc19e9eca2" - ChainRulesCore = "d360d2e6-b24c-11e9-a2a3-2a2ae2dbcce4" - GPUArraysCore = "46192b85-c4d5-4398-a991-12ede77f4527" - ReverseDiff = "37e2e3b7-166d-5795-8a7a-e32c996b4267" - SparseArrays = "2f01184e-e22b-5df5-ae63-d93ebab69eaf" - StaticArraysCore = "1e83bf80-4336-4d27-bf5d-d5a4f845583c" - Tracker = "9f7883ad-71c0-57eb-9f7f-b5c9e6d3789c" - -[[deps.ArrayLayouts]] -deps = ["FillArrays", "LinearAlgebra"] -git-tree-sha1 = "492681bc44fac86804706ddb37da10880a2bd528" -uuid = "4c555306-a7a7-4459-81d9-ec55ddd5c99a" -version = "1.10.4" -weakdeps = ["SparseArrays"] - - [deps.ArrayLayouts.extensions] - ArrayLayoutsSparseArraysExt = "SparseArrays" - -[[deps.Artifacts]] -uuid = "56f22d72-fd6d-98f1-02f0-08ddc0907c33" -version = "1.11.0" - -[[deps.Automa]] -deps = ["PrecompileTools", "SIMD", "TranscodingStreams"] -git-tree-sha1 = "a8f503e8e1a5f583fbef15a8440c8c7e32185df2" -uuid = "67c07d97-cdcb-5c2c-af73-a7f9c32a568b" -version = "1.1.0" - -[[deps.AxisAlgorithms]] -deps = ["LinearAlgebra", "Random", "SparseArrays", "WoodburyMatrices"] -git-tree-sha1 = "01b8ccb13d68535d73d2b0c23e39bd23155fb712" -uuid = "13072b0f-2c55-5437-9ae7-d433b7a33950" -version = "1.1.0" - -[[deps.AxisArrays]] -deps = ["Dates", "IntervalSets", "IterTools", "RangeArrays"] -git-tree-sha1 = "16351be62963a67ac4083f748fdb3cca58bfd52f" -uuid = "39de3d68-74b9-583c-8d2d-e117c070f3a9" -version = "0.4.7" - -[[deps.Base64]] -uuid = "2a0f44e3-6c83-55bd-87e4-b1978d98bd5f" -version = "1.11.0" - -[[deps.BenchmarkTools]] -deps = ["JSON", "Logging", "Printf", "Profile", "Statistics", "UUIDs"] -git-tree-sha1 = "f1dff6729bc61f4d49e140da1af55dcd1ac97b2f" -uuid = "6e4b80f9-dd63-53aa-95a3-0cdb28fa8baf" -version = "1.5.0" - -[[deps.Bijections]] -git-tree-sha1 = "d8b0439d2be438a5f2cd68ec158fe08a7b2595b7" -uuid = "e2ed5e7c-b2de-5872-ae92-c73ca462fb04" -version = "0.1.9" - -[[deps.BlockArrays]] -deps = ["ArrayLayouts", "FillArrays", "LinearAlgebra"] -git-tree-sha1 = "d434647f798823bcae510aee0bc0401927f64391" -uuid = "8e7c35d0-a365-5155-bbbb-fb81a777f24e" -version = "1.1.1" - - [deps.BlockArrays.extensions] - BlockArraysBandedMatricesExt = "BandedMatrices" - - [deps.BlockArrays.weakdeps] - BandedMatrices = "aae01518-5342-5314-be14-df237901396f" - -[[deps.Bzip2_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl", "Pkg"] -git-tree-sha1 = "8873e196c2eb87962a2048b3b8e08946535864a1" -uuid = "6e34b625-4abd-537c-b88f-471c36dfa7a0" -version = "1.0.8+2" - -[[deps.CEnum]] -git-tree-sha1 = "389ad5c84de1ae7cf0e28e381131c98ea87d54fc" -uuid = "fa961155-64e5-5f13-b03f-caf6b980ea82" -version = "0.5.0" - -[[deps.CRC32c]] -uuid = "8bf52ea8-c179-5cab-976a-9e18b702a9bc" -version = "1.11.0" - -[[deps.CRlibm_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl", "Pkg"] -git-tree-sha1 = "e329286945d0cfc04456972ea732551869af1cfc" -uuid = "4e9b3aee-d8a1-5a3d-ad8b-7d824db253f0" -version = "1.0.1+0" - -[[deps.Cairo]] -deps = ["Cairo_jll", "Colors", "Glib_jll", "Graphics", "Libdl", "Pango_jll"] -git-tree-sha1 = "7b6ad8c35f4bc3bca8eb78127c8b99719506a5fb" -uuid = "159f3aea-2a34-519c-b102-8c37f9878175" -version = "1.1.0" - -[[deps.CairoMakie]] -deps = ["CRC32c", "Cairo", "Cairo_jll", "Colors", "FileIO", "FreeType", "GeometryBasics", "LinearAlgebra", "Makie", "PrecompileTools"] -git-tree-sha1 = "c3161fbfe99d9d7ee121cf2017d49966b152857c" -uuid = "13f3f980-e62b-5c42-98c6-ff1f3baf88f0" -version = "0.12.16" - -[[deps.Cairo_jll]] -deps = ["Artifacts", "Bzip2_jll", "CompilerSupportLibraries_jll", "Fontconfig_jll", "FreeType2_jll", "Glib_jll", "JLLWrappers", "LZO_jll", "Libdl", "Pixman_jll", "Xorg_libXext_jll", "Xorg_libXrender_jll", "Zlib_jll", "libpng_jll"] -git-tree-sha1 = "009060c9a6168704143100f36ab08f06c2af4642" -uuid = "83423d85-b0ee-5818-9007-b63ccbeb887a" -version = "1.18.2+1" - -[[deps.ChainRulesCore]] -deps = ["Compat", "LinearAlgebra"] -git-tree-sha1 = "3e4b134270b372f2ed4d4d0e936aabaefc1802bc" -uuid = "d360d2e6-b24c-11e9-a2a3-2a2ae2dbcce4" -version = "1.25.0" -weakdeps = ["SparseArrays"] - - [deps.ChainRulesCore.extensions] - ChainRulesCoreSparseArraysExt = "SparseArrays" - -[[deps.CodecBzip2]] -deps = ["Bzip2_jll", "TranscodingStreams"] -git-tree-sha1 = "e7c529cc31bb85b97631b922fa2e6baf246f5905" -uuid = "523fee87-0ab8-5b00-afb7-3ecf72e48cfd" -version = "0.8.4" - -[[deps.CodecZlib]] -deps = ["TranscodingStreams", "Zlib_jll"] -git-tree-sha1 = "bce6804e5e6044c6daab27bb533d1295e4a2e759" -uuid = "944b1d66-785c-5afd-91f1-9de20f533193" -version = "0.7.6" - -[[deps.ColorBrewer]] -deps = ["Colors", "JSON", "Test"] -git-tree-sha1 = "61c5334f33d91e570e1d0c3eb5465835242582c4" -uuid = "a2cac450-b92f-5266-8821-25eda20663c8" -version = "0.4.0" - -[[deps.ColorSchemes]] -deps = ["ColorTypes", "ColorVectorSpace", "Colors", "FixedPointNumbers", "PrecompileTools", "Random"] -git-tree-sha1 = "c785dfb1b3bfddd1da557e861b919819b82bbe5b" -uuid = "35d6a980-a343-548e-a6ea-1d62b119f2f4" -version = "3.27.1" - -[[deps.ColorTypes]] -deps = ["FixedPointNumbers", "Random"] -git-tree-sha1 = "b10d0b65641d57b8b4d5e234446582de5047050d" -uuid = "3da002f7-5984-5a60-b8a6-cbb66c0b333f" -version = "0.11.5" - -[[deps.ColorVectorSpace]] -deps = ["ColorTypes", "FixedPointNumbers", "LinearAlgebra", "Requires", "Statistics", "TensorCore"] -git-tree-sha1 = "a1f44953f2382ebb937d60dafbe2deea4bd23249" -uuid = "c3611d14-8923-5661-9e6a-0046d554d3a4" -version = "0.10.0" -weakdeps = ["SpecialFunctions"] - - [deps.ColorVectorSpace.extensions] - SpecialFunctionsExt = "SpecialFunctions" - -[[deps.Colors]] -deps = ["ColorTypes", "FixedPointNumbers", "Reexport"] -git-tree-sha1 = "362a287c3aa50601b0bc359053d5c2468f0e7ce0" -uuid = "5ae59095-9a9b-59fe-a467-6f913c188581" -version = "0.12.11" - -[[deps.Combinatorics]] -git-tree-sha1 = "08c8b6831dc00bfea825826be0bc8336fc369860" -uuid = "861a8166-3701-5b0c-9a16-15d98fcdc6aa" -version = "1.0.2" - -[[deps.CommonSolve]] -git-tree-sha1 = "0eee5eb66b1cf62cd6ad1b460238e60e4b09400c" -uuid = "38540f10-b2f7-11e9-35d8-d573e4eb0ff2" -version = "0.2.4" - -[[deps.CommonSubexpressions]] -deps = ["MacroTools"] -git-tree-sha1 = "cda2cfaebb4be89c9084adaca7dd7333369715c5" -uuid = "bbf7d656-a473-5ed7-a52c-81e309532950" -version = "0.3.1" - -[[deps.CommonWorldInvalidations]] -git-tree-sha1 = "ae52d1c52048455e85a387fbee9be553ec2b68d0" -uuid = "f70d9fcc-98c5-4d4a-abd7-e4cdeebd8ca8" -version = "1.0.0" - -[[deps.Compat]] -deps = ["TOML", "UUIDs"] -git-tree-sha1 = "8ae8d32e09f0dcf42a36b90d4e17f5dd2e4c4215" -uuid = "34da2185-b29b-5c13-b0c7-acf172513d20" -version = "4.16.0" -weakdeps = ["Dates", "LinearAlgebra"] - - [deps.Compat.extensions] - CompatLinearAlgebraExt = "LinearAlgebra" - -[[deps.CompilerSupportLibraries_jll]] -deps = ["Artifacts", "Libdl"] -uuid = "e66e0078-7015-5450-92f7-15fbd957f2ae" -version = "1.1.1+0" - -[[deps.CompositeTypes]] -git-tree-sha1 = "bce26c3dab336582805503bed209faab1c279768" -uuid = "b152e2b5-7a66-4b01-a709-34e65c35f657" -version = "0.1.4" - -[[deps.CompositionsBase]] -git-tree-sha1 = "802bb88cd69dfd1509f6670416bd4434015693ad" -uuid = "a33af91c-f02d-484b-be07-31d278c5ca2b" -version = "0.1.2" -weakdeps = ["InverseFunctions"] - - [deps.CompositionsBase.extensions] - CompositionsBaseInverseFunctionsExt = "InverseFunctions" - -[[deps.ConstructionBase]] -git-tree-sha1 = "76219f1ed5771adbb096743bff43fb5fdd4c1157" -uuid = "187b0558-2788-49d3-abe0-74a17ed4e7c9" -version = "1.5.8" -weakdeps = ["IntervalSets", "LinearAlgebra", "StaticArrays"] - - [deps.ConstructionBase.extensions] - ConstructionBaseIntervalSetsExt = "IntervalSets" - ConstructionBaseLinearAlgebraExt = "LinearAlgebra" - ConstructionBaseStaticArraysExt = "StaticArrays" - -[[deps.Contour]] -git-tree-sha1 = "439e35b0b36e2e5881738abc8857bd92ad6ff9a8" -uuid = "d38c429a-6771-53c6-b99e-75d170b6e991" -version = "0.6.3" - -[[deps.DataAPI]] -git-tree-sha1 = "abe83f3a2f1b857aac70ef8b269080af17764bbe" -uuid = "9a962f9c-6df0-11e9-0e5d-c546b8b5ee8a" -version = "1.16.0" - -[[deps.DataStructures]] -deps = ["Compat", "InteractiveUtils", "OrderedCollections"] -git-tree-sha1 = "1d0a14036acb104d9e89698bd408f63ab58cdc82" -uuid = "864edb3b-99cc-5e75-8d2d-829cb0a9cfe8" -version = "0.18.20" - -[[deps.DataValueInterfaces]] -git-tree-sha1 = "bfc1187b79289637fa0ef6d4436ebdfe6905cbd6" -uuid = "e2d170a0-9d28-54be-80f0-106bbe20a464" -version = "1.0.0" - -[[deps.Dates]] -deps = ["Printf"] -uuid = "ade2ca70-3891-5945-98fb-dc099432e06a" -version = "1.11.0" - -[[deps.DelaunayTriangulation]] -deps = ["AdaptivePredicates", "EnumX", "ExactPredicates", "PrecompileTools", "Random"] -git-tree-sha1 = "89df54fbe66e5872d91d8c2cd3a375f660c3fd64" -uuid = "927a84f5-c5f4-47a5-9785-b46e178433df" -version = "1.6.1" - -[[deps.DiffResults]] -deps = ["StaticArraysCore"] -git-tree-sha1 = "782dd5f4561f5d267313f23853baaaa4c52ea621" -uuid = "163ba53b-c6d8-5494-b064-1a9d43ac40c5" -version = "1.1.0" - -[[deps.DiffRules]] -deps = ["IrrationalConstants", "LogExpFunctions", "NaNMath", "Random", "SpecialFunctions"] -git-tree-sha1 = "23163d55f885173722d1e4cf0f6110cdbaf7e272" -uuid = "b552c78f-8df3-52c6-915a-8e097449b14b" -version = "1.15.1" - -[[deps.Distributed]] -deps = ["Random", "Serialization", "Sockets"] -uuid = "8ba89e20-285c-5b6f-9357-94700520ee1b" -version = "1.11.0" - -[[deps.Distributions]] -deps = ["AliasTables", "FillArrays", "LinearAlgebra", "PDMats", "Printf", "QuadGK", "Random", "SpecialFunctions", "Statistics", "StatsAPI", "StatsBase", "StatsFuns"] -git-tree-sha1 = "3101c32aab536e7a27b1763c0797dba151b899ad" -uuid = "31c24e10-a181-5473-b8eb-7969acd0382f" -version = "0.25.113" - - [deps.Distributions.extensions] - DistributionsChainRulesCoreExt = "ChainRulesCore" - DistributionsDensityInterfaceExt = "DensityInterface" - DistributionsTestExt = "Test" - - [deps.Distributions.weakdeps] - ChainRulesCore = "d360d2e6-b24c-11e9-a2a3-2a2ae2dbcce4" - DensityInterface = "b429d917-457f-4dbc-8f4c-0cc954292b1d" - Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40" - -[[deps.DocStringExtensions]] -deps = ["LibGit2"] -git-tree-sha1 = "2fb1e02f2b635d0845df5d7c167fec4dd739b00d" -uuid = "ffbed154-4ef7-542d-bbb7-c09d3a79fcae" -version = "0.9.3" - -[[deps.DomainSets]] -deps = ["CompositeTypes", "IntervalSets", "LinearAlgebra", "Random", "StaticArrays"] -git-tree-sha1 = "490392af2c7d63183bfa2c8aaa6ab981c5ba7561" -uuid = "5b8099bc-c8ec-5219-889f-1d9e522a28bf" -version = "0.7.14" -weakdeps = ["Makie"] - - [deps.DomainSets.extensions] - DomainSetsMakieExt = "Makie" - -[[deps.Downloads]] -deps = ["ArgTools", "FileWatching", "LibCURL", "NetworkOptions"] -uuid = "f43a241f-c20a-4ad4-852c-f6b1247861c6" -version = "1.6.0" - -[[deps.DynamicPolynomials]] -deps = ["Future", "LinearAlgebra", "MultivariatePolynomials", "MutableArithmetics", "Reexport", "Test"] -git-tree-sha1 = "bbf1ace0781d9744cb697fb856bd2c3f6568dadb" -uuid = "7c1d4256-1411-5781-91ec-d7bc3513ac07" -version = "0.6.0" - -[[deps.EarCut_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl", "Pkg"] -git-tree-sha1 = "e3290f2d49e661fbd94046d7e3726ffcb2d41053" -uuid = "5ae413db-bbd1-5e63-b57d-d24a61df00f5" -version = "2.2.4+0" - -[[deps.Einsum]] -deps = ["Compat"] -git-tree-sha1 = "4a6b3eee0161c89700b6c1949feae8b851da5494" -uuid = "b7d42ee7-0b51-5a75-98ca-779d3107e4c0" -version = "0.4.1" - -[[deps.EnumX]] -git-tree-sha1 = "bdb1942cd4c45e3c678fd11569d5cccd80976237" -uuid = "4e289a0a-7415-4d19-859d-a7e5c4648b56" -version = "1.0.4" - -[[deps.ExactPredicates]] -deps = ["IntervalArithmetic", "Random", "StaticArrays"] -git-tree-sha1 = "b3f2ff58735b5f024c392fde763f29b057e4b025" -uuid = "429591f6-91af-11e9-00e2-59fbe8cec110" -version = "2.2.8" - -[[deps.Expat_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "1c6317308b9dc757616f0b5cb379db10494443a7" -uuid = "2e619515-83b5-522b-bb60-26c02a35a201" -version = "2.6.2+0" - -[[deps.ExponentialAction]] -deps = ["AbstractDifferentiation", "ChainRulesCore", "LinearAlgebra", "SparseArrays"] -git-tree-sha1 = "c8e96f985aa517c5b8413661c8c06e1021895639" -uuid = "e24c0720-ea99-47e8-929e-571b494574d3" -version = "0.2.10" - -[[deps.ExprTools]] -git-tree-sha1 = "27415f162e6028e81c72b82ef756bf321213b6ec" -uuid = "e2ba6199-217a-4e67-a87a-7c52f15ade04" -version = "0.1.10" - -[[deps.Expronicon]] -deps = ["MLStyle", "Pkg", "TOML"] -git-tree-sha1 = "fc3951d4d398b5515f91d7fe5d45fc31dccb3c9b" -uuid = "6b7a57c9-7cc1-4fdf-b7f5-e857abae3636" -version = "0.8.5" - -[[deps.Extents]] -git-tree-sha1 = "81023caa0021a41712685887db1fc03db26f41f5" -uuid = "411431e0-e8b7-467b-b5e0-f676ba4f2910" -version = "0.1.4" - -[[deps.FFMPEG_jll]] -deps = ["Artifacts", "Bzip2_jll", "FreeType2_jll", "FriBidi_jll", "JLLWrappers", "LAME_jll", "Libdl", "Ogg_jll", "OpenSSL_jll", "Opus_jll", "PCRE2_jll", "Zlib_jll", "libaom_jll", "libass_jll", "libfdk_aac_jll", "libvorbis_jll", "x264_jll", "x265_jll"] -git-tree-sha1 = "8cc47f299902e13f90405ddb5bf87e5d474c0d38" -uuid = "b22a6f82-2f65-5046-a5b2-351ab43fb4e5" -version = "6.1.2+0" - -[[deps.FFTW]] -deps = ["AbstractFFTs", "FFTW_jll", "LinearAlgebra", "MKL_jll", "Preferences", "Reexport"] -git-tree-sha1 = "4820348781ae578893311153d69049a93d05f39d" -uuid = "7a1cc6ca-52ef-59f5-83cd-3a7055c09341" -version = "1.8.0" - -[[deps.FFTW_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl", "Pkg"] -git-tree-sha1 = "4d81ed14783ec49ce9f2e168208a12ce1815aa25" -uuid = "f5851436-0d7a-5f13-b9de-f02708fd171a" -version = "3.3.10+1" - -[[deps.FileIO]] -deps = ["Pkg", "Requires", "UUIDs"] -git-tree-sha1 = "62ca0547a14c57e98154423419d8a342dca75ca9" -uuid = "5789e2e9-d7fb-5bc7-8068-2c6fae9b9549" -version = "1.16.4" - -[[deps.FilePaths]] -deps = ["FilePathsBase", "MacroTools", "Reexport", "Requires"] -git-tree-sha1 = "919d9412dbf53a2e6fe74af62a73ceed0bce0629" -uuid = "8fc22ac5-c921-52a6-82fd-178b2807b824" -version = "0.8.3" - -[[deps.FilePathsBase]] -deps = ["Compat", "Dates"] -git-tree-sha1 = "7878ff7172a8e6beedd1dea14bd27c3c6340d361" -uuid = "48062228-2e41-5def-b9a4-89aafe57970f" -version = "0.9.22" -weakdeps = ["Mmap", "Test"] - - [deps.FilePathsBase.extensions] - FilePathsBaseMmapExt = "Mmap" - FilePathsBaseTestExt = "Test" - -[[deps.FileWatching]] -uuid = "7b1f6079-737a-58dc-b8bc-7a2ca5c1b5ee" -version = "1.11.0" - -[[deps.FillArrays]] -deps = ["LinearAlgebra"] -git-tree-sha1 = "6a70198746448456524cb442b8af316927ff3e1a" -uuid = "1a297f60-69ca-5386-bcde-b61e274b549b" -version = "1.13.0" -weakdeps = ["PDMats", "SparseArrays", "Statistics"] - - [deps.FillArrays.extensions] - FillArraysPDMatsExt = "PDMats" - FillArraysSparseArraysExt = "SparseArrays" - FillArraysStatisticsExt = "Statistics" - -[[deps.FixedPointNumbers]] -deps = ["Statistics"] -git-tree-sha1 = "05882d6995ae5c12bb5f36dd2ed3f61c98cbb172" -uuid = "53c48c17-4a7d-5ca2-90c5-79b7896eea93" -version = "0.8.5" - -[[deps.Fontconfig_jll]] -deps = ["Artifacts", "Bzip2_jll", "Expat_jll", "FreeType2_jll", "JLLWrappers", "Libdl", "Libuuid_jll", "Zlib_jll"] -git-tree-sha1 = "db16beca600632c95fc8aca29890d83788dd8b23" -uuid = "a3f928ae-7b40-5064-980b-68af3947d34b" -version = "2.13.96+0" - -[[deps.Format]] -git-tree-sha1 = "9c68794ef81b08086aeb32eeaf33531668d5f5fc" -uuid = "1fa38f19-a742-5d3f-a2b9-30dd87b9d5f8" -version = "1.3.7" - -[[deps.ForwardDiff]] -deps = ["CommonSubexpressions", "DiffResults", "DiffRules", "LinearAlgebra", "LogExpFunctions", "NaNMath", "Preferences", "Printf", "Random", "SpecialFunctions"] -git-tree-sha1 = "a2df1b776752e3f344e5116c06d75a10436ab853" -uuid = "f6369f11-7733-5829-9624-2563aa707210" -version = "0.10.38" -weakdeps = ["StaticArrays"] - - [deps.ForwardDiff.extensions] - ForwardDiffStaticArraysExt = "StaticArrays" - -[[deps.FreeType]] -deps = ["CEnum", "FreeType2_jll"] -git-tree-sha1 = "907369da0f8e80728ab49c1c7e09327bf0d6d999" -uuid = "b38be410-82b0-50bf-ab77-7b57e271db43" -version = "4.1.1" - -[[deps.FreeType2_jll]] -deps = ["Artifacts", "Bzip2_jll", "JLLWrappers", "Libdl", "Zlib_jll"] -git-tree-sha1 = "5c1d8ae0efc6c2e7b1fc502cbe25def8f661b7bc" -uuid = "d7e528f0-a631-5988-bf34-fe36492bcfd7" -version = "2.13.2+0" - -[[deps.FreeTypeAbstraction]] -deps = ["ColorVectorSpace", "Colors", "FreeType", "GeometryBasics"] -git-tree-sha1 = "84dfe824bd6fdf2a5d73bb187ff31b5549b2a79c" -uuid = "663a7486-cb36-511b-a19d-713bb74d65c9" -version = "0.10.4" - -[[deps.FriBidi_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "1ed150b39aebcc805c26b93a8d0122c940f64ce2" -uuid = "559328eb-81f9-559d-9380-de523a88c83c" -version = "1.0.14+0" - -[[deps.FunctionWrappers]] -git-tree-sha1 = "d62485945ce5ae9c0c48f124a84998d755bae00e" -uuid = "069b7b12-0de2-55c6-9aab-29f3d0a68a2e" -version = "1.1.3" - -[[deps.FunctionWrappersWrappers]] -deps = ["FunctionWrappers"] -git-tree-sha1 = "b104d487b34566608f8b4e1c39fb0b10aa279ff8" -uuid = "77dc65aa-8811-40c2-897b-53d922fa7daf" -version = "0.1.3" - -[[deps.Future]] -deps = ["Random"] -uuid = "9fa8497b-333b-5362-9e8d-4d0656e87820" -version = "1.11.0" - -[[deps.GPUArraysCore]] -deps = ["Adapt"] -git-tree-sha1 = "ec632f177c0d990e64d955ccc1b8c04c485a0950" -uuid = "46192b85-c4d5-4398-a991-12ede77f4527" -version = "0.1.6" - -[[deps.GeoFormatTypes]] -git-tree-sha1 = "59107c179a586f0fe667024c5eb7033e81333271" -uuid = "68eda718-8dee-11e9-39e7-89f7f65f511f" -version = "0.4.2" - -[[deps.GeoInterface]] -deps = ["Extents", "GeoFormatTypes"] -git-tree-sha1 = "826b4fd69438d9ce4d2b19de6bc2f970f45f0f88" -uuid = "cf35fbd7-0cd7-5166-be24-54bfbe79505f" -version = "1.3.8" - -[[deps.GeometryBasics]] -deps = ["EarCut_jll", "Extents", "GeoInterface", "IterTools", "LinearAlgebra", "StaticArrays", "StructArrays", "Tables"] -git-tree-sha1 = "b62f2b2d76cee0d61a2ef2b3118cd2a3215d3134" -uuid = "5c1252a2-5f33-56bf-86c9-59e7332b4326" -version = "0.4.11" - -[[deps.Gettext_jll]] -deps = ["Artifacts", "CompilerSupportLibraries_jll", "JLLWrappers", "Libdl", "Libiconv_jll", "Pkg", "XML2_jll"] -git-tree-sha1 = "9b02998aba7bf074d14de89f9d37ca24a1a0b046" -uuid = "78b55507-aeef-58d4-861c-77aaff3498b1" -version = "0.21.0+0" - -[[deps.Giflib_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "0224cce99284d997f6880a42ef715a37c99338d1" -uuid = "59f7168a-df46-5410-90c8-f2779963d0ec" -version = "5.2.2+0" - -[[deps.Glib_jll]] -deps = ["Artifacts", "Gettext_jll", "JLLWrappers", "Libdl", "Libffi_jll", "Libiconv_jll", "Libmount_jll", "PCRE2_jll", "Zlib_jll"] -git-tree-sha1 = "674ff0db93fffcd11a3573986e550d66cd4fd71f" -uuid = "7746bdde-850d-59dc-9ae8-88ece973131d" -version = "2.80.5+0" - -[[deps.Graphics]] -deps = ["Colors", "LinearAlgebra", "NaNMath"] -git-tree-sha1 = "a641238db938fff9b2f60d08ed9030387daf428c" -uuid = "a2bd30eb-e257-5431-a919-1863eab51364" -version = "1.1.3" - -[[deps.Graphite2_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl", "Pkg"] -git-tree-sha1 = "344bf40dcab1073aca04aa0df4fb092f920e4011" -uuid = "3b182d85-2403-5c21-9c21-1e1f0cc25472" -version = "1.3.14+0" - -[[deps.GridLayoutBase]] -deps = ["GeometryBasics", "InteractiveUtils", "Observables"] -git-tree-sha1 = "fc713f007cff99ff9e50accba6373624ddd33588" -uuid = "3955a311-db13-416c-9275-1d80ed98e5e9" -version = "0.11.0" - -[[deps.Grisu]] -git-tree-sha1 = "53bb909d1151e57e2484c3d1b53e19552b887fb2" -uuid = "42e2da0e-8278-4e71-bc24-59509adca0fe" -version = "1.0.2" - -[[deps.HarfBuzz_jll]] -deps = ["Artifacts", "Cairo_jll", "Fontconfig_jll", "FreeType2_jll", "Glib_jll", "Graphite2_jll", "JLLWrappers", "Libdl", "Libffi_jll"] -git-tree-sha1 = "401e4f3f30f43af2c8478fc008da50096ea5240f" -uuid = "2e76f6c2-a576-52d4-95c1-20adfe4de566" -version = "8.3.1+0" - -[[deps.Hwloc_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "50aedf345a709ab75872f80a2779568dc0bb461b" -uuid = "e33a78d0-f292-5ffc-b300-72abe9b543c8" -version = "2.11.2+1" - -[[deps.HypergeometricFunctions]] -deps = ["LinearAlgebra", "OpenLibm_jll", "SpecialFunctions"] -git-tree-sha1 = "b1c2585431c382e3fe5805874bda6aea90a95de9" -uuid = "34004b35-14d8-5ef3-9330-4cdb6864b03a" -version = "0.3.25" - -[[deps.IfElse]] -git-tree-sha1 = "debdd00ffef04665ccbb3e150747a77560e8fad1" -uuid = "615f187c-cbe4-4ef1-ba3b-2fcf58d6d173" -version = "0.1.1" - -[[deps.ImageAxes]] -deps = ["AxisArrays", "ImageBase", "ImageCore", "Reexport", "SimpleTraits"] -git-tree-sha1 = "e12629406c6c4442539436581041d372d69c55ba" -uuid = "2803e5a7-5153-5ecf-9a86-9b4c37f5f5ac" -version = "0.6.12" - -[[deps.ImageBase]] -deps = ["ImageCore", "Reexport"] -git-tree-sha1 = "eb49b82c172811fd2c86759fa0553a2221feb909" -uuid = "c817782e-172a-44cc-b673-b171935fbb9e" -version = "0.1.7" - -[[deps.ImageCore]] -deps = ["Aqua", "BlockArrays", "ColorVectorSpace", "Colors", "FixedPointNumbers", "MappedArrays", "MosaicViews", "OffsetArrays", "PaddedViews", "PrecompileTools", "Reexport"] -git-tree-sha1 = "661ca04f8df633e8a021c55a22e96cf820220ede" -uuid = "a09fc81d-aa75-5fe9-8630-4744c3626534" -version = "0.10.4" - -[[deps.ImageIO]] -deps = ["FileIO", "IndirectArrays", "JpegTurbo", "LazyModules", "Netpbm", "OpenEXR", "PNGFiles", "QOI", "Sixel", "TiffImages", "UUIDs", "WebP"] -git-tree-sha1 = "696144904b76e1ca433b886b4e7edd067d76cbf7" -uuid = "82e4d734-157c-48bb-816b-45c225c6df19" -version = "0.6.9" - -[[deps.ImageMetadata]] -deps = ["AxisArrays", "ImageAxes", "ImageBase", "ImageCore"] -git-tree-sha1 = "2a81c3897be6fbcde0802a0ebe6796d0562f63ec" -uuid = "bc367c6b-8a6b-528e-b4bd-a4b897500b49" -version = "0.9.10" - -[[deps.Imath_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "0936ba688c6d201805a83da835b55c61a180db52" -uuid = "905a6f67-0a94-5f89-b386-d35d92009cd1" -version = "3.1.11+0" - -[[deps.IndirectArrays]] -git-tree-sha1 = "012e604e1c7458645cb8b436f8fba789a51b257f" -uuid = "9b13fd28-a010-5f03-acff-a1bbcff69959" -version = "1.0.0" - -[[deps.Inflate]] -git-tree-sha1 = "d1b1b796e47d94588b3757fe84fbf65a5ec4a80d" -uuid = "d25df0c9-e2be-5dd7-82c8-3ad0b3e990b9" -version = "0.1.5" - -[[deps.IntegerMathUtils]] -git-tree-sha1 = "b8ffb903da9f7b8cf695a8bead8e01814aa24b30" -uuid = "18e54dd8-cb9d-406c-a71d-865a43cbb235" -version = "0.1.2" - -[[deps.IntelOpenMP_jll]] -deps = ["Artifacts", "JLLWrappers", "LazyArtifacts", "Libdl"] -git-tree-sha1 = "10bd689145d2c3b2a9844005d01087cc1194e79e" -uuid = "1d5cc7b8-4909-519e-a0f8-d0f5ad9712d0" -version = "2024.2.1+0" - -[[deps.InteractiveUtils]] -deps = ["Markdown"] -uuid = "b77e0a4c-d291-57a0-90e8-8db25a27a240" -version = "1.11.0" - -[[deps.Interpolations]] -deps = ["Adapt", "AxisAlgorithms", "ChainRulesCore", "LinearAlgebra", "OffsetArrays", "Random", "Ratios", "Requires", "SharedArrays", "SparseArrays", "StaticArrays", "WoodburyMatrices"] -git-tree-sha1 = "88a101217d7cb38a7b481ccd50d21876e1d1b0e0" -uuid = "a98d9a8b-a2ab-59e6-89dd-64a1c18fca59" -version = "0.15.1" -weakdeps = ["Unitful"] - - [deps.Interpolations.extensions] - InterpolationsUnitfulExt = "Unitful" - -[[deps.IntervalArithmetic]] -deps = ["CRlibm_jll", "LinearAlgebra", "MacroTools", "RoundingEmulator"] -git-tree-sha1 = "24c095b1ec7ee58b936985d31d5df92f9b9cfebb" -uuid = "d1acc4aa-44c8-5952-acd4-ba5d80a2a253" -version = "0.22.19" -weakdeps = ["DiffRules", "ForwardDiff", "IntervalSets", "RecipesBase"] - - [deps.IntervalArithmetic.extensions] - IntervalArithmeticDiffRulesExt = "DiffRules" - IntervalArithmeticForwardDiffExt = "ForwardDiff" - IntervalArithmeticIntervalSetsExt = "IntervalSets" - IntervalArithmeticRecipesBaseExt = "RecipesBase" - -[[deps.IntervalSets]] -git-tree-sha1 = "dba9ddf07f77f60450fe5d2e2beb9854d9a49bd0" -uuid = "8197267c-284f-5f27-9208-e0e47529a953" -version = "0.7.10" -weakdeps = ["Random", "RecipesBase", "Statistics"] - - [deps.IntervalSets.extensions] - IntervalSetsRandomExt = "Random" - IntervalSetsRecipesBaseExt = "RecipesBase" - IntervalSetsStatisticsExt = "Statistics" - -[[deps.InverseFunctions]] -git-tree-sha1 = "a779299d77cd080bf77b97535acecd73e1c5e5cb" -uuid = "3587e190-3f89-42d0-90ee-14403ec27112" -version = "0.1.17" -weakdeps = ["Dates", "Test"] - - [deps.InverseFunctions.extensions] - InverseFunctionsDatesExt = "Dates" - InverseFunctionsTestExt = "Test" - -[[deps.Ipopt]] -deps = ["Ipopt_jll", "LinearAlgebra", "MathOptInterface", "OpenBLAS32_jll", "PrecompileTools"] -git-tree-sha1 = "76315a7100e9e901d959c25b6ab6d4a37e799132" -uuid = "b6b21f68-93f8-5de0-b562-5493be1d77c9" -version = "1.6.7" - -[[deps.Ipopt_jll]] -deps = ["ASL_jll", "Artifacts", "CompilerSupportLibraries_jll", "JLLWrappers", "Libdl", "MUMPS_seq_jll", "SPRAL_jll", "libblastrampoline_jll"] -git-tree-sha1 = "a0950d209a055b3adb6d29ade5cbdf005a6bd290" -uuid = "9cc047cb-c261-5740-88fc-0cf96f7bdcc7" -version = "300.1400.1600+0" - -[[deps.IrrationalConstants]] -git-tree-sha1 = "630b497eafcc20001bba38a4651b327dcfc491d2" -uuid = "92d709cd-6900-40b7-9082-c6be49f344b6" -version = "0.2.2" - -[[deps.Isoband]] -deps = ["isoband_jll"] -git-tree-sha1 = "f9b6d97355599074dc867318950adaa6f9946137" -uuid = "f1662d9f-8043-43de-a69a-05efc1cc6ff4" -version = "0.1.1" - -[[deps.IterTools]] -git-tree-sha1 = "42d5f897009e7ff2cf88db414a389e5ed1bdd023" -uuid = "c8e1da08-722c-5040-9ed9-7db0dc04731e" -version = "1.10.0" - -[[deps.IteratorInterfaceExtensions]] -git-tree-sha1 = "a3f24677c21f5bbe9d2a714f95dcd58337fb2856" -uuid = "82899510-4779-5014-852e-03e436cf321d" -version = "1.0.0" - -[[deps.JLD2]] -deps = ["FileIO", "MacroTools", "Mmap", "OrderedCollections", "PrecompileTools", "Requires", "TranscodingStreams"] -git-tree-sha1 = "ce5737c0d4490b0e0040b5dc77fbb6a351ddf188" -uuid = "033835bb-8acc-5ee8-8aae-3f567f8a3819" -version = "0.5.8" - -[[deps.JLLWrappers]] -deps = ["Artifacts", "Preferences"] -git-tree-sha1 = "be3dc50a92e5a386872a493a10050136d4703f9b" -uuid = "692b3bcd-3c85-4b1f-b108-f13ce0eb3210" -version = "1.6.1" - -[[deps.JSON]] -deps = ["Dates", "Mmap", "Parsers", "Unicode"] -git-tree-sha1 = "31e996f0a15c7b280ba9f76636b3ff9e2ae58c9a" -uuid = "682c06a0-de6a-54ab-a142-c8b1cf79cde6" -version = "0.21.4" - -[[deps.JpegTurbo]] -deps = ["CEnum", "FileIO", "ImageCore", "JpegTurbo_jll", "TOML"] -git-tree-sha1 = "fa6d0bcff8583bac20f1ffa708c3913ca605c611" -uuid = "b835a17e-a41a-41e7-81f0-2f016b05efe0" -version = "0.1.5" - -[[deps.JpegTurbo_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "25ee0be4d43d0269027024d75a24c24d6c6e590c" -uuid = "aacddb02-875f-59d6-b918-886e6ef4fbf8" -version = "3.0.4+0" - -[[deps.KernelDensity]] -deps = ["Distributions", "DocStringExtensions", "FFTW", "Interpolations", "StatsBase"] -git-tree-sha1 = "7d703202e65efa1369de1279c162b915e245eed1" -uuid = "5ab0869b-81aa-558d-bb23-cbf5423bbe9b" -version = "0.6.9" - -[[deps.LAME_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "170b660facf5df5de098d866564877e119141cbd" -uuid = "c1c5ebd0-6772-5130-a774-d5fcae4a789d" -version = "3.100.2+0" - -[[deps.LERC_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "36bdbc52f13a7d1dcb0f3cd694e01677a515655b" -uuid = "88015f11-f218-50d7-93a8-a6af411a945d" -version = "4.0.0+0" - -[[deps.LLVMOpenMP_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "78211fb6cbc872f77cad3fc0b6cf647d923f4929" -uuid = "1d63c593-3942-5779-bab2-d838dc0a180e" -version = "18.1.7+0" - -[[deps.LZO_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "854a9c268c43b77b0a27f22d7fab8d33cdb3a731" -uuid = "dd4b983a-f0e5-5f8d-a1b7-129d4a5fb1ac" -version = "2.10.2+1" - -[[deps.LaTeXStrings]] -git-tree-sha1 = "dda21b8cbd6a6c40d9d02a73230f9d70fed6918c" -uuid = "b964fa9f-0449-5b57-a5c2-d3ea65f4040f" -version = "1.4.0" - -[[deps.Latexify]] -deps = ["Format", "InteractiveUtils", "LaTeXStrings", "MacroTools", "Markdown", "OrderedCollections", "Requires"] -git-tree-sha1 = "ce5f5621cac23a86011836badfedf664a612cee4" -uuid = "23fbe1c1-3f47-55db-b15f-69d7ec21a316" -version = "0.16.5" - - [deps.Latexify.extensions] - DataFramesExt = "DataFrames" - SparseArraysExt = "SparseArrays" - SymEngineExt = "SymEngine" - - [deps.Latexify.weakdeps] - DataFrames = "a93c6f00-e57d-5684-b7b6-d8193f3e46c0" - SparseArrays = "2f01184e-e22b-5df5-ae63-d93ebab69eaf" - SymEngine = "123dc426-2d89-5057-bbad-38513e3affd8" - -[[deps.LazyArtifacts]] -deps = ["Artifacts", "Pkg"] -uuid = "4af54fe1-eca0-43a8-85a7-787d91b784e3" -version = "1.11.0" - -[[deps.LazyModules]] -git-tree-sha1 = "a560dd966b386ac9ae60bdd3a3d3a326062d3c3e" -uuid = "8cdb02fc-e678-4876-92c5-9defec4f444e" -version = "0.3.1" - -[[deps.LibCURL]] -deps = ["LibCURL_jll", "MozillaCACerts_jll"] -uuid = "b27032c2-a3e7-50c8-80cd-2d36dbcbfd21" -version = "0.6.4" - -[[deps.LibCURL_jll]] -deps = ["Artifacts", "LibSSH2_jll", "Libdl", "MbedTLS_jll", "Zlib_jll", "nghttp2_jll"] -uuid = "deac9b47-8bc7-5906-a0fe-35ac56dc84c0" -version = "8.6.0+0" - -[[deps.LibGit2]] -deps = ["Base64", "LibGit2_jll", "NetworkOptions", "Printf", "SHA"] -uuid = "76f85450-5226-5b5a-8eaa-529ad045b433" -version = "1.11.0" - -[[deps.LibGit2_jll]] -deps = ["Artifacts", "LibSSH2_jll", "Libdl", "MbedTLS_jll"] -uuid = "e37daf67-58a4-590a-8e99-b0245dd2ffc5" -version = "1.7.2+0" - -[[deps.LibSSH2_jll]] -deps = ["Artifacts", "Libdl", "MbedTLS_jll"] -uuid = "29816b5a-b9ab-546f-933c-edad1886dfa8" -version = "1.11.0+1" - -[[deps.Libdl]] -uuid = "8f399da3-3557-5675-b5ff-fb832c97cbdb" -version = "1.11.0" - -[[deps.Libffi_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl", "Pkg"] -git-tree-sha1 = "0b4a5d71f3e5200a7dff793393e09dfc2d874290" -uuid = "e9f186c6-92d2-5b65-8a66-fee21dc1b490" -version = "3.2.2+1" - -[[deps.Libgcrypt_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl", "Libgpg_error_jll"] -git-tree-sha1 = "8be878062e0ffa2c3f67bb58a595375eda5de80b" -uuid = "d4300ac3-e22c-5743-9152-c294e39db1e4" -version = "1.11.0+0" - -[[deps.Libglvnd_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl", "Pkg", "Xorg_libX11_jll", "Xorg_libXext_jll"] -git-tree-sha1 = "6f73d1dd803986947b2c750138528a999a6c7733" -uuid = "7e76a0d4-f3c7-5321-8279-8d96eeed0f29" -version = "1.6.0+0" - -[[deps.Libgpg_error_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "c6ce1e19f3aec9b59186bdf06cdf3c4fc5f5f3e6" -uuid = "7add5ba3-2f88-524e-9cd5-f83b8a55f7b8" -version = "1.50.0+0" - -[[deps.Libiconv_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "61dfdba58e585066d8bce214c5a51eaa0539f269" -uuid = "94ce4f54-9a6c-5748-9c1c-f9c7231a4531" -version = "1.17.0+1" - -[[deps.Libmount_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "0c4f9c4f1a50d8f35048fa0532dabbadf702f81e" -uuid = "4b2f31a3-9ecc-558c-b454-b3730dcb73e9" -version = "2.40.1+0" - -[[deps.Libtiff_jll]] -deps = ["Artifacts", "JLLWrappers", "JpegTurbo_jll", "LERC_jll", "Libdl", "XZ_jll", "Zlib_jll", "Zstd_jll"] -git-tree-sha1 = "b404131d06f7886402758c9ce2214b636eb4d54a" -uuid = "89763e89-9b03-5906-acba-b20f662cd828" -version = "4.7.0+0" - -[[deps.Libuuid_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "5ee6203157c120d79034c748a2acba45b82b8807" -uuid = "38a345b3-de98-5d2b-a5d3-14cd9215e700" -version = "2.40.1+0" - -[[deps.LinearAlgebra]] -deps = ["Libdl", "OpenBLAS_jll", "libblastrampoline_jll"] -uuid = "37e2e46d-f89d-539d-b4ee-838fcccc9c8e" -version = "1.11.0" - -[[deps.LogExpFunctions]] -deps = ["DocStringExtensions", "IrrationalConstants", "LinearAlgebra"] -git-tree-sha1 = "a2d09619db4e765091ee5c6ffe8872849de0feea" -uuid = "2ab3a3ac-af41-5b50-aa03-7779005ae688" -version = "0.3.28" - - [deps.LogExpFunctions.extensions] - LogExpFunctionsChainRulesCoreExt = "ChainRulesCore" - LogExpFunctionsChangesOfVariablesExt = "ChangesOfVariables" - LogExpFunctionsInverseFunctionsExt = "InverseFunctions" - - [deps.LogExpFunctions.weakdeps] - ChainRulesCore = "d360d2e6-b24c-11e9-a2a3-2a2ae2dbcce4" - ChangesOfVariables = "9e997f8a-9a97-42d5-a9f1-ce6bfc15e2c0" - InverseFunctions = "3587e190-3f89-42d0-90ee-14403ec27112" - -[[deps.Logging]] -uuid = "56ddb016-857b-54e1-b83d-db4d58db5568" -version = "1.11.0" - -[[deps.METIS_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl", "Pkg"] -git-tree-sha1 = "1fd0a97409e418b78c53fac671cf4622efdf0f21" -uuid = "d00139f3-1899-568f-a2f0-47f597d42d70" -version = "5.1.2+0" - -[[deps.MKL_jll]] -deps = ["Artifacts", "IntelOpenMP_jll", "JLLWrappers", "LazyArtifacts", "Libdl", "oneTBB_jll"] -git-tree-sha1 = "f046ccd0c6db2832a9f639e2c669c6fe867e5f4f" -uuid = "856f044c-d86e-5d09-b602-aeab76dc8ba7" -version = "2024.2.0+0" - -[[deps.MLStyle]] -git-tree-sha1 = "bc38dff0548128765760c79eb7388a4b37fae2c8" -uuid = "d8e11817-5142-5d16-987a-aa16d5891078" -version = "0.4.17" - -[[deps.MUMPS_seq_jll]] -deps = ["Artifacts", "CompilerSupportLibraries_jll", "JLLWrappers", "Libdl", "METIS_jll", "libblastrampoline_jll"] -git-tree-sha1 = "85047ac569761e3387717480a38a61d2a67df45c" -uuid = "d7ed1dd3-d0ae-5e8e-bfb4-87a502085b8d" -version = "500.700.300+0" - -[[deps.MacroTools]] -deps = ["Markdown", "Random"] -git-tree-sha1 = "2fa9ee3e63fd3a4f7a9a4f4744a52f4856de82df" -uuid = "1914dd2f-81c6-5fcd-8719-6d5c9610ff09" -version = "0.5.13" - -[[deps.Makie]] -deps = ["Animations", "Base64", "CRC32c", "ColorBrewer", "ColorSchemes", "ColorTypes", "Colors", "Contour", "Dates", "DelaunayTriangulation", "Distributions", "DocStringExtensions", "Downloads", "FFMPEG_jll", "FileIO", "FilePaths", "FixedPointNumbers", "Format", "FreeType", "FreeTypeAbstraction", "GeometryBasics", "GridLayoutBase", "ImageBase", "ImageIO", "InteractiveUtils", "Interpolations", "IntervalSets", "InverseFunctions", "Isoband", "KernelDensity", "LaTeXStrings", "LinearAlgebra", "MacroTools", "MakieCore", "Markdown", "MathTeXEngine", "Observables", "OffsetArrays", "Packing", "PlotUtils", "PolygonOps", "PrecompileTools", "Printf", "REPL", "Random", "RelocatableFolders", "Scratch", "ShaderAbstractions", "Showoff", "SignedDistanceFields", "SparseArrays", "Statistics", "StatsBase", "StatsFuns", "StructArrays", "TriplotBase", "UnicodeFun", "Unitful"] -git-tree-sha1 = "5e4e0e027642293da251bf35dac408d692ccba8b" -uuid = "ee78f7c6-11fb-53f2-987a-cfe4a2b5a57a" -version = "0.21.16" - -[[deps.MakieCore]] -deps = ["ColorTypes", "GeometryBasics", "IntervalSets", "Observables"] -git-tree-sha1 = "ae4dbe0fcf1594ed98594e5f4ee685295a2a6f74" -uuid = "20f20a25-4f0e-4fdf-b5d1-57303727442b" -version = "0.8.10" - -[[deps.MappedArrays]] -git-tree-sha1 = "2dab0221fe2b0f2cb6754eaa743cc266339f527e" -uuid = "dbb5928d-eab1-5f90-85c2-b9b0edb7c900" -version = "0.4.2" - -[[deps.Markdown]] -deps = ["Base64"] -uuid = "d6f4376e-aef5-505a-96c1-9c027394607a" -version = "1.11.0" - -[[deps.MathOptInterface]] -deps = ["BenchmarkTools", "CodecBzip2", "CodecZlib", "DataStructures", "ForwardDiff", "JSON", "LinearAlgebra", "MutableArithmetics", "NaNMath", "OrderedCollections", "PrecompileTools", "Printf", "SparseArrays", "SpecialFunctions", "Test", "Unicode"] -git-tree-sha1 = "e065ca5234f53fd6f920efaee4940627ad991fb4" -uuid = "b8f27783-ece8-5eb3-8dc8-9495eed66fee" -version = "1.34.0" - -[[deps.MathTeXEngine]] -deps = ["AbstractTrees", "Automa", "DataStructures", "FreeTypeAbstraction", "GeometryBasics", "LaTeXStrings", "REPL", "RelocatableFolders", "UnicodeFun"] -git-tree-sha1 = "f45c8916e8385976e1ccd055c9874560c257ab13" -uuid = "0a4f8689-d25c-4efe-a92b-7142dfc1aa53" -version = "0.6.2" - -[[deps.MbedTLS_jll]] -deps = ["Artifacts", "Libdl"] -uuid = "c8ffd9c3-330d-5841-b78e-0817d7145fa1" -version = "2.28.6+0" - -[[deps.Missings]] -deps = ["DataAPI"] -git-tree-sha1 = "ec4f7fbeab05d7747bdf98eb74d130a2a2ed298d" -uuid = "e1d29d7a-bbdc-5cf2-9ac0-f12de2c33e28" -version = "1.2.0" - -[[deps.Mmap]] -uuid = "a63ad114-7e13-5084-954f-fe012c677804" -version = "1.11.0" - -[[deps.MosaicViews]] -deps = ["MappedArrays", "OffsetArrays", "PaddedViews", "StackViews"] -git-tree-sha1 = "7b86a5d4d70a9f5cdf2dacb3cbe6d251d1a61dbe" -uuid = "e94cdb99-869f-56ef-bcf0-1ae2bcbe0389" -version = "0.3.4" - -[[deps.MozillaCACerts_jll]] -uuid = "14a3606d-f60d-562e-9121-12d972cd8159" -version = "2023.12.12" - -[[deps.MultivariatePolynomials]] -deps = ["ChainRulesCore", "DataStructures", "LinearAlgebra", "MutableArithmetics"] -git-tree-sha1 = "8d39779e29f80aa6c071e7ac17101c6e31f075d7" -uuid = "102ac46a-7ee4-5c85-9060-abc95bfdeaa3" -version = "0.5.7" - -[[deps.MutableArithmetics]] -deps = ["LinearAlgebra", "SparseArrays", "Test"] -git-tree-sha1 = "90077f1e79de8c9c7c8a90644494411111f4e07b" -uuid = "d8a4904e-b15c-11e9-3269-09a3773c0cb0" -version = "1.5.2" - -[[deps.NaNMath]] -deps = ["OpenLibm_jll"] -git-tree-sha1 = "0877504529a3e5c3343c6f8b4c0381e57e4387e4" -uuid = "77ba4419-2d1f-58cd-9bb1-8ffee604a2e3" -version = "1.0.2" - -[[deps.NamedTrajectories]] -deps = ["CairoMakie", "JLD2", "LaTeXStrings", "Latexify", "OrderedCollections", "Random", "Reexport", "Unidecode"] -git-tree-sha1 = "8b72d6806501fd61684dcc6e9c336855acd5abe1" -uuid = "538bc3a1-5ab9-4fc3-b776-35ca1e893e08" -version = "0.2.2" - -[[deps.Netpbm]] -deps = ["FileIO", "ImageCore", "ImageMetadata"] -git-tree-sha1 = "d92b107dbb887293622df7697a2223f9f8176fcd" -uuid = "f09324ee-3d7c-5217-9330-fc30815ba969" -version = "1.1.1" - -[[deps.NetworkOptions]] -uuid = "ca575930-c2e3-43a9-ace4-1e988b2c1908" -version = "1.2.0" - -[[deps.Observables]] -git-tree-sha1 = "7438a59546cf62428fc9d1bc94729146d37a7225" -uuid = "510215fc-4207-5dde-b226-833fc4488ee2" -version = "0.5.5" - -[[deps.OffsetArrays]] -git-tree-sha1 = "1a27764e945a152f7ca7efa04de513d473e9542e" -uuid = "6fe1bfb0-de20-5000-8ca7-80f57d26f881" -version = "1.14.1" -weakdeps = ["Adapt"] - - [deps.OffsetArrays.extensions] - OffsetArraysAdaptExt = "Adapt" - -[[deps.Ogg_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl", "Pkg"] -git-tree-sha1 = "887579a3eb005446d514ab7aeac5d1d027658b8f" -uuid = "e7412a2a-1a6e-54c0-be00-318e2571c051" -version = "1.3.5+1" - -[[deps.OpenBLAS32_jll]] -deps = ["Artifacts", "CompilerSupportLibraries_jll", "JLLWrappers", "Libdl"] -git-tree-sha1 = "dd806c813429ff09878ea3eeb317818f3ca02871" -uuid = "656ef2d0-ae68-5445-9ca0-591084a874a2" -version = "0.3.28+3" - -[[deps.OpenBLAS_jll]] -deps = ["Artifacts", "CompilerSupportLibraries_jll", "Libdl"] -uuid = "4536629a-c528-5b80-bd46-f80d51c5b363" -version = "0.3.27+1" - -[[deps.OpenEXR]] -deps = ["Colors", "FileIO", "OpenEXR_jll"] -git-tree-sha1 = "97db9e07fe2091882c765380ef58ec553074e9c7" -uuid = "52e1d378-f018-4a11-a4be-720524705ac7" -version = "0.3.3" - -[[deps.OpenEXR_jll]] -deps = ["Artifacts", "Imath_jll", "JLLWrappers", "Libdl", "Zlib_jll"] -git-tree-sha1 = "8292dd5c8a38257111ada2174000a33745b06d4e" -uuid = "18a262bb-aa17-5467-a713-aee519bc75cb" -version = "3.2.4+0" - -[[deps.OpenLibm_jll]] -deps = ["Artifacts", "Libdl"] -uuid = "05823500-19ac-5b8b-9628-191a04bc5112" -version = "0.8.1+2" - -[[deps.OpenSSL_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "7493f61f55a6cce7325f197443aa80d32554ba10" -uuid = "458c3c95-2e84-50aa-8efc-19380b2a3a95" -version = "3.0.15+1" - -[[deps.OpenSpecFun_jll]] -deps = ["Artifacts", "CompilerSupportLibraries_jll", "JLLWrappers", "Libdl", "Pkg"] -git-tree-sha1 = "13652491f6856acfd2db29360e1bbcd4565d04f1" -uuid = "efe28fd5-8261-553b-a9e1-b2916fc3738e" -version = "0.5.5+0" - -[[deps.Opus_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "6703a85cb3781bd5909d48730a67205f3f31a575" -uuid = "91d4177d-7536-5919-b921-800302f37372" -version = "1.3.3+0" - -[[deps.OrderedCollections]] -git-tree-sha1 = "dfdf5519f235516220579f949664f1bf44e741c5" -uuid = "bac558e1-5e72-5ebc-8fee-abe8a469f55d" -version = "1.6.3" - -[[deps.PCRE2_jll]] -deps = ["Artifacts", "Libdl"] -uuid = "efcefdf7-47ab-520b-bdef-62a2eaa19f15" -version = "10.42.0+1" - -[[deps.PDMats]] -deps = ["LinearAlgebra", "SparseArrays", "SuiteSparse"] -git-tree-sha1 = "949347156c25054de2db3b166c52ac4728cbad65" -uuid = "90014a1f-27ba-587c-ab20-58faa44d9150" -version = "0.11.31" - -[[deps.PNGFiles]] -deps = ["Base64", "CEnum", "ImageCore", "IndirectArrays", "OffsetArrays", "libpng_jll"] -git-tree-sha1 = "67186a2bc9a90f9f85ff3cc8277868961fb57cbd" -uuid = "f57f5aa1-a3ce-4bc8-8ab9-96f992907883" -version = "0.4.3" - -[[deps.Packing]] -deps = ["GeometryBasics"] -git-tree-sha1 = "ec3edfe723df33528e085e632414499f26650501" -uuid = "19eb6ba3-879d-56ad-ad62-d5c202156566" -version = "0.5.0" - -[[deps.PaddedViews]] -deps = ["OffsetArrays"] -git-tree-sha1 = "0fac6313486baae819364c52b4f483450a9d793f" -uuid = "5432bcbf-9aad-5242-b902-cca2824c8663" -version = "0.5.12" - -[[deps.Pango_jll]] -deps = ["Artifacts", "Cairo_jll", "Fontconfig_jll", "FreeType2_jll", "FriBidi_jll", "Glib_jll", "HarfBuzz_jll", "JLLWrappers", "Libdl"] -git-tree-sha1 = "e127b609fb9ecba6f201ba7ab753d5a605d53801" -uuid = "36c8627f-9965-5494-a995-c6b170f724f3" -version = "1.54.1+0" - -[[deps.Parsers]] -deps = ["Dates", "PrecompileTools", "UUIDs"] -git-tree-sha1 = "8489905bcdbcfac64d1daa51ca07c0d8f0283821" -uuid = "69de0a69-1ddd-5017-9359-2bf0b02dc9f0" -version = "2.8.1" - -[[deps.Pixman_jll]] -deps = ["Artifacts", "CompilerSupportLibraries_jll", "JLLWrappers", "LLVMOpenMP_jll", "Libdl"] -git-tree-sha1 = "35621f10a7531bc8fa58f74610b1bfb70a3cfc6b" -uuid = "30392449-352a-5448-841d-b1acce4e97dc" -version = "0.43.4+0" - -[[deps.Pkg]] -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.11.0" -weakdeps = ["REPL"] - - [deps.Pkg.extensions] - REPLExt = "REPL" - -[[deps.PkgVersion]] -deps = ["Pkg"] -git-tree-sha1 = "f9501cc0430a26bc3d156ae1b5b0c1b47af4d6da" -uuid = "eebad327-c553-4316-9ea0-9fa01ccd7688" -version = "0.3.3" - -[[deps.PlotUtils]] -deps = ["ColorSchemes", "Colors", "Dates", "PrecompileTools", "Printf", "Random", "Reexport", "StableRNGs", "Statistics"] -git-tree-sha1 = "3ca9a356cd2e113c420f2c13bea19f8d3fb1cb18" -uuid = "995b91a9-d308-5afd-9ec6-746e21dbc043" -version = "1.4.3" - -[[deps.PolygonOps]] -git-tree-sha1 = "77b3d3605fc1cd0b42d95eba87dfcd2bf67d5ff6" -uuid = "647866c9-e3ac-4575-94e7-e3d426903924" -version = "0.1.2" - -[[deps.PrecompileTools]] -deps = ["Preferences"] -git-tree-sha1 = "5aa36f7049a63a1528fe8f7c3f2113413ffd4e1f" -uuid = "aea7be01-6a6a-4083-8856-8a6e6704d82a" -version = "1.2.1" - -[[deps.Preferences]] -deps = ["TOML"] -git-tree-sha1 = "9306f6085165d270f7e3db02af26a400d580f5c6" -uuid = "21216c6a-2e73-6563-6e65-726566657250" -version = "1.4.3" - -[[deps.Primes]] -deps = ["IntegerMathUtils"] -git-tree-sha1 = "cb420f77dc474d23ee47ca8d14c90810cafe69e7" -uuid = "27ebfcd6-29c5-5fa9-bf4b-fb8fc14df3ae" -version = "0.5.6" - -[[deps.Printf]] -deps = ["Unicode"] -uuid = "de0858da-6303-5e67-8744-51eddeeeb8d7" -version = "1.11.0" - -[[deps.Profile]] -uuid = "9abbd945-dff8-562f-b5e8-e1ebf5ef1b79" -version = "1.11.0" - -[[deps.ProgressMeter]] -deps = ["Distributed", "Printf"] -git-tree-sha1 = "8f6bc219586aef8baf0ff9a5fe16ee9c70cb65e4" -uuid = "92933f4c-e287-5a05-a399-4b506db050ca" -version = "1.10.2" - -[[deps.PtrArrays]] -git-tree-sha1 = "77a42d78b6a92df47ab37e177b2deac405e1c88f" -uuid = "43287f4e-b6f4-7ad1-bb20-aadabca52c3d" -version = "1.2.1" - -[[deps.QOI]] -deps = ["ColorTypes", "FileIO", "FixedPointNumbers"] -git-tree-sha1 = "8b3fc30bc0390abdce15f8822c889f669baed73d" -uuid = "4b34888f-f399-49d4-9bb3-47ed5cae4e65" -version = "1.0.1" - -[[deps.QuadGK]] -deps = ["DataStructures", "LinearAlgebra"] -git-tree-sha1 = "cda3b045cf9ef07a08ad46731f5a3165e56cf3da" -uuid = "1fd47b50-473d-5c70-9696-f719f8f3bcdc" -version = "2.11.1" - - [deps.QuadGK.extensions] - QuadGKEnzymeExt = "Enzyme" - - [deps.QuadGK.weakdeps] - Enzyme = "7da242da-08ed-463a-9acd-ee780be4f1d9" - -[[deps.REPL]] -deps = ["InteractiveUtils", "Markdown", "Sockets", "StyledStrings", "Unicode"] -uuid = "3fa0cd96-eef1-5676-8a61-b3b8758bbffb" -version = "1.11.0" - -[[deps.Random]] -deps = ["SHA"] -uuid = "9a3f8284-a2c9-5f02-9a11-845980a1fd5c" -version = "1.11.0" - -[[deps.RangeArrays]] -git-tree-sha1 = "b9039e93773ddcfc828f12aadf7115b4b4d225f5" -uuid = "b3c3ace0-ae52-54e7-9d0b-2c1406fd6b9d" -version = "0.3.2" - -[[deps.Ratios]] -deps = ["Requires"] -git-tree-sha1 = "1342a47bf3260ee108163042310d26f2be5ec90b" -uuid = "c84ed2f1-dad5-54f0-aa8e-dbefe2724439" -version = "0.4.5" -weakdeps = ["FixedPointNumbers"] - - [deps.Ratios.extensions] - RatiosFixedPointNumbersExt = "FixedPointNumbers" - -[[deps.RecipesBase]] -deps = ["PrecompileTools"] -git-tree-sha1 = "5c3d09cc4f31f5fc6af001c250bf1278733100ff" -uuid = "3cdcf5f2-1ef4-517c-9805-6587b60abb01" -version = "1.3.4" - -[[deps.RecursiveArrayTools]] -deps = ["Adapt", "ArrayInterface", "DocStringExtensions", "GPUArraysCore", "IteratorInterfaceExtensions", "LinearAlgebra", "RecipesBase", "StaticArraysCore", "Statistics", "SymbolicIndexingInterface", "Tables"] -git-tree-sha1 = "6f4dca5fd8e97087a76b7ab8384d1c3086ace0b7" -uuid = "731186ca-8d62-57ce-b412-fbd966d074cd" -version = "3.27.3" - - [deps.RecursiveArrayTools.extensions] - RecursiveArrayToolsFastBroadcastExt = "FastBroadcast" - RecursiveArrayToolsForwardDiffExt = "ForwardDiff" - RecursiveArrayToolsMeasurementsExt = "Measurements" - RecursiveArrayToolsMonteCarloMeasurementsExt = "MonteCarloMeasurements" - RecursiveArrayToolsReverseDiffExt = ["ReverseDiff", "Zygote"] - RecursiveArrayToolsSparseArraysExt = ["SparseArrays"] - RecursiveArrayToolsTrackerExt = "Tracker" - RecursiveArrayToolsZygoteExt = "Zygote" - - [deps.RecursiveArrayTools.weakdeps] - FastBroadcast = "7034ab61-46d4-4ed7-9d0f-46aef9175898" - ForwardDiff = "f6369f11-7733-5829-9624-2563aa707210" - Measurements = "eff96d63-e80a-5855-80a2-b1b0885c5ab7" - MonteCarloMeasurements = "0987c9cc-fe09-11e8-30f0-b96dd679fdca" - ReverseDiff = "37e2e3b7-166d-5795-8a7a-e32c996b4267" - SparseArrays = "2f01184e-e22b-5df5-ae63-d93ebab69eaf" - Tracker = "9f7883ad-71c0-57eb-9f7f-b5c9e6d3789c" - Zygote = "e88e6eb3-aa80-5325-afca-941959d7151f" - -[[deps.Reexport]] -git-tree-sha1 = "45e428421666073eab6f2da5c9d310d99bb12f9b" -uuid = "189a3867-3050-52da-a836-e630ba90ab69" -version = "1.2.2" - -[[deps.RelocatableFolders]] -deps = ["SHA", "Scratch"] -git-tree-sha1 = "ffdaf70d81cf6ff22c2b6e733c900c3321cab864" -uuid = "05181044-ff0b-4ac5-8273-598c1e38db00" -version = "1.0.1" - -[[deps.Requires]] -deps = ["UUIDs"] -git-tree-sha1 = "838a3a4188e2ded87a4f9f184b4b0d78a1e91cb7" -uuid = "ae029012-a4dd-5104-9daa-d747884805df" -version = "1.3.0" - -[[deps.Rmath]] -deps = ["Random", "Rmath_jll"] -git-tree-sha1 = "852bd0f55565a9e973fcfee83a84413270224dc4" -uuid = "79098fc4-a85e-5d69-aa6a-4863f24498fa" -version = "0.8.0" - -[[deps.Rmath_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "58cdd8fb2201a6267e1db87ff148dd6c1dbd8ad8" -uuid = "f50d1b31-88e8-58de-be2c-1cc44531875f" -version = "0.5.1+0" - -[[deps.RoundingEmulator]] -git-tree-sha1 = "40b9edad2e5287e05bd413a38f61a8ff55b9557b" -uuid = "5eaf0fd0-dfba-4ccb-bf02-d820a40db705" -version = "0.2.1" - -[[deps.RuntimeGeneratedFunctions]] -deps = ["ExprTools", "SHA", "Serialization"] -git-tree-sha1 = "04c968137612c4a5629fa531334bb81ad5680f00" -uuid = "7e49a35a-f44a-4d26-94aa-eba1b4ca6b47" -version = "0.5.13" - -[[deps.SHA]] -uuid = "ea8e919c-243c-51af-8825-aaa63cd721ce" -version = "0.7.0" - -[[deps.SIMD]] -deps = ["PrecompileTools"] -git-tree-sha1 = "98ca7c29edd6fc79cd74c61accb7010a4e7aee33" -uuid = "fdea26ae-647d-5447-a871-4b548cad5224" -version = "3.6.0" - -[[deps.SPRAL_jll]] -deps = ["Artifacts", "CompilerSupportLibraries_jll", "Hwloc_jll", "JLLWrappers", "Libdl", "METIS_jll", "libblastrampoline_jll"] -git-tree-sha1 = "11f3da4b25efacd1cec8e263421f2a9003a5e8e0" -uuid = "319450e9-13b8-58e8-aa9f-8fd1420848ab" -version = "2024.5.8+0" - -[[deps.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 = "7527b9adb22904f0f51d8ab85d826f81ebb6f78d" -uuid = "0bca4576-84f4-4d90-8ffe-ffa030f20462" -version = "2.59.2" - - [deps.SciMLBase.extensions] - SciMLBaseChainRulesCoreExt = "ChainRulesCore" - SciMLBaseMakieExt = "Makie" - SciMLBasePartialFunctionsExt = "PartialFunctions" - SciMLBasePyCallExt = "PyCall" - SciMLBasePythonCallExt = "PythonCall" - SciMLBaseRCallExt = "RCall" - SciMLBaseZygoteExt = "Zygote" - - [deps.SciMLBase.weakdeps] - ChainRules = "082447d4-558c-5d27-93f4-14fc19e9eca2" - ChainRulesCore = "d360d2e6-b24c-11e9-a2a3-2a2ae2dbcce4" - Makie = "ee78f7c6-11fb-53f2-987a-cfe4a2b5a57a" - PartialFunctions = "570af359-4316-4cb7-8c74-252c00c2016b" - PyCall = "438e738f-606a-5dbb-bf0a-cddfbfd45ab0" - PythonCall = "6099a3de-0909-46bc-b1f4-468b9a2dfc0d" - RCall = "6f49c342-dc21-5d91-9882-a32aef131414" - Zygote = "e88e6eb3-aa80-5325-afca-941959d7151f" - -[[deps.SciMLOperators]] -deps = ["Accessors", "ArrayInterface", "DocStringExtensions", "LinearAlgebra", "MacroTools"] -git-tree-sha1 = "6149620767866d4b0f0f7028639b6e661b6a1e44" -uuid = "c0aeaf25-5076-4817-a8d5-81caf7dfa961" -version = "0.3.12" -weakdeps = ["SparseArrays", "StaticArraysCore"] - - [deps.SciMLOperators.extensions] - SciMLOperatorsSparseArraysExt = "SparseArrays" - SciMLOperatorsStaticArraysCoreExt = "StaticArraysCore" - -[[deps.SciMLStructures]] -deps = ["ArrayInterface"] -git-tree-sha1 = "25514a6f200219cd1073e4ff23a6324e4a7efe64" -uuid = "53ae85a6-f571-4167-b2af-e1d143709226" -version = "1.5.0" - -[[deps.Scratch]] -deps = ["Dates"] -git-tree-sha1 = "3bac05bc7e74a75fd9cba4295cde4045d9fe2386" -uuid = "6c6a2e73-6563-6170-7368-637461726353" -version = "1.2.1" - -[[deps.Serialization]] -uuid = "9e88b42a-f829-5b0c-bbe9-9e923198166b" -version = "1.11.0" - -[[deps.Setfield]] -deps = ["ConstructionBase", "Future", "MacroTools", "StaticArraysCore"] -git-tree-sha1 = "e2cc6d8c88613c05e1defb55170bf5ff211fbeac" -uuid = "efcf1570-3423-57d1-acb7-fd33fddbac46" -version = "1.1.1" - -[[deps.ShaderAbstractions]] -deps = ["ColorTypes", "FixedPointNumbers", "GeometryBasics", "LinearAlgebra", "Observables", "StaticArrays", "StructArrays", "Tables"] -git-tree-sha1 = "79123bc60c5507f035e6d1d9e563bb2971954ec8" -uuid = "65257c39-d410-5151-9873-9b3e5be5013e" -version = "0.4.1" - -[[deps.SharedArrays]] -deps = ["Distributed", "Mmap", "Random", "Serialization"] -uuid = "1a1011a3-84de-559e-8e89-a11a2f7dc383" -version = "1.11.0" - -[[deps.Showoff]] -deps = ["Dates", "Grisu"] -git-tree-sha1 = "91eddf657aca81df9ae6ceb20b959ae5653ad1de" -uuid = "992d4aef-0814-514b-bc4d-f2e9a6c4116f" -version = "1.0.3" - -[[deps.SignedDistanceFields]] -deps = ["Random", "Statistics", "Test"] -git-tree-sha1 = "d263a08ec505853a5ff1c1ebde2070419e3f28e9" -uuid = "73760f76-fbc4-59ce-8f25-708e95d2df96" -version = "0.4.0" - -[[deps.SimpleTraits]] -deps = ["InteractiveUtils", "MacroTools"] -git-tree-sha1 = "5d7e3f4e11935503d3ecaf7186eac40602e7d231" -uuid = "699a6c99-e7fa-54fc-8d76-47d257e15c1d" -version = "0.9.4" - -[[deps.Sixel]] -deps = ["Dates", "FileIO", "ImageCore", "IndirectArrays", "OffsetArrays", "REPL", "libsixel_jll"] -git-tree-sha1 = "2da10356e31327c7096832eb9cd86307a50b1eb6" -uuid = "45858cf5-a6b0-47a3-bbea-62219f50df47" -version = "0.1.3" - -[[deps.Sockets]] -uuid = "6462fe0b-24de-5631-8697-dd941f90decc" -version = "1.11.0" - -[[deps.SortingAlgorithms]] -deps = ["DataStructures"] -git-tree-sha1 = "66e0a8e672a0bdfca2c3f5937efb8538b9ddc085" -uuid = "a2af1166-a08f-5f64-846c-94a0d3cef48c" -version = "1.2.1" - -[[deps.SparseArrays]] -deps = ["Libdl", "LinearAlgebra", "Random", "Serialization", "SuiteSparse_jll"] -uuid = "2f01184e-e22b-5df5-ae63-d93ebab69eaf" -version = "1.11.0" - -[[deps.SpecialFunctions]] -deps = ["IrrationalConstants", "LogExpFunctions", "OpenLibm_jll", "OpenSpecFun_jll"] -git-tree-sha1 = "2f5d4697f21388cbe1ff299430dd169ef97d7e14" -uuid = "276daf66-3868-5448-9aa4-cd146d93841b" -version = "2.4.0" -weakdeps = ["ChainRulesCore"] - - [deps.SpecialFunctions.extensions] - SpecialFunctionsChainRulesCoreExt = "ChainRulesCore" - -[[deps.StableRNGs]] -deps = ["Random"] -git-tree-sha1 = "83e6cce8324d49dfaf9ef059227f91ed4441a8e5" -uuid = "860ef19b-820b-49d6-a774-d7a799459cd3" -version = "1.0.2" - -[[deps.StackViews]] -deps = ["OffsetArrays"] -git-tree-sha1 = "46e589465204cd0c08b4bd97385e4fa79a0c770c" -uuid = "cae243ae-269e-4f55-b966-ac2d0dc13c15" -version = "0.1.1" - -[[deps.StaticArrays]] -deps = ["LinearAlgebra", "PrecompileTools", "Random", "StaticArraysCore"] -git-tree-sha1 = "777657803913ffc7e8cc20f0fd04b634f871af8f" -uuid = "90137ffa-7385-5640-81b9-e52037218182" -version = "1.9.8" -weakdeps = ["ChainRulesCore", "Statistics"] - - [deps.StaticArrays.extensions] - StaticArraysChainRulesCoreExt = "ChainRulesCore" - StaticArraysStatisticsExt = "Statistics" - -[[deps.StaticArraysCore]] -git-tree-sha1 = "192954ef1208c7019899fbf8049e717f92959682" -uuid = "1e83bf80-4336-4d27-bf5d-d5a4f845583c" -version = "1.4.3" - -[[deps.Statistics]] -deps = ["LinearAlgebra"] -git-tree-sha1 = "ae3bb1eb3bba077cd276bc5cfc337cc65c3075c0" -uuid = "10745b16-79ce-11e8-11f9-7d13ad32a3b2" -version = "1.11.1" -weakdeps = ["SparseArrays"] - - [deps.Statistics.extensions] - SparseArraysExt = ["SparseArrays"] - -[[deps.StatsAPI]] -deps = ["LinearAlgebra"] -git-tree-sha1 = "1ff449ad350c9c4cbc756624d6f8a8c3ef56d3ed" -uuid = "82ae8749-77ed-4fe6-ae5f-f523153014b0" -version = "1.7.0" - -[[deps.StatsBase]] -deps = ["DataAPI", "DataStructures", "LinearAlgebra", "LogExpFunctions", "Missings", "Printf", "Random", "SortingAlgorithms", "SparseArrays", "Statistics", "StatsAPI"] -git-tree-sha1 = "5cf7606d6cef84b543b483848d4ae08ad9832b21" -uuid = "2913bbd2-ae8a-5f71-8c99-4fb6c76f3a91" -version = "0.34.3" - -[[deps.StatsFuns]] -deps = ["HypergeometricFunctions", "IrrationalConstants", "LogExpFunctions", "Reexport", "Rmath", "SpecialFunctions"] -git-tree-sha1 = "b423576adc27097764a90e163157bcfc9acf0f46" -uuid = "4c63d2b9-4356-54db-8cca-17b64c39e42c" -version = "1.3.2" -weakdeps = ["ChainRulesCore", "InverseFunctions"] - - [deps.StatsFuns.extensions] - StatsFunsChainRulesCoreExt = "ChainRulesCore" - StatsFunsInverseFunctionsExt = "InverseFunctions" - -[[deps.StructArrays]] -deps = ["ConstructionBase", "DataAPI", "Tables"] -git-tree-sha1 = "f4dc295e983502292c4c3f951dbb4e985e35b3be" -uuid = "09ab397b-f2b6-538f-b94a-2f83cf4a842a" -version = "0.6.18" -weakdeps = ["Adapt", "GPUArraysCore", "SparseArrays", "StaticArrays"] - - [deps.StructArrays.extensions] - StructArraysAdaptExt = "Adapt" - StructArraysGPUArraysCoreExt = "GPUArraysCore" - StructArraysSparseArraysExt = "SparseArrays" - StructArraysStaticArraysExt = "StaticArrays" - -[[deps.StyledStrings]] -uuid = "f489334b-da3d-4c2e-b8f0-e476e12c162b" -version = "1.11.0" - -[[deps.SuiteSparse]] -deps = ["Libdl", "LinearAlgebra", "Serialization", "SparseArrays"] -uuid = "4607b0f0-06f3-5cda-b6b1-a6196a1729e9" - -[[deps.SuiteSparse_jll]] -deps = ["Artifacts", "Libdl", "libblastrampoline_jll"] -uuid = "bea87d4a-7f5b-5778-9afe-8cc45184846c" -version = "7.7.0+0" - -[[deps.SymbolicIndexingInterface]] -deps = ["Accessors", "ArrayInterface", "RuntimeGeneratedFunctions", "StaticArraysCore"] -git-tree-sha1 = "20cf607cafb31f922bce84d60379203e7a126911" -uuid = "2efcf032-c050-4f8e-a9bb-153293bab1f5" -version = "0.3.34" - -[[deps.SymbolicLimits]] -deps = ["SymbolicUtils"] -git-tree-sha1 = "fabf4650afe966a2ba646cabd924c3fd43577fc3" -uuid = "19f23fe9-fdab-4a78-91af-e7b7767979c3" -version = "0.2.2" - -[[deps.SymbolicUtils]] -deps = ["AbstractTrees", "ArrayInterface", "Bijections", "ChainRulesCore", "Combinatorics", "ConstructionBase", "DataStructures", "DocStringExtensions", "DynamicPolynomials", "IfElse", "LinearAlgebra", "MultivariatePolynomials", "NaNMath", "Setfield", "SparseArrays", "SpecialFunctions", "StaticArrays", "SymbolicIndexingInterface", "TermInterface", "TimerOutputs", "Unityper"] -git-tree-sha1 = "04e9157537ba51dad58336976f8d04b9ab7122f0" -uuid = "d1185830-fcd6-423d-90d6-eec64667417b" -version = "3.7.2" - - [deps.SymbolicUtils.extensions] - SymbolicUtilsLabelledArraysExt = "LabelledArrays" - SymbolicUtilsReverseDiffExt = "ReverseDiff" - - [deps.SymbolicUtils.weakdeps] - LabelledArrays = "2ee39098-c373-598a-b85f-a56591580800" - ReverseDiff = "37e2e3b7-166d-5795-8a7a-e32c996b4267" - -[[deps.Symbolics]] -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 = "0caef7687abf7094132fa3112bf5514c36a99226" -uuid = "0c5d862f-8b57-4792-8d23-62f2024744c7" -version = "6.18.3" - - [deps.Symbolics.extensions] - SymbolicsForwardDiffExt = "ForwardDiff" - SymbolicsGroebnerExt = "Groebner" - SymbolicsLuxExt = "Lux" - SymbolicsNemoExt = "Nemo" - SymbolicsPreallocationToolsExt = ["PreallocationTools", "ForwardDiff"] - SymbolicsSymPyExt = "SymPy" - - [deps.Symbolics.weakdeps] - ForwardDiff = "f6369f11-7733-5829-9624-2563aa707210" - Groebner = "0b43b601-686d-58a3-8a1c-6623616c7cd4" - Lux = "b2108857-7c20-44ae-9111-449ecde12c47" - Nemo = "2edaba10-b0f1-5616-af89-8c11ac63239a" - PreallocationTools = "d236fae5-4411-538c-8e31-a6e3d9e00b46" - SymPy = "24249f21-da20-56a4-8eb1-6a02cf4ae2e6" - -[[deps.TOML]] -deps = ["Dates"] -uuid = "fa267f1f-6049-4f14-aa54-33bafae1ed76" -version = "1.0.3" - -[[deps.TableTraits]] -deps = ["IteratorInterfaceExtensions"] -git-tree-sha1 = "c06b2f539df1c6efa794486abfb6ed2022561a39" -uuid = "3783bdb8-4a98-5b6b-af9a-565f29a5fe9c" -version = "1.0.1" - -[[deps.Tables]] -deps = ["DataAPI", "DataValueInterfaces", "IteratorInterfaceExtensions", "OrderedCollections", "TableTraits"] -git-tree-sha1 = "598cd7c1f68d1e205689b1c2fe65a9f85846f297" -uuid = "bd369af6-aec1-5ad0-b16a-f7cc5008161c" -version = "1.12.0" - -[[deps.Tar]] -deps = ["ArgTools", "SHA"] -uuid = "a4e569a6-e804-4fa4-b0f3-eef7a1d5b13e" -version = "1.10.0" - -[[deps.TensorCore]] -deps = ["LinearAlgebra"] -git-tree-sha1 = "1feb45f88d133a655e001435632f019a9a1bcdb6" -uuid = "62fd8b95-f654-4bbd-a8a5-9c27f68ccd50" -version = "0.1.1" - -[[deps.TermInterface]] -git-tree-sha1 = "d673e0aca9e46a2f63720201f55cc7b3e7169b16" -uuid = "8ea1fca8-c5ef-4a55-8b96-4e9afe9c9a3c" -version = "2.0.0" - -[[deps.Test]] -deps = ["InteractiveUtils", "Logging", "Random", "Serialization"] -uuid = "8dfed614-e22c-5e08-85e1-65c5234f0b40" -version = "1.11.0" - -[[deps.TestItemRunner]] -deps = ["Pkg", "TOML", "Test", "TestItems", "UUIDs"] -git-tree-sha1 = "29647c5398be04a1d697265ba385bdf3f623c993" -uuid = "f8b46487-2199-4994-9208-9a1283c18c0a" -version = "1.0.5" - -[[deps.TestItems]] -git-tree-sha1 = "42fd9023fef18b9b78c8343a4e2f3813ffbcefcb" -uuid = "1c621080-faea-4a02-84b6-bbd5e436b8fe" -version = "1.0.0" - -[[deps.TiffImages]] -deps = ["ColorTypes", "DataStructures", "DocStringExtensions", "FileIO", "FixedPointNumbers", "IndirectArrays", "Inflate", "Mmap", "OffsetArrays", "PkgVersion", "ProgressMeter", "SIMD", "UUIDs"] -git-tree-sha1 = "0248b1b2210285652fbc67fd6ced9bf0394bcfec" -uuid = "731e570b-9d59-4bfa-96dc-6df516fadf69" -version = "0.11.1" - -[[deps.TimerOutputs]] -deps = ["ExprTools", "Printf"] -git-tree-sha1 = "3a6f063d690135f5c1ba351412c82bae4d1402bf" -uuid = "a759f4b9-e2f1-59dc-863e-4aeb61b1ea8f" -version = "0.5.25" - -[[deps.TrajectoryIndexingUtils]] -git-tree-sha1 = "108da5f045005c9b57e6713ea84aca49d77fccaa" -uuid = "6dad8b7f-dd9a-4c28-9b70-85b9a079bfc8" -version = "0.1.0" - -[[deps.TranscodingStreams]] -git-tree-sha1 = "0c45878dcfdcfa8480052b6ab162cdd138781742" -uuid = "3bb67fe8-82b1-5028-8e26-92a6c54297fa" -version = "0.11.3" - -[[deps.TriplotBase]] -git-tree-sha1 = "4d4ed7f294cda19382ff7de4c137d24d16adc89b" -uuid = "981d1d27-644d-49a2-9326-4793e63143c3" -version = "0.1.0" - -[[deps.UUIDs]] -deps = ["Random", "SHA"] -uuid = "cf7118a7-6976-5b1a-9a39-7adc72f591a4" -version = "1.11.0" - -[[deps.Unicode]] -uuid = "4ec0a83e-493e-50e2-b9ac-8f72acf5a8f5" -version = "1.11.0" - -[[deps.UnicodeFun]] -deps = ["REPL"] -git-tree-sha1 = "53915e50200959667e78a92a418594b428dffddf" -uuid = "1cfade01-22cf-5700-b092-accc4b62d6e1" -version = "0.4.1" - -[[deps.Unidecode]] -deps = ["REPL", "Test", "Unicode"] -git-tree-sha1 = "2264362f72926965e708ee26f58824b929c72637" -uuid = "967fb449-e509-55aa-8007-234b4096b967" -version = "1.1.0" - -[[deps.Unitful]] -deps = ["Dates", "LinearAlgebra", "Random"] -git-tree-sha1 = "d95fe458f26209c66a187b1114df96fd70839efd" -uuid = "1986cc42-f94f-5a68-af5c-568840ba703d" -version = "1.21.0" -weakdeps = ["ConstructionBase", "InverseFunctions"] - - [deps.Unitful.extensions] - ConstructionBaseUnitfulExt = "ConstructionBase" - InverseFunctionsUnitfulExt = "InverseFunctions" - -[[deps.Unityper]] -deps = ["ConstructionBase"] -git-tree-sha1 = "25008b734a03736c41e2a7dc314ecb95bd6bbdb0" -uuid = "a7c27f48-0311-42f6-a7f8-2c11e75eb415" -version = "0.1.6" - -[[deps.WebP]] -deps = ["CEnum", "ColorTypes", "FileIO", "FixedPointNumbers", "ImageCore", "libwebp_jll"] -git-tree-sha1 = "aa1ca3c47f119fbdae8770c29820e5e6119b83f2" -uuid = "e3aaa7dc-3e4b-44e0-be63-ffb868ccd7c1" -version = "0.1.3" - -[[deps.WoodburyMatrices]] -deps = ["LinearAlgebra", "SparseArrays"] -git-tree-sha1 = "c1a7aa6219628fcd757dede0ca95e245c5cd9511" -uuid = "efce3f68-66dc-5838-9240-27a6d6f5f9b6" -version = "1.0.0" - -[[deps.XML2_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl", "Libiconv_jll", "Zlib_jll"] -git-tree-sha1 = "6a451c6f33a176150f315726eba8b92fbfdb9ae7" -uuid = "02c8fc9c-b97f-50b9-bbe4-9be30ff0a78a" -version = "2.13.4+0" - -[[deps.XSLT_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl", "Libgcrypt_jll", "Libgpg_error_jll", "Libiconv_jll", "XML2_jll", "Zlib_jll"] -git-tree-sha1 = "a54ee957f4c86b526460a720dbc882fa5edcbefc" -uuid = "aed1982a-8fda-507f-9586-7b0439959a61" -version = "1.1.41+0" - -[[deps.XZ_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "15e637a697345f6743674f1322beefbc5dcd5cfc" -uuid = "ffd25f8a-64ca-5728-b0f7-c24cf3aae800" -version = "5.6.3+0" - -[[deps.Xorg_libX11_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl", "Xorg_libxcb_jll", "Xorg_xtrans_jll"] -git-tree-sha1 = "afead5aba5aa507ad5a3bf01f58f82c8d1403495" -uuid = "4f6342f7-b3d2-589e-9d20-edeb45f2b2bc" -version = "1.8.6+0" - -[[deps.Xorg_libXau_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "6035850dcc70518ca32f012e46015b9beeda49d8" -uuid = "0c0b7dd1-d40b-584c-a123-a41640f87eec" -version = "1.0.11+0" - -[[deps.Xorg_libXdmcp_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "34d526d318358a859d7de23da945578e8e8727b7" -uuid = "a3789734-cfe1-5b06-b2d0-1dd0d9d62d05" -version = "1.1.4+0" - -[[deps.Xorg_libXext_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl", "Xorg_libX11_jll"] -git-tree-sha1 = "d2d1a5c49fae4ba39983f63de6afcbea47194e85" -uuid = "1082639a-0dae-5f34-9b06-72781eeb8cb3" -version = "1.3.6+0" - -[[deps.Xorg_libXrender_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl", "Xorg_libX11_jll"] -git-tree-sha1 = "47e45cd78224c53109495b3e324df0c37bb61fbe" -uuid = "ea2f1a96-1ddc-540d-b46f-429655e07cfa" -version = "0.9.11+0" - -[[deps.Xorg_libpthread_stubs_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "8fdda4c692503d44d04a0603d9ac0982054635f9" -uuid = "14d82f49-176c-5ed1-bb49-ad3f5cbd8c74" -version = "0.1.1+0" - -[[deps.Xorg_libxcb_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl", "XSLT_jll", "Xorg_libXau_jll", "Xorg_libXdmcp_jll", "Xorg_libpthread_stubs_jll"] -git-tree-sha1 = "bcd466676fef0878338c61e655629fa7bbc69d8e" -uuid = "c7cfdc94-dc32-55de-ac96-5a1b8d977c5b" -version = "1.17.0+0" - -[[deps.Xorg_xtrans_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "e92a1a012a10506618f10b7047e478403a046c77" -uuid = "c5fb5394-a638-5e4d-96e5-b29de1b5cf10" -version = "1.5.0+0" - -[[deps.Zlib_jll]] -deps = ["Libdl"] -uuid = "83775a58-1f1d-513f-b197-d71354ab007a" -version = "1.2.13+1" - -[[deps.Zstd_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "555d1076590a6cc2fdee2ef1469451f872d8b41b" -uuid = "3161d3a3-bdf6-5164-811a-617609db77b4" -version = "1.5.6+1" - -[[deps.isoband_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl", "Pkg"] -git-tree-sha1 = "51b5eeb3f98367157a7a12a1fb0aa5328946c03c" -uuid = "9a68df92-36a6-505f-a73e-abb412b6bfb4" -version = "0.2.3+0" - -[[deps.libaom_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "1827acba325fdcdf1d2647fc8d5301dd9ba43a9d" -uuid = "a4ae2306-e953-59d6-aa16-d00cac43593b" -version = "3.9.0+0" - -[[deps.libass_jll]] -deps = ["Artifacts", "Bzip2_jll", "FreeType2_jll", "FriBidi_jll", "HarfBuzz_jll", "JLLWrappers", "Libdl", "Zlib_jll"] -git-tree-sha1 = "e17c115d55c5fbb7e52ebedb427a0dca79d4484e" -uuid = "0ac62f75-1d6f-5e53-bd7c-93b484bb37c0" -version = "0.15.2+0" - -[[deps.libblastrampoline_jll]] -deps = ["Artifacts", "Libdl"] -uuid = "8e850b90-86db-534c-a0d3-1478176c7d93" -version = "5.11.0+0" - -[[deps.libfdk_aac_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "8a22cf860a7d27e4f3498a0fe0811a7957badb38" -uuid = "f638f0a6-7fb0-5443-88ba-1cc74229b280" -version = "2.0.3+0" - -[[deps.libpng_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl", "Zlib_jll"] -git-tree-sha1 = "b70c870239dc3d7bc094eb2d6be9b73d27bef280" -uuid = "b53b4c65-9356-5827-b1ea-8c7a1a84506f" -version = "1.6.44+0" - -[[deps.libsixel_jll]] -deps = ["Artifacts", "JLLWrappers", "JpegTurbo_jll", "Libdl", "Pkg", "libpng_jll"] -git-tree-sha1 = "7dfa0fd9c783d3d0cc43ea1af53d69ba45c447df" -uuid = "075b6546-f08a-558a-be8f-8157d0f608a5" -version = "1.10.3+1" - -[[deps.libvorbis_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl", "Ogg_jll", "Pkg"] -git-tree-sha1 = "490376214c4721cdaca654041f635213c6165cb3" -uuid = "f27f6e37-5d2b-51aa-960f-b287f2bc3b7a" -version = "1.3.7+2" - -[[deps.libwebp_jll]] -deps = ["Artifacts", "Giflib_jll", "JLLWrappers", "JpegTurbo_jll", "Libdl", "Libglvnd_jll", "Libtiff_jll", "libpng_jll"] -git-tree-sha1 = "ccbb625a89ec6195856a50aa2b668a5c08712c94" -uuid = "c5f90fcd-3b7e-5836-afba-fc50a0988cb2" -version = "1.4.0+0" - -[[deps.nghttp2_jll]] -deps = ["Artifacts", "Libdl"] -uuid = "8e850ede-7688-5339-a07c-302acd2aaf8d" -version = "1.59.0+0" - -[[deps.oneTBB_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "7d0ea0f4895ef2f5cb83645fa689e52cb55cf493" -uuid = "1317d2d5-d96f-522e-a858-c73665f53c3e" -version = "2021.12.0+0" - -[[deps.p7zip_jll]] -deps = ["Artifacts", "Libdl"] -uuid = "3f19e933-33d8-53b3-aaab-bd5110c3b7a0" -version = "17.4.0+2" - -[[deps.x264_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "35976a1216d6c066ea32cba2150c4fa682b276fc" -uuid = "1270edf5-f2f9-52d2-97e9-ab00b5d0237a" -version = "10164.0.0+0" - -[[deps.x265_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "dcc541bb19ed5b0ede95581fb2e41ecf179527d2" -uuid = "dfaa095f-4041-5dcd-9319-2fabd8486b76" -version = "3.6.0+0" diff --git a/build/QuantumCollocation.jl b/build/QuantumCollocation.jl deleted file mode 100644 index 8609d32e..00000000 --- a/build/QuantumCollocation.jl +++ /dev/null @@ -1,66 +0,0 @@ -module QuantumCollocation - -using Reexport - -include("structure_utils.jl") -@reexport using .StructureUtils - -include("quantum_utils.jl") -@reexport using .QuantumUtils - -include("quantum_systems.jl") -@reexport using .QuantumSystems - -include("quantum_system_templates/_quantum_system_templates.jl") -@reexport using .QuantumSystemTemplates - -include("embedded_operators.jl") -@reexport using .EmbeddedOperators - -include("losses.jl") -@reexport using .Losses - -include("constraints.jl") -@reexport using .Constraints - -include("objectives.jl") -@reexport using .Objectives - -include("integrators.jl") -@reexport using .Integrators - -include("dynamics.jl") -@reexport using .Dynamics - -include("evaluators.jl") -@reexport using .Evaluators - -include("ipopt_options.jl") -@reexport using .IpoptOptions - -include("problems.jl") -@reexport using .Problems - -include("rollouts.jl") -@reexport using .Rollouts - -include("trajectory_initialization.jl") -@reexport using .TrajectoryInitialization - -include("continuous_trajectories.jl") -@reexport using .ContinuousTrajectories - -include("problem_templates/_problem_templates.jl") -@reexport using .ProblemTemplates - -include("save_load_utils.jl") -@reexport using .SaveLoadUtils - -include("problem_solvers.jl") -@reexport using .ProblemSolvers - -include("plotting.jl") -@reexport using .Plotting - - -end diff --git a/build/constraints.jl b/build/constraints.jl deleted file mode 100644 index 0043e9e0..00000000 --- a/build/constraints.jl +++ /dev/null @@ -1,841 +0,0 @@ -module Constraints - -export constrain! -export trajectory_constraints - -export AbstractConstraint - -export NonlinearConstraint - -export NonlinearEqualityConstraint - -export NonlinearInequalityConstraint - -export FinalFidelityConstraint -export FinalUnitaryFidelityConstraint -export FinalQuantumStateFidelityConstraint - -export ComplexModulusContraint - -export LinearConstraint - -export EqualityConstraint -export BoundsConstraint -export TimeStepBoundsConstraint -export TimeStepEqualityConstraint -export TimeStepsAllEqualConstraint -export L1SlackConstraint - -using ..StructureUtils -using ..QuantumUtils - -using TrajectoryIndexingUtils -using NamedTrajectories -using ForwardDiff -using SparseArrays -using Ipopt -using MathOptInterface -const MOI = MathOptInterface - - -abstract type AbstractConstraint end - -abstract type NonlinearConstraint <: AbstractConstraint end - - -function NonlinearConstraint(params::Dict) - return eval(params[:type])(; delete!(params, :type)...) -end - -""" - struct NonlinearEqualityConstraint - -Represents a nonlinear equality constraint. - -# Fields -- `g::Function`: the constraint function -- `∂g::Function`: the Jacobian of the constraint function -- `∂g_structure::Vector{Tuple{Int, Int}}`: the structure of the Jacobian - i.e. all non-zero entries -- `μ∂²g::Function`: the Hessian of the constraint function -- `μ∂²g_structure::Vector{Tuple{Int, Int}}`: the structure of the Hessian -- `dim::Int`: the dimension of the constraint function -- `params::Dict{Symbol, Any}`: a dictionary of parameters - -""" -struct NonlinearEqualityConstraint <: NonlinearConstraint - g::Function - ∂g::Function - ∂g_structure::Vector{Tuple{Int, Int}} - μ∂²g::Function - μ∂²g_structure::Vector{Tuple{Int, Int}} - dim::Int - params::Dict{Symbol, Any} -end - -""" - struct NonlinearInequalityConstraint - -Represents a nonlinear inequality constraint. - -# Fields -- `g::Function`: the constraint function -- `∂g::Function`: the Jacobian of the constraint function -- `∂g_structure::Vector{Tuple{Int, Int}}`: the structure of the Jacobian - i.e. all non-zero entries -- `μ∂²g::Function`: the Hessian of the constraint function -- `μ∂²g_structure::Vector{Tuple{Int, Int}}`: the structure of the Hessian -- `dim::Int`: the dimension of the constraint function -- `params::Dict{Symbol, Any}`: a dictionary of parameters containing additional - information about the constraint - -""" -struct NonlinearInequalityConstraint <: NonlinearConstraint - g::Function - ∂g::Function - ∂g_structure::Vector{Tuple{Int, Int}} - μ∂²g::Function - μ∂²g_structure::Vector{Tuple{Int, Int}} - dim::Int - params::Dict{Symbol, Any} -end - -""" - FinalFidelityConstraint() - - -Returns a NonlinearInequalityConstraint representing a constraint on the -minimum allowed fidelity. - -# Arguments -- `fidelity_function::Union{Function,Nothing}=nothing`: the fidelity function -- `value::Union{Float64,Nothing}=nothing`: the minimum fidelity value allowed - by the constraint -- `comps::Union{AbstractVector{Int},Nothing}=nothing`: the components of the - state to which the fidelity function is applied -- `goal::Union{AbstractVector{Float64},Nothing}=nothing`: the goal state -- `statedim::Union{Int,Nothing}=nothing`: the dimension of the state -- `zdim::Union{Int,Nothing}=nothing`: the dimension of a single time step of the trajectory -- `T::Union{Int,Nothing}=nothing`: the number of time steps -- `subspace::Union{AbstractVector{<:Integer}, Nothing}=nothing`: the subspace indices of the fidelity - -""" - -function FinalFidelityConstraint(; - fidelity_function::Union{Function,Nothing}=nothing, - value::Union{Float64,Nothing}=nothing, - comps::Union{AbstractVector{Int},Nothing}=nothing, - goal::Union{AbstractVector{Float64},Nothing}=nothing, - statedim::Union{Int,Nothing}=nothing, - zdim::Union{Int,Nothing}=nothing, - T::Union{Int,Nothing}=nothing, - subspace::Union{AbstractVector{<:Integer}, Nothing}=nothing -) - @assert !isnothing(fidelity_function) "must provide a fidelity function" - @assert !isnothing(value) "must provide a fidelity value" - @assert !isnothing(comps) "must provide a list of components" - @assert !isnothing(goal) "must provide a goal state" - @assert !isnothing(statedim) "must provide a state dimension" - @assert !isnothing(zdim) "must provide a z dimension" - @assert !isnothing(T) "must provide a T" - - fidelity_function_symbol = Symbol(fidelity_function) - - if isnothing(subspace) - fid = x -> fidelity_function(x, goal) - else - fid = x -> fidelity_function(x, goal; subspace=subspace) - end - - @assert fid(randn(statedim)) isa Float64 "fidelity function must return a scalar" - - params = Dict{Symbol, Any}() - - if fidelity_function_symbol ∉ names(QuantumUtils) - @warn "fidelity function is not exported by QuantumUtils: will not be able to save this constraint" - params[:type] = :FinalFidelityConstraint - params[:fidelity_function] = :not_saveable - else - params[:type] = :FinalFidelityConstraint - params[:fidelity_function] = fidelity_function_symbol - params[:value] = value - params[:comps] = comps - params[:statedim] = statedim - params[:zdim] = zdim - params[:T] = T - params[:subspace] = subspace - end - - state_slice = slice(T, comps, zdim) - - ℱ(x) = [fid(x)] - - g(Z⃗) = ℱ(Z⃗[state_slice]) .- value - - ∂ℱ(x) = ForwardDiff.jacobian(ℱ, x) - - ∂ℱ_structure = jacobian_structure(∂ℱ, statedim) - - col_offset = index(T, comps[1] - 1, zdim) - - ∂g_structure = [(i, j + col_offset) for (i, j) in ∂ℱ_structure] - - @views function ∂g(Z⃗; ipopt=true) - ∂ = spzeros(1, T * zdim) - ∂ℱ_x = ∂ℱ(Z⃗[state_slice]) - for (i, j) ∈ ∂ℱ_structure - ∂[i, j + col_offset] = ∂ℱ_x[i, j] - end - if ipopt - return [∂[i, j] for (i, j) in ∂g_structure] - else - return ∂ - end - end - - ∂²ℱ(x) = ForwardDiff.hessian(fid, x) - - ∂²ℱ_structure = hessian_of_lagrangian_structure(∂²ℱ, statedim, 1) - - μ∂²g_structure = [ij .+ col_offset for ij in ∂²ℱ_structure] - - @views function μ∂²g(Z⃗, μ; ipopt=true) - HoL = spzeros(T * zdim, T * zdim) - μ∂²ℱ = μ[1] * ∂²ℱ(Z⃗[state_slice]) - for (i, j) ∈ ∂²ℱ_structure - HoL[i + col_offset, j + col_offset] = μ∂²ℱ[i, j] - end - if ipopt - return [HoL[i, j] for (i, j) in μ∂²g_structure] - else - return HoL - end - end - - return NonlinearInequalityConstraint( - g, - ∂g, - ∂g_structure, - μ∂²g, - μ∂²g_structure, - 1, - params - ) -end - -""" - FinalUnitaryFidelityConstraint(statesymb::Symbol, val::Float64, traj::NamedTrajectory) - -Returns a FinalFidelityConstraint for the unitary fidelity function where statesymb -is the NamedTrajectory symbol representing the unitary. - -""" -function FinalUnitaryFidelityConstraint( - statesymb::Symbol, - val::Float64, - traj::NamedTrajectory; - subspace::Union{AbstractVector{<:Integer}, Nothing}=nothing -) - @assert statesymb ∈ traj.names - return FinalFidelityConstraint(; - fidelity_function=unitary_fidelity, - value=val, - comps=traj.components[statesymb], - goal=traj.goal[statesymb], - statedim=traj.dims[statesymb], - zdim=traj.dim, - T=traj.T, - subspace=subspace - ) -end - -""" - FinalQuantumStateFidelityConstraint(statesymb::Symbol, val::Float64, traj::NamedTrajectory) - -Returns a FinalFidelityConstraint for the unitary fidelity function where statesymb -is the NamedTrajectory symbol representing the unitary. - -""" -function FinalQuantumStateFidelityConstraint( - statesymb::Symbol, - val::Float64, - traj::NamedTrajectory -) - @assert statesymb ∈ traj.names - return FinalFidelityConstraint(; - fidelity_function=fidelity, - value=val, - comps=traj.components[statesymb], - goal=traj.goal[statesymb], - statedim=traj.dims[statesymb], - zdim=traj.dim, - T=traj.T - ) -end - - - -# function FinalStateFidelityConstraint( -# val::Float64, -# statesymb::Symbol, -# statedim::Int; -# fidelity_function::Function=fidelity -# ) -# return FinalFidelityConstraint(; -# fidelity_function=fidelity_function, -# value=val, -# statesymb=statesymb, -# statedim=statedim -# ) -# end - -""" - ComplexModulusContraint() - -Returns a NonlinearInequalityConstraint on the complex modulus of a complex control - -# Arguments -- `R::Union{Float64,Nothing}=nothing`: the maximum allowed complex modulus -- `comps::Union{AbstractVector{Int},Nothing}=nothing`: the components of the complex control, - both the real and imaginary parts -- `times::Union{AbstractVector{Int},Nothing}=nothing`: the times at which the constraint is applied -- `zdim::Union{Int,Nothing}=nothing`: the dimension of a single time step of the trajectory -- `T::Union{Int,Nothing}=nothing`: the number of time steps -""" -function ComplexModulusContraint(; - R::Union{Float64, Nothing}=nothing, - comps::Union{AbstractVector{Int}, Nothing}=nothing, - times::Union{AbstractVector{Int}, Nothing}=nothing, - zdim::Union{Int, Nothing}=nothing, - T::Union{Int, Nothing}=nothing, -) - @assert !isnothing(R) "must provide a value R, s.t. |z| <= R" - @assert !isnothing(comps) "must provide components of the complex number" - @assert !isnothing(times) "must provide times" - @assert !isnothing(zdim) "must provide a z dimension" - @assert !isnothing(T) "must provide a T" - - @assert length(comps) == 2 "component must represent a complex number and have dimension 2" - - params = Dict{Symbol, Any}() - - params[:type] = :ComplexModulusContraint - params[:R] = R - params[:comps] = comps - params[:times] = times - params[:zdim] = zdim - params[:T] = T - - gₜ(xₜ, yₜ) = [R^2 - xₜ^2 - yₜ^2] - ∂gₜ(xₜ, yₜ) = [-2xₜ, -2yₜ] - μₜ∂²gₜ(μₜ) = sparse([1, 2], [1, 2], [-2μₜ, -2μₜ]) - - @views function g(Z⃗) - r = zeros(length(times)) - for (i, t) ∈ enumerate(times) - zₜ = Z⃗[slice(t, comps, zdim)] - xₜ = zₜ[1] - yₜ = zₜ[2] - r[i] = gₜ(xₜ, yₜ)[1] - end - return r - end - - ∂g_structure = [] - - for (i, t) ∈ enumerate(times) - push!(∂g_structure, (i, index(t, comps[1], zdim))) - push!(∂g_structure, (i, index(t, comps[2], zdim))) - end - - @views function ∂g(Z⃗; ipopt=true) - ∂ = spzeros(length(times), zdim * T) - for (i, t) ∈ enumerate(times) - zₜ = Z⃗[slice(t, comps, zdim)] - xₜ = zₜ[1] - yₜ = zₜ[2] - ∂[i, slice(t, comps, zdim)] = ∂gₜ(xₜ, yₜ) - end - if ipopt - return [∂[i, j] for (i, j) in ∂g_structure] - else - return ∂ - end - end - - μ∂²g_structure = [] - - for t ∈ times - push!( - μ∂²g_structure, - ( - index(t, comps[1], zdim), - index(t, comps[1], zdim) - ) - ) - push!( - μ∂²g_structure, - ( - index(t, comps[2], zdim), - index(t, comps[2], zdim) - ) - ) - end - - function μ∂²g(Z⃗, μ; ipopt=true) - μ∂² = spzeros(zdim * T, zdim * T) - for (i, t) ∈ enumerate(times) - t_slice = slice(t, comps, zdim) - μ∂²[t_slice, t_slice] = μₜ∂²gₜ(μ[i]) - end - if ipopt - return [μ∂²[i, j] for (i, j) in μ∂²g_structure] - else - return μ∂² - end - end - - return NonlinearInequalityConstraint( - g, - ∂g, - ∂g_structure, - μ∂²g, - μ∂²g_structure, - length(times), - params - ) -end - -""" - ComplexModulusContraint(symb::Symbol, R::Float64, traj::NamedTrajectory) - -Returns a ComplexModulusContraint for the complex control NamedTrajector symbol -where R is the maximum allowed complex modulus. -""" -function ComplexModulusContraint( - symb::Symbol, - R::Float64, - traj::NamedTrajectory; - times=1:traj.T -) - @assert symb ∈ traj.names - return ComplexModulusContraint(; - R=R, - comps=traj.components[symb], - times=times, - zdim=traj.dim, - T=traj.T - ) -end - - -abstract type LinearConstraint <: AbstractConstraint end - -""" - constrain!(opt::Ipopt.Optimizer, vars::Vector{MOI.VariableIndex}, cons::Vector{LinearConstraint}, traj::NamedTrajectory; verbose=false) - -Supplies a set of LinearConstraints to IPOPT using MathOptInterface - -""" -function constrain!( - opt::Ipopt.Optimizer, - vars::Vector{MOI.VariableIndex}, - cons::Vector{LinearConstraint}, - traj::NamedTrajectory; - verbose=false -) - for con in cons - if verbose - println("applying constraint: ", con.label) - end - con(opt, vars, traj) - end -end - -""" - trajectory_constraints(traj::NamedTrajectory) - -Implements the initial and final value constraints and bounds constraints on the controls -and states as specified by traj. - -""" - -function trajectory_constraints(traj::NamedTrajectory) - cons = AbstractConstraint[] - - init_names = [] - - # add initial equality constraints - for (name, val) ∈ pairs(traj.initial) - ts = [1] - js = traj.components[name] - con_label = "initial value of $name" - eq_con = EqualityConstraint(ts, js, val, traj.dim; label=con_label) - push!(cons, eq_con) - push!(init_names, name) - end - - final_names = [] - - # add final equality constraints - for (name, val) ∈ pairs(traj.final) - ts = [traj.T] - js = traj.components[name] - con_label = "final value of $name" - eq_con = EqualityConstraint(ts, js, val, traj.dim; label=con_label) - push!(cons, eq_con) - push!(final_names, name) - end - - # add bounds constraints - for (name, bound) ∈ pairs(traj.bounds) - if name ∈ init_names && name ∈ final_names - ts = 2:traj.T-1 - elseif name ∈ init_names && !(name ∈ final_names) - ts = 2:traj.T - elseif name ∈ final_names && !(name ∈ init_names) - ts = 1:traj.T-1 - else - ts = 1:traj.T - end - js = traj.components[name] - con_label = "bounds on $name" - bounds = collect(zip(bound[1], bound[2])) - bounds_con = BoundsConstraint(ts, js, bounds, traj.dim; label=con_label) - push!(cons, bounds_con) - end - - return cons -end - - - -""" - struct EqualityConstraint - -Represents a linear equality constraint. - -# Fields -- `ts::AbstractArray{Int}`: the time steps at which the constraint is applied -- `js::AbstractArray{Int}`: the components of the trajectory at which the constraint is applied -- `vals::Vector{R}`: the values of the constraint -- `vardim::Int`: the dimension of a single time step of the trajectory -- `label::String`: a label for the constraint - -""" -struct EqualityConstraint <: LinearConstraint - ts::AbstractArray{Int} - js::AbstractArray{Int} - vals::Vector{R} where R - vardim::Int - label::String -end - -function EqualityConstraint( - t::Union{Int, AbstractArray{Int}}, - j::Union{Int, AbstractArray{Int}}, - val::Union{R, Vector{R}}, - vardim::Int; - label="unlabeled equality constraint" -) where R - - @assert !(isa(val, Vector{R}) && isa(j, Int)) - "if val is an array, j must be an array of integers" - - @assert isa(val, R) || - (isa(val, Vector{R}) && isa(j, AbstractArray{Int})) && - length(val) == length(j) """ - if j and val are both arrays, dimensions must match: - length(j) = $(length(j)) - length(val) = $(length(val)) - """ - - if isa(val, R) && isa(j, AbstractArray{Int}) - val = fill(val, length(j)) - end - - return EqualityConstraint( - [t...], - [j...], - [val...], - vardim, - label - ) -end - - -function (con::EqualityConstraint)( - opt::Ipopt.Optimizer, - vars::Vector{MOI.VariableIndex}, - traj::NamedTrajectory -) - for t in con.ts - for (j, val) in zip(con.js, con.vals) - MOI.add_constraints( - opt, - vars[index(t, j, con.vardim)], - MOI.EqualTo(val) - ) - end - end -end - -struct BoundsConstraint <: LinearConstraint - ts::AbstractArray{Int} - js::AbstractArray{Int} - vals::Vector{Tuple{R, R}} where R <: Real - vardim::Int - label::String -end - -function BoundsConstraint( - t::Union{Int, AbstractArray{Int}}, - j::Union{Int, AbstractArray{Int}}, - val::Union{Tuple{R, R}, Vector{Tuple{R, R}}}, - vardim::Int; - label="unlabeled bounds constraint" -) where R <: Real - - @assert !(isa(val, Vector{Tuple{R, R}}) && isa(j, Int)) - "if val is an array, var must be an array of integers" - - if isa(val, Tuple{R,R}) && isa(j, AbstractArray{Int}) - - val = fill(val, length(j)) - - elseif isa(val, Tuple{R, R}) && isa(j, Int) - - val = [val] - j = [j] - - end - - @assert *([v[1] <= v[2] for v in val]...) "lower bound must be less than upper bound" - - return BoundsConstraint( - [t...], - j, - val, - vardim, - label - ) -end - -function BoundsConstraint( - t::Union{Int, AbstractArray{Int}}, - j::Union{Int, AbstractArray{Int}}, - val::Union{R, Vector{R}}, - vardim::Int; - label="unlabeled bounds constraint" -) where R <: Real - - @assert !(isa(val, Vector{R}) && isa(j, Int)) - "if val is an array, var must be an array of integers" - - if isa(val, R) && isa(j, AbstractArray{Int}) - - bounds = (-abs(val), abs(val)) - val = fill(bounds, length(j)) - - elseif isa(val, R) && isa(j, Int) - - bounds = (-abs(val), abs(val)) - val = [bounds] - j = [j] - - elseif isa(val, Vector{R}) - - val = [(-abs(v), abs(v)) for v in val] - - end - - return BoundsConstraint( - [t...], - j, - val, - vardim, - label - ) -end - -function (con::BoundsConstraint)( - opt::Ipopt.Optimizer, - vars::Vector{MOI.VariableIndex}, - traj::NamedTrajectory -) - for t in con.ts - for (j, (lb, ub)) in zip(con.js, con.vals) - MOI.add_constraints( - opt, - vars[index(t, j, con.vardim)], - MOI.GreaterThan(lb) - ) - MOI.add_constraints( - opt, - vars[index(t, j, con.vardim)], - MOI.LessThan(ub) - ) - end - end -end - -struct TimeStepBoundsConstraint <: LinearConstraint - bounds::Tuple{R, R} where R <: Real - Δt_indices::AbstractVector{Int} - label::String - - function TimeStepBoundsConstraint( - bounds::Tuple{R, R} where R <: Real, - Δt_indices::AbstractVector{Int}, - T::Int; - label="time step bounds constraint" - ) - @assert bounds[1] < bounds[2] "lower bound must be less than upper bound" - return new(bounds, Δt_indices, label) - end -end - -function (con::TimeStepBoundsConstraint)( - opt::Ipopt.Optimizer, - vars::Vector{MOI.VariableIndex}, - traj::NamedTrajectory -) - for i ∈ con.Δt_indices - MOI.add_constraints( - opt, - vars[i], - MOI.GreaterThan(con.bounds[1]) - ) - MOI.add_constraints( - opt, - vars[i], - MOI.LessThan(con.bounds[2]) - ) - end -end - -struct TimeStepEqualityConstraint <: LinearConstraint - val::R where R <: Real - Δt_indices::AbstractVector{Int} - label::String - - function TimeStepEqualityConstraint( - val::R where R <: Real, - Δt_indices::AbstractVector{Int}; - label="unlabeled time step equality constraint" - ) - return new(val, Δt_indices, label) - end -end - -function (con::TimeStepEqualityConstraint)( - opt::Ipopt.Optimizer, - vars::Vector{MOI.VariableIndex}, - traj::NamedTrajectory -) - for i ∈ con.Δt_indices - MOI.add_constraints( - opt, - vars[i], - MOI.EqualTo(con.val) - ) - end -end - -struct TimeStepsAllEqualConstraint <: LinearConstraint - Δt_indices::AbstractVector{Int} - label::String - - function TimeStepsAllEqualConstraint( - Δt_indices::AbstractVector{Int}; - label="time step all equal constraint" - ) - return new(Δt_indices, label) - end - - function TimeStepsAllEqualConstraint( - Δt_symb::Symbol, - traj::NamedTrajectory; - label="time step all equal constraint" - ) - Δt_comp = traj.components[Δt_symb][1] - Δt_indices = [index(t, Δt_comp, traj.dim) for t = 1:traj.T] - return new(Δt_indices, label) - end -end - -function (con::TimeStepsAllEqualConstraint)( - opt::Ipopt.Optimizer, - vars::Vector{MOI.VariableIndex}, - traj::NamedTrajectory -) - N = length(con.Δt_indices) - for i = 1:N-1 - Δtᵢ = MOI.ScalarAffineTerm(1.0, vars[con.Δt_indices[i]]) - minusΔt̄ = MOI.ScalarAffineTerm(-1.0, vars[con.Δt_indices[end]]) - MOI.add_constraints( - opt, - MOI.ScalarAffineFunction([Δtᵢ, minusΔt̄], 0.0), - MOI.EqualTo(0.0) - ) - end -end - -struct L1SlackConstraint <: LinearConstraint - var_name::Symbol - slack_names::Vector{Symbol} - indices::AbstractVector{Int} - times::AbstractVector{Int} - label::String - - function L1SlackConstraint( - name::Symbol, - traj::NamedTrajectory; - indices=1:traj.dims[name], - times=(name ∈ keys(traj.initial) ? 2 : 1):traj.T, - label="L1 slack constraint on $name" - ) - @assert all(i ∈ 1:traj.dims[name] for i ∈ indices) - s1_name = Symbol("s1_$name") - s2_name = Symbol("s2_$name") - slack_names = [s1_name, s2_name] - add_component!(traj, s1_name, rand(length(indices), traj.T)) - add_component!(traj, s2_name, rand(length(indices), traj.T)) - return new(name, slack_names, indices, times, label) - end -end - -function (con::L1SlackConstraint)( - opt::Ipopt.Optimizer, - vars::Vector{MOI.VariableIndex}, - traj::NamedTrajectory -) - for t ∈ con.times - for (s1, s2, x) in zip( - slice(t, traj.components[con.slack_names[1]], traj.dim), - slice(t, traj.components[con.slack_names[2]], traj.dim), - slice(t, traj.components[con.var_name][con.indices], traj.dim) - ) - MOI.add_constraints( - opt, - vars[s1], - MOI.GreaterThan(0.0) - ) - MOI.add_constraints( - opt, - vars[s2], - MOI.GreaterThan(0.0) - ) - t1 = MOI.ScalarAffineTerm(1.0, vars[s1]) - t2 = MOI.ScalarAffineTerm(-1.0, vars[s2]) - t3 = MOI.ScalarAffineTerm(-1.0, vars[x]) - MOI.add_constraints( - opt, - MOI.ScalarAffineFunction([t1, t2, t3], 0.0), - MOI.EqualTo(0.0) - ) - end - end -end - -end diff --git a/build/continuous_trajectories.jl b/build/continuous_trajectories.jl deleted file mode 100644 index 6f2c6352..00000000 --- a/build/continuous_trajectories.jl +++ /dev/null @@ -1,111 +0,0 @@ -module ContinuousTrajectories - -export ContinuousTrajectory -export plot - -using CairoMakie -using HDF5 - -import NamedTrajectories: plot, save - -struct ContinuousTrajectory - A::AbstractMatrix{Float64} - dA::AbstractMatrix{Float64} - times::AbstractVector{Float64} -end - -function cubic_spline_coeffs(aᵢ, ȧᵢ, aᵢ₊₁, ȧᵢ₊₁, tᵢ, tᵢ₊₁) - M = [ - 1 tᵢ tᵢ^2 tᵢ^3 ; - 0 1 2tᵢ 3tᵢ^2 ; - 1 tᵢ₊₁ tᵢ₊₁^2 tᵢ₊₁^3 ; - 0 1 2tᵢ₊₁ 3tᵢ₊₁^2 - ] - A = vcat(transpose.([aᵢ, ȧᵢ, aᵢ₊₁, ȧᵢ₊₁])...) - B = inv(M) * A - return B -end - -function (ct::ContinuousTrajectory)(t::Real) - @assert t >= ct.times[1] && t <= ct.times[end] "t = $(t) must be in the range of the trajectory, i.e. t ∈ [$(ct.times[1]), $(ct.times[end])]." - if t == ct.times[1] - return ct.A[:, 1] - elseif t == ct.times[end] - return ct.A[:, end] - end - tₜ = findfirst(t .< ct.times) - tₜ₋₁ = tₜ - 1 - tᵢ = ct.times[tₜ₋₁] - tᵢ₊₁ = ct.times[tₜ] - aᵢ = ct.A[:, tₜ₋₁] - aᵢ₊₁ = ct.A[:, tₜ] - ȧᵢ = ct.dA[:, tₜ₋₁] - ȧᵢ₊₁ = ct.dA[:, tₜ] - B = cubic_spline_coeffs(aᵢ, ȧᵢ, aᵢ₊₁, ȧᵢ₊₁, tᵢ, tᵢ₊₁) - T = [1, t, t^2, t^3] - return B' * T -end - -function (ct::ContinuousTrajectory)(ts::AbstractVector{<:Real}) - @assert issorted(ts) - return hcat([ct(tᵢ) for tᵢ in ts]...) -end - -function (ct::ContinuousTrajectory)(nsamples::Int; return_times=false, return_timestep=false) - ts = LinRange(ct.times[1], ct.times[end], nsamples) - if !return_times && !return_timestep - return ct(ts) - elseif return_times && !return_timestep - return ct(ts), ts - elseif !return_times && return_timestep - return ct(ts), ts[2] - ts[1] - else - return ct(ts), ts, ts[2] - ts[1] - end -end - -function plot( - ct::ContinuousTrajectory, - ts::AbstractVector{<:Real}; - fig_size=(800, 400), -) - fig = Figure(size=fig_size) - ax = Axis(fig[1, 1]) - A = ct(ts) - series!(ax, ts, A) - return fig -end - -function plot( - ct::ContinuousTrajectory, - nsamples::Int; - fig_size=(800, 400), -) - fig = Figure(size=fig_size) - ax = Axis(fig[1, 1]) - A, ts = ct(nsamples; return_times=true) - series!(ax, ts, A) - return fig -end - -function save(path::String, ct::ContinuousTrajectory, ts::AbstractVector{<:Real}) - A = ct(ts) - mkdir(dirname(path)) - h5open(path, "w") do file - file["controls"] = A - file["times"] = ts - file["T"] = length(ts) - end -end - -function save(path::String, ct::ContinuousTrajectory, nsamples::Int) - A, ts = ct(nsamples; return_times=true) - mkdir(dirname(path)) - h5open(path, "w") do file - file["controls"] = A - file["times"] = ts - file["T"] = length(ts) - end -end - -end diff --git a/build/dynamics.jl b/build/dynamics.jl deleted file mode 100644 index f9555eee..00000000 --- a/build/dynamics.jl +++ /dev/null @@ -1,400 +0,0 @@ -module Dynamics - -export AbstractDynamics -export QuantumDynamics - -export dynamics -export dynamics_jacobian -export dynamics_hessian_of_lagrangian -export dynamics_components - -using ..QuantumSystems -using ..QuantumUtils -using ..StructureUtils -using ..Integrators - -using TrajectoryIndexingUtils -using NamedTrajectories -using LinearAlgebra -using SparseArrays -using ForwardDiff - - -abstract type AbstractDynamics end - -""" - QuantumDynamics <: AbstractDynamics -""" -struct QuantumDynamics <: AbstractDynamics - integrators::Union{Nothing, Vector{<:AbstractIntegrator}} - F::Function - ∂F::Function - ∂F_structure::Vector{Tuple{Int, Int}} - μ∂²F::Union{Function, Nothing} - μ∂²F_structure::Union{Vector{Tuple{Int, Int}}, Nothing} - dim::Int -end - -function dynamics_components(integrators::Vector{<:AbstractIntegrator}) - dynamics_comps = [] - comp_mark = 0 - for integrator ∈ integrators - integrator_comps = (comp_mark + 1):(comp_mark + dim(integrator)) - push!(dynamics_comps, integrator_comps) - comp_mark += dim(integrator) - end - return dynamics_comps -end - -function dynamics( - integrators::Vector{<:AbstractIntegrator}, - traj::NamedTrajectory -) - dynamics_comps = dynamics_components(integrators) - dynamics_dim = dim(integrators) - function f(zₜ, zₜ₊₁) - δ = Vector{eltype(zₜ)}(undef, dynamics_dim) - for (integrator, integrator_comps) ∈ zip(integrators, dynamics_comps) - δ[integrator_comps] = integrator(zₜ, zₜ₊₁, traj) - end - return δ - end - return f -end - - - -function dynamics_jacobian( - integrators::Vector{<:AbstractIntegrator}, - traj::NamedTrajectory -) - dynamics_comps = dynamics_components(integrators) - dynamics_dim = dim(integrators) - free_time = traj.timestep isa Symbol - @views function ∂f(zₜ, zₜ₊₁) - ∂ = zeros(eltype(zₜ), dynamics_dim, 2traj.dim) - for (integrator, integrator_comps) ∈ zip(integrators, dynamics_comps) - if integrator isa QuantumIntegrator - if integrator.autodiff - ∂Pᵢ(z1, z2) = ForwardDiff.jacobian( - zz -> integrator(zz[1:traj.dim], zz[traj.dim+1:end], traj), - [z1; z2] - ) - ∂[integrator_comps, 1:2traj.dim] = ∂Pᵢ(zₜ, zₜ₊₁) - else - if free_time - x_comps, u_comps, Δt_comps = comps(integrator, traj) - ∂xₜf, ∂xₜ₊₁f, ∂uₜf, ∂Δtₜf = - Integrators.jacobian(integrator, zₜ, zₜ₊₁, traj) - ∂[integrator_comps, Δt_comps] = ∂Δtₜf - else - x_comps, u_comps = comps(integrator, traj) - ∂xₜf, ∂xₜ₊₁f, ∂uₜf = - Integrators.jacobian(integrator, zₜ, zₜ₊₁, traj) - end - ∂[integrator_comps, x_comps] = ∂xₜf - ∂[integrator_comps, x_comps .+ traj.dim] = ∂xₜ₊₁f - if u_comps isa Tuple - for (uᵢ_comps, ∂uₜᵢf) ∈ zip(u_comps, ∂uₜf) - ∂[integrator_comps, uᵢ_comps] = ∂uₜᵢf - end - else - ∂[integrator_comps, u_comps] = ∂uₜf - end - end - elseif integrator isa DerivativeIntegrator - if free_time - x_comps, dx_comps, Δt_comps = comps(integrator, traj) - ∂xₜf, ∂xₜ₊₁f, ∂dxₜf, ∂Δtₜf = - Integrators.jacobian(integrator, zₜ, zₜ₊₁, traj) - else - x_comps, dx_comps = comps(integrator, traj) - ∂xₜf, ∂xₜ₊₁f, ∂dxₜf = - Integrators.jacobian(integrator, zₜ, zₜ₊₁, traj) - end - ∂[integrator_comps, x_comps] = ∂xₜf - ∂[integrator_comps, x_comps .+ traj.dim] = ∂xₜ₊₁f - ∂[integrator_comps, dx_comps] = ∂dxₜf - if free_time - ∂[integrator_comps, Δt_comps] = ∂Δtₜf - end - else - error("integrator type not supported: $(typeof(integrator))") - end - end - return sparse(∂) - end - return ∂f -end - -function dynamics_hessian_of_lagrangian( - integrators::Vector{<:AbstractIntegrator}, - traj::NamedTrajectory -) - dynamics_comps = dynamics_components(integrators) - free_time = traj.timestep isa Symbol - function μ∂²f(zₜ, zₜ₊₁, μₜ) - μ∂² = zeros(eltype(zₜ), 2traj.dim, 2traj.dim) - for (integrator, integrator_comps) ∈ zip(integrators, dynamics_comps) - if integrator isa QuantumIntegrator - if integrator.autodiff - μ∂²P(z1, z2, μ) = ForwardDiff.hessian( - zz -> μ' * integrator(zz[1:traj.dim], zz[traj.dim+1:end], traj), - [z1; z2] - ) - μ∂²[1:2traj.dim, 1:2traj.dim] = sparse(μ∂²P(zₜ, zₜ₊₁, μₜ[integrator_comps])) - else - if free_time - x_comps, u_comps, Δt_comps = comps(integrator, traj) - μ∂uₜ∂xₜf, μ∂²uₜf, μ∂Δtₜ∂xₜf, μ∂Δtₜ∂uₜf, μ∂²Δtₜf, μ∂xₜ₊₁∂uₜf, μ∂xₜ₊₁∂Δtₜf = - hessian_of_the_lagrangian(integrator, zₜ, zₜ₊₁, μₜ[integrator_comps], traj) - else - x_comps, u_comps = comps(integrator, traj) - μ∂uₜ∂xₜf, μ∂²uₜf, μ∂xₜ₊₁∂uₜf = - hessian_of_the_lagrangian(integrator, zₜ, zₜ₊₁, μₜ[integrator_comps], traj) - end - if u_comps isa Tuple - for (uᵢ_comps, μ∂uₜᵢ∂xₜf) ∈ zip(u_comps, μ∂uₜ∂xₜf) - μ∂²[x_comps, uᵢ_comps] += μ∂uₜᵢ∂xₜf - end - for (uᵢ_comps, μ∂²uₜᵢf) ∈ zip(u_comps, μ∂²uₜf) - μ∂²[uᵢ_comps, uᵢ_comps] += μ∂²uₜᵢf - end - if free_time - for (uᵢ_comps, μ∂Δtₜ∂uₜᵢf) ∈ zip(u_comps, μ∂Δtₜ∂uₜf) - μ∂²[uᵢ_comps, Δt_comps] += μ∂Δtₜ∂uₜᵢf - end - end - for (uᵢ_comps, μ∂xₜ₊₁∂uₜᵢf) ∈ zip(u_comps, μ∂xₜ₊₁∂uₜf) - μ∂²[uᵢ_comps, x_comps .+ traj.dim] += μ∂xₜ₊₁∂uₜᵢf - end - else - μ∂²[x_comps, u_comps] += μ∂uₜ∂xₜf - μ∂²[u_comps, u_comps] += μ∂²uₜf - if free_time - μ∂²[u_comps, Δt_comps] += μ∂Δtₜ∂uₜf - end - μ∂²[u_comps, x_comps .+ traj.dim] += μ∂xₜ₊₁∂uₜf - end - if free_time - μ∂²[x_comps, Δt_comps] += μ∂Δtₜ∂xₜf - μ∂²[Δt_comps, x_comps .+ traj.dim] += μ∂xₜ₊₁∂Δtₜf - μ∂²[Δt_comps, Δt_comps] .+= μ∂²Δtₜf - end - end - elseif integrator isa DerivativeIntegrator - if free_time - x_comps, dx_comps, Δt_comps = comps(integrator, traj) - μ∂dxₜ∂Δtₜf = -μₜ[integrator_comps] - μ∂²[dx_comps, Δt_comps] += μ∂dxₜ∂Δtₜf - end - end - end - return sparse(μ∂²) - end - return μ∂²f -end - - -function QuantumDynamics( - integrators::Vector{<:AbstractIntegrator}, - traj::NamedTrajectory; - hessian_approximation=false, - jacobian_structure=true, - verbose=false -) - if verbose - println(" constructing knot point dynamics functions...") - end - - free_time = traj.timestep isa Symbol - - if free_time - @assert all([ - !isnothing(state(integrator)) && - !isnothing(controls(integrator)) - for integrator ∈ integrators - ]) - else - @assert all([ - !isnothing(state(integrator)) && - !isnothing(controls(integrator)) - for integrator ∈ integrators - ]) - end - - for integrator ∈ integrators - if integrator isa QuantumIntegrator && controls(integrator) isa Tuple - drive_comps = [traj.components[s] for s ∈ integrator.drive_symb] - number_of_drives = sum(length.(drive_comps)) - @assert number_of_drives == integrator.n_drives "number of drives ($(number_of_drives)) does not match number of drive terms in Hamiltonian ($(integrator.n_drives))" - end - end - - f = dynamics(integrators, traj) - - ∂f = dynamics_jacobian(integrators, traj) - - if hessian_approximation - μ∂²f = nothing - else - μ∂²f = dynamics_hessian_of_lagrangian(integrators, traj) - end - - if verbose - println(" determining dynamics derivative structure...") - end - - dynamics_dim = dim(integrators) - - if hessian_approximation - ∂f_structure, ∂F_structure = dynamics_structure(∂f, traj, dynamics_dim; - verbose=verbose, - jacobian=jacobian_structure, - ) - μ∂²F_structure = nothing - else - ∂f_structure, ∂F_structure, μ∂²f_structure, μ∂²F_structure = - dynamics_structure(∂f, μ∂²f, traj, dynamics_dim; - verbose=verbose, - jacobian=jacobian_structure, - hessian=!any( - integrator.autodiff for integrator ∈ integrators if integrator isa QuantumIntegrator - ) - ) - μ∂²f_nnz = length(μ∂²f_structure) - end - - ∂f_nnz = length(∂f_structure) - - if verbose - println(" constructing full dynamics derivative functions...") - end - - @views function F(Z⃗::AbstractVector{R}) where R <: Real - δ = Vector{R}(undef, dynamics_dim * (traj.T - 1)) - Threads.@threads for t = 1:traj.T-1 - zₜ = Z⃗[slice(t, traj.dim)] - zₜ₊₁ = Z⃗[slice(t + 1, traj.dim)] - δ[slice(t, dynamics_dim)] = f(zₜ, zₜ₊₁) - end - return δ - end - - @views function ∂F(Z⃗::AbstractVector{R}) where R <: Real - ∂s = zeros(R, length(∂F_structure)) - Threads.@threads for t = 1:traj.T-1 - zₜ = Z⃗[slice(t, traj.dim)] - zₜ₊₁ = Z⃗[slice(t + 1, traj.dim)] - ∂fₜ = ∂f(zₜ, zₜ₊₁) - for (k, (i, j)) ∈ enumerate(∂f_structure) - ∂s[index(t, k, ∂f_nnz)] = ∂fₜ[i, j] - end - end - return ∂s - end - - if hessian_approximation - μ∂²F = nothing - else - @views μ∂²F = (Z⃗::AbstractVector{<:Real}, μ⃗::AbstractVector{<:Real}) -> begin - μ∂²s = Vector{eltype(Z⃗)}(undef, length(μ∂²F_structure)) - Threads.@threads for t = 1:traj.T-1 - zₜ = Z⃗[slice(t, traj.dim)] - zₜ₊₁ = Z⃗[slice(t + 1, traj.dim)] - μₜ = μ⃗[slice(t, dynamics_dim)] - μₜ∂²fₜ = μ∂²f(zₜ, zₜ₊₁, μₜ) - for (k, (i, j)) ∈ enumerate(μ∂²f_structure) - μ∂²s[index(t, k, μ∂²f_nnz)] = μₜ∂²fₜ[i, j] - end - end - return μ∂²s - end - end - return QuantumDynamics( - integrators, - F, - ∂F, - ∂F_structure, - μ∂²F, - μ∂²F_structure, - dynamics_dim - ) -end - -QuantumDynamics(P::AbstractIntegrator, traj::NamedTrajectory; kwargs...) = - QuantumDynamics([P], traj; kwargs...) - -function QuantumDynamics( - f::Function, - traj::NamedTrajectory; - verbose=false, -) - dynamics_dim = length(f(traj[1].data, traj[2].data)) - - @views function F(Z⃗::AbstractVector{<:Real}) - r = zeros(eltype(Z⃗), dynamics_dim * (traj.T - 1)) - Threads.@threads for t = 1:traj.T-1 - zₜ = Z⃗[slice(t, traj.dim)] - zₜ₊₁ = Z⃗[slice(t + 1, traj.dim)] - r[slice(t, dynamics_dim)] = f(zₜ, zₜ₊₁) - end - return r - end - - # TODO: benchmark Zygote vs ForwardDiff for jacobian - # function ∂f(zₜ, zₜ₊₁) - # ∂zₜf, ∂zₜ₊₁f = Zygote.jacobian(f, zₜ, zₜ₊₁) - # ∂fₜ = hcat(∂zₜf, ∂zₜ₊₁f) - # return ∂fₜ - # end - - @views f̂(zz) = f(zz[1:traj.dim], zz[traj.dim+1:end]) - - ∂f̂(zz) = ForwardDiff.jacobian(f̂, zz) - - ∂f_structure, ∂F_structure, μ∂²f_structure, μ∂²F_structure = - dynamics_structure(∂f̂, traj, dynamics_dim) - - ∂f(zₜ, zₜ₊₁) = ∂f̂([zₜ; zₜ₊₁]) - - ∂f_nnz = length(∂f_structure) - - @views function ∂F(Z⃗::AbstractVector{R}) where R <: Real - ∂ = zeros(R, length(∂F_structure)) - Threads.@threads for t = 1:traj.T-1 - zₜ = Z⃗[slice(t, traj.dim)] - zₜ₊₁ = Z⃗[slice(t + 1, traj.dim)] - ∂fₜ = ∂f(zₜ, zₜ₊₁) - for (k, (i, j)) ∈ enumerate(∂f_structure) - ∂[index(t, k, ∂f_nnz)] = ∂fₜ[i, j] - end - end - return ∂ - end - - μf̂(zz, μ) = dot(μ, f̂(zz)) - - @views function μ∂²f̂(zₜzₜ₊₁, μₜ) - return ForwardDiff.hessian(zz -> μf̂(zz, μₜ), zₜzₜ₊₁) - end - - μ∂²f_nnz = length(μ∂²f_structure) - - @views function μ∂²F(Z⃗::AbstractVector{R}, μ::AbstractVector{R}) where R <: Real - μ∂² = zeros(R, length(μ∂²F_structure)) - Threads.@threads for t = 1:traj.T-1 - zₜzₜ₊₁ = Z⃗[slice(t:t+1, traj.dim)] - μₜ = μ[slice(t, dynamics_dim)] - μ∂²fₜ = μ∂²f̂(zₜzₜ₊₁, μₜ) - for (k, (i, j)) ∈ enumerate(μ∂²f_structure) - μ∂²[index(t, k, μ∂²f_nnz)] = μ∂²fₜ[i, j] - end - end - return μ∂² - end - - return QuantumDynamics(nothing, F, ∂F, ∂F_structure, μ∂²F, μ∂²F_structure, dynamics_dim) -end - -end diff --git a/build/embedded_operators.jl b/build/embedded_operators.jl deleted file mode 100644 index b57caeb4..00000000 --- a/build/embedded_operators.jl +++ /dev/null @@ -1,273 +0,0 @@ -module EmbeddedOperators - -export EmbeddedOperator - -export embed -export unembed -export get_subspace_indices -export get_subspace_leakage_indices -export get_unitary_isomorphism_leakage_indices -export get_unitary_isomorphism_subspace_indices -export get_subspace_identity - -using LinearAlgebra - -using TrajectoryIndexingUtils - -using ..QuantumUtils -using ..QuantumSystems - -function get_subspace_indices( - subspaces::Vector{<:AbstractVector{Int}}, - subsystem_levels::AbstractVector{Int} -) - @assert length(subspaces) == length(subsystem_levels) - - basis = kron([""], [string.(1:level) for level ∈ subsystem_levels]...) - - subspace_indices = findall( - b -> all( - l ∈ subspaces[i] - for (i, l) ∈ enumerate([parse(Int, bᵢ) for bᵢ ∈ b]) - ), - basis - ) - - return subspace_indices -end - -get_subspace_indices(subspace::AbstractVector{Int}, levels::Int) = - get_subspace_indices([subspace], [levels]) - -get_subspace_indices(levels::AbstractVector{Int}; subspace=1:2, kwargs...) = - get_subspace_indices(fill(subspace, length(levels)), levels; kwargs...) - -function get_subspace_leakage_indices( - subspaces::Vector{<:AbstractVector{Int}}, - subsystem_levels::AbstractVector{Int}; -) - subspace_indices = get_subspace_indices(subspaces, subsystem_levels) - return get_subspace_leakage_indices(subspace_indices) -end - -get_subspace_leakage_indices(subspace_indices::AbstractVector{Int}, levels::Int) = - setdiff(1:levels, subspace_indices) - -function get_unitary_isomorphism_subspace_indices( - subspace_indices::AbstractVector{Int}, - subsystem_levels::AbstractVector{Int} -) - N = prod(subsystem_levels) - iso_subspace_indices = Int[] - for sⱼ ∈ subspace_indices - for sᵢ ∈ subspace_indices - push!(iso_subspace_indices, index(sⱼ, sᵢ, 2N)) - end - for sᵢ ∈ subspace_indices - push!(iso_subspace_indices, index(sⱼ, sᵢ + N, 2N)) - end - end - return iso_subspace_indices -end - -function get_unitary_isomorphism_leakage_indices( - subspace_indices::AbstractVector{Int}, - subsystem_levels::AbstractVector{Int} -) - N = prod(subsystem_levels) - leakage_indices = get_subspace_leakage_indices(subspace_indices, N) - iso_leakage_indices = Int[] - for sⱼ ∈ subspace_indices - for lᵢ ∈ leakage_indices - push!(iso_leakage_indices, index(sⱼ, lᵢ, 2N)) - end - for lᵢ ∈ leakage_indices - push!(iso_leakage_indices, index(sⱼ, lᵢ + N, 2N)) - end - end - return iso_leakage_indices -end - - -struct EmbeddedOperator - operator::Matrix{ComplexF64} - subspace_indices::Vector{Int} - subsystem_levels::Vector{Int} -end - -Base.size(op::EmbeddedOperator) = size(op.operator) - -function EmbeddedOperator( - op::AbstractMatrix{<:Number}, - system::QuantumSystem; - subspace=1:size(op, 1) -) - op_embedded = embed(op, system) - return EmbeddedOperator( - op_embedded, - get_subspace_indices(subspace, system.levels), - [system.levels] - ) -end - -function EmbeddedOperator( - op::AbstractMatrix{<:Number}, - system::CompositeQuantumSystem, - op_subsystem_index::Int; - subspaces=fill(1:2, length(system.subsystems)), -) - op_embedded = embed(op, system, op_subsystem_index; subspaces=subspaces) - return EmbeddedOperator( - op_embedded, - get_subspace_indices(subspaces, system.subsystem_levels), - system.subsystem_levels - ) -end - -function EmbeddedOperator( - op::AbstractMatrix{<:Number}, - system::CompositeQuantumSystem, - op_subsystem_indices::AbstractVector{Int}; - subspaces=fill(1:2, length(system.subsystems)), -) - op_embedded = embed(op, system, op_subsystem_indices; subspaces=subspaces) - return EmbeddedOperator( - op_embedded, - get_subspace_indices(subspaces, system.subsystem_levels), - system.subsystem_levels - ) -end - -function Base.:*( - op1::EmbeddedOperator, - op2::EmbeddedOperator -) - @assert size(op1) == size(op2) "Operators must be of the same size." - @assert op1.subspace_indices == op2.subspace_indices "Operators must have the same subspace." - @assert op1.subsystem_levels == op2.subsystem_levels "Operators must have the same subsystem levels." - return EmbeddedOperator( - op1.operator * op2.operator, - op1.subspace_indices, - op1.subsystem_levels - ) -end - -function EmbeddedOperator(op::Symbol, args...; kwargs...) - @assert op ∈ keys(GATES) "Operator must be a valid gate. See QuantumCollocation.QuantumUtils.GATES dict for available gates." - op = GATES[op] - return EmbeddedOperator(op, args...; kwargs...) -end - -function EmbeddedOperator( - ops::AbstractVector{Symbol}, - sys::CompositeQuantumSystem, - op_indices::AbstractVector{Int} -) - ops_embedded = [ - EmbeddedOperator(op, sys, op_indices[i]) - for (op, i) ∈ zip(ops, op_indices) - ] - return *(ops_embedded...) -end - - - - -function get_subspace_identity(op::EmbeddedOperator) - return embed( - Matrix{ComplexF64}(I(length(op.subspace_indices))), - op.subspace_indices, - size(op)[1] - ) -end - -function embed(op::Matrix{ComplexF64}, subspace_indices::AbstractVector{Int}, levels::Int) - op_embedded = zeros(ComplexF64, levels, levels) - op_embedded[subspace_indices, subspace_indices] = op - return op_embedded -end - -function embed(A::AbstractMatrix{<:Number}, op::EmbeddedOperator) - @assert size(A, 1) == size(A, 2) "Operator must be square." - @assert size(A, 1) == length(op.subspace_indices) "Operator size must match subspace size." - return embed(A, op.subspace_indices, size(op)[1]) -end - -function unembed(op::EmbeddedOperator)::Matrix{ComplexF64} - return op.operator[op.subspace_indices, op.subspace_indices] -end - -function get_subspace_leakage_indices(op::EmbeddedOperator) - return get_subspace_leakage_indices(op.subspace_indices, size(op)[1]) -end - -get_unitary_isomorphism_subspace_indices(op::EmbeddedOperator) = - get_unitary_isomorphism_subspace_indices(op.subspace_indices, op.subsystem_levels) - -get_unitary_isomorphism_leakage_indices(op::EmbeddedOperator) = - get_unitary_isomorphism_leakage_indices(op.subspace_indices, op.subsystem_levels) - - -# embed(op::AbstractMatrix) - -function embed( - op::Matrix{ComplexF64}, - sys::QuantumSystem; - subspace=1:size(op, 1) -)::Matrix{ComplexF64} - @assert size(op, 1) == size(op, 2) "Operator must be square." - op_embedded = embed(op, subspace, sys.levels) - return op_embedded -end - -embed(op::AbstractMatrix{<:Number}, sys; kwargs...) = - embed(Matrix{ComplexF64}(op), sys; kwargs...) - - -function embed( - op::Matrix{ComplexF64}, - csys::CompositeQuantumSystem, - op_subsystem_indices::AbstractVector{Int}; - subspaces::Vector{<:AbstractVector{Int}}=fill(1:2, length(csys.subsystems)) -) - @assert size(op, 1) == size(op, 2) "Operator must be square." - @assert all(diff(op_subsystem_indices) .== 1) "op_subsystem_indices must be consecutive (for now)." - - if size(op, 1) == prod(length.(subspaces[op_subsystem_indices])) - Is = Matrix{ComplexF64}.(I.(length.(subspaces))) - Is[op_subsystem_indices[1]] = op - deleteat!(Is, op_subsystem_indices[2:end]) - op = kron(Is...) - else - @assert( - size(op, 1) == prod(length.(subspaces)), - """\n - Operator size ($(size(op, 1))) must match product of subsystem subspaces ($(prod(length.(subspaces)))). Or - """ - ) - end - - subspace_indices = get_subspace_indices(subspaces, csys.subsystem_levels) - - op_embedded = embed(op, subspace_indices, csys.levels) - - return op_embedded -end - -function embed( - op::Matrix{ComplexF64}, - csys::CompositeQuantumSystem, - op_subsystem_index::Int; - kwargs... -) - return embed(op, csys, [op_subsystem_index]; kwargs...) -end - -embed(op::AbstractMatrix{<:Number}, sys::AbstractQuantumSystem, args...; kwargs...) = - embed(Matrix{ComplexF64}(op), sys, args...; kwargs...) - - - - - -end diff --git a/build/evaluators.jl b/build/evaluators.jl deleted file mode 100644 index 5761a355..00000000 --- a/build/evaluators.jl +++ /dev/null @@ -1,175 +0,0 @@ -module Evaluators - -export PicoEvaluator - -using ..QuantumSystems -using ..Integrators -using ..Dynamics -using ..Objectives -using ..Constraints - -using NamedTrajectories -using MathOptInterface -const MOI = MathOptInterface - -mutable struct PicoEvaluator <: MOI.AbstractNLPEvaluator - trajectory::NamedTrajectory - objective::Objective - dynamics::QuantumDynamics - n_dynamics_constraints::Int - nonlinear_constraints::Vector{<:NonlinearConstraint} - n_nonlinear_constraints::Int - eval_hessian::Bool - - function PicoEvaluator( - trajectory::NamedTrajectory, - objective::Objective, - dynamics::QuantumDynamics, - nonlinear_constraints::Vector{<:NonlinearConstraint}, - eval_hessian::Bool - ) - n_dynamics_constraints = dynamics.dim * (trajectory.T - 1) - n_nonlinear_constraints = sum(con.dim for con ∈ nonlinear_constraints; init=0) - - return new( - trajectory, - objective, - dynamics, - n_dynamics_constraints, - nonlinear_constraints, - n_nonlinear_constraints, - eval_hessian - ) - end -end - -MOI.initialize(::PicoEvaluator, features) = nothing - -function MOI.features_available(evaluator::PicoEvaluator) - if evaluator.eval_hessian - return [:Grad, :Jac, :Hess] - else - return [:Grad, :Jac] - end -end - - -# objective and gradient - -@views function MOI.eval_objective( - evaluator::PicoEvaluator, - Z⃗::AbstractVector -) - return evaluator.objective.L(Z⃗, evaluator.trajectory) -end - -@views function MOI.eval_objective_gradient( - evaluator::PicoEvaluator, - ∇::AbstractVector, - Z⃗::AbstractVector -) - ∇[:] = evaluator.objective.∇L(Z⃗, evaluator.trajectory) - return nothing -end - - -# constraints and Jacobian - -@views function MOI.eval_constraint( - evaluator::PicoEvaluator, - g::AbstractVector, - Z⃗::AbstractVector -) - g[1:evaluator.n_dynamics_constraints] = evaluator.dynamics.F(Z⃗) - offset = evaluator.n_dynamics_constraints - for con ∈ evaluator.nonlinear_constraints - g[offset .+ (1:con.dim)] = con.g(Z⃗) - offset += con.dim - end - return nothing -end - -function MOI.jacobian_structure(evaluator::PicoEvaluator) - dynamics_structure = evaluator.dynamics.∂F_structure - row_offset = evaluator.n_dynamics_constraints - nl_constraint_structure = [] - for con ∈ evaluator.nonlinear_constraints - con_structure = [(i + row_offset, j) for (i, j) in con.∂g_structure] - push!(nl_constraint_structure, con_structure) - row_offset += con.dim - end - return vcat(dynamics_structure, nl_constraint_structure...) -end - -@views function MOI.eval_constraint_jacobian( - evaluator::PicoEvaluator, - J::AbstractVector, - Z⃗::AbstractVector -) - ∂s_dynamics = evaluator.dynamics.∂F(Z⃗) - for (k, ∂ₖ) in enumerate(∂s_dynamics) - J[k] = ∂ₖ - end - offset = length(∂s_dynamics) - for con ∈ evaluator.nonlinear_constraints - ∂s_con = con.∂g(Z⃗) - for (k, ∂ₖ) in enumerate(∂s_con) - J[offset + k] = ∂ₖ - end - offset += length(∂s_con) - end - return nothing -end - - -# Hessian of the Lagrangian - -function MOI.hessian_lagrangian_structure(evaluator::PicoEvaluator) - objective_structure = evaluator.objective.∂²L_structure(evaluator.trajectory) - dynamics_structure = evaluator.dynamics.μ∂²F_structure - nl_constraint_structure = [con.μ∂²g_structure for con ∈ evaluator.nonlinear_constraints] - return vcat(objective_structure, dynamics_structure, nl_constraint_structure...) -end - -@views function MOI.eval_hessian_lagrangian( - evaluator::PicoEvaluator, - H::AbstractVector{T}, - Z⃗::AbstractVector{T}, - σ::T, - μ::AbstractVector{T} -) where T - - σ∂²Ls = σ * evaluator.objective.∂²L(Z⃗, evaluator.trajectory) - - for (k, σ∂²Lₖ) in enumerate(σ∂²Ls) - H[k] = σ∂²Lₖ - end - - μ_dynamics = μ[1:evaluator.n_dynamics_constraints] - - μ_offset = evaluator.n_dynamics_constraints - - offset = length(evaluator.objective.∂²L_structure(evaluator.trajectory)) - - μ∂²Fs = evaluator.dynamics.μ∂²F(Z⃗, μ_dynamics) - - for (k, μ∂²Fₖ) in enumerate(μ∂²Fs) - H[offset + k] = μ∂²Fₖ - end - - offset += length(evaluator.dynamics.μ∂²F_structure) - - for con ∈ evaluator.nonlinear_constraints - μ_con = μ[μ_offset .+ (1:con.dim)] - μ∂²gs = con.μ∂²g(Z⃗, μ_con) - for (k, μ∂²gₖ) in enumerate(μ∂²gs) - H[offset + k] = μ∂²gₖ - end - offset += length(μ∂²gs) - μ_offset += con.dim - end - - return nothing -end - -end diff --git a/build/integrators.jl b/build/integrators.jl deleted file mode 100644 index 3866e596..00000000 --- a/build/integrators.jl +++ /dev/null @@ -1,1161 +0,0 @@ -module Integrators - -export AbstractIntegrator - -export QuantumIntegrator - -export QuantumPadeIntegrator -export QuantumStatePadeIntegrator -export UnitaryPadeIntegrator - -export DerivativeIntegrator - -export state -export controls -export timestep -export comps -export dim - -export jacobian -export hessian_of_the_lagrangian - -export nth_order_pade -export fourth_order_pade -export sixth_order_pade -export eighth_order_pade -export tenth_order_pade - -using TrajectoryIndexingUtils -using ..QuantumSystems -using ..QuantumUtils - -using NamedTrajectories -using LinearAlgebra -using SparseArrays - - - -function nth_order_pade(Gₜ::Matrix, n::Int) - @assert n ∈ keys(PADE_COEFFICIENTS) - coeffs = PADE_COEFFICIENTS[n] - Id = 1.0I(size(Gₜ, 1)) - p = n ÷ 2 - G_powers = [Gₜ^i for i = 1:p] - B = Id + sum((-1)^k * coeffs[k] * G_powers[k] for k = 1:p) - F = Id + sum(coeffs[k] * G_powers[k] for k = 1:p) - return inv(B) * F -end - - - -fourth_order_pade(Gₜ::Matrix) = nth_order_pade(Gₜ, 4) -sixth_order_pade(Gₜ::Matrix) = nth_order_pade(Gₜ, 6) -eighth_order_pade(Gₜ::Matrix) = nth_order_pade(Gₜ, 8) -tenth_order_pade(Gₜ::Matrix) = nth_order_pade(Gₜ, 10) - -function compute_powers(G::AbstractMatrix{T}, order::Int) where T <: Number - powers = Array{typeof(G)}(undef, order) - powers[1] = G - for k = 2:order - powers[k] = powers[k-1] * G - end - return powers -end - - -# G(a) helper function -function G( - a::AbstractVector, - G_drift::AbstractMatrix, - G_drives::AbstractVector{<:AbstractMatrix} -) - return G_drift + sum(a .* G_drives) -end - -const Id2 = 1.0 * I(2) -const Im2 = 1.0 * [0 -1; 1 0] - -anticomm(A::AbstractMatrix{R}, B::AbstractMatrix{R}) where R <: Number = A * B + B * A - -function anticomm( - A::AbstractMatrix{R}, - Bs::AbstractVector{<:AbstractMatrix{R}} -) where R <: Number - return [anticomm(A, B) for B in Bs] -end - -function anticomm( - As::AbstractVector{<:AbstractMatrix{R}}, - Bs::AbstractVector{<:AbstractMatrix{R}} -) where R <: Number - @assert length(As) == length(Bs) - n = length(As) - anticomms = Matrix{Matrix{R}}(undef, n, n) - for i = 1:n - for j = 1:n - anticomms[i, j] = anticomm(As[i], Bs[j]) - end - end - return anticomms -end - -pade(n, k) = (factorial(n + k) // (factorial(n - k) * factorial(k) * 2^n)) -pade_coeffs(n) = [pade(n, k) for k = n:-1:0][2:end] // pade(n, n) - -@inline function operator( - a::AbstractVector{<:Real}, - A_drift::Matrix{<:Real}, - A_drives::Vector{<:Matrix{<:Real}} -) - return A_drift + sum(a .* A_drives) -end - -@inline function operator_anticomm_operator( - a::AbstractVector{<:Real}, - A_drift_anticomm_B_drift::Matrix{<:Real}, - A_drift_anticomm_B_drives::Vector{<:Matrix{<:Real}}, - B_drift_anticomm_A_drives::Vector{<:Matrix{<:Real}}, - A_drives_anticomm_B_drives::Matrix{<:Matrix{<:Real}}, - n_drives::Int -) - A_anticomm_B = A_drift_anticomm_B_drift - for i = 1:n_drives - aⁱ = a[i] - A_anticomm_B += aⁱ * A_drift_anticomm_B_drives[i] - A_anticomm_B += aⁱ * B_drift_anticomm_A_drives[i] - A_anticomm_B += aⁱ^2 * A_drives_anticomm_B_drives[i, i] - for j = i+1:n_drives - aʲ = a[j] - A_anticomm_B += 2 * aⁱ * aʲ * A_drives_anticomm_B_drives[i, j] - end - end - return A_anticomm_B -end - -@inline function operator_anticomm_term( - a::AbstractVector{<:Real}, - A_drift_anticomm_B_drives::Vector{<:Matrix{<:Real}}, - A_drives_anticomm_B_drives::Matrix{<:Matrix{<:Real}}, - n_drives::Int, - j::Int -) - A_anticomm_Bⱼ = A_drift_anticomm_B_drives[j] - for i = 1:n_drives - aⁱ = a[i] - A_anticomm_Bⱼ += aⁱ * A_drives_anticomm_B_drives[i, j] - end - return A_anticomm_Bⱼ -end - -function build_anticomms( - G_drift::AbstractMatrix{R}, - G_drives::Vector{<:AbstractMatrix{R}}, - n_drives::Int) where R <: Number - - drive_anticomms = fill( - zeros(size(G_drift)), - n_drives, - n_drives - ) - - for j = 1:n_drives - for k = 1:j - if k == j - drive_anticomms[k, k] = 2 * G_drives[k]^2 - else - drive_anticomms[k, j] = - anticomm(G_drives[k], G_drives[j]) - end - end - end - - drift_anticomms = [ - anticomm(G_drive, G_drift) - for G_drive in G_drives - ] - - return Symmetric(drive_anticomms), drift_anticomms -end - -# -# integrator types -# - -abstract type AbstractIntegrator end - -abstract type QuantumIntegrator <: AbstractIntegrator end - -abstract type QuantumPadeIntegrator <: QuantumIntegrator end - - -function comps(P::AbstractIntegrator, traj::NamedTrajectory) - state_comps = traj.components[state(P)] - u = controls(P) - if u isa Tuple - control_comps = Tuple(traj.components[uᵢ] for uᵢ ∈ u) - else - control_comps = traj.components[u] - end - if traj.timestep isa Float64 - return state_comps, control_comps - else - timestep_comp = traj.components[traj.timestep] - return state_comps, control_comps, timestep_comp - end -end - -dim(integrator::AbstractIntegrator) = integrator.dim -dim(integrators::AbstractVector{<:AbstractIntegrator}) = sum(dim, integrators) - - -### -### Derivative Integrator -### - -struct DerivativeIntegrator <: AbstractIntegrator - variable::Symbol - derivative::Symbol - dim::Int -end - -function DerivativeIntegrator( - variable::Symbol, - derivative::Symbol, - traj::NamedTrajectory -) - return DerivativeIntegrator(variable, derivative, traj.dims[variable]) -end - -state(integrator::DerivativeIntegrator) = integrator.variable -controls(integrator::DerivativeIntegrator) = integrator.derivative - -@views function (D::DerivativeIntegrator)( - zₜ::AbstractVector, - zₜ₊₁::AbstractVector, - traj::NamedTrajectory -) - xₜ = zₜ[traj.components[D.variable]] - xₜ₊₁ = zₜ₊₁[traj.components[D.variable]] - dxₜ = zₜ[traj.components[D.derivative]] - if traj.timestep isa Symbol - Δtₜ = zₜ[traj.components[traj.timestep]][1] - else - Δtₜ = traj.timestep - end - return xₜ₊₁ - xₜ - Δtₜ * dxₜ -end - -@views function jacobian( - D::DerivativeIntegrator, - zₜ::AbstractVector, - zₜ₊₁::AbstractVector, - traj::NamedTrajectory -) - dxₜ = zₜ[traj.components[D.derivative]] - if traj.timestep isa Symbol - Δtₜ = zₜ[traj.components[traj.timestep]][1] - else - Δtₜ = traj.timestep - end - ∂xₜD = sparse(-1.0I(D.dim)) - ∂xₜ₊₁D = sparse(1.0I(D.dim)) - ∂dxₜD = sparse(-Δtₜ * I(D.dim)) - ∂ΔtₜD = -dxₜ - return ∂xₜD, ∂xₜ₊₁D, ∂dxₜD, ∂ΔtₜD -end - -# key is the order of the integrator -# and the value are the Pade coefficients -# for each term -const PADE_COEFFICIENTS = Dict{Int,Vector{Float64}}( - 4 => [1/2, 1/12], - 6 => [1/2, 1/10, 1/120], - 8 => [1/2, 3/28, 1/84, 1/1680], - 10 => [1/2, 1/9, 1/72, 1/1008, 1/30240] -) - -""" -""" -struct UnitaryPadeIntegrator <: QuantumPadeIntegrator - I_2N::SparseMatrixCSC{Float64, Int} - G_drift::Matrix{Float64} - G_drives::Vector{Matrix{Float64}} - G_drive_anticomms::Union{Nothing, Symmetric} - G_drift_anticomms::Union{Nothing, Vector{Matrix{Float64}}} - unitary_symb::Union{Symbol, Nothing} - drive_symb::Union{Symbol, Tuple{Vararg{Symbol}}, Nothing} - n_drives::Int - N::Int - dim::Int - order::Int - autodiff::Bool - G::Union{Function, Nothing} - - """ - UnitaryPadeIntegrator( - sys::AbstractQuantumSystem, - unitary_symb::Symbol, - drive_symb::Union{Symbol,Tuple{Vararg{Symbol}}}; - order::Int=4, - autodiff::Bool=order != 4 - ) where R <: Real - - Construct a `UnitaryPadeIntegrator` for the quantum system `sys`. - - # Examples - - ## a bare integrator - ```julia - P = UnitaryPadeIntegrator(sys) - ``` - - ## for a single drive `a`: - ```julia - P = UnitaryPadeIntegrator(sys, :Ũ⃗, :a) - ``` - - ## for two drives `α` and `γ`, order `4`, and autodiffed: - ```julia - P = UnitaryPadeIntegrator(sys, :Ũ⃗, (:α, :γ); order=4, autodiff=true) - ``` - - # Arguments - - `sys::AbstractQuantumSystem`: the quantum system - - `unitary_symb::Union{Symbol,Nothing}=nothing`: the symbol for the unitary - - `drive_symb::Union{Symbol,Tuple{Vararg{Symbol}},Nothing}=nothing`: the symbol(s) for the drives - - `order::Int=4`: the order of the Pade approximation. Must be in `[4, 6, 8, 10]`. If order is not `4` and `autodiff` is `false`, then the integrator will use the hand-coded fourth order derivatives. - - `autodiff::Bool=order != 4`: whether to use automatic differentiation to compute the jacobian and hessian of the lagrangian - - """ - function UnitaryPadeIntegrator( - sys::AbstractQuantumSystem, - unitary_symb::Union{Symbol,Nothing}=nothing, - drive_symb::Union{Symbol,Tuple{Vararg{Symbol}},Nothing}=nothing; - order::Int=4, - autodiff::Bool=false, - G::Union{Function, Nothing}=nothing, - ) - @assert order ∈ [4, 6, 8, 10] "order must be in [4, 6, 8, 10]" - @assert !isnothing(unitary_symb) "must specify unitary symbol" - @assert !isnothing(drive_symb) "must specify drive symbol" - - n_drives = length(sys.H_drives) - N = size(sys.H_drift, 1) - dim = 2N^2 - - I_2N = sparse(I(2N)) - - G_drift = sys.G_drift - G_drives = sys.G_drives - - drive_anticomms, drift_anticomms = - order == 4 ? build_anticomms(G_drift, G_drives, n_drives) : (nothing, nothing) - - return new( - I_2N, - G_drift, - G_drives, - drive_anticomms, - drift_anticomms, - unitary_symb, - drive_symb, - n_drives, - N, - dim, - order, - autodiff, - G, - ) - end -end - -state(P::UnitaryPadeIntegrator) = P.unitary_symb -controls(P::UnitaryPadeIntegrator) = P.drive_symb - -struct QuantumStatePadeIntegrator <: QuantumPadeIntegrator - I_2N::SparseMatrixCSC{Float64, Int} - G_drift::Matrix{Float64} - G_drives::Vector{Matrix{Float64}} - G_drive_anticomms::Union{Symmetric, Nothing} - G_drift_anticomms::Union{Vector{Matrix{Float64}}, Nothing} - state_symb::Union{Symbol,Nothing} - drive_symb::Union{Symbol,Tuple{Vararg{Symbol}},Nothing} - n_drives::Int - N::Int - dim::Int - order::Int - autodiff::Bool - G::Function - - """ - QuantumStatePadeIntegrator( - sys::AbstractQuantumSystem, - state_symb::Union{Symbol,Nothing}=nothing, - drive_symb::Union{Symbol,Tuple{Vararg{Symbol}},Nothing}=nothing, - timestep_symb::Union{Symbol,Nothing}=nothing; - order::Int=4, - autodiff::Bool=false - ) where R <: Real - - Construct a `QuantumStatePadeIntegrator` for the quantum system `sys`. - - # Examples - - ## for a single drive `a`: - ```julia - P = QuantumStatePadeIntegrator(sys, :ψ̃, :a) - ``` - - ## for two drives `α` and `γ`, order `8`, and autodiffed: - ```julia - P = QuantumStatePadeIntegrator(sys, :ψ̃, (:α, :γ); order=8, autodiff=true) - ``` - - # Arguments - - `sys::AbstractQuantumSystem`: the quantum system - - `state_symb::Symbol`: the symbol for the quantum state - - `drive_symb::Union{Symbol,Tuple{Vararg{Symbol}}}`: the symbol(s) for the drives - - `order::Int=4`: the order of the Pade approximation. Must be in `[4, 6, 8, 10]`. If order is not `4` and `autodiff` is `false`, then the integrator will use the hand-coded fourth order derivatives. - - `autodiff::Bool=false`: whether to use automatic differentiation to compute the jacobian and hessian of the lagrangian - """ - function QuantumStatePadeIntegrator( - sys::AbstractQuantumSystem, - state_symb::Union{Symbol,Nothing}=nothing, - drive_symb::Union{Symbol,Tuple{Vararg{Symbol}},Nothing}=nothing; - order::Int=4, - autodiff::Bool=order != 4, - G::Union{Function, Nothing}=nothing, - ) - @assert order ∈ [4, 6, 8, 10] "order must be in [4, 6, 8, 10]" - @assert !isnothing(state_symb) "state_symb must be specified" - @assert !isnothing(drive_symb) "drive_symb must be specified" - n_drives = length(sys.H_drives_real) - N = size(sys.H_drift_real, 1) - dim = 2N - I_2N = sparse(I(2N)) - - G_drift = sys.G_drift - G_drives = sys.G_drives - - drive_anticomms, drift_anticomms = - order == 4 ? build_anticomms(G_drift, G_drives, n_drives) : (nothing, nothing) - - return new( - I_2N, - G_drift, - G_drives, - drive_anticomms, - drift_anticomms, - state_symb, - drive_symb, - n_drives, - N, - dim, - order, - autodiff, - G - ) - end -end - -state(P::QuantumStatePadeIntegrator) = P.state_symb -controls(P::QuantumStatePadeIntegrator) = P.drive_symb - -function nth_order_pade( - P::UnitaryPadeIntegrator, - Ũ⃗ₜ₊₁::AbstractVector, - Ũ⃗ₜ::AbstractVector, - aₜ::AbstractVector, - Δt::Real -) - Ũₜ₊₁ = iso_vec_to_iso_operator(Ũ⃗ₜ₊₁) - Ũₜ = iso_vec_to_iso_operator(Ũ⃗ₜ) - Gₜ = isnothing(P.G) ? G(aₜ, P.G_drift, P.G_drives) : P.G(aₜ, P.G_drift, P.G_drives) - n = P.order ÷ 2 - Gₜ_powers = compute_powers(Gₜ, n) - B = P.I_2N + sum([ - (-1)^k * PADE_COEFFICIENTS[P.order][k] * Δt^k * Gₜ_powers[k] - for k = 1:n - ]) - F = P.I_2N + sum([ - PADE_COEFFICIENTS[P.order][k] * Δt^k * Gₜ_powers[k] - for k = 1:n - ]) - δŨ = B * Ũₜ₊₁ - F * Ũₜ - return iso_operator_to_iso_vec(δŨ) -end - -@views function(P::UnitaryPadeIntegrator)( - zₜ::AbstractVector, - zₜ₊₁::AbstractVector, - traj::NamedTrajectory -) - Ũ⃗ₜ₊₁ = zₜ₊₁[traj.components[P.unitary_symb]] - Ũ⃗ₜ = zₜ[traj.components[P.unitary_symb]] - if traj.timestep isa Symbol - Δtₜ = zₜ[traj.components[traj.timestep]][1] - else - Δtₜ = traj.timestep - end - if P.drive_symb isa Tuple - aₜ = vcat([zₜ[traj.components[s]] for s in P.drive_symb]...) - else - aₜ = zₜ[traj.components[P.drive_symb]] - end - return nth_order_pade(P, Ũ⃗ₜ₊₁, Ũ⃗ₜ, aₜ, Δtₜ) -end - - - -function nth_order_pade( - P::QuantumStatePadeIntegrator, - ψ̃ₜ₊₁::AbstractVector, - ψ̃ₜ::AbstractVector, - aₜ::AbstractVector, - Δt::Real -) - Gₜ = isnothing(P.G) ? G(aₜ, P.G_drift, P.G_drives) : P.G(aₜ, P.G_drift, P.G_drives) - n = P.order ÷ 2 - Gₜ_powers = compute_powers(Gₜ, n) - B = P.I_2N + sum([ - (-1)^k * PADE_COEFFICIENTS[P.order][k] * Δt^k * Gₜ_powers[k] - for k = 1:n - ]) - F = P.I_2N + sum([ - PADE_COEFFICIENTS[P.order][k] * Δt^k * Gₜ_powers[k] - for k = 1:n - ]) - δψ̃ = B * ψ̃ₜ₊₁ - F * ψ̃ₜ - return δψ̃ -end - - -@views function(P::QuantumStatePadeIntegrator)( - zₜ::AbstractVector, - zₜ₊₁::AbstractVector, - traj::NamedTrajectory -) - ψ̃ₜ₊₁ = zₜ₊₁[traj.components[P.state_symb]] - ψ̃ₜ = zₜ[traj.components[P.state_symb]] - if P.drive_symb isa Tuple - aₜ = vcat([zₜ[traj.components[s]] for s in P.drive_symb]...) - else - aₜ = zₜ[traj.components[P.drive_symb]] - end - if traj.timestep isa Symbol - Δtₜ = zₜ[traj.components[traj.timestep]][1] - else - Δtₜ = traj.timestep - end - return nth_order_pade(P, ψ̃ₜ₊₁, ψ̃ₜ, aₜ, Δtₜ) -end - -# aₜ should be a vector with all the controls. concatenate all the named traj controls -function ∂aₜ( - P::UnitaryPadeIntegrator, - Ũ⃗ₜ₊₁::AbstractVector{T}, - Ũ⃗ₜ::AbstractVector{T}, - aₜ::AbstractVector{T}, - Δtₜ::Real, -) where T <: Real - - if P.autodiff || !isnothing(P.G) - - # then we need to use the nth_order_pade function - # which handles nonlinear G and higher order Pade integrators - - f(a) = nth_order_pade(P, Ũ⃗ₜ₊₁, Ũ⃗ₜ, a, Δtₜ) - ∂aP = ForwardDiff.jacobian(f, aₜ) - - # otherwise we don't have a nonlinear G or are fine with using - # the fourth order derivatives - - elseif P.order == 4 - n_drives = length(aₜ) - ∂aP = Array{T}(undef, P.dim, n_drives) - isodim = 2*P.N - for j = 1:n_drives - Gʲ = P.G_drives[j] - Gʲ_anticomm_Gₜ = - G(aₜ, P.G_drift_anticomms[j], P.G_drive_anticomms[:, j]) - for i = 0:P.N-1 - ψ̃ⁱₜ₊₁ = @view Ũ⃗ₜ₊₁[i * isodim .+ (1:isodim)] - ψ̃ⁱₜ = @view Ũ⃗ₜ[i * isodim .+ (1:isodim)] - ∂aP[i*isodim .+ (1:isodim), j] = - -Δtₜ / 2 * Gʲ * (ψ̃ⁱₜ₊₁ + ψ̃ⁱₜ) + - Δtₜ^2 / 12 * Gʲ_anticomm_Gₜ * (ψ̃ⁱₜ₊₁ - ψ̃ⁱₜ) - end - end - else - ## higher order pade code goes here - end - return ∂aP -end - - -function ∂aₜ( - P::QuantumStatePadeIntegrator, - ψ̃ₜ₊₁::AbstractVector{T}, - ψ̃ₜ::AbstractVector{T}, - aₜ::AbstractVector{T}, - Δtₜ::Real, -) where T <: Real - if P.autodiff || !isnothing(P.G) - - # then we need to use the nth_order_pade function - # which handles nonlinear G and higher order Pade integrators - - f(a) = nth_order_pade(P, ψ̃ₜ₊₁, ψ̃ₜ, a, Δtₜ) - ∂aP = ForwardDiff.jacobian(f, aₜ) - - # otherwise we don't have a nonlinear G or are fine with using - # the fourth order derivatives - - elseif P.order == 4 - n_drives = length(aₜ) - ∂aP = zeros(P.dim, n_drives) - for j = 1:n_drives - Gʲ = P.G_drives[j] - Gʲ_anticomm_Gₜ = - G(aₜ, P.G_drift_anticomms[j], P.G_drive_anticomms[:, j]) - ∂aP[:, j] = - -Δtₜ / 2 * Gʲ * (ψ̃ₜ₊₁ + ψ̃ₜ) + - Δtₜ^2 / 12 * Gʲ_anticomm_Gₜ * (ψ̃ₜ₊₁ - ψ̃ₜ) - end - else - ### code for arbitrary Pade goes here - end - return ∂aP -end - - - - -function ∂Δtₜ( - P::UnitaryPadeIntegrator, - Ũ⃗ₜ₊₁::AbstractVector, - Ũ⃗ₜ::AbstractVector, - aₜ::AbstractVector, - Δtₜ::Real -) - - Gₜ = isnothing(P.G) ? G(aₜ, P.G_drift, P.G_drives) : P.G(aₜ) - Ũₜ₊₁ = iso_vec_to_iso_operator(Ũ⃗ₜ₊₁) - Ũₜ = iso_vec_to_iso_operator(Ũ⃗ₜ) - if P.order == 4 - ∂ΔtₜP_operator = -1/2 * Gₜ * (Ũₜ₊₁ + Ũₜ) + 1/6 * Δtₜ * Gₜ^2 * (Ũₜ₊₁ - Ũₜ) - ∂ΔtₜP = iso_operator_to_iso_vec(∂ΔtₜP_operator) - else - n = P.order ÷ 2 - Gₜ_powers = compute_powers(Gₜ, n) - B = sum([ - (-1)^k * k * PADE_COEFFICIENTS[P.order][k] * Δtₜ^(k-1) * Gₜ_powers[k] - for k = 1:n - ]) - F = sum([ - k * PADE_COEFFICIENTS[P.order][k] * Δtₜ^(k-1) * Gₜ_powers[k] - for k = 1:n - ]) - ∂ΔtₜP_operator = B * Ũₜ₊₁ - F * Ũₜ - ∂ΔtₜP = iso_operator_to_iso_vec(∂ΔtₜP_operator) - end - - return ∂ΔtₜP -end - -function ∂Δtₜ( - P::QuantumStatePadeIntegrator, - ψ̃ₜ₊₁::AbstractVector, - ψ̃ₜ::AbstractVector, - aₜ::AbstractVector, - Δtₜ::Real -) - - Gₜ = isnothing(P.G) ? G(aₜ, P.G_drift, P.G_drives) : P.G(aₜ) - if P.order==4 - ∂ΔtₜP = -1/2 * Gₜ * (ψ̃ₜ₊₁ + ψ̃ₜ) + 1/6 * Δtₜ * Gₜ^2 * (ψ̃ₜ₊₁ - ψ̃ₜ) - else - n = P.order ÷ 2 - Gₜ_powers = [Gₜ^i for i in 1:n] - B = sum([(-1)^k * k * PADE_COEFFICIENTS[P.order][k] * Δtₜ^(k-1) * Gₜ_powers[k] for k = 1:n]) - F = sum([k * PADE_COEFFICIENTS[P.order][k] * Δtₜ^(k-1) * Gₜ_powers[k] for k = 1:n]) - ∂ΔtₜP = B*ψ̃ₜ₊₁ - F*ψ̃ₜ - end - return ∂ΔtₜP -end - - -@views function jacobian( - P::UnitaryPadeIntegrator, - zₜ::AbstractVector{T}, - zₜ₊₁::AbstractVector{T}, - traj::NamedTrajectory -) where T <: Number - free_time = traj.timestep isa Symbol - - Ũ⃗ₜ₊₁ = zₜ₊₁[traj.components[P.unitary_symb]] - Ũ⃗ₜ = zₜ[traj.components[P.unitary_symb]] - - Δtₜ = free_time ? zₜ[traj.components[traj.timestep]][1] : traj.timestep - - if P.drive_symb isa Tuple - inds = [traj.components[s] for s in P.drive_symb] - inds = vcat(collect.(inds)...) - else - inds = traj.components[P.drive_symb] - end - - for i = 1:length(inds) - 1 - @assert inds[i] + 1 == inds[i + 1] "Controls must be in order" - end - - aₜ = zₜ[inds] - ∂aₜP = ∂aₜ(P, Ũ⃗ₜ₊₁, Ũ⃗ₜ, aₜ, Δtₜ) - if free_time - ∂ΔtₜP = ∂Δtₜ(P, Ũ⃗ₜ₊₁, Ũ⃗ₜ, aₜ, Δtₜ) - end - - ∂Ũ⃗ₜP = spzeros(T, P.dim, P.dim) - ∂Ũ⃗ₜ₊₁P = spzeros(T, P.dim, P.dim) - Gₜ = isnothing(P.G) ? G(aₜ, P.G_drift, P.G_drives) : P.G(aₜ, P.G_drift, P.G_drives) - n = P.order ÷ 2 - - # can memoize this chunk of code, prly memoize G powers - Gₜ_powers = compute_powers(Gₜ, n) - B = P.I_2N + sum([(-1)^k * PADE_COEFFICIENTS[P.order][k] * Δtₜ^k * Gₜ_powers[k] for k = 1:n]) - F = P.I_2N + sum([PADE_COEFFICIENTS[P.order][k] * Δtₜ^k * Gₜ_powers[k] for k = 1:n]) - - ∂Ũ⃗ₜ₊₁P = blockdiag(fill(sparse(B), P.N)...) - ∂Ũ⃗ₜP = blockdiag(fill(sparse(-F), P.N)...) - - if free_time - return ∂Ũ⃗ₜP, ∂Ũ⃗ₜ₊₁P, ∂aₜP, ∂ΔtₜP - else - return ∂Ũ⃗ₜP, ∂Ũ⃗ₜ₊₁P, ∂aₜP - end -end - -@views function jacobian( - P::QuantumStatePadeIntegrator, - zₜ::AbstractVector, - zₜ₊₁::AbstractVector, - traj::NamedTrajectory -) - free_time = traj.timestep isa Symbol - - ψ̃ₜ₊₁ = zₜ₊₁[traj.components[P.state_symb]] - ψ̃ₜ = zₜ[traj.components[P.state_symb]] - - - Δtₜ = free_time ? zₜ[traj.components[traj.timestep]][1] : traj.timestep - - if P.drive_symb isa Tuple - inds = [traj.components[s] for s in P.drive_symb] - inds = vcat(collect.(inds)...) - else - inds = traj.components[P.drive_symb] - end - - for i = 1:length(inds) - 1 - @assert inds[i] + 1 == inds[i + 1] "Controls must be in order" - end - - aₜ = zₜ[inds] - - ∂aₜP = ∂aₜ(P, ψ̃ₜ₊₁, ψ̃ₜ, aₜ, Δtₜ) - if free_time - ∂ΔtₜP = ∂Δtₜ(P, ψ̃ₜ₊₁, ψ̃ₜ, aₜ, Δtₜ) - end - - Gₜ = isnothing(P.G) ? G(aₜ, P.G_drift, P.G_drives) : P.G(aₜ, P.G_drift, P.G_drives) - n = P.order ÷ 2 - Gₜ_powers = compute_powers(Gₜ, n) - B = P.I_2N + sum([(-1)^k * PADE_COEFFICIENTS[P.order][k] * Δtₜ^k * Gₜ_powers[k] for k = 1:n]) - F = P.I_2N + sum([PADE_COEFFICIENTS[P.order][k] * Δtₜ^k * Gₜ_powers[k] for k = 1:n]) - - ∂ψ̃ₜP = -F - ∂ψ̃ₜ₊₁P = B - - if free_time - return ∂ψ̃ₜP, ∂ψ̃ₜ₊₁P, ∂aₜP, ∂ΔtₜP - else - return ∂ψ̃ₜP, ∂ψ̃ₜ₊₁P, ∂aₜP - end -end - - -# --------------------------------------- -# Hessian of the Lagrangian -# --------------------------------------- - -#calculate a deriv first and then indexing game -function μ∂aₜ∂Ũ⃗ₜ( - P::UnitaryPadeIntegrator, - aₜ::AbstractVector{T}, - Δtₜ::Real, - μₜ::AbstractVector{T}, -) where T <: Real - - n_drives = P.n_drives - - if P.autodiff || !isnothing(P.G) - - elseif P.order == 4 - μ∂aₜ∂Ũ⃗ₜP = Array{T}(undef, P.dim, n_drives) - - for j = 1:n_drives - Gʲ = P.G_drives[j] - Ĝʲ = G(aₜ, P.G_drift_anticomms[j], P.G_drive_anticomms[:, j]) - ∂aₜ∂Ũ⃗ₜ_block_i = -(Δtₜ / 2 * Gʲ + Δtₜ^2 / 12 * Ĝʲ) - # sparse is necessary since blockdiag doesn't accept dense matrices - ∂aₜ∂Ũ⃗ₜ = blockdiag(fill(sparse(∂aₜ∂Ũ⃗ₜ_block_i), P.N)...) - μ∂aₜ∂Ũ⃗ₜP[:, j] = ∂aₜ∂Ũ⃗ₜ' * μₜ - end - else - ## higher order pade goes here - end - return μ∂aₜ∂Ũ⃗ₜP -end - -function μ∂Ũ⃗ₜ₊₁∂aₜ( - P::UnitaryPadeIntegrator, - aₜ::AbstractVector{T}, - Δtₜ::Real, - μₜ::AbstractVector{T}, -) where T <: Real - - n_drives = P.n_drives - μ∂Ũ⃗ₜ₊₁∂aₜP = zeros(T, n_drives, P.dim) - - for j = 1:n_drives - Gʲ = P.G_drives[j] - Ĝʲ = G(aₜ, P.G_drift_anticomms[j], P.G_drive_anticomms[:, j]) - ∂Ũ⃗ₜ₊₁∂aₜ_block_i = -Δtₜ / 2 * Gʲ + Δtₜ^2 / 12 * Ĝʲ - # sparse is necessary since blockdiag doesn't accept dense matrices - ∂Ũ⃗ₜ₊₁∂aₜ = blockdiag(fill(sparse(∂Ũ⃗ₜ₊₁∂aₜ_block_i), P.N)...) - μ∂Ũ⃗ₜ₊₁∂aₜP[j, :] = μₜ' * ∂Ũ⃗ₜ₊₁∂aₜ - end - - return μ∂Ũ⃗ₜ₊₁∂aₜP -end - -function μ∂aₜ∂ψ̃ₜ( - P::QuantumStatePadeIntegrator, - aₜ::AbstractVector{T}, - Δtₜ::Real, - μₜ::AbstractVector{T}, -) where T <: Real - - n_drives = P.n_drives - μ∂aₜ∂ψ̃ₜP = zeros(T, P.dim, n_drives) - - for j = 1:n_drives - Gʲ = P.G_drives[j] - Ĝʲ = G(aₜ, P.G_drift_anticomms[j], P.G_drive_anticomms[:, j]) - ∂aₜ∂ψ̃ₜP = -(Δtₜ / 2 * Gʲ + Δtₜ^2 / 12 * Ĝʲ) - μ∂aₜ∂ψ̃ₜP[:, j] = ∂aₜ∂ψ̃ₜP' * μₜ - end - - return μ∂aₜ∂ψ̃ₜP -end - -function μ∂ψ̃ₜ₊₁∂aₜ( - P::QuantumStatePadeIntegrator, - aₜ::AbstractVector{T}, - Δtₜ::Real, - μₜ::AbstractVector{T}, -) where T <: Real - - n_drives = P.n_drives - μ∂ψ̃ₜ₊₁∂aₜP = zeros(T, n_drives, P.dim) - - for j = 1:n_drives - Gʲ = P.G_drives[j] - Ĝʲ = G(aₜ, P.G_drift_anticomms[j], P.G_drive_anticomms[:, j]) - ∂ψ̃ₜ₊₁∂aₜP = -Δtₜ / 2 * Gʲ + Δtₜ^2 / 12 * Ĝʲ - μ∂ψ̃ₜ₊₁∂aₜP[j, :] = μₜ' * ∂ψ̃ₜ₊₁∂aₜP - end - - #can add if else for higher order derivatives - return μ∂ψ̃ₜ₊₁∂aₜP -end - -function μ∂²aₜ( - P::UnitaryPadeIntegrator, - Ũ⃗ₜ₊₁::AbstractVector{T}, - Ũ⃗ₜ::AbstractVector{T}, - Δtₜ::Real, - μₜ::AbstractVector{T}, -) where T <: Real - - n_drives = P.n_drives - μ∂²aₜP = zeros(T, n_drives, n_drives) - - if P.order==4 - for i = 1:n_drives - for j = 1:i - ∂aʲ∂aⁱP_block = - Δtₜ^2 / 12 * P.G_drive_anticomms[i, j] - ∂aʲ∂aⁱP = blockdiag(fill(sparse(∂aʲ∂aⁱP_block), P.N)...) - μ∂²aₜP[j, i] = dot(μₜ, ∂aʲ∂aⁱP*(Ũ⃗ₜ₊₁ - Ũ⃗ₜ)) - end - end - end - - return Symmetric(μ∂²aₜP) -end - -function μ∂²aₜ( - P::QuantumStatePadeIntegrator, - ψ̃ₜ₊₁::AbstractVector{T}, - ψ̃ₜ::AbstractVector{T}, - Δtₜ::Real, - μₜ::AbstractVector{T}, -) where T <: Real - - n_drives = length(drive_indices) - μ∂²aₜP = Array{T}(undef, n_drives, n_drives) - - if P.order==4 - for i = 1:n_drives - for j = 1:i - ∂aʲ∂aⁱP = Δtₜ^2 / 12 * P.G_drive_anticomms[i, j] * (ψ̃ₜ₊₁ - ψ̃ₜ) - μ∂²aₜP[j, i] = dot(μₜ, ∂aʲ∂aⁱP) - end - end - end - - return Symmetric(μ∂²aₜP) -end - -function μ∂Δtₜ∂aₜ( - P::UnitaryPadeIntegrator, - Ũ⃗ₜ₊₁::AbstractVector{T}, - Ũ⃗ₜ::AbstractVector{T}, - aₜ::AbstractVector{T}, - Δtₜ::T, - μₜ::AbstractVector{T}, -) where T <: Real - - n_drives = P.n_drives - μ∂Δtₜ∂aₜP = Array{T}(undef, n_drives) - - if P.order == 4 - for j = 1:n_drives - Gʲ = P.G_drives[j] - Ĝʲ = G(aₜ, P.G_drift_anticomms[j], P.G_drive_anticomms[:, j]) - B = blockdiag(fill(sparse(-1/2 * Gʲ + 1/6 * Δtₜ * Ĝʲ), P.N)...) - F = blockdiag(fill(sparse(1/2 * Gʲ + 1/6 * Δtₜ * Ĝʲ), P.N)...) - ∂Δtₜ∂aₜ_j = B*Ũ⃗ₜ₊₁ - F*Ũ⃗ₜ - μ∂Δtₜ∂aₜP[j] = dot(μₜ, ∂Δtₜ∂aₜ_j) - end - end - return μ∂Δtₜ∂aₜP -end - -function μ∂Δtₜ∂aₜ( - P::QuantumStatePadeIntegrator, - ψ̃ₜ₊₁::AbstractVector{T}, - ψ̃ₜ::AbstractVector{T}, - aₜ::AbstractVector{T}, - Δtₜ::T, - μₜ::AbstractVector{T}, -) where T <: Real - - n_drives = P.n_drives - μ∂Δtₜ∂aₜP = Array{T}(undef, n_drives) - - if P.order == 4 - for j = 1:n_drives - Gʲ = P.G_drives[j] - Ĝʲ = G(aₜ, P.G_drift_anticomms[j], P.G_drive_anticomms[:, j]) - ∂Δt∂aʲP = - -1 / 2 * Gʲ * (ψ̃ₜ₊₁ + ψ̃ₜ) + - 1 / 6 * Δtₜ * Ĝʲ * (ψ̃ₜ₊₁ - ψ̃ₜ) - μ∂Δtₜ∂aₜP[j] = dot(μₜ, ∂Δt∂aʲP) - end - end - return μ∂Δtₜ∂aₜP -end - -function μ∂Δtₜ∂Ũ⃗ₜ( - P::UnitaryPadeIntegrator, - aₜ::AbstractVector, - Δtₜ::Real, - μₜ::AbstractVector -) - Gₜ = G(aₜ, P.G_drift, P.G_drives) - minus_F = -(1/2 * Gₜ + 1/6 * Δtₜ * Gₜ^2) - big_minus_F = blockdiag(fill(sparse(minus_F), P.N)...) - return big_minus_F' * μₜ -end - -function μ∂Ũ⃗ₜ₊₁∂Δtₜ( - P::UnitaryPadeIntegrator, - aₜ::AbstractVector, - Δtₜ::Real, - μₜ::AbstractVector -) - Gₜ = G(aₜ, P.G_drift, P.G_drives) - B = -1/2 * Gₜ + 1/6 * Δtₜ * Gₜ^2 - big_B = blockdiag(fill(sparse(B), P.N)...) - return μₜ' * big_B -end - -function μ∂Δtₜ∂ψ̃ₜ( - P::QuantumStatePadeIntegrator, - aₜ::AbstractVector, - Δtₜ::Real, - μₜ::AbstractVector -) - # memoize the calc here - Gₜ = G(aₜ, P.G_drift, P.G_drives) - minus_F = -(1/2 * Gₜ + 1/6 * Δtₜ * Gₜ^2) - return minus_F' * μₜ -end - -function μ∂ψ̃ₜ₊₁∂Δtₜ( - P::QuantumStatePadeIntegrator, - aₜ::AbstractVector, - Δtₜ::Real, - μₜ::AbstractVector -) - Gₜ = G(aₜ, P.G_drift, P.G_drives) - B = -1/2 * Gₜ + 1/6 * Δtₜ * Gₜ^2 - return μₜ' * B -end - -function μ∂²Δtₜ( - P::UnitaryPadeIntegrator, - Ũ⃗ₜ₊₁::AbstractVector, - Ũ⃗ₜ::AbstractVector, - aₜ::AbstractVector, - μₜ::AbstractVector -) - Gₜ = G(aₜ, P.G_drift, P.G_drives) - ∂²Δtₜ_gen_block = 1/6 * Gₜ^2 - ∂²Δtₜ_gen = blockdiag(fill(sparse(∂²Δtₜ_gen_block), P.N)...) - ∂²Δtₜ = ∂²Δtₜ_gen * (Ũ⃗ₜ₊₁ - Ũ⃗ₜ) - return μₜ' * ∂²Δtₜ -end - -function μ∂²Δtₜ( - P::QuantumStatePadeIntegrator, - ψ̃ₜ₊₁::AbstractVector, - ψ̃ₜ::AbstractVector, - aₜ::AbstractVector, - μₜ::AbstractVector -) - Gₜ = G(aₜ, P.G_drift, P.G_drives) - ∂²Δtₜ = 1/6 * Gₜ^2 * (ψ̃ₜ₊₁ - ψ̃ₜ) - return μₜ' * ∂²Δtₜ -end - -@views function hessian_of_the_lagrangian( - P::UnitaryPadeIntegrator, - zₜ::AbstractVector, - zₜ₊₁::AbstractVector, - μₜ::AbstractVector, - traj::NamedTrajectory -) - free_time = traj.timestep isa Symbol - - Ũ⃗ₜ₊₁ = zₜ₊₁[traj.components[P.unitary_symb]] - Ũ⃗ₜ = zₜ[traj.components[P.unitary_symb]] - - Δtₜ = free_time ? zₜ[traj.components[traj.timestep]][1] : traj.timestep - - if P.drive_symb isa Tuple - inds = [traj.components[s] for s in P.drive_symb] - inds = vcat(collect.(inds)...) - else - inds = traj.components[P.drive_symb] - end - - aₜ = zₜ[inds] - - μ∂aₜ∂Ũ⃗ₜP = μ∂aₜ∂Ũ⃗ₜ(P, aₜ, Δtₜ, μₜ) - μ∂²aₜP = μ∂²aₜ(P, Ũ⃗ₜ₊₁, Ũ⃗ₜ, Δtₜ, μₜ) - if free_time - μ∂Δtₜ∂aₜP = μ∂Δtₜ∂aₜ(P, Ũ⃗ₜ₊₁, Ũ⃗ₜ, aₜ, Δtₜ, μₜ) - end - - μ∂Ũ⃗ₜ₊₁∂aₜP = μ∂Ũ⃗ₜ₊₁∂aₜ(P, aₜ, Δtₜ, μₜ) - - if free_time - μ∂Δtₜ∂Ũ⃗ₜP = μ∂Δtₜ∂Ũ⃗ₜ(P, aₜ, Δtₜ, μₜ) - μ∂²ΔtₜP = μ∂²Δtₜ(P, Ũ⃗ₜ₊₁, Ũ⃗ₜ, aₜ, μₜ) - μ∂Ũ⃗ₜ₊₁∂ΔtₜP = μ∂Ũ⃗ₜ₊₁∂Δtₜ(P, aₜ, Δtₜ, μₜ) - return ( - μ∂aₜ∂Ũ⃗ₜP, - μ∂²aₜP, - μ∂Δtₜ∂Ũ⃗ₜP, - μ∂Δtₜ∂aₜP, - μ∂²ΔtₜP, - μ∂Ũ⃗ₜ₊₁∂aₜP, - μ∂Ũ⃗ₜ₊₁∂ΔtₜP - ) - else - return ( - μ∂aₜ∂Ũ⃗ₜP, - μ∂²aₜP, - μ∂Ũ⃗ₜ₊₁∂aₜP - ) - end -end - -@views function hessian_of_the_lagrangian( - P::QuantumStatePadeIntegrator, - zₜ::AbstractVector, - zₜ₊₁::AbstractVector, - μₜ::AbstractVector, - traj::NamedTrajectory -) - free_time = traj.timestep isa Symbol - - ψ̃ₜ₊₁ = zₜ₊₁[traj.components[P.state_symb]] - ψ̃ₜ = zₜ[traj.components[P.state_symb]] - - Δtₜ = free_time ? zₜ[traj.components[traj.timestep]][1] : traj.timestep - - if P.drive_symb isa Tuple - inds = [traj.components[s] for s in P.drive_symb] - inds = vcat(collect.(inds)...) - else - inds = traj.components[P.drive_symb] - end - - aₜ = zₜ[inds] - - μ∂aₜ∂ψ̃ₜP = μ∂aₜ∂ψ̃ₜ(P, aₜ, Δtₜ, μₜ) - μ∂²aₜP = μ∂²aₜ(P, ψ̃ₜ₊₁, ψ̃ₜ, Δtₜ, μₜ) - if free_time - μ∂Δtₜ∂aₜP = μ∂Δtₜ∂aₜ(P, ψ̃ₜ₊₁, ψ̃ₜ, aₜ, Δtₜ, μₜ) - end - μ∂ψ̃ₜ₊₁∂aₜP = μ∂ψ̃ₜ₊₁∂aₜ(P, aₜ, Δtₜ, μₜ) - - if free_time - μ∂Δtₜ∂ψ̃ₜP = μ∂Δtₜ∂ψ̃ₜ(P, aₜ, Δtₜ, μₜ) - μ∂²ΔtₜP = μ∂²Δtₜ(P, ψ̃ₜ₊₁, ψ̃ₜ, aₜ, μₜ) - μ∂ψ̃ₜ₊₁∂ΔtₜP = μ∂ψ̃ₜ₊₁∂Δtₜ(P, aₜ, Δtₜ, μₜ) - - return ( - μ∂aₜ∂ψ̃ₜP, - μ∂²aₜP, - μ∂Δtₜ∂ψ̃ₜP, - μ∂Δtₜ∂aₜP, - μ∂²ΔtₜP, - μ∂ψ̃ₜ₊₁∂aₜP, - μ∂ψ̃ₜ₊₁∂ΔtₜP - ) - else - return ( - μ∂aₜ∂ψ̃ₜP, - μ∂²aₜP, - μ∂ψ̃ₜ₊₁∂aₜP - ) - end -end - - -end diff --git a/build/ipopt_options.jl b/build/ipopt_options.jl deleted file mode 100644 index be41e736..00000000 --- a/build/ipopt_options.jl +++ /dev/null @@ -1,67 +0,0 @@ -module IpoptOptions - -export Options -export set! - -using Ipopt -using Libdl -using Base: @kwdef - -""" - Solver options for Ipopt - - https://coin-or.github.io/Ipopt/OPTIONS.html#OPT_print_options_documentation -""" -@kwdef mutable struct Options{T} - tol::T = 1e-8 - s_max::T = 100.0 - max_iter::Int = 1_000 - max_cpu_time = 1_000_000.0 - dual_inf_tol::T = 1.0 - constr_viol_tol::T = 1.0e-6 - compl_inf_tol::T = 1.0e-3 - acceptable_tol::T = 1.0e-6 - acceptable_iter::Int = 15 - acceptable_dual_inf_tol::T = 1.0e10 - acceptable_constr_viol_tol::T = 1.0e-2 - acceptable_compl_inf_tol::T = 1.0e-2 - acceptable_obj_change_tol::T = 1.0e-5 - diverging_iterates_tol::T = 1.0e8 - mu_target::T = 1.0e-4 - print_level::Int = 5 - output_file = nothing - print_user_options = "no" - print_options_documentation = "no" - print_timing_statistics = "no" - print_options_mode = "text" - print_advanced_options = "no" - print_info_string = "no" - inf_pr_output = "original" - print_frequency_iter = 1 - print_frequency_time = 0.0 - skip_finalize_solution_call = "no" - hsllib = nothing - hessian_approximation = "exact" - recalc_y = "no" - recalc_y_feas_tol = 1.0e-6 - linear_solver = "mumps" - watchdog_shortened_iter_trigger = 10 - watchdog_trial_iter_max = 3 -end - -function set!(optimizer::Ipopt.Optimizer, options::Options) - for name in fieldnames(typeof(options)) - value = getfield(options, name) - if name == :linear_solver - if value == "pardiso" - Libdl.dlopen("/usr/lib/x86_64-linux-gnu/liblapack.so.3", RTLD_GLOBAL) - Libdl.dlopen("/usr/lib/x86_64-linux-gnu/libomp.so.5", RTLD_GLOBAL) - end - end - if !isnothing(value) - optimizer.options[String(name)] = value - end - end -end - -end diff --git a/build/losses.jl b/build/losses.jl deleted file mode 100644 index 5c71d79f..00000000 --- a/build/losses.jl +++ /dev/null @@ -1,645 +0,0 @@ -module Losses - -export Loss - -export QuantumLoss -export QuantumLossGradient -export QuantumLossHessian - -export InfidelityLoss -export UnitaryInfidelityLoss -export UnitaryTraceLoss - -export infidelity -export unitary_infidelity - -using ..QuantumUtils -using ..QuantumSystems -using ..StructureUtils - - -using NamedTrajectories - -using TrajectoryIndexingUtils -using LinearAlgebra -using SparseArrays -using ForwardDiff -using Symbolics - -# -# loss functions -# - - -# TODO: renormalize vectors in place of abs -# ⋅ penalize loss to remain near unit norm -# ⋅ Σ α * (1 - ψ̃'ψ̃), α = 1e-3 - -abstract type AbstractLoss end - -""" - infidelity(ψ̃::AbstractVector, ψ̃goal::AbstractVector) - -Returns the infidelity between two quantum statevectors specified -in the ``\\mathbb{C}^n \\to \\mathbb{R}^{2n}`` isomorphism space. - -""" -function infidelity(ψ̃::AbstractVector, ψ̃goal::AbstractVector) - ψ = iso_to_ket(ψ̃) - ψgoal = iso_to_ket(ψ̃goal) - return abs(1 - abs2(ψgoal'ψ)) -end - -@doc raw""" - isovec_unitary_fidelity(Ũ::AbstractVector, Ũgoal::AbstractVector) - -Returns the fidelity between the isomorphic unitary $\vec{\widetilde{U}} \sim U \in SU(n)$ and the isomorphic goal unitary $\vec{\widetilde{U}}_{\text{goal}}$. - -```math -\begin{aligned} -\mathcal{F}(\vec{\widetilde{U}}, \vec{\widetilde{U}}_{\text{goal}}) &= \frac{1}{n} \abs{\tr \qty(U_{\text{goal}}^\dagger U)} \\ -&= \frac{1}{n} \sqrt{T_R^{2} + T_I^{2}} -\end{aligned} -``` - -where $T_R = \langle \vec{\widetilde{U}}_{\text{goal}, R}, \vec{\widetilde{U}}_R \rangle + \langle \vec{\widetilde{U}}_{\text{goal}, I}, \vec{\widetilde{U}}_I \rangle$ and $T_I = \langle \vec{\widetilde{U}}_{\text{goal}, R}, \vec{\widetilde{U}}_I \rangle - \langle \vec{\widetilde{U}}_{\text{goal}, I}, \vec{\widetilde{U}}_R \rangle$. - -""" -@inline @views function isovec_unitary_fidelity( - Ũ⃗::AbstractVector, - Ũ⃗_goal::AbstractVector, - subspace::Tuple{AbstractVector{Int},AbstractVector{Int}}=axes(iso_vec_to_operator(Ũ⃗_goal)) -) - subspace_rows, subspace_cols = subspace - U = iso_vec_to_operator(Ũ⃗)[subspace_rows, subspace_cols] - n = size(U, 1) - U_goal = iso_vec_to_operator(Ũ⃗_goal)[subspace_rows, subspace_cols] - U⃗ᵣ, U⃗ᵢ = vec(real(U)), vec(imag(U)) - Ū⃗ᵣ, Ū⃗ᵢ = vec(real(U_goal)), vec(imag(U_goal)) - Tᵣ = Ū⃗ᵣ' * U⃗ᵣ + Ū⃗ᵢ' * U⃗ᵢ - Tᵢ = Ū⃗ᵣ' * U⃗ᵢ - Ū⃗ᵢ' * U⃗ᵣ - return 1 / n * sqrt(Tᵣ^2 + Tᵢ^2) -end - -@views function unitary_infidelity( - Ũ⃗::AbstractVector, - Ũ⃗_goal::AbstractVector, - subspace::Tuple{AbstractVector{Int},AbstractVector{Int}}= - axes(iso_vec_to_operator(Ũ⃗_goal)) -) - ℱ = isovec_unitary_fidelity(Ũ⃗, Ũ⃗_goal, subspace) - return abs(1 - ℱ) -end - -@views function unitary_infidelity_gradient( - Ũ⃗::AbstractVector, - Ũ⃗_goal::AbstractVector, - subspace::Tuple{AbstractVector{Int},AbstractVector{Int}}= - axes(iso_vec_to_operator(Ũ⃗_goal)) -) - subspace_rows, subspace_cols = subspace - U = iso_vec_to_operator(Ũ⃗)[subspace_rows, subspace_cols] - n = size(U, 1) - U_goal = iso_vec_to_operator(Ũ⃗_goal)[subspace_rows, subspace_cols] - U⃗ᵣ, U⃗ᵢ = vec(real(U)), vec(imag(U)) - Ū⃗ᵣ, Ū⃗ᵢ = vec(real(U_goal)), vec(imag(U_goal)) - Tᵣ = Ū⃗ᵣ' * U⃗ᵣ + Ū⃗ᵢ' * U⃗ᵢ - Tᵢ = Ū⃗ᵣ' * U⃗ᵢ - Ū⃗ᵢ' * U⃗ᵣ - ℱ = 1 / n * sqrt(Tᵣ^2 + Tᵢ^2) - ∇ᵣℱ = 1 / (n^2 * ℱ) * (Tᵣ * Ū⃗ᵣ - Tᵢ * Ū⃗ᵢ) - ∇ᵢℱ = 1 / (n^2 * ℱ) * (Tᵣ * Ū⃗ᵢ + Tᵢ * Ū⃗ᵣ) - ∇ℱ = [∇ᵣℱ; ∇ᵢℱ] - permutation = vcat(vcat([[slice(j, n), slice(j, n) .+ n^2] for j = 1:n]...)...) - ∇ℱ = ∇ℱ[permutation] - return -sign(1 - ℱ) * ∇ℱ -end - -@views function unitary_infidelity_hessian( - Ũ⃗::AbstractVector, - Ũ⃗_goal::AbstractVector, - subspace::Tuple{AbstractVector{Int},AbstractVector{Int}}=axes(iso_vec_to_operator(Ũ⃗_goal)) -) - subspace_rows, subspace_cols = subspace - U = iso_vec_to_operator(Ũ⃗)[subspace_rows, subspace_cols] - n = size(U, 1) - U_goal = iso_vec_to_operator(Ũ⃗_goal)[subspace_rows, subspace_cols] - U⃗ᵣ, U⃗ᵢ = vec(real(U)), vec(imag(U)) - Ū⃗ᵣ, Ū⃗ᵢ = vec(real(U_goal)), vec(imag(U_goal)) - Tᵣ = Ū⃗ᵣ' * U⃗ᵣ + Ū⃗ᵢ' * U⃗ᵢ - Tᵢ = Ū⃗ᵣ' * U⃗ᵢ - Ū⃗ᵢ' * U⃗ᵣ - Wᵣᵣ = Ū⃗ᵣ * Ū⃗ᵣ' - Wᵢᵢ = Ū⃗ᵢ * Ū⃗ᵢ' - Wᵣᵢ = Ū⃗ᵣ * Ū⃗ᵢ' - Wᵢᵣ = Wᵣᵢ' - ℱ = 1 / n * sqrt(Tᵣ^2 + Tᵢ^2) - ∇ᵣℱ = 1 / (n^2 * ℱ) * (Tᵣ * Ū⃗ᵣ - Tᵢ * Ū⃗ᵢ) - ∇ᵢℱ = 1 / (n^2 * ℱ) * (Tᵣ * Ū⃗ᵢ + Tᵢ * Ū⃗ᵣ) - ∂ᵣ²ℱ = 1 / ℱ * (-∇ᵣℱ * ∇ᵣℱ' + 1 / n^2 * (Wᵣᵣ + Wᵢᵢ)) - ∂ᵢ²ℱ = 1 / ℱ * (-∇ᵢℱ * ∇ᵢℱ' + 1 / n^2 * (Wᵣᵣ + Wᵢᵢ)) - ∂ᵣ∂ᵢℱ = 1 / ℱ * (-∇ᵢℱ * ∇ᵣℱ' + 1 / n^2 * (Wᵢᵣ - Wᵣᵢ)) - ∂²ℱ = [∂ᵣ²ℱ ∂ᵣ∂ᵢℱ; ∂ᵣ∂ᵢℱ' ∂ᵢ²ℱ] - permutation = vcat(vcat([[slice(j, n), slice(j, n) .+ n^2] for j = 1:n]...)...) - ∂²ℱ = ∂²ℱ[permutation, permutation] - return -sign(1 - ℱ) * ∂²ℱ -end - - - -struct UnitaryInfidelityLoss <: AbstractLoss - l::Function - ∇l::Function - ∇²l::Function - ∇²l_structure::Vector{Tuple{Int,Int}} - name::Symbol - - function UnitaryInfidelityLoss( - name::Symbol, - Ũ⃗_goal::AbstractVector; - subspace::Union{Nothing, AbstractVector{Int}, Tuple{AbstractVector{Int},AbstractVector{Int}}}=nothing, - ) - if isnothing(subspace) - subspace = axes(iso_vec_to_operator(Ũ⃗_goal)) - elseif subspace isa AbstractVector{Int} - subspace = (subspace, subspace) - end - - l = Ũ⃗ -> unitary_infidelity(Ũ⃗, Ũ⃗_goal, subspace) - - @views ∇l = Ũ⃗ -> begin - subspace_rows, subspace_cols = subspace - n_subspace = length(subspace_rows) - n_full = Int(sqrt(length(Ũ⃗) ÷ 2)) - ∇l_subspace = unitary_infidelity_gradient(Ũ⃗, Ũ⃗_goal, subspace) - ∇l_full = zeros(2 * n_full^2) - for j ∈ eachindex(subspace_cols) - ∇l_full[slice(2subspace_cols[j] - 1, subspace_rows, n_full)] = - ∇l_subspace[slice(2j - 1, n_subspace)] - ∇l_full[slice(2subspace_cols[j], subspace_rows, n_full)] = - ∇l_subspace[slice(2j, n_subspace)] - end - return ∇l_full - end - - @views ∇²l = Ũ⃗ -> begin - subspace_rows, subspace_cols = subspace - n_subspace = length(subspace_rows) - n_full = Int(sqrt(length(Ũ⃗) ÷ 2)) - ∇²l_subspace = unitary_infidelity_hessian(Ũ⃗, Ũ⃗_goal, subspace) - ∇²l_full = zeros(2 * n_full^2, 2 * n_full^2) - # TODO: make sure this is correct for case where subspace_rows ≠ subspace_cols - for k ∈ eachindex(subspace_cols) - for j ∈ eachindex(subspace_cols) - ∇²l_full[ - slice(2subspace_cols[k] - 1, subspace_rows, n_full), - slice(2subspace_cols[j] - 1, subspace_rows, n_full) - ] = ∇²l_subspace[ - slice(2k - 1, n_subspace), - slice(2j - 1, n_subspace) - ] - - ∇²l_full[ - slice(2subspace_cols[k] - 1, subspace_rows, n_full), - slice(2subspace_cols[j], subspace_rows, n_full) - ] = ∇²l_subspace[ - slice(2k - 1, n_subspace), - slice(2j, n_subspace) - ] - - ∇²l_full[ - slice(2subspace_cols[k], subspace_rows, n_full), - slice(2subspace_cols[j] - 1, subspace_rows, n_full) - ] = ∇²l_subspace[ - slice(2k, n_subspace), - slice(2j - 1, n_subspace) - ] - - ∇²l_full[ - slice(2subspace_cols[k], subspace_rows, n_full), - slice(2subspace_cols[j], subspace_rows, n_full) - ] = ∇²l_subspace[ - slice(2k, n_subspace), - slice(2j, n_subspace) - ] - end - end - return ∇²l_full - end - - Ũ⃗_dim = length(Ũ⃗_goal) - ∇²l_structure = [] - for (i, j) ∈ Iterators.product(1:Ũ⃗_dim, 1:Ũ⃗_dim) - if i ≤ j - push!(∇²l_structure, (i, j)) - end - end - return new(l, ∇l, ∇²l, ∇²l_structure, name) - end -end - -function (loss::UnitaryInfidelityLoss)( - Ũ⃗_end::AbstractVector{<:Real}; - gradient=false, - hessian=false -) - @assert !(gradient && hessian) - if !(gradient || hessian) - return loss.l(Ũ⃗_end) - elseif gradient - return loss.∇l(Ũ⃗_end) - elseif hessian - return loss.∇²l(Ũ⃗_end) - end -end - - - - - - - -function unitary_trace_loss(Ũ⃗::AbstractVector, Ũ⃗_goal::AbstractVector) - U = iso_vec_to_operator(Ũ⃗) - Ugoal = iso_vec_to_operator(Ũ⃗_goal) - return 1 / 2 * tr(sqrt((U - Ugoal)' * (U - Ugoal))) -end - - -struct Loss <: AbstractLoss - l::Function - ∇l::Function - ∇²l::Function - ∇²l_structure::Vector{Tuple{Int,Int}} - name::Symbol - - function Loss( - Z::NamedTrajectory, - J::Function, - x::Symbol - ) - @assert x ∈ Z.names - @assert Z.goal[x] isa AbstractVector - - x_goal = Z.goal[x] - - J = x̄ -> J(x̄, x_goal) - ∇J = x̄ -> ForwardDiff.gradient(J, x̄) - - Symbolics.@variables x̄[1:Z.dims[x]] - x̄ = collect(x̄) - - ∇²J_symbolic = Symbolics.sparsehessian(J(x̄), x̄) - rows, cols, _ = findnz(∇²J_symbolic) - rowcols = collect(zip(rows, cols)) - filter!((row, col) -> row ≥ col, rowcols) - ∇²J_structure = rowcols - - ∇²J_expression = Symbolics.build_function(∇²J_symbolic, x̄) - ∇²J = eval(∇²J_expression[1]) - - return new(J, ∇J, ∇²J, ∇²J_structure, x) - end -end - -function (loss::Loss)(Z::NamedTrajectory; gradient=false, hessian=false) - @assert !(gradient && hessian) - if !(gradient || hessian) - return loss.l(Z[end][loss.name]) - elseif gradient - return loss.∇l(Z[end][loss.name]) - elseif hessian - return loss.∇²l(Z[end][loss.name]) - end -end - - -struct UnitaryTraceLoss <: AbstractLoss - l::Function - ∇l::Function - ∇²l::Function - ∇²l_structure::Vector{Tuple{Int,Int}} - name::Symbol - - function UnitaryTraceLoss( - name::Symbol, - Ũ⃗_goal::AbstractVector - ) - l = Ũ⃗ -> unitary_trace_loss(Ũ⃗, Ũ⃗_goal) - ∇l = Ũ⃗ -> ForwardDiff.gradient(l, Ũ⃗) - ∇²l = Ũ⃗ -> ForwardDiff.hessian(l, Ũ⃗) - Ũ⃗_dim = length(Ũ⃗_goal) - ∇²l_structure = [] - for (i, j) ∈ Iterators.product(1:Ũ⃗_dim, 1:Ũ⃗_dim) - if i ≤ j - push!(∇²l_structure, (i, j)) - end - end - return new(l, ∇l, ∇²l, ∇²l_structure, name) - end -end - -function (loss::UnitaryTraceLoss)( - Ũ⃗_end::AbstractVector{<:Real}; - gradient=false, - hessian=false -) - @assert !(gradient && hessian) - - if !(gradient || hessian) - return loss.l(Ũ⃗_end) - elseif gradient - return loss.∇l(Ũ⃗_end) - elseif hessian - return loss.∇²l(Ũ⃗_end) - end -end - - - - - -struct InfidelityLoss <: AbstractLoss - l::Function - ∇l::Function - ∇²l::Function - ∇²l_structure::Vector{Tuple{Int,Int}} - wfn_name::Symbol - - function InfidelityLoss( - name::Symbol, - ψ̃_goal::AbstractVector - ) - l = ψ̃ -> infidelity(ψ̃, ψ̃_goal) - ∇l = ψ̃ -> ForwardDiff.gradient(l, ψ̃) - - Symbolics.@variables ψ̃[1:length(ψ̃_goal)] - ψ̃ = collect(ψ̃) - - ∇²l_symbolic = Symbolics.sparsehessian(l(ψ̃), ψ̃) - K, J, _ = findnz(∇²l_symbolic) - kjs = collect(zip(K, J)) - filter!(((k, j),) -> k ≤ j, kjs) - ∇²l_structure = kjs - - ∇²l_expression = Symbolics.build_function(∇²l_symbolic, ψ̃) - ∇²l = eval(∇²l_expression[1]) - - return new(l, ∇l, ∇²l, ∇²l_structure, name) - end -end - -function (loss::InfidelityLoss)( - ψ̃_end::AbstractVector{<:Real}; - gradient=false, - hessian=false -) - @assert !(gradient && hessian) - - if !(gradient || hessian) - return loss.l(ψ̃_end) - elseif gradient - return loss.∇l(ψ̃_end) - elseif hessian - return loss.∇²l(ψ̃_end) - end -end - - - - - - - - -struct QuantumLoss - cs::Vector{Function} - isodim::Int - - function QuantumLoss( - sys::AbstractQuantumSystem, - loss::Symbol = :infidelity_loss - ) - if loss == :energy_loss - cs = [ψ̃ⁱ -> eval(loss)(ψ̃ⁱ, sys.H_target) for i = 1:sys.nqstates] - elseif loss == :neg_entropy_loss - cs = [ψ̃ⁱ -> eval(loss)(ψ̃ⁱ) for i = 1:sys.nqstates] - else - cs = [ - ψ̃ⁱ -> eval(loss)( - ψ̃ⁱ, - sys.ψ̃goal[slice(i, sys.isodim)] - ) for i = 1:sys.nqstates - ] - end - return new(cs, sys.isodim) - end -end - -function (qloss::QuantumLoss)(ψ̃::AbstractVector) - loss = 0.0 - for (i, cⁱ) in enumerate(qloss.cs) - loss += cⁱ(ψ̃[slice(i, qloss.isodim)]) - end - return loss -end - -struct QuantumLossGradient - ∇cs::Vector{Function} - isodim::Int - - function QuantumLossGradient( - loss::QuantumLoss; - simplify=true - ) - Symbolics.@variables ψ̃[1:loss.isodim] - - ψ̃ = collect(ψ̃) - - ∇cs_symbs = [ - Symbolics.gradient(c(ψ̃), ψ̃; simplify=simplify) - for c in loss.cs - ] - - ∇cs_exprs = [ - Symbolics.build_function(∇c, ψ̃) - for ∇c in ∇cs_symbs - ] - - ∇cs = [ - eval(∇c_expr[1]) - for ∇c_expr in ∇cs_exprs - ] - - return new(∇cs, loss.isodim) - end -end - -@views function (∇c::QuantumLossGradient)( - ψ̃::AbstractVector -) - ∇ = similar(ψ̃) - - for (i, ∇cⁱ) in enumerate(∇c.∇cs) - - ψ̃ⁱ_slice = slice(i, ∇c.isodim) - - ∇[ψ̃ⁱ_slice] = ∇cⁱ(ψ̃[ψ̃ⁱ_slice]) - end - - return ∇ -end - -struct QuantumLossHessian - ∇²cs::Vector{Function} - ∇²c_structures::Vector{Vector{Tuple{Int, Int}}} - isodim::Int - - function QuantumLossHessian( - loss::QuantumLoss; - simplify=true - ) - - Symbolics.@variables ψ̃[1:loss.isodim] - ψ̃ = collect(ψ̃) - - ∇²c_symbs = [ - Symbolics.sparsehessian( - c(ψ̃), - ψ̃; - simplify=simplify - ) for c in loss.cs - ] - - ∇²c_structures = [] - - for ∇²c_symb in ∇²c_symbs - K, J, _ = findnz(∇²c_symb) - - KJ = collect(zip(K, J)) - - filter!(((k, j),) -> k ≤ j, KJ) - - push!(∇²c_structures, KJ) - end - - ∇²c_exprs = [ - Symbolics.build_function(∇²c_symb, ψ̃) - for ∇²c_symb in ∇²c_symbs - ] - - ∇²cs = [ - eval(∇²c_expr[1]) - for ∇²c_expr in ∇²c_exprs - ] - - return new(∇²cs, ∇²c_structures, loss.isodim) - end -end - -function StructureUtils.structure( - H::QuantumLossHessian, - T::Int, - vardim::Int -) - H_structure = [] - - T_offset = index(T, 0, vardim) - - for (i, KJⁱ) in enumerate(H.∇²c_structures) - - i_offset = index(i, 0, H.isodim) - - for kj in KJⁱ - push!(H_structure, (T_offset + i_offset) .+ kj) - end - end - - return H_structure -end - -@views function (H::QuantumLossHessian)(ψ̃::AbstractVector) - - Hs = [] - - for (i, ∇²cⁱ) in enumerate(H.∇²cs) - - ψ̃ⁱ = ψ̃[slice(i, H.isodim)] - - for (k, j) in H.∇²c_structures[i] - - Hⁱᵏʲ = ∇²cⁱ(ψ̃ⁱ)[k, j] - - append!(Hs, Hⁱᵏʲ) - end - end - - return Hs -end - - -# -# primary loss functions -# - - -function energy_loss( - ψ̃::AbstractVector, - H::AbstractMatrix -) - ψ = iso_to_ket(ψ̃) - return real(ψ' * H * ψ) -end - - -# TODO: figure out a way to implement this without erroring and Von Neumann entropy being always 0 for a pure state -function neg_entropy_loss( - ψ̃::AbstractVector -) - ψ = iso_to_ket(ψ̃) - ρ = ψ * ψ' - ρ = Hermitian(ρ) - return tr(ρ * log(ρ)) -end - - - - -# -# experimental loss functions -# - -function pure_real_loss(ψ̃, ψ̃goal) - ψ = iso_to_ket(ψ̃) - ψgoal = iso_to_ket(ψ̃goal) - return -(ψ'ψgoal) -end - -function geodesic_loss(ψ̃, ψ̃goal) - ψ = iso_to_ket(ψ̃) - ψgoal = iso_to_ket(ψ̃goal) - amp = ψ'ψgoal - return min(abs(1 - amp), abs(1 + amp)) -end - -function real_loss(ψ̃, ψ̃goal) - ψ = iso_to_ket(ψ̃) - ψgoal = iso_to_ket(ψ̃goal) - amp = ψ'ψgoal - return min(abs(1 - real(amp)), abs(1 + real(amp))) -end - -function iso_infidelity(ψ̃, ψ̃f) - ψ = iso_to_ket(ψ̃) - ψf = iso_to_ket(ψ̃f) - return 1 - abs2(ψ'ψf) -end - - -function quaternionic_loss(ψ̃, ψ̃goal) - return min( - abs(1 - dot(ψ̃, ψ̃goal)), - abs(1 + dot(ψ̃, ψ̃goal)) - ) - -end - -end diff --git a/build/objectives.jl b/build/objectives.jl deleted file mode 100644 index e0425f2e..00000000 --- a/build/objectives.jl +++ /dev/null @@ -1,835 +0,0 @@ -module Objectives - -export Objective - -export QuantumObjective -export QuantumStateObjective -export QuantumUnitaryObjective -export UnitaryInfidelityObjective - -export MinimumTimeObjective -export InfidelityRobustnessObjective - -export QuadraticRegularizer -export QuadraticSmoothnessRegularizer -export L1Regularizer - -using TrajectoryIndexingUtils -using ..QuantumUtils -using ..QuantumSystems -using ..EmbeddedOperators -using ..Losses -using ..Constraints - -using NamedTrajectories -using LinearAlgebra -using SparseArrays -using Symbolics - -# -# objective functions -# - -""" - Objective - -A structure for defining objective functions. - -Fields: - `L`: the objective function - `∇L`: the gradient of the objective function - `∂²L`: the Hessian of the objective function - `∂²L_structure`: the structure of the Hessian of the objective function - `terms`: a vector of dictionaries containing the terms of the objective function -""" -struct Objective - L::Function - ∇L::Function - ∂²L::Union{Function, Nothing} - ∂²L_structure::Union{Function, Nothing} - terms::Vector{Dict} -end - -function Base.:+(obj1::Objective, obj2::Objective) - L = (Z⃗, Z) -> obj1.L(Z⃗, Z) + obj2.L(Z⃗, Z) - ∇L = (Z⃗, Z) -> obj1.∇L(Z⃗, Z) + obj2.∇L(Z⃗, Z) - if isnothing(obj1.∂²L) && isnothing(obj2.∂²L) - ∂²L = Nothing - ∂²L_structure = Nothing - elseif isnothing(obj1.∂²L) - ∂²L = (Z⃗, Z) -> obj2.∂²L(Z⃗, Z) - ∂²L_structure = obj2.∂²L_structure - elseif isnothing(obj2.∂²L) - ∂²L = (Z⃗, Z) -> obj1.∂²L(Z⃗, Z) - ∂²L_structure = obj1.∂²L_structure - else - ∂²L = (Z⃗, Z) -> vcat(obj1.∂²L(Z⃗, Z), obj2.∂²L(Z⃗, Z)) - ∂²L_structure = Z -> vcat(obj1.∂²L_structure(Z), obj2.∂²L_structure(Z)) - end - terms = vcat(obj1.terms, obj2.terms) - return Objective(L, ∇L, ∂²L, ∂²L_structure, terms) -end - -Base.:+(obj::Objective, ::Nothing) = obj - -function Objective(terms::Vector{Dict}) - return +(Objective.(terms)...) -end - -function Objective(term::Dict) - return eval(term[:type])(; delete!(term, :type)...) -end - -# function to convert sparse matrix to tuple of vector of nonzero indices and vector of nonzero values -function sparse_to_moi(A::SparseMatrixCSC) - inds = collect(zip(findnz(A)...)) - vals = [A[i,j] for (i,j) ∈ inds] - return (inds, vals) -end -""" - QuantumObjective - - -""" -function QuantumObjective(; - names::Union{Nothing,Tuple{Vararg{Symbol}}}=nothing, - name::Union{Nothing,Symbol}=nothing, - goals::Union{Nothing,AbstractVector{<:Real},Tuple{Vararg{AbstractVector{<:Real}}}}=nothing, - loss::Symbol=:InfidelityLoss, - Q::Union{Float64, Vector{Float64}}=100.0, - eval_hessian::Bool=true -) - @assert !(isnothing(names) && isnothing(name)) "name or names must be specified" - @assert !isnothing(goals) "goals corresponding to names must be specified" - - if isnothing(names) - names = (name,) - end - - if goals isa AbstractVector - goals = (goals,) - end - - if Q isa Float64 - Q = ones(length(names)) * Q - else - @assert length(Q) == length(names) - end - - params = Dict( - :type => :QuantumObjective, - :names => names, - :goals => goals, - :loss => loss, - :Q => Q, - :eval_hessian => eval_hessian, - ) - - losses = [eval(loss)(name, goal) for (name, goal) ∈ zip(names, goals)] - - @views function L(Z⃗::AbstractVector{<:Real}, Z::NamedTrajectory) - loss = 0.0 - for (Qᵢ, lᵢ, name) ∈ zip(Q, losses, names) - name_slice = slice(Z.T, Z.components[name], Z.dim) - loss += Qᵢ * lᵢ(Z⃗[name_slice]) - end - return loss - end - - @views function ∇L(Z⃗::AbstractVector{<:Real}, Z::NamedTrajectory) - ∇ = zeros(Z.dim * Z.T) - for (Qᵢ, lᵢ, name) ∈ zip(Q, losses, names) - name_slice = slice(Z.T, Z.components[name], Z.dim) - ∇[name_slice] = Qᵢ * lᵢ(Z⃗[name_slice]; gradient=true) - end - return ∇ - end - - function ∂²L_structure(Z::NamedTrajectory) - structure = [] - final_time_offset = index(Z.T, 0, Z.dim) - for (name, loss) ∈ zip(names, losses) - comp_start_offset = Z.components[name][1] - 1 - comp_hessian_structure = [ - ij .+ (final_time_offset + comp_start_offset) - for ij ∈ loss.∇²l_structure - ] - append!(structure, comp_hessian_structure) - end - return structure - end - - - @views function ∂²L(Z⃗::AbstractVector{<:Real}, Z::NamedTrajectory; return_moi_vals=true) - H = spzeros(Z.dim * Z.T, Z.dim * Z.T) - for (Qᵢ, name, lᵢ) ∈ zip(Q, names, losses) - name_slice = slice(Z.T, Z.components[name], Z.dim) - H[name_slice, name_slice] = - Qᵢ * lᵢ(Z⃗[name_slice]; hessian=true) - end - if return_moi_vals - Hs = [H[i,j] for (i, j) ∈ ∂²L_structure(Z)] - return Hs - else - return H - end - end - - return Objective(L, ∇L, ∂²L, ∂²L_structure, Dict[params]) -end - - - -""" - UnitaryInfidelityObjective - - -""" -function UnitaryInfidelityObjective(; - name::Union{Nothing,Symbol}=nothing, - goal::Union{Nothing,AbstractVector{<:Real}}=nothing, - Q::Float64=100.0, - eval_hessian::Bool=true, - subspace=nothing -) - @assert !isnothing(goal) "unitary goal name must be specified" - - loss = :UnitaryInfidelityLoss - l = eval(loss)(name, goal; subspace=subspace) - - params = Dict( - :type => :UnitaryInfidelityObjective, - :name => name, - :goal => goal, - :Q => Q, - :eval_hessian => eval_hessian, - :subspace => subspace - ) - - @views function L(Z⃗::AbstractVector{<:Real}, Z::NamedTrajectory) - return Q * l(Z⃗[slice(Z.T, Z.components[name], Z.dim)]) - end - - @views function ∇L(Z⃗::AbstractVector{<:Real}, Z::NamedTrajectory) - ∇ = zeros(Z.dim * Z.T) - Ũ⃗_slice = slice(Z.T, Z.components[name], Z.dim) - Ũ⃗ = Z⃗[Ũ⃗_slice] - ∇l = l(Ũ⃗; gradient=true) - ∇[Ũ⃗_slice] .= Q * ∇l - return ∇ - end - - function ∂²L_structure(Z::NamedTrajectory) - final_time_offset = index(Z.T, 0, Z.dim) - comp_start_offset = Z.components[name][1] - 1 - structure = [ - ij .+ (final_time_offset + comp_start_offset) - for ij ∈ l.∇²l_structure - ] - return structure - end - - - @views function ∂²L(Z⃗::AbstractVector{<:Real}, Z::NamedTrajectory; return_moi_vals=true) - H = spzeros(Z.dim * Z.T, Z.dim * Z.T) - Ũ⃗_slice = slice(Z.T, Z.components[name], Z.dim) - H[Ũ⃗_slice, Ũ⃗_slice] = Q * l(Z⃗[Ũ⃗_slice]; hessian=true) - if return_moi_vals - Hs = [H[i,j] for (i, j) ∈ ∂²L_structure(Z)] - return Hs - else - return H - end - end - - - # ∂²L_structure(Z::NamedTrajectory) = [] - - # ∂²L(Z⃗::AbstractVector{<:Real}, Z::NamedTrajectory) = [] - - return Objective(L, ∇L, ∂²L, ∂²L_structure, Dict[params]) -end - -function QuantumObjective( - name::Symbol, - traj::NamedTrajectory, - loss::Symbol, - Q::Float64 -) - goal = traj.goal[name] - return QuantumObjective(name=name, goals=goal, loss=loss, Q=Q) -end - -function UnitaryInfidelityObjective( - name::Symbol, - traj::NamedTrajectory, - Q::Float64; - subspace=nothing -) - return UnitaryInfidelityObjective(name=name, goal=traj.goal[name], Q=Q, subspace=subspace) -end - -function QuantumObjective( - names::Tuple{Vararg{Symbol}}, - traj::NamedTrajectory, - loss::Symbol, - Q::Float64 -) - goals = Tuple(traj.goal[name] for name in names) - return QuantumObjective(names=names, goals=goals, loss=loss, Q=Q) -end - -function QuantumUnitaryObjective( - name::Symbol, - traj::NamedTrajectory, - Q::Float64 -) - return QuantumObjective(name, traj, :UnitaryInfidelityLoss, Q) -end - -function QuantumStateObjective( - name::Symbol, - traj::NamedTrajectory, - Q::Float64 -) - return QuantumObjective(name, traj, :InfidelityLoss, Q) -end - -function QuadraticRegularizer(; - name::Symbol=nothing, - times::AbstractVector{Int}=1:traj.T, - dim::Int=nothing, - R::AbstractVector{<:Real}=ones(traj.dims[name]), - eval_hessian=true, - timestep_symbol=:Δt -) - - @assert !isnothing(name) "name must be specified" - @assert !isnothing(times) "times must be specified" - @assert !isnothing(dim) "dim must be specified" - - params = Dict( - :type => :QuadraticRegularizer, - :name => name, - :times => times, - :dim => dim, - :R => R, - :eval_hessian => eval_hessian - ) - - @views function L(Z⃗::AbstractVector{<:Real}, Z::NamedTrajectory) - J = 0.0 - for t ∈ times - if Z.timestep isa Symbol - Δt = Z⃗[slice(t, Z.components[timestep_symbol], Z.dim)] - else - Δt = Z.timestep - end - - vₜ = Z⃗[slice(t, Z.components[name], Z.dim)] - rₜ = Δt .* vₜ - J += 0.5 * rₜ' * (R .* rₜ) - end - return J - end - - @views function ∇L(Z⃗::AbstractVector{<:Real}, Z::NamedTrajectory) - ∇ = zeros(Z.dim * Z.T) - Threads.@threads for t ∈ times - vₜ_slice = slice(t, Z.components[name], Z.dim) - vₜ = Z⃗[vₜ_slice] - - if Z.timestep isa Symbol - Δt_slice = slice(t, Z.components[timestep_symbol], Z.dim) - Δt = Z⃗[Δt_slice] - ∇[Δt_slice] .= vₜ' * (R .* (Δt .* vₜ)) - else - Δt = Z.timestep - end - - ∇[vₜ_slice] .= R .* (Δt.^2 .* vₜ) - end - return ∇ - end - - ∂²L = nothing - ∂²L_structure = nothing - - if eval_hessian - - ∂²L_structure = Z -> begin - structure = [] - # Hessian structure (eq. 17) - for t ∈ times - vₜ_slice = slice(t, Z.components[name], Z.dim) - vₜ_vₜ_inds = collect(zip(vₜ_slice, vₜ_slice)) - append!(structure, vₜ_vₜ_inds) - - if Z.timestep isa Symbol - Δt_slice = slice(t, Z.components[timestep_symbol], Z.dim) - # ∂²_vₜ_Δt - vₜ_Δt_inds = [(i, j) for i ∈ vₜ_slice for j ∈ Δt_slice] - append!(structure, vₜ_Δt_inds) - # ∂²_Δt_vₜ - Δt_vₜ_inds = [(i, j) for i ∈ Δt_slice for j ∈ vₜ_slice] - append!(structure, Δt_vₜ_inds) - # ∂²_Δt_Δt - Δt_Δt_inds = collect(zip(Δt_slice, Δt_slice)) - append!(structure, Δt_Δt_inds) - end - end - return structure - end - - ∂²L = (Z⃗, Z) -> begin - values = [] - # Match Hessian structure indices - for t ∈ times - if Z.timestep isa Symbol - Δt = Z⃗[slice(t, Z.components[timestep_symbol], Z.dim)] - append!(values, R .* Δt.^2) - # ∂²_vₜ_Δt, ∂²_Δt_vₜ - vₜ = Z⃗[slice(t, Z.components[name], Z.dim)] - append!(values, 2 * (R .* (Δt .* vₜ))) - append!(values, 2 * (R .* (Δt .* vₜ))) - # ∂²_Δt_Δt - append!(values, vₜ' * (R .* vₜ)) - else - Δt = Z.timestep - append!(values, R .* Δt.^2) - end - end - return values - end - end - - return Objective(L, ∇L, ∂²L, ∂²L_structure, Dict[params]) -end - -function QuadraticRegularizer( - name::Symbol, - traj::NamedTrajectory, - R::AbstractVector{<:Real}; - kwargs... -) - return QuadraticRegularizer(; - name=name, - times=1:traj.T, - dim=traj.dim, - R=R, - kwargs... - ) -end - -function QuadraticRegularizer( - name::Symbol, - traj::NamedTrajectory, - R::Real; - kwargs... -) - return QuadraticRegularizer(; - name=name, - times=1:traj.T, - dim=traj.dim, - R=R * ones(traj.dims[name]), - kwargs... - ) -end - - -function QuadraticSmoothnessRegularizer(; - name::Symbol=nothing, - times::AbstractVector{Int}=1:traj.T, - R::AbstractVector{<:Real}=ones(traj.dims[name]), - eval_hessian=true -) - @assert !isnothing(name) "name must be specified" - @assert !isnothing(times) "times must be specified" - - params = Dict( - :type => :QuadraticSmoothnessRegularizer, - :name => name, - :times => times, - :R => R, - :eval_hessian => eval_hessian - ) - - @views function L(Z⃗::AbstractVector{<:Real}, Z::NamedTrajectory) - ∑Δv² = 0.0 - for t ∈ times[1:end-1] - vₜ₊₁ = Z⃗[slice(t + 1, Z.components[name], Z.dim)] - vₜ = Z⃗[slice(t, Z.components[name], Z.dim)] - Δv = vₜ₊₁ - vₜ - ∑Δv² += 0.5 * Δv' * (R .* Δv) - end - return ∑Δv² - end - - @views function ∇L(Z⃗::AbstractVector{<:Real}, Z::NamedTrajectory) - ∇ = zeros(Z.dim * Z.T) - Threads.@threads for t ∈ times[1:end-1] - - vₜ_slice = slice(t, Z.components[name], Z.dim) - vₜ₊₁_slice = slice(t + 1, Z.components[name], Z.dim) - - vₜ = Z⃗[vₜ_slice] - vₜ₊₁ = Z⃗[vₜ₊₁_slice] - - Δv = vₜ₊₁ - vₜ - - ∇[vₜ_slice] += -R .* Δv - ∇[vₜ₊₁_slice] += R .* Δv - end - return ∇ - end - ∂²L = nothing - ∂²L_structure = nothing - - if eval_hessian - - ∂²L_structure = Z -> begin - structure = [] - # u smoothness regularizer Hessian main diagonal structure - - for t ∈ times - - vₜ_slice = slice(t, Z.components[name], Z.dim) - - # main diagonal (2 if t != 1 or T-1) * Rₛ I - # components: ∂²vₜSₜ - - append!( - structure, - collect( - zip( - vₜ_slice, - vₜ_slice - ) - ) - ) - end - - - # u smoothness regularizer Hessian off diagonal structure - - for t ∈ times[1:end-1] - - vₜ_slice = slice(t, Z.components[name], Z.dim) - vₜ₊₁_slice = slice(t + 1, Z.components[name], Z.dim) - - # off diagonal -Rₛ I components: ∂vₜ₊₁∂vₜSₜ - - append!( - structure, - collect( - zip( - vₜ_slice, - vₜ₊₁_slice - ) - ) - ) - end - return structure - end - - ∂²L = (Z⃗, Z) -> begin - - H = [] - - # u smoothness regularizer Hessian main diagonal values - - append!(H, R) - - for t in times[2:end-1] - append!(H, 2 * R) - end - - append!(H, R) - - - # u smoothness regularizer Hessian off diagonal values - - for t in times[1:end-1] - append!(H, -R) - end - - return H - end - end - - return Objective(L, ∇L, ∂²L, ∂²L_structure, Dict[params]) -end - -function QuadraticSmoothnessRegularizer( - name::Symbol, - traj::NamedTrajectory, - R::AbstractVector{<:Real}; - kwargs... -) - return QuadraticSmoothnessRegularizer(; - name=name, - times=1:traj.T, - R=R, - kwargs... - ) -end - -function QuadraticSmoothnessRegularizer( - name::Symbol, - traj::NamedTrajectory, - R::Real; - kwargs... -) - return QuadraticSmoothnessRegularizer(; - name=name, - times=1:traj.T, - R=R * ones(traj.dims[name]), - kwargs... - ) -end - -function L1Regularizer(; - name=nothing, - R::Vector{Float64}=nothing, - times=nothing, - eval_hessian=true -) - @assert !isnothing(name) "name must be specified" - @assert !isnothing(R) "R must be specified" - @assert !isnothing(times) "times must be specified" - - s1_name = Symbol("s1_$name") - s2_name = Symbol("s2_$name") - - params = Dict( - :type => :L1Regularizer, - :name => name, - :R => R, - :eval_hessian => eval_hessian, - :times => times, - ) - - L = (Z⃗, Z) -> sum( - dot( - R, - Z⃗[slice(t, Z.components[s1_name], Z.dim)] + - Z⃗[slice(t, Z.components[s2_name], Z.dim)] - ) for t ∈ times - ) - - ∇L = (Z⃗, Z) -> begin - ∇ = zeros(typeof(Z⃗[1]), length(Z⃗)) - Threads.@threads for t ∈ times - ∇[slice(t, Z.components[s1_name], Z.dim)] += R - ∇[slice(t, Z.components[s2_name], Z.dim)] += R - end - return ∇ - end - - if eval_hessian - ∂²L = (_, _) -> [] - ∂²L_structure = _ -> [] - else - ∂²L = nothing - ∂²L_structure = nothing - end - - return Objective(L, ∇L, ∂²L, ∂²L_structure, Dict[params]) -end - -@doc raw""" - L1Regularizer( - name::Symbol; - R_value::Float64=10.0, - R::Vector{Float64}=fill(R_value, length(indices)), - eval_hessian=true - ) - -Create an L1 regularizer for the trajectory component `name` with regularization -strength `R`. The regularizer is defined as - -```math -J_{L1}(u) = \sum_t \abs{R \cdot u_t} -``` -""" -function L1Regularizer( - name::Symbol, - traj::NamedTrajectory; - indices::AbstractVector{Int}=1:traj.dims[name], - times=(name ∈ keys(traj.initial) ? 2 : 1):traj.T, - R_value::Float64=10.0, - R::Vector{Float64}=fill(R_value, length(indices)), - eval_hessian=true -) - J = L1Regularizer(; - name=name, - R=R, - times=times, - eval_hessian=eval_hessian - ) - - slack_con = L1SlackConstraint(name, traj; indices=indices, times=times) - - return J, slack_con -end - - -function MinimumTimeObjective(; - D::Float64=1.0, - Δt_indices::AbstractVector{Int}=nothing, - eval_hessian::Bool=true -) - @assert !isnothing(Δt_indices) "Δt_indices must be specified" - - params = Dict( - :type => :MinimumTimeObjective, - :D => D, - :Δt_indices => Δt_indices, - :eval_hessian => eval_hessian - ) - - # TODO: amend this for case of no TimeStepsAllEqualConstraint - L(Z⃗::AbstractVector, Z::NamedTrajectory) = D * sum(Z⃗[Δt_indices]) - - ∇L = (Z⃗::AbstractVector, Z::NamedTrajectory) -> begin - ∇ = zeros(typeof(Z⃗[1]), length(Z⃗)) - ∇[Δt_indices] .= D - return ∇ - end - - if eval_hessian - ∂²L = (Z⃗, Z) -> [] - ∂²L_structure = Z -> [] - else - ∂²L = nothing - ∂²L_structure = nothing - end - - return Objective(L, ∇L, ∂²L, ∂²L_structure, Dict[params]) -end - -function MinimumTimeObjective(traj::NamedTrajectory; D=1.0) - @assert traj.timestep isa Symbol "trajectory does not have a dynamical timestep" - Δt_indices = [index(t, traj.components[traj.timestep][1], traj.dim) for t = 1:traj.T] - return MinimumTimeObjective(; D=D, Δt_indices=Δt_indices) -end - -@doc raw""" -InfidelityRobustnessObjective( - Hₑ::AbstractMatrix{<:Number}, - Z::NamedTrajectory; - eval_hessian::Bool=false, - subspace::Union{AbstractVector{<:Integer}, Nothing}=nothing -) - -Create a control objective which penalizes the sensitivity of the infidelity -to the provided operator defined in the subspace of the control dynamics, -thereby realizing robust control. - -The control dynamics are -```math -U_C(a)= \prod_t \exp{-i H_C(a_t)} -``` - -In the control frame, the Hₑ operator is (proportional to) -```math -R_{Robust}(a) = \frac{1}{T \norm{H_e}_2} \sum_t U_C(a_t)^\dag H_e U_C(a_t) \Delta t -``` -where we have adjusted to a unitless expression of the operator. - -The robustness objective is -```math -R_{Robust}(a) = \frac{1}{N} \norm{R}^2_F -``` -where N is the dimension of the Hilbert space. -""" -function InfidelityRobustnessObjective( - Hₑ::AbstractMatrix{<:Number}, - Z::NamedTrajectory; - eval_hessian::Bool=false, - subspace::Union{AbstractVector{<:Integer}, Nothing}=nothing -) - # Indices of all non-zero subspace components for iso_vec_operators - function iso_vec_subspace(subspace::AbstractVector{<:Integer}, Z::NamedTrajectory) - d = isqrt(Z.dims[:Ũ⃗] ÷ 2) - A = zeros(Complex, d, d) - A[subspace, subspace] .= 1 + im - # Return any index where there is a 1. - return [ - j for (s, j) ∈ zip(operator_to_iso_vec(A), Z.components[:Ũ⃗]) - if convert(Bool, s) - ] - end - ivs = iso_vec_subspace(isnothing(subspace) ? collect(1:size(Hₑ, 1)) : subspace, Z) - - @views function get_timesteps(Z⃗::AbstractVector{<:Real}, Z::NamedTrajectory) - return map(1:Z.T) do t - if Z.timestep isa Symbol - Z⃗[slice(t, Z.components[Z.timestep], Z.dim)][1] - else - Z.timestep - end - end - end - - # Control frame - @views function toggle(Z⃗::AbstractVector{<:Real}, Z::NamedTrajectory) - Δts = get_timesteps(Z⃗, Z) - T = sum(Δts) - R = sum( - map(1:Z.T) do t - Uₜ = iso_vec_to_operator(Z⃗[slice(t, ivs, Z.dim)]) - Uₜ'Hₑ*Uₜ .* Δts[t] - end - ) / norm(Hₑ) / T - return R - end - - function L(Z⃗::AbstractVector{<:Real}, Z::NamedTrajectory) - R = toggle(Z⃗, Z) - return real(tr(R'R)) / size(R, 1) - end - - @views function ∇L(Z⃗::AbstractVector{<:Real}, Z::NamedTrajectory) - ∇ = zeros(Z.dim * Z.T) - R = toggle(Z⃗, Z) - Δts = get_timesteps(Z⃗, Z) - T = sum(Δts) - Threads.@threads for t ∈ 1:Z.T - # State gradients - Uₜ_slice = slice(t, ivs, Z.dim) - Uₜ = iso_vec_to_operator(Z⃗[Uₜ_slice]) - ∇[Uₜ_slice] .= 2 .* operator_to_iso_vec( - Hₑ * Uₜ * R .* Δts[t] - ) / norm(Hₑ) / T - # Time gradients - if Z.timestep isa Symbol - t_slice = slice(t, Z.components[Z.timestep], Z.dim) - ∂R = Uₜ'Hₑ*Uₜ - ∇[t_slice] .= tr(∂R*R + R*∂R) / norm(Hₑ) / T - end - end - return ∇ / size(R, 1) - end - - # Hessian is dense (Control frame R contains sum over all unitaries). - if eval_hessian - # TODO - ∂²L = (Z⃗, Z) -> [] - ∂²L_structure = Z -> [] - else - ∂²L = nothing - ∂²L_structure = nothing - end - - params = Dict( - :type => :QuantumRobustnessObjective, - :error => Hₑ, - :eval_hessian => eval_hessian - ) - - return Objective(L, ∇L, ∂²L, ∂²L_structure, Dict[params]) -end - - -end diff --git a/build/plotting.jl b/build/plotting.jl deleted file mode 100644 index c13d06d7..00000000 --- a/build/plotting.jl +++ /dev/null @@ -1,62 +0,0 @@ -module Plotting - -export plot_unitary_populations - -using NamedTrajectories - -using ..QuantumUtils -using ..Problems - -""" - plot_unitary_populations( - traj::NamedTrajectory; - unitary_columns::AbstractVector{Int}=1:2, - unitary_name::Symbol=:Ũ⃗, - control_name::Symbol=:a, - kwargs... - ) - - plot_unitary_populations( - prob::QuantumControlProblem; - kwargs... - ) - -Plot the populations of the unitary columns of the unitary matrix in the trajectory. `kwargs` are passed to [`NamedTrajectories.plot`](https://aarontrowbridge.github.io/NamedTrajectories.jl/dev/generated/plotting/). -""" -function plot_unitary_populations end - -function plot_unitary_populations( - traj::NamedTrajectory; - unitary_columns::AbstractVector{Int}=1:2, - unitary_name::Symbol=:Ũ⃗, - control_name::Symbol=:a, - kwargs... -) - - transformations = OrderedDict( - unitary_name => [ - x -> populations(iso_vec_to_operator(x)[:, i]) - for i ∈ unitary_columns - ] - ) - - transformation_titles = OrderedDict( - unitary_name => [ - L"Populations: $\left| U_{:, %$(i)}(t) \right|^2$" - for i ∈ unitary_columns - ] - ) - - plot(traj, [control_name]; - transformations=transformations, - transformation_titles=transformation_titles, - include_transformation_labels=true, - kwargs... - ) -end - -function plot_unitary_populations(prob::QuantumControlProblem; kwargs...) - plot_unitary_populations(prob.trajectory; kwargs...) -end - -end diff --git a/build/problem_solvers.jl b/build/problem_solvers.jl deleted file mode 100644 index 860b58c0..00000000 --- a/build/problem_solvers.jl +++ /dev/null @@ -1,56 +0,0 @@ -module ProblemSolvers - -export solve! - -using ..Constraints -using ..Problems -using ..SaveLoadUtils -using ..IpoptOptions - -using NamedTrajectories -using MathOptInterface -const MOI = MathOptInterface - -function solve!( - prob::QuantumControlProblem; - init_traj=nothing, - save_path=nothing, - controls_save_path=nothing, - max_iter::Int=prob.options.max_iter, - linear_solver::String=prob.options.linear_solver, -) - prob.options.max_iter = max_iter - prob.options.linear_solver = linear_solver - - set!(prob.optimizer, prob.options) - - if !isnothing(init_traj) - initialize_trajectory!(prob, init_traj) - else - initialize_trajectory!(prob) - end - - MOI.optimize!(prob.optimizer) - - update_trajectory!(prob) - - slack_var_names = Symbol[] - for con in prob.params[:linear_constraints] - if con isa L1SlackConstraint - append!(slack_var_names, con.slack_names) - end - end - - prob.trajectory = remove_components(prob.trajectory, slack_var_names) - - if !isnothing(save_path) - save_problem(save_path, prob) - end - - # TODO: sort this out - # if !isnothing(controls_save_path) - # save_controls(prob, controls_save_path) - # end -end - -end diff --git a/build/problem_templates/_problem_templates.jl b/build/problem_templates/_problem_templates.jl deleted file mode 100644 index 6a60ea53..00000000 --- a/build/problem_templates/_problem_templates.jl +++ /dev/null @@ -1,32 +0,0 @@ -module ProblemTemplates - -export UnitarySmoothPulseProblem -export UnitaryMinimumTimeProblem -export UnitaryRobustnessProblem - -export QuantumStateSmoothPulseProblem -export QuantumStateMinimumTimeProblem - -using ..QuantumSystems -using ..QuantumUtils -using ..EmbeddedOperators -using ..Rollouts -using ..TrajectoryInitialization -using ..Objectives -using ..Constraints -using ..Integrators -using ..Problems -using ..IpoptOptions - -using NamedTrajectories -using LinearAlgebra -using Distributions -using JLD2 - -include("unitary_smooth_pulse_problem.jl") -include("unitary_minimum_time_problem.jl") -include("unitary_robustness_problem.jl") -include("quantum_state_smooth_pulse_problem.jl") -include("quantum_state_minimum_time_problem.jl") - -end diff --git a/build/problem_templates/quantum_state_minimum_time_problem.jl b/build/problem_templates/quantum_state_minimum_time_problem.jl deleted file mode 100644 index 18073f68..00000000 --- a/build/problem_templates/quantum_state_minimum_time_problem.jl +++ /dev/null @@ -1,68 +0,0 @@ -""" - QuantumStateMinimumTimeProblem - -TODO: Add documentation -""" -function QuantumStateMinimumTimeProblem end - -function QuantumStateMinimumTimeProblem( - trajectory::NamedTrajectory, - system::QuantumSystem, - objective::Objective, - integrators::Vector{<:AbstractIntegrator}, - constraints::Vector{<:AbstractConstraint}; - state_symbol::Symbol=:ψ̃, - D=1.0, - verbose::Bool=false, - ipopt_options::Options=Options(), - kwargs... -) - @assert state_symbol ∈ trajectory.names - - objective += MinimumTimeObjective(trajectory; D=D) - - final_fidelity = fidelity(trajectory[end][state_symbol], trajectory.goal[state_symbol]) - - fidelity_constraint = FinalQuantumStateFidelityConstraint( - state_symbol, - final_fidelity, - trajectory - ) - - push!(constraints, fidelity_constraint) - - return QuantumControlProblem( - system, - trajectory, - objective, - integrators; - constraints=constraints, - verbose=verbose, - ipopt_options=ipopt_options, - kwargs... - ) -end - -function QuantumStateMinimumTimeProblem( - data_path::String; - kwargs... -) - data = load(data_path) - system = data["system"] - trajectory = data["trajectory"] - objective = Objective(data["params"][:objective_terms]) - integrators = data["params"][:dynamics] - constraints = AbstractConstraint[ - data["params"][:linear_constraints]..., - NonlinearConstraint.(data["params"][:nonlinear_constraints])... - ] - return QuantumStateMinimumTimeProblem( - trajectory, - system, - objective, - integrators, - constraints; - build_trajectory_constraints=false, - kwargs... - ) -end diff --git a/build/problem_templates/quantum_state_smooth_pulse_problem.jl b/build/problem_templates/quantum_state_smooth_pulse_problem.jl deleted file mode 100644 index 1d35f8c9..00000000 --- a/build/problem_templates/quantum_state_smooth_pulse_problem.jl +++ /dev/null @@ -1,253 +0,0 @@ -""" - QuantumStateSmoothPulseProblem( - system::AbstractQuantumSystem, - ψ_init::Union{AbstractVector{<:Number}, Vector{<:AbstractVector{<:Number}}}, - ψ_goal::Union{AbstractVector{<:Number}, Vector{<:AbstractVector{<:Number}}}, - T::Int, - Δt::Float64; - kwargs... - ) - - QuantumStateSmoothPulseProblem( - H_drift::AbstractMatrix{<:Number}, - H_drives::Vector{<:AbstractMatrix{<:Number}}, - args...; - kwargs... - ) - -Create a quantum control problem for smooth pulse optimization of a quantum state trajectory. - -# Keyword Arguments - -# TODO: clean up this whole constructor - -""" -function QuantumStateSmoothPulseProblem end - -function QuantumStateSmoothPulseProblem( - system::AbstractQuantumSystem, - ψ_init::Union{AbstractVector{<:Number}, Vector{<:AbstractVector{<:Number}}}, - ψ_goal::Union{AbstractVector{<:Number}, Vector{<:AbstractVector{<:Number}}}, - T::Int, - Δt::Float64; - free_time=true, - init_trajectory::Union{NamedTrajectory, Nothing}=nothing, - a_bound::Float64=Inf, - a_bounds::Vector{Float64}=fill(a_bound, length(system.G_drives)), - a_guess::Union{Matrix{Float64}, Nothing}=nothing, - dda_bound::Float64=Inf, - dda_bounds::Vector{Float64}=fill(dda_bound, length(system.G_drives)), - Δt_min::Float64=0.5 * Δt, - Δt_max::Float64=1.5 * Δt, - drive_derivative_σ::Float64=0.01, - Q::Float64=100.0, - R=1e-2, - R_a::Union{Float64, Vector{Float64}}=R, - R_da::Union{Float64, Vector{Float64}}=R, - R_dda::Union{Float64, Vector{Float64}}=R, - R_L1::Float64=20.0, - max_iter::Int=1000, - linear_solver::String="mumps", - ipopt_options::Options=Options(), - constraints::Vector{<:AbstractConstraint}=AbstractConstraint[], - timesteps_all_equal::Bool=true, - L1_regularized_names=Symbol[], - L1_regularized_indices::NamedTuple=NamedTuple(), - verbose=false, -) - @assert all(name ∈ L1_regularized_names for name in keys(L1_regularized_indices) if !isempty(L1_regularized_indices[name])) - - if ψ_init isa AbstractVector{<:Number} && ψ_goal isa AbstractVector{<:Number} - ψ_inits = [ψ_init] - ψ_goals = [ψ_goal] - else - @assert length(ψ_init) == length(ψ_goal) - ψ_inits = ψ_init - ψ_goals = ψ_goal - end - - ψ_inits = Vector{ComplexF64}.(ψ_init) - ψ̃_inits = ket_to_iso.(ψ_init) - - ψ_goals = Vector{ComplexF64}.(ψ_goal) - ψ̃_goals = ket_to_iso.(ψ_goal) - - n_drives = length(system.G_drives) - - if !isnothing(init_trajectory) - traj = init_trajectory - else - if free_time - Δt = fill(Δt, T) - end - - if isnothing(a_guess) - ψ̃s = NamedTuple([ - Symbol("ψ̃$i") => linear_interpolation(ψ̃_init, ψ̃_goal, T) - for (i, (ψ̃_init, ψ̃_goal)) in enumerate(zip(ψ̃_inits, ψ̃_goals)) - ]) - a_dists = [Uniform(-a_bounds[i], a_bounds[i]) for i = 1:n_drives] - a = hcat([ - zeros(n_drives), - vcat([rand(a_dists[i], 1, T - 2) for i = 1:n_drives]...), - zeros(n_drives) - ]...) - da = randn(n_drives, T) * drive_derivative_σ - dda = randn(n_drives, T) * drive_derivative_σ - else - ψ̃s = NamedTuple([ - Symbol("ψ̃$i") => rollout(ψ̃_init, a_guess, Δt, system) - for (i, ψ̃_init) in enumerate(ψ̃_inits) - ]) - a = a_guess - da = derivative(a, Δt) - dda = derivative(da, Δt) - end - - ψ̃_initial = NamedTuple([ - Symbol("ψ̃$i") => ψ̃_init - for (i, ψ̃_init) in enumerate(ψ̃_inits) - ]) - - control_initial = ( - a = zeros(n_drives), - ) - - initial = merge(ψ̃_initial, control_initial) - - final = ( - a = zeros(n_drives), - ) - - goal = NamedTuple([ - Symbol("ψ̃$i") => ψ̃_goal - for (i, ψ̃_goal) in enumerate(ψ̃_goals) - ]) - - if free_time - - control_components = ( - a = a, - da = da, - dda = dda, - Δt = Δt, - ) - - components = merge(ψ̃s, control_components) - - bounds = ( - a = a_bounds, - dda = dda_bounds, - Δt = (Δt_min, Δt_max), - ) - - traj = NamedTrajectory( - components; - controls=(:dda, :Δt), - timestep=:Δt, - bounds=bounds, - initial=initial, - final=final, - goal=goal - ) - else - control_components = ( - a = a, - da = da, - dda = dda, - ) - - components = merge(ψ̃s, control_components) - - bounds = ( - a = a_bounds, - dda = dda_bounds, - ) - - traj = NamedTrajectory( - components; - controls=(:dda,), - timestep=Δt, - bounds=bounds, - initial=initial, - final=final, - goal=goal - ) - end - end - - J = QuadraticRegularizer(:a, traj, R_a) - J += QuadraticRegularizer(:da, traj, R_da) - J += QuadraticRegularizer(:dda, traj, R_dda) - - for i = 1:length(ψ_inits) - J += QuantumStateObjective(Symbol("ψ̃$i"), traj, Q) - end - - L1_slack_constraints = [] - - for name in L1_regularized_names - if name in keys(L1_regularized_indices) - J_L1, slack_con = L1Regularizer(name, traj; R_value=R_L1, indices=L1_regularized_indices[name]) - else - J_L1, slack_con = L1Regularizer(name, traj; R_value=R_L1) - end - J += J_L1 - push!(L1_slack_constraints, slack_con) - end - - append!(constraints, L1_slack_constraints) - - if free_time - - ψ̃_integrators = [ - QuantumStatePadeIntegrator(system, Symbol("ψ̃$i"), :a) - for i = 1:length(ψ_inits) - ] - - integrators = [ - ψ̃_integrators..., - DerivativeIntegrator(:a, :da, traj), - DerivativeIntegrator(:da, :dda, traj) - ] - else - ψ̃_integrators = [ - QuantumStatePadeIntegrator(system, Symbol("ψ̃$i"), :a) - for i = 1:length(ψ_inits) - ] - - integrators = [ - ψ̃_integrators..., - DerivativeIntegrator(:a, :da, traj), - DerivativeIntegrator(:da, :dda, traj) - ] - end - - if free_time - if timesteps_all_equal - push!(constraints, TimeStepsAllEqualConstraint(:Δt, traj)) - end - end - - return QuantumControlProblem( - system, - traj, - J, - integrators; - constraints=constraints, - max_iter=max_iter, - linear_solver=linear_solver, - verbose=verbose, - ipopt_options=ipopt_options, - ) -end - -function QuantumStateSmoothPulseProblem( - H_drift::AbstractMatrix{<:Number}, - H_drives::Vector{<:AbstractMatrix{<:Number}}, - args...; - kwargs... -) - system = QuantumSystem(H_drift, H_drives) - return QuantumStateSmoothPulseProblem(system, args...; kwargs...) -end diff --git a/build/problem_templates/unitary_minimum_time_problem.jl b/build/problem_templates/unitary_minimum_time_problem.jl deleted file mode 100644 index 2a9c0ca2..00000000 --- a/build/problem_templates/unitary_minimum_time_problem.jl +++ /dev/null @@ -1,135 +0,0 @@ -@doc raw""" - UnitaryMinimumTimeProblem( - trajectory::NamedTrajectory, - system::AbstractQuantumSystem, - objective::Objective, - integrators::Vector{<:AbstractIntegrator}, - constraints::Vector{<:AbstractConstraint}; - kwargs... - ) - - UnitaryMinimumTimeProblem( - prob::QuantumControlProblem; - kwargs... - ) - - UnitaryMinimumTimeProblem( - data_path::String; - kwargs... - ) - -Create a minimum-time problem for unitary control. - -```math -\begin{aligned} -\underset{\vec{\tilde{U}}, a, \dot{a}, \ddot{a}, \Delta t}{\text{minimize}} & \quad -J(\vec{\tilde{U}}, a, \dot{a}, \ddot{a}) + D \sum_t \Delta t_t \\ -\text{ subject to } & \quad \vb{P}^{(n)}\qty(\vec{\tilde{U}}_{t+1}, \vec{\tilde{U}}_t, a_t, \Delta t_t) = 0 \\ -& c(\vec{\tilde{U}}, a, \dot{a}, \ddot{a}) = 0 \\ -& \quad \Delta t_{\text{min}} \leq \Delta t_t \leq \Delta t_{\text{max}} \\ -\end{aligned} -``` - -# Arguments -- `trajectory::NamedTrajectory`: The initial trajectory. -- `system::AbstractQuantumSystem`: The quantum system. -- `objective::Objective`: The objective function (additional to the minimum-time objective). -- `integrators::Vector{<:AbstractIntegrator}`: The integrators. -- `constraints::Vector{<:AbstractConstraint}`: The constraints. - -# Keyword Arguments -- `unitary_symbol::Symbol=:Ũ⃗`: The symbol for the unitary control. -- `final_fidelity::Float64=0.99`: The final fidelity. -- `D=1.0`: The weight for the minimum-time objective. -- `verbose::Bool=false`: Whether to print additional information. -- `ipopt_options::Options=Options()`: The options for the Ipopt solver. -- `kwargs...`: Additional keyword arguments to pass to `QuantumControlProblem`. -""" -function UnitaryMinimumTimeProblem end - -function UnitaryMinimumTimeProblem( - trajectory::NamedTrajectory, - system::AbstractQuantumSystem, - objective::Objective, - integrators::Vector{<:AbstractIntegrator}, - constraints::Vector{<:AbstractConstraint}; - unitary_symbol::Symbol=:Ũ⃗, - final_fidelity::Float64=0.99, - D=1.0, - verbose::Bool=false, - ipopt_options::Options=Options(), - subspace=nothing, - kwargs... -) - @assert unitary_symbol ∈ trajectory.names - - objective += MinimumTimeObjective(trajectory; D=D) - - fidelity_constraint = FinalUnitaryFidelityConstraint( - unitary_symbol, - final_fidelity, - trajectory; - subspace=subspace - ) - - constraints = AbstractConstraint[constraints..., fidelity_constraint] - - return QuantumControlProblem( - system, - trajectory, - objective, - integrators; - constraints=constraints, - verbose=verbose, - ipopt_options=ipopt_options, - kwargs... - ) -end - -function UnitaryMinimumTimeProblem( - prob::QuantumControlProblem; - kwargs... -) - params = deepcopy(prob.params) - trajectory = copy(prob.trajectory) - system = prob.system - objective = Objective(params[:objective_terms]) - integrators = prob.integrators - constraints = [ - params[:linear_constraints]..., - NonlinearConstraint.(params[:nonlinear_constraints])... - ] - return UnitaryMinimumTimeProblem( - trajectory, - system, - objective, - integrators, - constraints; - build_trajectory_constraints=false, - kwargs... - ) -end - -function UnitaryMinimumTimeProblem( - data_path::String; - kwargs... -) - data = load(data_path) - system = data["system"] - trajectory = data["trajectory"] - objective = Objective(data["params"][:objective_terms]) - integrators = data["integrators"] - constraints = AbstractConstraint[ - data["params"][:linear_constraints]..., - NonlinearConstraint.(data["params"][:nonlinear_constraints])... - ] - return UnitaryMinimumTimeProblem( - trajectory, - system, - objective, - integrators, - constraints; - build_trajectory_constraints=false, - kwargs... - ) -end diff --git a/build/problem_templates/unitary_robustness_problem.jl b/build/problem_templates/unitary_robustness_problem.jl deleted file mode 100644 index cfb9f9d3..00000000 --- a/build/problem_templates/unitary_robustness_problem.jl +++ /dev/null @@ -1,94 +0,0 @@ -@doc raw""" - UnitaryRobustnessProblem(Hₑ, trajectory, system, objective, integrators, constraints; - unitary_symbol=:Ũ⃗, - final_fidelity=unitary_fidelity(trajectory[end][unitary_symbol], trajectory.goal[unitary_symbol]), - subspace=nothing, - eval_hessian=false, - verbose=false, - ipopt_options=Options(), - kwargs... - ) - - UnitaryRobustnessProblem(Hₑ, prob::QuantumControlProblem; kwargs...) - -Create a quantum control problem for robustness optimization of a unitary trajectory. -""" -function UnitaryRobustnessProblem end - - -function UnitaryRobustnessProblem( - Hₑ::AbstractMatrix{<:Number}, - trajectory::NamedTrajectory, - system::QuantumSystem, - objective::Objective, - integrators::Vector{<:AbstractIntegrator}, - constraints::Vector{<:AbstractConstraint}; - unitary_symbol::Symbol=:Ũ⃗, - final_fidelity::Float64=unitary_fidelity(trajectory[end][unitary_symbol], trajectory.goal[unitary_symbol]), - subspace::Union{AbstractVector{<:Integer}, Nothing}=nothing, - eval_hessian::Bool=false, - verbose::Bool=false, - ipopt_options::Options=Options(), - kwargs... -) - @assert unitary_symbol ∈ trajectory.names - - if !eval_hessian - ipopt_options.hessian_approximation = "limited-memory" - end - - objective += InfidelityRobustnessObjective( - Hₑ, - trajectory, - eval_hessian=eval_hessian, - subspace=subspace - ) - - fidelity_constraint = FinalUnitaryFidelityConstraint( - unitary_symbol, - final_fidelity, - trajectory; - subspace=subspace - ) - - constraints = AbstractConstraint[constraints..., fidelity_constraint] - - return QuantumControlProblem( - system, - trajectory, - objective, - integrators; - constraints=constraints, - verbose=verbose, - ipopt_options=ipopt_options, - eval_hessian=eval_hessian, - kwargs... - ) -end - -function UnitaryRobustnessProblem( - Hₑ::AbstractMatrix{<:Number}, - prob::QuantumControlProblem; - kwargs... -) - params = deepcopy(prob.params) - trajectory = copy(prob.trajectory) - system = prob.system - objective = Objective(params[:objective_terms]) - integrators = prob.integrators - constraints = [ - params[:linear_constraints]..., - NonlinearConstraint.(params[:nonlinear_constraints])... - ] - - return UnitaryRobustnessProblem( - Hₑ, - trajectory, - system, - objective, - integrators, - constraints; - build_trajectory_constraints=false, - kwargs... - ) -end diff --git a/build/problem_templates/unitary_smooth_pulse_problem.jl b/build/problem_templates/unitary_smooth_pulse_problem.jl deleted file mode 100644 index 504cfdc1..00000000 --- a/build/problem_templates/unitary_smooth_pulse_problem.jl +++ /dev/null @@ -1,292 +0,0 @@ -@doc raw""" - UnitarySmoothPulseProblem(H_drift, H_drives, operator, T, Δt; kwargs...) - UnitarySmoothPulseProblem(system::QuantumSystem, operator, T, Δt; kwargs...) - -Construct a `QuantumControlProblem` for a free-time unitary gate problem with smooth control pulses enforced by constraining the second derivative of the pulse trajectory, i.e., - -```math -\begin{aligned} -\underset{\vec{\tilde{U}}, a, \dot{a}, \ddot{a}, \Delta t}{\text{minimize}} & \quad -Q \cdot \ell\qty(\vec{\tilde{U}}_T, \vec{\tilde{U}}_{\text{goal}}) + \frac{1}{2} \sum_t \qty(R_a a_t^2 + R_{\dot{a}} \dot{a}_t^2 + R_{\ddot{a}} \ddot{a}_t^2) \\ -\text{ subject to } & \quad \vb{P}^{(n)}\qty(\vec{\tilde{U}}_{t+1}, \vec{\tilde{U}}_t, a_t, \Delta t_t) = 0 \\ -& a_{t+1} - a_t - \dot{a}_t \Delta t_t = 0 \\ -& \quad \dot{a}_{t+1} - \dot{a}_t - \ddot{a}_t \Delta t_t = 0 \\ -& \quad |a_t| \leq a_{\text{bound}} \\ -& \quad |\ddot{a}_t| \leq \ddot{a}_{\text{bound}} \\ -& \quad \Delta t_{\text{min}} \leq \Delta t_t \leq \Delta t_{\text{max}} \\ -\end{aligned} -``` - -where, for $U \in SU(N)$, - -```math -\ell\qty(\vec{\tilde{U}}_T, \vec{\tilde{U}}_{\text{goal}}) = -\abs{1 - \frac{1}{N} \abs{ \tr \qty(U_{\text{goal}}, U_T)} } -``` - -is the *infidelity* objective function, $Q$ is a weight, $R_a$, $R_{\dot{a}}$, and $R_{\ddot{a}}$ are weights on the regularization terms, and $\vb{P}^{(n)}$ is the $n$th-order Pade integrator. - -# Arguments - -- `H_drift::AbstractMatrix{<:Number}`: the drift hamiltonian -- `H_drives::Vector{<:AbstractMatrix{<:Number}}`: the control hamiltonians -or -- `system::QuantumSystem`: the system to be controlled -with -- `operator::Union{EmbeddedOperator, AbstractMatrix{<:Number}}`: the target unitary, either in the form of an `EmbeddedOperator` or a `Matrix{ComplexF64} -- `T::Int`: the number of timesteps -- `Δt::Float64`: the (initial) time step size - -# Keyword Arguments -- `free_time::Bool=true`: whether or not to allow the time steps to vary -- `init_trajectory::Union{NamedTrajectory, Nothing}=nothing`: an initial trajectory to use -- `a_bound::Float64=1.0`: the bound on the control pulse -- `a_bounds::Vector{Float64}=fill(a_bound, length(system.G_drives))`: the bounds on the control pulses, one for each drive -- `a_guess::Union{Matrix{Float64}, Nothing}=nothing`: an initial guess for the control pulses -- `dda_bound::Float64=1.0`: the bound on the control pulse derivative -- `dda_bounds::Vector{Float64}=fill(dda_bound, length(system.G_drives))`: the bounds on the control pulse derivatives, one for each drive -- `Δt_min::Float64=0.5 * Δt`: the minimum time step size -- `Δt_max::Float64=1.5 * Δt`: the maximum time step size -- `drive_derivative_σ::Float64=0.01`: the standard deviation of the initial guess for the control pulse derivatives -- `Q::Float64=100.0`: the weight on the infidelity objective -- `R=1e-2`: the weight on the regularization terms -- `R_a::Union{Float64, Vector{Float64}}=R`: the weight on the regularization term for the control pulses -- `R_da::Union{Float64, Vector{Float64}}=R`: the weight on the regularization term for the control pulse derivatives -- `R_dda::Union{Float64, Vector{Float64}}=R`: the weight on the regularization term for the control pulse second derivatives -- `leakage_suppression::Bool=false`: whether or not to suppress leakage to higher energy states -- `R_leakage=1e-1`: the weight on the leakage suppression term -- `max_iter::Int=1000`: the maximum number of iterations for the solver -- `linear_solver::String="mumps"`: the linear solver to use -- `ipopt_options::Options=Options()`: the options for the Ipopt solver -- `constraints::Vector{<:AbstractConstraint}=AbstractConstraint[]`: additional constraints to add to the problem -- `timesteps_all_equal::Bool=true`: whether or not to enforce that all time steps are equal -- `verbose::Bool=false`: whether or not to print constructor output -- `integrator=Integrators.fourth_order_pade`: the integrator to use for the unitary -- `geodesic=true`: whether or not to use the geodesic as the initial guess for the unitary -- `pade_order=4`: the order of the Pade approximation to use for the unitary integrator -- `autodiff=pade_order != 4`: whether or not to use automatic differentiation for the unitary integrator -- `subspace=nothing`: the subspace to use for the unitary integrator -- `jacobian_structure=true`: whether or not to use the jacobian structure -- `hessian_approximation=false`: whether or not to use L-BFGS hessian approximation in Ipopt -- `blas_multithreading=true`: whether or not to use multithreading in BLAS -""" -function UnitarySmoothPulseProblem end - -function UnitarySmoothPulseProblem( - system::AbstractQuantumSystem, - operator::Union{EmbeddedOperator, AbstractMatrix{<:Number}}, - T::Int, - Δt::Float64; - free_time=true, - init_trajectory::Union{NamedTrajectory, Nothing}=nothing, - a_bound::Float64=1.0, - a_bounds::Vector{Float64}=fill(a_bound, length(system.G_drives)), - a_guess::Union{Matrix{Float64}, Nothing}=nothing, - dda_bound::Float64=1.0, - dda_bounds::Vector{Float64}=fill(dda_bound, length(system.G_drives)), - Δt_min::Float64=0.5 * Δt, - Δt_max::Float64=1.5 * Δt, - drive_derivative_σ::Float64=0.01, - Q::Float64=100.0, - R=1e-2, - R_a::Union{Float64, Vector{Float64}}=R, - R_da::Union{Float64, Vector{Float64}}=R, - R_dda::Union{Float64, Vector{Float64}}=R, - leakage_suppression=false, - R_leakage=1e-1, - max_iter::Int=1000, - linear_solver::String="mumps", - ipopt_options::Options=Options(), - constraints::Vector{<:AbstractConstraint}=AbstractConstraint[], - timesteps_all_equal::Bool=true, - verbose::Bool=false, - integrator=Integrators.fourth_order_pade, - geodesic=true, - pade_order=4, - autodiff=pade_order != 4, - jacobian_structure=true, - hessian_approximation=false, - blas_multithreading=true, -) - if operator isa EmbeddedOperator - U_goal = operator.operator - U_init = get_subspace_identity(operator) - else - U_goal = Matrix{ComplexF64}(operator) - U_init = Matrix{ComplexF64}(I(size(U_goal, 1))) - end - - if !blas_multithreading - BLAS.set_num_threads(1) - end - - if hessian_approximation - ipopt_options.hessian_approximation = "limited-memory" - end - - - n_drives = length(system.G_drives) - - if !isnothing(init_trajectory) - traj = init_trajectory - else - if free_time - Δt = fill(Δt, 1, T) - end - - if isnothing(a_guess) - if geodesic - if operator isa EmbeddedOperator - Ũ⃗ = unitary_geodesic(operator, T) - else - Ũ⃗ = unitary_geodesic(U_goal, T) - end - else - Ũ⃗ = unitary_linear_interpolation(U_init, U_goal, T) - end - - a_dists = [Uniform(-a_bounds[i], a_bounds[i]) for i = 1:n_drives] - - a = hcat([ - zeros(n_drives), - vcat([rand(a_dists[i], 1, T - 2) for i = 1:n_drives]...), - zeros(n_drives) - ]...) - - da = randn(n_drives, T) * drive_derivative_σ - dda = randn(n_drives, T) * drive_derivative_σ - else - Ũ⃗ = unitary_rollout( - operator_to_iso_vec(U_init), - a_guess, - Δt, - system; - integrator=integrator - ) - a = a_guess - da = derivative(a, Δt) - dda = derivative(da, Δt) - end - - initial = ( - Ũ⃗ = operator_to_iso_vec(U_init), - a = zeros(n_drives), - ) - - final = ( - a = zeros(n_drives), - ) - - goal = ( - Ũ⃗ = operator_to_iso_vec(U_goal), - ) - - if free_time - components = ( - Ũ⃗ = Ũ⃗, - a = a, - da = da, - dda = dda, - Δt = Δt, - ) - - bounds = ( - a = a_bounds, - dda = dda_bounds, - Δt = (Δt_min, Δt_max), - ) - - traj = NamedTrajectory( - components; - controls=(:dda, :Δt), - timestep=:Δt, - bounds=bounds, - initial=initial, - final=final, - goal=goal - ) - else - components = ( - Ũ⃗ = Ũ⃗, - a = a, - da = da, - dda = dda, - ) - - bounds = ( - a = a_bounds, - dda = dda_bounds, - ) - - traj = NamedTrajectory( - components; - controls=(:dda,), - timestep=Δt, - bounds=bounds, - initial=initial, - final=final, - goal=goal - ) - end - end - - J = UnitaryInfidelityObjective(:Ũ⃗, traj, Q; - subspace=operator isa EmbeddedOperator ? operator.subspace_indices : nothing, - ) - J += QuadraticRegularizer(:a, traj, R_a) - J += QuadraticRegularizer(:da, traj, R_da) - J += QuadraticRegularizer(:dda, traj, R_dda) - - if leakage_suppression - if operator isa EmbeddedOperator - leakage_indices = get_unitary_isomorphism_leakage_indices(operator) - J_leakage, slack_con = L1Regularizer( - :Ũ⃗, - traj; - R_value=R_leakage, - indices=leakage_indices - ) - push!(constraints, slack_con) - J += J_leakage - else - @warn "leakage_suppression is not supported for non-embedded operators, ignoring." - end - end - - integrators = [ - UnitaryPadeIntegrator(system, :Ũ⃗, :a; order=pade_order, autodiff=autodiff), - DerivativeIntegrator(:a, :da, traj), - DerivativeIntegrator(:da, :dda, traj), - ] - - if free_time - if timesteps_all_equal - push!(constraints, TimeStepsAllEqualConstraint(:Δt, traj)) - end - end - - return QuantumControlProblem( - system, - traj, - J, - integrators; - constraints=constraints, - max_iter=max_iter, - linear_solver=linear_solver, - verbose=verbose, - ipopt_options=ipopt_options, - jacobian_structure=jacobian_structure, - hessian_approximation=hessian_approximation, - eval_hessian=!hessian_approximation - ) -end - -function UnitarySmoothPulseProblem( - H_drift::AbstractMatrix{<:Number}, - H_drives::Vector{<:AbstractMatrix{<:Number}}, - args...; - kwargs... -) - system = QuantumSystem(H_drift, H_drives) - return UnitarySmoothPulseProblem(system, args...; kwargs...) -end diff --git a/build/problems.jl b/build/problems.jl deleted file mode 100644 index 04e83a81..00000000 --- a/build/problems.jl +++ /dev/null @@ -1,290 +0,0 @@ -module Problems - -export AbstractProblem -export FixedTimeProblem -export QuantumControlProblem - -export initialize_trajectory! -export update_trajectory! -export get_traj_data -export get_datavec - -using ..QuantumSystems -using ..Integrators -using ..Evaluators -using ..IpoptOptions -using ..Constraints -using ..Dynamics -using ..Objectives - -using TrajectoryIndexingUtils -using NamedTrajectories -using JLD2 -using Ipopt -using MathOptInterface -const MOI = MathOptInterface - -abstract type AbstractProblem end - -""" - mutable struct QuantumControlProblem <: AbstractProblem - -Stores all the information needed to set up and solve a QuantumControlProblem as well as the solution -after the solver terminates. - -# Fields -- `optimizer::Ipopt.Optimizer`: Ipopt optimizer object -""" -mutable struct QuantumControlProblem <: AbstractProblem - optimizer::Ipopt.Optimizer - variables::Matrix{MOI.VariableIndex} - system::AbstractQuantumSystem - trajectory::NamedTrajectory - integrators::Union{Nothing,Vector{<:AbstractIntegrator}} - options::Options - params::Dict{Symbol, Any} -end - -function QuantumControlProblem( - system::AbstractQuantumSystem, - traj::NamedTrajectory, - obj::Objective, - dynamics::QuantumDynamics; - eval_hessian::Bool=true, - options::Options=Options(), - constraints::Vector{<:AbstractConstraint}=AbstractConstraint[], - params::Dict{Symbol, Any}=Dict{Symbol, Any}(), - max_iter::Int=options.max_iter, - linear_solver::String=options.linear_solver, - verbose=false, - build_trajectory_constraints::Bool=true, - kwargs... -) - options.max_iter = max_iter - options.linear_solver = linear_solver - - nonlinear_constraints = NonlinearConstraint[con for con ∈ constraints if con isa NonlinearConstraint] - - if verbose - println(" building evaluator...") - end - evaluator = PicoEvaluator(traj, obj, dynamics, nonlinear_constraints, eval_hessian) - - n_dynamics_constraints = dynamics.dim * (traj.T - 1) - n_variables = traj.dim * traj.T - - linear_constraints = LinearConstraint[con for con ∈ constraints if con isa LinearConstraint] - - if build_trajectory_constraints - linear_constraints = LinearConstraint[trajectory_constraints(traj); linear_constraints] - end - - optimizer = Ipopt.Optimizer() - - if verbose - println(" initializing optimizer...") - end - - variables = initialize_optimizer!( - optimizer, - evaluator, - traj, - linear_constraints, - n_dynamics_constraints, - nonlinear_constraints, - n_variables - ) - - variables = reshape(variables, traj.dim, traj.T) - - params = merge(kwargs, params) - - params[:eval_hessian] = eval_hessian - params[:options] = options - params[:linear_constraints] = linear_constraints - params[:nonlinear_constraints] = [ - nl_constraint.params for nl_constraint ∈ nonlinear_constraints - ] - params[:objective_terms] = obj.terms - - return QuantumControlProblem( - optimizer, - variables, - system, - traj, - dynamics.integrators, - options, - params - ) -end - -function QuantumControlProblem( - system::AbstractQuantumSystem, - traj::NamedTrajectory, - obj::Objective, - integrators::Vector{<:AbstractIntegrator}; - params::Dict{Symbol,Any}=Dict{Symbol, Any}(), - ipopt_options::Options=Options(), - verbose=false, - jacobian_structure=true, - hessian_approximation=false, - kwargs... -) - if verbose - println(" building dynamics from integrators...") - end - dynamics = QuantumDynamics(integrators, traj; - jacobian_structure=jacobian_structure, - hessian_approximation=hessian_approximation, - verbose=verbose - ) - return QuantumControlProblem( - system, - traj, - obj, - dynamics; - options=ipopt_options, - params=params, - verbose=verbose, - kwargs... - ) -end - -# constructor that accepts just an AbstractIntegrator -function QuantumControlProblem( - system::AbstractQuantumSystem, - traj::NamedTrajectory, - obj::Objective, - integrator::AbstractIntegrator; - params::Dict{Symbol,Any}=Dict{Symbol, Any}(), - ipopt_options::Options=Options(), - verbose=false, - jacobian_structure=true, - hessian_approximation=false, - kwargs... -) - if verbose - println(" building dynamics from integrator...") - end - dynamics = QuantumDynamics(integrator, traj; - jacobian_structure=jacobian_structure, - hessian_approximation=hessian_approximation, - verbose=verbose - ) - return QuantumControlProblem( - system, - traj, - obj, - dynamics; - options=ipopt_options, - params=params, - verbose=verbose, - kwargs... - ) -end - -function QuantumControlProblem( - system::AbstractQuantumSystem, - traj::NamedTrajectory, - obj::Objective, - f::Function; - params::Dict{Symbol,Any}=Dict{Symbol, Any}(), - ipopt_options::Options=Options(), - verbose=false, - jacobian_structure=true, - hessian_approximation=false, - kwargs... -) - if verbose - println(" building dynamics from function...") - end - dynamics = QuantumDynamics(f, traj; - jacobian_structure=jacobian_structure, - hessian_approximation=hessian_approximation, - verbose=verbose - ) - return QuantumControlProblem( - system, - traj, - obj, - dynamics; - options=ipopt_options, - params=params, - verbose=verbose, - kwargs... - ) -end - -function initialize_optimizer!( - optimizer::Ipopt.Optimizer, - evaluator::PicoEvaluator, - trajectory::NamedTrajectory, - linear_constraints::Vector{LinearConstraint}, - n_dynamics_constraints::Int, - nonlinear_constraints::Vector{NonlinearConstraint}, - n_variables::Int -) - nl_cons = fill( - MOI.NLPBoundsPair(0.0, 0.0), - n_dynamics_constraints - ) - - for nl_con ∈ nonlinear_constraints - if nl_con isa NonlinearEqualityConstraint - append!(nl_cons, fill(MOI.NLPBoundsPair(0.0, 0.0), nl_con.dim)) - elseif nl_con isa NonlinearInequalityConstraint - append!(nl_cons, fill(MOI.NLPBoundsPair(0.0, Inf), nl_con.dim)) - else - error("Unknown nonlinear constraint type") - end - end - - # build NLP block data - block_data = MOI.NLPBlockData(nl_cons, evaluator, true) - - # set NLP block data - MOI.set(optimizer, MOI.NLPBlock(), block_data) - - # set objective sense: minimize - MOI.set(optimizer, MOI.ObjectiveSense(), MOI.MIN_SENSE) - - # add variables - variables = MOI.add_variables(optimizer, n_variables) - - # add linear constraints - constrain!(optimizer, variables, linear_constraints, trajectory, verbose=true) - - return variables -end - -function initialize_trajectory!( - prob::QuantumControlProblem, - traj::NamedTrajectory -) - MOI.set( - prob.optimizer, - MOI.VariablePrimalStart(), - vec(prob.variables), - collect(traj.datavec) - ) -end - -initialize_trajectory!(prob::QuantumControlProblem) = - initialize_trajectory!(prob, prob.trajectory) - -function get_datavec(prob::QuantumControlProblem) - Z⃗ = MOI.get( - prob.optimizer, - MOI.VariablePrimal(), - vec(prob.variables) - ) - return Z⃗ -end - -@views function update_trajectory!(prob::QuantumControlProblem) - Z⃗ = get_datavec(prob) - prob.trajectory = NamedTrajectory(Z⃗, prob.trajectory) -end - - -end diff --git a/build/quantum_system_templates/_quantum_system_templates.jl b/build/quantum_system_templates/_quantum_system_templates.jl deleted file mode 100644 index 51694174..00000000 --- a/build/quantum_system_templates/_quantum_system_templates.jl +++ /dev/null @@ -1,14 +0,0 @@ -module QuantumSystemTemplates - -export TransmonSystem -export TransmonDipoleCoupling -export MultiTransmonSystem - -using ..QuantumUtils -using ..QuantumSystems - -using LinearAlgebra - -include("transmons.jl") - -end diff --git a/build/quantum_system_templates/transmons.jl b/build/quantum_system_templates/transmons.jl deleted file mode 100644 index 7c75405b..00000000 --- a/build/quantum_system_templates/transmons.jl +++ /dev/null @@ -1,239 +0,0 @@ -@doc raw""" - TransmonSystem(; - ω::Float64=4.4153, # GHz - δ::Float64=0.17215, # GHz - levels::Int=3, - lab_frame::Bool=false, - frame_ω::Float64=ω, - ) -> QuantumSystem - -Returns a `QuantumSystem` object for a transmon qubit, with the Hamiltonian - -```math -H = \omega a^\dagger a - \frac{\delta}{2} a^\dagger a^\dagger a a -``` - -where `a` is the annihilation operator. - -# Keyword Arguments -- `ω`: The frequency of the transmon, in GHz. -- `δ`: The anharmonicity of the transmon, in GHz. -- `levels`: The number of levels in the transmon. -- `lab_frame`: Whether to use the lab frame Hamiltonian, or an ω-rotating frame. -- `frame_ω`: The frequency of the rotating frame, in GHz. -- `mutiply_by_2π`: Whether to multiply the Hamiltonian by 2π, set to true by default because the frequency is in GHz. -- `lab_frame_type`: The type of lab frame Hamiltonian to use, one of (:duffing, :quartic, :cosine). -- `drives`: Whether to include drives in the Hamiltonian. -""" -function TransmonSystem(; - ω::Float64=4.0, # GHz - δ::Float64=0.2, # GHz - levels::Int=3, - lab_frame::Bool=false, - frame_ω::Float64=lab_frame ? 0.0 : ω, - mutiply_by_2π::Bool=true, - lab_frame_type::Symbol=:duffing, - drives::Bool=true, -) - - @assert lab_frame_type ∈ (:duffing, :quartic, :cosine) "lab_frame_type must be one of (:duffing, :quartic, :cosine)" - - if lab_frame - if frame_ω ≉ 0.0 - frame_ω = 0.0 - end - end - - if frame_ω ≉ 0.0 - lab_frame = false - end - - a = annihilate(levels) - - if lab_frame - if lab_frame_type == :duffing - H_drift = ω * a' * a - δ / 2 * a' * a' * a * a - elseif lab_frame_type == :quartic - ω₀ = ω + δ - H_drift = ω₀ * a' * a - δ / 12 * (a + a')^4 - elseif lab_frame_type == :cosine - ω₀ = ω + δ - E_C = δ - E_J = ω₀^2 / 8E_C - n̂ = im / 2 * (E_J / 2E_C)^(1/4) * (a - a') - φ̂ = (2E_C / E_J)^(1/4) * (a + a') - H_drift = 4 * E_C * n̂^2 - E_J * cos(φ̂) - # H_drift = 4 * E_C * n̂^2 - E_J * (I - φ̂^2 / 2 + φ̂^4 / 24) - end - else - H_drift = (ω - frame_ω) * a' * a - δ / 2 * a' * a' * a * a - end - - if drives - H_drives = [a + a', 1.0im * (a - a')] - else - H_drives = Matrix{ComplexF64}[] - end - - if mutiply_by_2π - H_drift *= 2π - H_drives .*= 2π - end - - params = Dict{Symbol, Any}( - :ω => ω, - :δ => δ, - :levels => levels, - :lab_frame => lab_frame, - :frame_ω => frame_ω, - :mutiply_by_2π => mutiply_by_2π, - :lab_frame_type => lab_frame_type, - :drives => drives, - ) - - return QuantumSystem( - H_drift, - H_drives; - constructor=TransmonSystem, - params=params, - ) -end - -@doc raw""" - TransmonDipoleCoupling( - g_ij::Float64, - pair::Tuple{Int, Int}, - subsystem_levels::Vector{Int}; - lab_frame::Bool=false, - ) -> QuantumSystemCoupling - - TransmonDipoleCoupling( - g_ij::Float64, - pair::Tuple{Int, Int}, - sub_systems::Vector{QuantumSystem}; - kwargs... - ) -> QuantumSystemCoupling - -Returns a `QuantumSystemCoupling` object for a transmon qubit. In the lab frame, the Hamiltonian coupling term is - -```math -H = g_{ij} (a_i + a_i^\dagger) (a_j + a_j^\dagger) -``` - -In the rotating frame, the Hamiltonian coupling term is - -```math -H = g_{ij} (a_i a_j^\dagger + a_i^\dagger a_j) -``` - -where `a_i` is the annihilation operator for the `i`th transmon. - -""" -function TransmonDipoleCoupling end - -function TransmonDipoleCoupling( - g_ij::Float64, - pair::Tuple{Int, Int}, - subsystem_levels::Vector{Int}; - lab_frame::Bool=false, - mulitply_by_2π::Bool=true, -) - i, j = pair - a_i = lift(annihilate(subsystem_levels[i]), i, subsystem_levels) - a_j = lift(annihilate(subsystem_levels[j]), j, subsystem_levels) - - if lab_frame - op = g_ij * (a_i + a_i') * (a_j + a_j') - else - op = g_ij * (a_i * a_j' + a_i' * a_j) - end - - if mulitply_by_2π - op *= 2π - end - - params = Dict{Symbol, Any}( - :lab_frame => lab_frame, - :mulitply_by_2π => mulitply_by_2π, - ) - - return QuantumSystemCoupling( - op, - g_ij, - pair, - subsystem_levels, - TransmonDipoleCoupling, - params - ) -end - -function TransmonDipoleCoupling( - g_ij::Float64, - pair::Tuple{Int, Int}, - sub_systems::Vector{QuantumSystem}; - kwargs... -) - subsystem_levels = [sys.levels for sys ∈ sub_systems] - return TransmonDipoleCoupling(g_ij, pair, subsystem_levels; kwargs...) -end - -""" - MultiTransmonSystem( - ωs::AbstractVector{Float64}, - δs::AbstractVector{Float64}, - gs::AbstractMatrix{Float64}; - levels_per_transmon::Int = 3, - subsystem_levels::AbstractVector{Int} = fill(levels_per_transmon, length(ωs)), - lab_frame=false, - subsystems::AbstractVector{Int} = 1:length(ωs), - subsystem_drive_indices::AbstractVector{Int} = 1:length(ωs), - kwargs... - ) -> CompositeQuantumSystem - -Returns a `CompositeQuantumSystem` object for a multi-transmon system. -""" -function MultiTransmonSystem( - ωs::AbstractVector{Float64}, - δs::AbstractVector{Float64}, - gs::AbstractMatrix{Float64}; - levels_per_transmon::Int = 3, - subsystem_levels::AbstractVector{Int} = fill(levels_per_transmon, length(ωs)), - lab_frame=false, - subsystems::AbstractVector{Int} = 1:length(ωs), - subsystem_drive_indices::AbstractVector{Int} = 1:length(ωs), - kwargs... -) - n_subsystems = length(ωs) - @assert length(δs) == n_subsystems - @assert size(gs) == (n_subsystems, n_subsystems) - - systems = QuantumSystem[] - - for (i, (ω, δ, levels)) ∈ enumerate(zip(ωs, δs, subsystem_levels)) - if i ∈ subsystems - sysᵢ = TransmonSystem( - levels=levels, - ω=ω, - δ=δ, - lab_frame=lab_frame, - drives=i ∈ subsystem_drive_indices - ) - push!(systems, sysᵢ) - end - end - - couplings = QuantumSystemCoupling[] - - for i = 1:n_subsystems-1 - for j = i+1:n_subsystems - if i ∈ subsystems && j ∈ subsystems - push!( - couplings, - TransmonDipoleCoupling(gs[i, j], (i, j), systems; lab_frame=lab_frame) - ) - end - end - end - - return CompositeQuantumSystem(systems, couplings) -end diff --git a/build/quantum_system_utils.jl b/build/quantum_system_utils.jl deleted file mode 100644 index 7df0cb30..00000000 --- a/build/quantum_system_utils.jl +++ /dev/null @@ -1,4 +0,0 @@ -module QuantumSystemUtils - - -end diff --git a/build/quantum_systems.jl b/build/quantum_systems.jl deleted file mode 100644 index 7c05b8c4..00000000 --- a/build/quantum_systems.jl +++ /dev/null @@ -1,486 +0,0 @@ -module QuantumSystems - -export AbstractQuantumSystem -export QuantumSystem -export CompositeQuantumSystem -export QuantumSystemCoupling - -export embed -export is_linearly_dependent -export operator_algebra - - -export iso - -using ..QuantumUtils - -using LinearAlgebra -using SparseArrays - -function is_linearly_dependent( - basis::Vector{<:AbstractMatrix}; - eps=eps(Float32) -) - # Note: basis is assumed to be linearly independent - M = hcat(vec.(basis)...) - return is_linearly_dependent(M, eps=eps) -end - -function is_linearly_dependent( - basis::Vector{<:AbstractMatrix}, - op::AbstractMatrix; - eps=eps(Float32) -) - # Note: basis is assumed to be linearly independent - M = hcat(vec.(basis)..., vec(op)) - return is_linearly_dependent(M, eps=eps) -end - -function is_linearly_dependent(M::AbstractMatrix; eps=eps(Float32)) - if size(M, 2) > size(M, 1) - println("Linearly dependent because columns > rows.") - return true - end - # QR decomposition has a zero R on diagonal if linearly dependent - val = minimum(abs.(diag(qr(M).R))) - return isapprox(val, 0.0, atol=eps) -end - -commutator(A::AbstractMatrix, B::AbstractMatrix) = A * B - B * A - -is_hermitian(A::AbstractMatrix) = isapprox(A, A', atol=1e-8) - -function operator_algebra( - gens::Vector{<:AbstractMatrix}; return_layers=false, normalize=false -) - """ - operator_algebra(generators; return_layers=false, normalize=false) - - Compute the Lie algebra basis for the given generators. - If return_layers is true, the Lie tree layers are also returned. - """ - basis = normalize ? [g / norm(g) for g ∈ gens] : copy(gens) - current_layer = copy(basis) - if return_layers - all_layers = Vector{Matrix{ComplexF64}}[copy(gens)] - end - - ℓ = 1 - println("ℓ = $ℓ") - if is_linearly_dependent(basis) - println("Linearly dependent generators.") - else - # Note: Use left normalized commutators - # Note: Jacobi identity is not checked - while length(basis) < size(first(gens), 1)^2 - 1 - layer = Matrix{ComplexF64}[] - # Repeat commutators until no new operators are found. - for op ∈ current_layer - for gen ∈ gens - test = commutator(gen, op) - if all(test .≈ 0) - continue - # Current basis is assumed to be linearly independent - elseif is_linearly_dependent([basis..., test]) - continue - else - test .= is_hermitian(test) ? test : im * test - test .= normalize ? test / norm(test) : test - push!(layer, test) - push!(basis, test) - end - end - end - - if isempty(layer) - println("Subspace termination.") - break - else - current_layer = layer - ℓ += 1 - println("ℓ = $ℓ") - end - - if return_layers - append!(all_layers, [current_layer]) - end - end - end - if return_layers - return basis, all_layers - else - return basis - end -end - - - -const Im2 = [ - 0 -1; - 1 0 -] - -@doc raw""" - G(H::AbstractMatrix)::Matrix{Float64} - -Returns the isomorphism of ``-iH``: - -```math -G(H) = \widetilde{- i H} = \mqty(1 & 0 \\ 0 & 1) \otimes \Im(H) - \mqty(0 & -1 \\ 1 & 0) \otimes \Re(H) -``` - -where ``\Im(H)`` and ``\Re(H)`` are the imaginary and real parts of ``H`` and the tilde indicates the standard isomorphism of a complex valued matrix: - -```math -\widetilde{H} = \mqty(1 & 0 \\ 0 & 1) \otimes \Re(H) + \mqty(0 & -1 \\ 1 & 0) \otimes \Im(H) -``` -""" -G(H::AbstractMatrix{<:Number}) = I(2) ⊗ imag(H) - Im2 ⊗ real(H) - -iso(H::AbstractMatrix{<:Number}) = I(2) ⊗ real(H) + Im2 ⊗ imag(H) - - -""" - H(G::AbstractMatrix{<:Number})::Matrix{ComplexF64} - -Returns the inverse of `G(H) = iso(-iH)`, i.e. returns H - -""" -function H(G::AbstractMatrix{<:Number}) - dim = size(G, 1) ÷ 2 - H_imag = G[1:dim, 1:dim] - H_real = -G[dim+1:end, 1:dim] - return H_real + 1.0im * H_imag -end - -""" -```julia -AbstractQuantumSystem -``` - -Abstract type for defining systems. -""" -abstract type AbstractQuantumSystem end - -# TODO: make subtypes: SingleQubitSystem, TwoQubitSystem, TransmonSystem, MultimodeSystem, etc. - -""" -QuantumSystem - | - -> EmbeddedOperator - | | - | -> QuantumObjective - | | - -> Matrix (goal) - -""" - -""" - QuantumSystem <: AbstractQuantumSystem - -A struct for storing the isomorphisms of the system's drift and drive Hamiltonians, -as well as the system's parameters. -""" -struct QuantumSystem <: AbstractQuantumSystem - H_drift::SparseMatrixCSC{ComplexF64, Int} - H_drives::Vector{SparseMatrixCSC{ComplexF64, Int}} - G_drift::SparseMatrixCSC{Float64, Int} - G_drives::Vector{SparseMatrixCSC{Float64, Int}} - levels::Int - constructor::Union{Function, Nothing} - params::Dict{Symbol, <:Any} -end - -# TODO: add frame info to type - -""" - QuantumSystem( - H_drift::Matrix{<:Number}, - H_drives::Vector{Matrix{<:Number}}; - params=Dict{Symbol, Any}(), - kwargs... - )::QuantumSystem - -Constructs a `QuantumSystem` object from the drift and drive Hamiltonian terms. -""" -function QuantumSystem( - H_drift::AbstractMatrix{<:Number}, - H_drives::Vector{<:AbstractMatrix{<:Number}}; - constructor::Union{Function, Nothing}=nothing, - params::Dict{Symbol, <:Any}=Dict{Symbol, Any}(), - kwargs... -) - H_drift = sparse(H_drift) - H_drives = sparse.(H_drives) - G_drift = G(H_drift) - G_drives = G.(H_drives) - params = merge(params, Dict{Symbol, Any}(kwargs...)) - levels = size(H_drift, 1) - return QuantumSystem( - H_drift, - H_drives, - G_drift, - G_drives, - levels, - constructor, - params - ) -end - -function QuantumSystem(H_drives::Vector{<:AbstractMatrix{<:Number}}; kwargs...) - return QuantumSystem( - zeros(eltype(H_drives[1]), size(H_drives[1])), - H_drives; - kwargs... - ) -end - -function QuantumSystem(H_drift::AbstractMatrix{<:Number}; kwargs...) - return QuantumSystem( - H_drift, - Matrix{ComplexF64}[]; - kwargs... - ) -end - -function (sys::QuantumSystem)(; params...) - @assert !isnothing(sys.constructor) "No constructor provided." - @assert all([ - key ∈ keys(sys.params) for key ∈ keys(params) - ]) "Invalid parameter(s) provided." - return sys.constructor(; merge(sys.params, Dict(params...))...) -end - -function Base.copy(sys::QuantumSystem) - return QuantumSystem( - copy(sys.H_drift), - copy.(sys.H_drives); - constructor=sys.constructor, - params=copy(sys.params) - ) -end - - - - -# ------------------------------------------------------------------ -# Quantum System couplings -# ------------------------------------------------------------------ - -""" - QuantumSystemCoupling <: AbstractQuantumSystem - -""" -struct QuantumSystemCoupling - term::SparseMatrixCSC{ComplexF64, Int} - g_ij::Float64 - pair::Tuple{Int, Int} - subsystem_levels::Vector{Int} - constructor::Union{Function, Nothing} - params::Dict{Symbol, <:Any} - - function QuantumSystemCoupling(op::AbstractMatrix{<:ComplexF64}, args...) - return new( - sparse(op), - args... - ) - end -end - -function (coupling::QuantumSystemCoupling)(; - g_ij::Float64=coupling.g_ij, - pair::Tuple{Int, Int}=coupling.pair, - subsystem_levels::Vector{Int}=coupling.subsystem_levels, - params... -) - @assert !isnothing(coupling.constructor) "No constructor provided." - @assert all([ - key ∈ keys(coupling.params) for key ∈ keys(params) - ]) "Invalid parameter(s) provided: $(filter(param -> param ∉ keys(coupling.params), keys(params)))" - return coupling.constructor( - g_ij, - pair, - subsystem_levels; - merge(coupling.params, Dict(params...))... - ) -end - -function Base.copy(coupling::QuantumSystemCoupling) - return QuantumSystemCoupling( - copy(coupling.op), - coupling.g_ij, - coupling.pair, - coupling.subsystem_levels, - coupling.constructor, - copy(coupling.params) - ) -end - - -struct CompositeQuantumSystem <: AbstractQuantumSystem - H_drift::SparseMatrixCSC{ComplexF64, Int} - H_drives::Vector{SparseMatrixCSC{ComplexF64, Int}} - G_drift::SparseMatrixCSC{Float64, Int} - G_drives::Vector{SparseMatrixCSC{Float64, Int}} - levels::Int - subsystem_levels::Vector{Int} - params::Dict{Symbol, Any} - subsystems::Vector{QuantumSystem} - couplings::Vector{QuantumSystemCoupling} -end - -function CompositeQuantumSystem( - subsystems::Vector{QuantumSystem}, - couplings::Vector{QuantumSystemCoupling}=QuantumSystemCoupling[]; - subsystem_frame_index::Int=1, - frame_ω::Float64=subsystems[subsystem_frame_index].params[:ω], - lab_frame::Bool=false -) - # set all subsystems to the same frame_ω - subsystems = [sys(; frame_ω=frame_ω) for sys ∈ subsystems] - - if lab_frame - subsystems = [sys(; lab_frame=true) for sys ∈ subsystems] - couplings = [coupling(; lab_frame=true) for coupling ∈ couplings] - end - - subsystem_levels = [sys.levels for sys ∈ subsystems] - levels = prod(subsystem_levels) - - # add lifted subsystem drift Hamiltonians - H_drift = sparse(zeros(levels, levels)) - for (i, sys) ∈ enumerate(subsystems) - H_drift += lift(sys.H_drift, i, subsystem_levels) - end - - # add lifated couplings to the drift Hamiltonian - for coupling ∈ couplings - H_drift += coupling.term - end - - # add lifted subsystem drive Hamiltonians - H_drives = SparseMatrixCSC{ComplexF64, Int}[] - for (i, sys) ∈ enumerate(subsystems) - for H_drive ∈ sys.H_drives - push!(H_drives, lift(H_drive, i, subsystem_levels)) - end - end - - G_drift = G(H_drift) - G_drives = G.(H_drives) - levels = size(H_drift, 1) - subsystem_levels = [sys.levels for sys ∈ subsystems] - params = Dict{Symbol, Any}() - - return CompositeQuantumSystem( - H_drift, - H_drives, - G_drift, - G_drives, - levels, - subsystem_levels, - params, - subsystems, - couplings - ) -end - -function (csys::CompositeQuantumSystem)(; - subsystem_params::Dict{Int, <:Dict{Symbol, <:Any}}=Dict{Int, Dict{Symbol, Any}}(), - coupling_params::Dict{Int, <:Dict{Symbol, <:Any}}=Dict{Int, Dict{Symbol, Any}}(), - lab_frame::Bool=false, - subsystem_frame_index::Int=1, - frame_ω::Float64=csys.subsystems[subsystem_frame_index].params[:ω], - subsystem_levels::Union{Nothing, Int, Vector{Int}}=nothing, -) - subsystems = deepcopy(csys.subsystems) - couplings = deepcopy(csys.couplings) - - # if lab frame then set all subsystems and couplings to lab frame - if lab_frame - - # set lab frame in subsystem_params for all subsystems - for i = 1:length(csys.subsystems) - if i ∈ keys(subsystem_params) - subsystem_params[i][:lab_frame] = true - else - subsystem_params[i] = Dict{Symbol, Any}(:lab_frame => true) - end - end - - # set lab frame in coupling_params for all couplings - for i = 1:length(csys.couplings) - if i ∈ keys(coupling_params) - coupling_params[i][:lab_frame] = true - else - coupling_params[i] = Dict{Symbol, Any}(:lab_frame => true) - end - end - end - - # if subsystem_levels is provided then set all subsystems and couplings to subsystem_levels - if !isnothing(subsystem_levels) - - if subsystem_levels isa Int - subsystem_levels = fill(subsystem_levels, length(csys.subsystems)) - else - @assert( - length(subsystem_levels) == length(csys.subsystems), - """\n - number of subsystem_levels ($(length(subsystem_levels))) must match number of subsystems ($(length(csys.subsystems))). - """ - ) - end - - for i = 1:length(csys.subsystems) - if i ∈ keys(subsystem_params) - subsystem_params[i][:levels] = subsystem_levels[i] - else - subsystem_params[i] = Dict{Symbol, Any}( - :levels => subsystem_levels[i] - ) - end - end - - for i = 1:length(csys.couplings) - if i ∈ keys(coupling_params) - coupling_params[i][:subsystem_levels] = subsystem_levels - else - coupling_params[i] = Dict{Symbol, Any}( - :subsystem_levels => subsystem_levels - ) - end - end - end - - # construct subsystems with new parameters - for (i, sys_params) ∈ subsystem_params - subsystem_i_new_params = merge(subsystems[i].params, sys_params) - subsystem_i_new_params[:frame_ω] = frame_ω - subsystems[i] = subsystems[i](; subsystem_i_new_params...) - end - - # sometimes redundant, but here to catch any changes in indvidual subsystem levels - subsystem_levels = [sys.levels for sys ∈ subsystems] - - # construct couplings with new parameters - if !isempty(csys.couplings) - for (i, coupling_params) ∈ coupling_params - couplings[i] = couplings[i](; - merge(couplings[i].params, coupling_params)..., - subsystem_levels=subsystem_levels - ) - end - end - - return CompositeQuantumSystem( - subsystems, - couplings - ) -end - -QuantumUtils.quantum_state(ket::String, csys::CompositeQuantumSystem; kwargs...) = - quantum_state(ket, csys.subsystem_levels; kwargs...) - -# TODO: add methods to combine composite quantum systems - -end diff --git a/build/quantum_utils.jl b/build/quantum_utils.jl deleted file mode 100644 index f4a7fad4..00000000 --- a/build/quantum_utils.jl +++ /dev/null @@ -1,432 +0,0 @@ -module QuantumUtils - -export GATES -export get_gate -export ⊗ -export vec⁻¹ -export operators_from_dict -export kron_from_dict -export apply -export qubit_system_state -export lift -export ket_to_iso -export iso_to_ket -export operator_to_iso_vec -export iso_vec_to_operator -export iso_vec_to_iso_operator -export iso_operator_to_iso_vec -export annihilate -export create -export quad -export cavity_state -export multimode_state -export number -export fidelity -export iso_fidelity -export unitary_fidelity -export population -export populations -export subspace_unitary -export quantum_state - -using TrajectoryIndexingUtils -using LinearAlgebra - - -""" - kronecker product utility -""" - -⊗(A::AbstractVecOrMat, B::AbstractVecOrMat) = kron(A, B) - - -""" - quantum gates -""" - -const GATES = Dict{Symbol, Matrix{ComplexF64}}( - :I => [1 0; - 0 1], - - :X => [0 1; - 1 0], - - :Y => [0 -im; - im 0], - - :Z => [1 0; - 0 -1], - - :H => [1 1; - 1 -1]/√2, - - :CX => [1 0 0 0; - 0 1 0 0; - 0 0 0 1; - 0 0 1 0], - - :XI => [0 0 -im 0; - 0 0 0 -im; - -im 0 0 0; - 0 -im 0 0], - - :sqrtiSWAP => [1 0 0 0; - 0 1/sqrt(2) 1im/sqrt(2) 0; - 0 1im/sqrt(2) 1/sqrt(2) 0; - 0 0 0 1] -) - -get_gate(U::Symbol) = GATES[U] - -function apply(gate::Symbol, ψ::Vector{<:Number}) - @assert norm(ψ) ≈ 1.0 - @assert gate in keys(GATES) "gate not found" - Û = get_gate(gate) - @assert size(Û, 2) == size(ψ, 1) "gate size does not match ket dim" - return ComplexF64.(normalize(Û * ψ)) -end - -""" -operators_from_dict(keys::AbstractVector{<:Any}, operator_dictionary; I_key=:I) - - Replace the vector of keys using the operators from a dictionary. -""" -function operators_from_dict(keys::AbstractVector{<:Any}, operator_dictionary; I_key=:I) - first_operator = first(values(operator_dictionary)) - I_default = Matrix{eltype(first_operator)}(I, size(first_operator)) - # Identity key is replaced by operator_dictionary, else default I. - return replace(replace(keys, operator_dictionary...), I_key => I_default) -end - -""" -operators_from_dict(key_string::String, operator_dictionary; I_key="I") - - Replace the string (each character is one key) with operators from a dictionary. -""" -operators_from_dict(key_string::String, operator_dictionary; I_key="I") = - operators_from_dict([string(c) for c ∈ key_string], operator_dictionary, I_key=I_key) - -""" -kron_from_dict(keys, dict; kwargs...) - - Reduce the keys to a single operator by using the provided dictionary and the kronecker product. -""" -function kron_from_dict(keys, dict; kwargs...) - if occursin("+", keys) - return sum( - [kron_from_dict(string(s), dict; kwargs...) - for s ∈ split(keys, "+")] - ) - else - return reduce(kron, operators_from_dict(keys, dict; kwargs...)) - end -end - -function qubit_system_state(ket::String) - cs = [c for c ∈ ket] - @assert all(c ∈ "01" for c ∈ cs) - states = [c == '0' ? [1, 0] : [0, 1] for c ∈ cs] - ψ = foldr(⊗, states) - ψ = Vector{ComplexF64}(ψ) - return ψ -end - -function lift( - U::AbstractMatrix{<:Number}, - qubit_index::Int, - n_qubits::Int; - levels::Int=size(U, 1) -)::Matrix{ComplexF64} - Is = Matrix{Complex}[I(levels) for _ = 1:n_qubits] - Is[qubit_index] = U - return foldr(⊗, Is) -end - -function lift( - op::AbstractMatrix{<:Number}, - i::Int, - subsystem_levels::Vector{Int} -)::Matrix{ComplexF64} - @assert size(op, 1) == size(op, 2) == subsystem_levels[i] "Operator must be square and match dimension of subsystem i" - - Is = [collect(1.0 * typeof(op)(I, l, l)) for l ∈ subsystem_levels] - Is[i] = op - return kron(1.0, Is...) -end - - - - -""" - quantum harmonic oscillator operators -""" - -""" - annihilate(levels::Int) - -Get the annihilation operator for a system with `levels` levels. -""" -function annihilate(levels::Int)::Matrix{ComplexF64} - return diagm(1 => map(sqrt, 1:levels - 1)) -end - -""" - create(levels::Int) - -Get the creation operator for a system with `levels` levels. -""" -function create(levels::Int) - return collect(annihilate(levels)') -end - -""" - number(levels::Int) - -Get the number operator `n = a'a` for a system with `levels` levels. -""" -function number(levels::Int) - return create(levels) * annihilate(levels) -end - -""" - quad(levels::Int) - -Get the operator `n(n - I)` for a system with `levels` levels. -""" -function quad(levels::Int) - return number(levels) * (number(levels) - I(levels)) -end - - -function cavity_state(level::Int, cavity_levels::Int) - state = zeros(ComplexF64, cavity_levels) - state[level + 1] = 1. - return state -end - - -""" - multimode system utilities -""" - -function multimode_state(ψ::String, transmon_levels::Int, cavity_levels::Int) - @assert length(ψ) == 2 - - @assert transmon_levels ∈ 2:4 - - transmon_state = ψ[1] - - @assert transmon_state ∈ ['g', 'e'] - - cavity_state = parse(Int, ψ[2]) - - @assert cavity_state ∈ 0:cavity_levels - 2 "cavity state must be in [0, ..., cavity_levels - 2] (hightest cavity level is prohibited)" - - ψ_transmon = zeros(ComplexF64, transmon_levels) - ψ_transmon[transmon_state == 'g' ? 1 : 2] = 1.0 - - ψ_cavity = zeros(ComplexF64, cavity_levels) - ψ_cavity[cavity_state + 1] = 1.0 - - return ψ_transmon ⊗ ψ_cavity -end - - -""" - isomporphism utilities -""" -function vec⁻¹(x::AbstractVector) - n = isqrt(length(x)) - return reshape(x, n, n) -end - -ket_to_iso(ψ) = [real(ψ); imag(ψ)] - -iso_to_ket(ψ̃) = ψ̃[1:div(length(ψ̃), 2)] + im * ψ̃[(div(length(ψ̃), 2) + 1):end] - -function iso_vec_to_operator(Ũ⃗::AbstractVector{R}) where R <: Real - Ũ⃗_dim = div(length(Ũ⃗), 2) - N = Int(sqrt(Ũ⃗_dim)) - U = Matrix{Complex{R}}(undef, N, N) - for i=0:N-1 - U[:, i+1] .= - @view(Ũ⃗[i * 2N .+ (1:N)]) + - one(R) * im * @view(Ũ⃗[i * 2N .+ (N+1:2N)]) - end - return U -end - -function iso_vec_to_iso_operator(Ũ⃗::AbstractVector{R}) where R <: Real - N = Int(sqrt(length(Ũ⃗) ÷ 2)) - Ũ = Matrix{R}(undef, 2N, 2N) - U_real = Matrix{R}(undef, N, N) - U_imag = Matrix{R}(undef, N, N) - for i=0:N-1 - U_real[:, i+1] .= @view(Ũ⃗[i*2N .+ (1:N)]) - U_imag[:, i+1] .= @view(Ũ⃗[i*2N .+ (N+1:2N)]) - end - Ũ[1:N, 1:N] .= U_real - Ũ[1:N, (N + 1):end] .= -U_imag - Ũ[(N + 1):end, 1:N] .= U_imag - Ũ[(N + 1):end, (N + 1):end] .= U_real - return Ũ -end - - -function operator_to_iso_vec(U::AbstractMatrix{<:Complex}) - N = size(U,1) - Ũ⃗ = Vector{Float64}(undef, N^2 * 2) - for i=0:N-1 - Ũ⃗[i*2N .+ (1:N)] .= real(@view(U[:, i+1])) - Ũ⃗[i*2N .+ (N+1:2N)] .= imag(@view(U[:, i+1])) - end - return Ũ⃗ -end - -function iso_operator_to_iso_vec(Ũ::AbstractMatrix{R}) where R <: Real - N = size(Ũ, 1) ÷ 2 - Ũ⃗ = Vector{R}(undef, N^2 * 2) - for i=0:N-1 - Ũ⃗[i*2N .+ (1:2N)] .= @view Ũ[:, i+1] - end - return Ũ⃗ -end - - -""" - quantum metrics -""" - -function fidelity(ψ, ψ_goal; subspace=1:length(ψ)) - ψ = ψ[subspace] - ψ_goal = ψ_goal[subspace] - return abs2(ψ_goal' * ψ) -end - -function iso_fidelity(ψ̃, ψ̃_goal; kwargs...) - ψ = iso_to_ket(ψ̃) - ψ_goal = iso_to_ket(ψ̃_goal) - return fidelity(ψ, ψ_goal; kwargs...) -end - -function unitary_fidelity( - U::Matrix, - U_goal::Matrix; - subspace=nothing -) - if isnothing(subspace) - N = size(U, 1) - return 1 / N * abs(tr(U_goal'U)) - else - U_goal = U_goal[subspace, subspace] - U = U[subspace, subspace] - N = length(subspace) - return 1 / N * abs(tr(U_goal'U)) - end -end - -function unitary_fidelity( - Ũ⃗::AbstractVector{<:Real}, - Ũ⃗_goal::AbstractVector{<:Real}; - subspace=nothing -) - U = iso_vec_to_operator(Ũ⃗) - U_goal = iso_vec_to_operator(Ũ⃗_goal) - return unitary_fidelity(U, U_goal; subspace=subspace) -end - -# TODO: add unitary squared fidelity - -""" - quantum measurement functions -""" - -function population(ψ̃, i) - @assert i ∈ 0:length(ψ̃) ÷ 2 - 1 - ψ = iso_to_ket(ψ̃) - return abs2(ψ[i + 1]) -end - -function populations(ψ::AbstractVector{<:Complex}) - return abs2.(ψ) -end - -function populations(ψ̃::AbstractVector{<:Real}) - return populations(iso_to_ket(ψ̃)) -end - - -""" - quantum_state( - ket::String, - levels::Vector{Int}; - level_dict=Dict(:g => 0, :e => 1, :f => 2, :h => 2), - return_states=false - ) - -Construct a quantum state from a string ket representation. - -# Example - -# TODO: add example -""" -function quantum_state( - ket::String, - levels::Vector{Int}; - level_dict=Dict(:g => 0, :e => 1, :f => 2, :h => 2), - return_states=false -) - kets = [] - - for x ∈ split(ket, ['(', ')']) - if x == "" - continue - elseif all(Symbol(xᵢ) ∈ keys(level_dict) for xᵢ ∈ x) - append!(kets, x) - elseif occursin("+", x) - superposition = split(x, '+') - @assert all(all(Symbol(xᵢ) ∈ keys(level_dict) for xᵢ ∈ x) for x ∈ superposition) "Invalid ket: $x" - @assert length(superposition) == 2 "Only two states can be superposed for now" - push!(kets, x) - else - error("Invalid ket: $x") - end - end - - states = [] - - for (ψᵢ, l) ∈ zip(kets, levels) - if ψᵢ isa AbstractString && occursin("+", ψᵢ) - superposition = split(ψᵢ, '+') - superposition_states = [level_dict[Symbol(x)] for x ∈ superposition] - @assert all(state ≤ l - 1 for state ∈ superposition_states) "Level $ψᵢ is not allowed for $l levels" - superposition_state = sum([ - cavity_state(state, l) for state ∈ superposition_states - ]) - normalize!(superposition_state) - push!(states, superposition_state) - else - state = level_dict[Symbol(ψᵢ)] - @assert state ≤ l - 1 "Level $ψᵢ is not allowed for $l levels" - push!(states, cavity_state(state, l)) - end - end - - if return_states - return states - else - return kron(states...) - end -end - - - - - - - - - - - -end diff --git a/build/rollouts.jl b/build/rollouts.jl deleted file mode 100644 index 1d98da16..00000000 --- a/build/rollouts.jl +++ /dev/null @@ -1,308 +0,0 @@ -module Rollouts - -export rollout -export unitary_rollout -export lab_frame_unitary_rollout -export lab_frame_unitary_rollout_trajectory -export sample_at -export upsample - -using ..QuantumUtils -using ..QuantumSystems -using ..EmbeddedOperators -using ..Integrators -using ..Problems - -using LinearAlgebra -using NamedTrajectories - -function rollout( - ψ̃₁::AbstractVector{Float64}, - controls::AbstractMatrix{Float64}, - Δt::Union{AbstractVector{Float64}, AbstractMatrix{Float64}, Float64}, - system::AbstractQuantumSystem; - integrator=Integrators.fourth_order_pade -) - if Δt isa AbstractMatrix - @assert size(Δt, 1) == 1 - Δt = vec(Δt) - elseif Δt isa Float64 - Δt = fill(Δt, size(controls, 2)) - end - - T = size(controls, 2) - - Ψ̃ = zeros(length(ψ̃₁), T) - - Ψ̃[:, 1] .= ψ̃₁ - - G_drift = Matrix{Float64}(system.G_drift) - G_drives = Matrix{Float64}.(system.G_drives) - - for t = 2:T - aₜ₋₁ = controls[:, t - 1] - Gₜ = Integrators.G( - aₜ₋₁, - G_drift, - G_drives - ) - Ψ̃[:, t] .= integrator(Gₜ * Δt[t - 1]) * Ψ̃[:, t - 1] - end - - return Ψ̃ -end - -rollout(ψ::Vector{<:Complex}, args...; kwargs...) = - rollout(ket_to_iso(ψ), args...; kwargs...) - -function rollout( - ψ̃₁s::AbstractVector{<:AbstractVector}, args...; kwargs... -) - return vcat([rollout(ψ̃₁, args...; kwargs...) for ψ̃₁ ∈ ψ̃₁s]...) -end - -function QuantumUtils.fidelity( - ψ̃₁::AbstractVector{Float64}, - ψ̃_goal::AbstractVector{Float64}, - controls::AbstractMatrix{Float64}, - Δt::Union{AbstractVector{Float64}, AbstractMatrix{Float64}, Float64}, - system::AbstractQuantumSystem; - kwargs... -) - Ψ̃ = rollout(ψ̃₁, controls, Δt, system; kwargs...) - return iso_fidelity(Ψ̃[:, end], ψ̃_goal) -end - -function QuantumUtils.fidelity( - ψ₁::AbstractVector{<:Complex}, - ψ_goal::AbstractVector{<:Complex}, - controls::AbstractMatrix{Float64}, - Δt::Union{AbstractVector{Float64}, AbstractMatrix{Float64}, Float64}, - system::AbstractQuantumSystem; - kwargs... -) - return fidelity(ket_to_iso(ψ₁), ket_to_iso(ψ_goal), args...; kwargs...) -end - - -function unitary_rollout( - Ũ⃗₁::AbstractVector{<:Real}, - controls::AbstractMatrix{Float64}, - Δt::Union{AbstractVector{Float64}, AbstractMatrix{Float64}, Float64}, - system::AbstractQuantumSystem; - integrator=exp -) - if Δt isa AbstractMatrix - @assert size(Δt, 1) == 1 - Δt = vec(Δt) - elseif Δt isa Float64 - Δt = fill(Δt, size(controls, 2)) - end - - T = size(controls, 2) - - Ũ⃗ = zeros(length(Ũ⃗₁), T) - - Ũ⃗[:, 1] .= Ũ⃗₁ - - G_drift = Matrix{Float64}(system.G_drift) - G_drives = Matrix{Float64}.(system.G_drives) - - for t = 2:T - aₜ₋₁ = controls[:, t - 1] - Gₜ = Integrators.G( - aₜ₋₁, - G_drift, - G_drives - ) - Ũ⃗ₜ₋₁ = Ũ⃗[:, t - 1] - Ũₜ₋₁ = iso_vec_to_iso_operator(Ũ⃗ₜ₋₁) - Ũₜ = integrator(Gₜ * Δt[t - 1]) * Ũₜ₋₁ - Ũ⃗ₜ = iso_operator_to_iso_vec(Ũₜ) - Ũ⃗[:, t] .= Ũ⃗ₜ - end - - return Ũ⃗ -end - - - -function unitary_rollout( - controls::AbstractMatrix{Float64}, - Δt::Union{AbstractVector{Float64}, AbstractMatrix{Float64}, Float64}, - system::AbstractQuantumSystem; - integrator=exp -) - return unitary_rollout( - operator_to_iso_vec(Matrix{ComplexF64}(I(size(system.H_drift, 1)))), - controls, - Δt, - system; - integrator=integrator - ) -end - -function unitary_rollout( - traj::NamedTrajectory, - system::AbstractQuantumSystem; - unitary_name::Symbol=:Ũ⃗, - drive_name::Symbol=:a, - integrator=exp, - only_drift=false -) - Ũ⃗₁ = traj.initial[unitary_name] - if only_drift - controls = zeros(size(traj[drive_name])) - else - controls = traj[drive_name] - end - Δt = get_timesteps(traj) - return unitary_rollout( - Ũ⃗₁, - controls, - Δt, - system; - integrator=integrator - ) -end - -function QuantumUtils.unitary_fidelity( - traj::NamedTrajectory, - system::AbstractQuantumSystem; - unitary_name::Symbol=:Ũ⃗, - subspace=nothing, - kwargs... -) - Ũ⃗_final = unitary_rollout( - traj, - system; - unitary_name=unitary_name, - kwargs... - )[:, end] - return unitary_fidelity( - Ũ⃗_final, - traj.goal[unitary_name]; - subspace=subspace - ) -end - -function QuantumUtils.unitary_fidelity( - prob::QuantumControlProblem; - kwargs... -) - return unitary_fidelity(prob.trajectory, prob.system; kwargs...) -end - -function QuantumUtils.unitary_fidelity( - U_goal::AbstractMatrix{ComplexF64}, - controls::AbstractMatrix{Float64}, - Δt::Union{AbstractVector{Float64}, AbstractMatrix{Float64}, Float64}, - system::AbstractQuantumSystem; - subspace=nothing, - integrator=exp -) - Ũ⃗_final = unitary_rollout(controls, Δt, system; integrator=integrator)[:, end] - return unitary_fidelity( - Ũ⃗_final, - operator_to_iso_vec(U_goal); - subspace=subspace - ) -end - -function sample_at(t::Float64, controls::AbstractMatrix{Float64}, Δt::Float64) - @assert t >= 0 "t must be non-negative" - @assert Δt > 0 "Δt must be positive" - @assert t <= size(controls, 2) * Δt "t must be less than the duration of the controls" - - i = floor(Int, t / Δt) + 1 - controls[:, i] -end - -function upsample( - controls::AbstractMatrix{Float64}, - duration::Float64, - Δt::Float64, - Δt_new::Float64 -) - @assert Δt > 0 "Δt must be positive" - @assert Δt_new > 0 "Δt_new must be positive" - @assert Δt_new < Δt "Δt_new must be less than Δt" - - times_upsampled = LinRange(0, duration, floor(Int, duration / Δt_new) + 1) - - controls_upsampled = stack([sample_at(t, controls, Δt) for t in times_upsampled]) - - return controls_upsampled, times_upsampled -end - -""" - lab_frame_unitary_rollout( - sys::AbstractQuantumSystem, - controls::AbstractMatrix{Float64}; - duration=nothing, - timestep=nothing, - ω=nothing, - timestep_nyquist=1 / (50 * ω) - ) -""" -function lab_frame_unitary_rollout( - sys::AbstractQuantumSystem, - controls::AbstractMatrix{Float64}; - duration=nothing, - timestep=nothing, - ω=nothing, - timestep_nyquist=1 / (50 * ω) -) - @assert !isnothing(duration) "must specify duration" - @assert !isnothing(timestep) "must specify timestep" - @assert !isnothing(ω) "must specify ω" - - controls_upsampled, times_upsampled = - upsample(controls, duration, timestep, timestep_nyquist) - - u = controls_upsampled[1, :] - v = controls_upsampled[2, :] - - c = cos.(2π * ω * times_upsampled) - s = sin.(2π * ω * times_upsampled) - - pulse = stack([u .* c - v .* s, u .* s + v .* c], dims=1) - - return unitary_rollout(pulse, timestep_nyquist, sys), pulse -end - -function lab_frame_unitary_rollout_trajectory( - sys_lab_frame::AbstractQuantumSystem, - traj_rotating_frame::NamedTrajectory, - op_lab_frame::EmbeddedOperator; - timestep_nyquist=1/(400 * sys_lab_frame.params[:ω]), - control_name::Symbol=:a, -)::NamedTrajectory - @assert sys_lab_frame.params[:lab_frame] "QuantumSystem must be in the lab frame" - - Ũ⃗_labframe, pulse = lab_frame_unitary_rollout( - sys_lab_frame, - traj_rotating_frame[control_name]; - duration=get_times(traj_rotating_frame)[end], - timestep=traj_rotating_frame.Δt[end], - ω=sys_lab_frame.params[:ω], - timestep_nyquist=timestep_nyquist - ) - - return NamedTrajectory( - ( - Ũ⃗=Ũ⃗_labframe, - a=pulse - ); - timestep=timestep_nyquist, - controls=(control_name,), - initial=( - Ũ⃗=Ũ⃗_labframe[:, 1], - ), - goal=( - Ũ⃗=operator_to_iso_vec(op_lab_frame.operator), - ) - ) -end - -end diff --git a/build/save_load_utils.jl b/build/save_load_utils.jl deleted file mode 100644 index dbabe292..00000000 --- a/build/save_load_utils.jl +++ /dev/null @@ -1,154 +0,0 @@ -module SaveLoadUtils - -export save_problem -export load_problem -export generate_file_path - -using ..Constraints -using ..Objectives -using ..Integrators -using ..Problems - -using JLD2 - - -function save_problem( - path::String, - prob::QuantumControlProblem, - info::Dict{String,<:Any}=Dict{String, Any}() -) - mkpath(dirname(path)) - - data = Dict( - "system" => prob.system, - "trajectory" => prob.trajectory, - "integrators" => prob.integrators, - "options" => prob.options, - "params" => prob.params, - ) - - # assert none of the keys in info are already in data - for key in keys(info) - if haskey(data, key) - @warn "Key $(key) in info exists in data dict, removing" - delete!(info, key) - end - end - - merge!(data, info) - - save(path, data) -end - -const RESERVED_KEYS = ["system", "trajectory", "options", "params", "integrators"] - -function load_problem(path::String; verbose=true, return_data=false, kwargs...) - data = load(path) - - if verbose - println("Loading $(return_data ? "data dict" : "problem") from $(path):\n") - for (key, value) ∈ data - if key ∉ RESERVED_KEYS - println(" $(key) = $(value)") - end - end - end - - if return_data - return data - else - if isnothing(data["integrators"]) - @warn "Dynamics was built using a user defined function, which could not be saved: returning data dict instead of problem (keys = [\"trajectory\", \"system\", \"params\"]) " - return data - end - - system = data["system"] - delete!(data, "system") - - trajectory = data["trajectory"] - delete!(data, "trajectory") - - options = data["options"] - delete!(data, "options") - - params = data["params"] - delete!(data, "params") - - integrators = data["integrators"] - delete!(data, "integrators") - - objective = Objective(params[:objective_terms]) - delete!(params, :objective_terms) - - linear_constraints = params[:linear_constraints] - delete!(params, :linear_constraints) - - nonlinear_constraints = NonlinearConstraint.(params[:nonlinear_constraints]) - delete!(params, :nonlinear_constraints) - - constraints = AbstractConstraint[linear_constraints; nonlinear_constraints] - - prob = QuantumControlProblem( - system, - trajectory, - objective, - integrators; - constraints=constraints, - options=options, - verbose=verbose, - build_trajectory_constraints=false, - params..., - kwargs... - ) - - return prob - end -end - -function save_h5(prob::QuantumControlProblem, save_path::String; verbose=true) - traj = prob.trajectory - - result = Dict( - - ) -end - -function generate_file_path(extension, file_name, path) - # Ensure the path exists. - mkpath(path) - - # remove dot from extension - extension = split(extension, ".")[end] - - # Create a save file name based on the one given; ensure it will - # not conflict with others in the directory. - max_numeric_suffix = -1 - for (_, _, files) in walkdir(path) - for file_name_ in files - if occursin("$(file_name)", file_name_) && occursin(".$(extension)", file_name_) - - numeric_suffix = parse( - Int, - split(split(file_name_, "_")[end], ".")[1] - ) - - max_numeric_suffix = max( - numeric_suffix, - max_numeric_suffix - ) - end - end - end - - file_path = joinpath( - path, - file_name * - "_$(lpad(max_numeric_suffix + 1, 5, '0')).$(extension)" - ) - - return file_path -end - - - -end diff --git a/build/structure_utils.jl b/build/structure_utils.jl deleted file mode 100644 index 96ec9421..00000000 --- a/build/structure_utils.jl +++ /dev/null @@ -1,241 +0,0 @@ -module StructureUtils - -export upper_half_vals -export random_sparse_symbolics_matrix - -export structure - -export jacobian_structure -export hessian_of_lagrangian_structure - -export dynamics_jacobian_structure -export dynamics_hessian_of_lagrangian_structure -export dynamics_structure - -export loss_hessian_structure - -using NamedTrajectories -using TrajectoryIndexingUtils -using LinearAlgebra -using SparseArrays -using Symbolics -using ForwardDiff -using Einsum - -function upper_half_vals(A::AbstractMatrix) - n = size(A, 1) - vals = similar(A, n * (n + 1) ÷ 2) - k = 1 - for j ∈ axes(A, 2) - for i = 1:j - vals[k] = A[i, j] - k += 1 - end - end - return vals -end - -# create an m x n sparse matrix filled with l symbolics num variables -function random_sparse_symbolics_matrix(m, n, l) - A = zeros(Symbolics.Num, m * n) - xs = collect(Symbolics.@variables(x[1:l])...) - rands = randperm(m * n)[1:l] - for i ∈ 1:l - A[rands[i]] = xs[i] - end - return sparse(reshape(A, m, n)) -end - -function structure(A::SparseMatrixCSC; upper_half=false) - I, J, _ = findnz(A) - index_pairs = collect(zip(I, J)) - if upper_half - @assert size(A, 1) == size(A, 2) - index_pairs = filter(p -> p[1] <= p[2], index_pairs) - end - return index_pairs -end - -function jacobian_structure(∂f::Function, xdim::Int) - x = collect(Symbolics.@variables(x[1:xdim])...) - return structure(sparse(∂f(x))) -end - -dynamics_jacobian_structure(∂f::Function, zdim::Int) = jacobian_structure(∂f, 2zdim) - -function hessian_of_lagrangian_structure(∂²f::Function, xdim::Int, μdim::Int) - x = collect(Symbolics.@variables(x[1:xdim])...) - μ = collect(Symbolics.@variables(μ[1:μdim])...) - ∂²f_x = ∂²f(x) - if length(size(∂²f_x)) == 3 - @einsum μ∂²f[j, k] := μ[i] * ∂²f_x[i, j, k] - elseif length(size(∂²f_x)) == 2 - μ∂²f = μ[1] * ∂²f_x - else - error("hessian of lagrangian must be 2 or 3 dimensional") - end - return structure(sparse(μ∂²f); upper_half=true) -end - -dynamics_hessian_of_lagrangian_structure(∂²f::Function, zdim::Int, μdim::Int) = - hessian_of_lagrangian_structure(∂²f, 2zdim, μdim) - -# function dynamics_structure(∂f̂::Function, traj::NamedTrajectory, dynamics_dim::Int) -# ∂²f̂(zz) = reshape( -# ForwardDiff.jacobian(x -> vec(∂f̂(x)), zz), -# traj.dims.states, -# 2traj.dim, -# 2traj.dim -# ) - -# ∂f_structure = dynamics_jacobian_structure(∂f̂, traj.dim) - -# ∂F_structure = Tuple{Int,Int}[] - -# for t = 1:traj.T-1 -# ∂fₜ_structure = [ -# ( -# i + index(t, 0, dynamics_dim), -# j + index(t, 0, traj.dim) -# ) for (i, j) ∈ ∂f_structure -# ] -# append!(∂F_structure, ∂fₜ_structure) -# end - -# μ∂²f_structure = -# dynamics_hessian_of_lagrangian_structure(∂²f̂, traj.dim, dynamics_dim) - -# μ∂²F_structure = Tuple{Int,Int}[] - -# for t = 1:traj.T-1 -# μ∂²fₜ_structure = [ij .+ index(t, 0, traj.dim) for ij ∈ μ∂²f_structure] -# append!(μ∂²F_structure, μ∂²fₜ_structure) -# end - -# return ∂f_structure, ∂F_structure, μ∂²f_structure, μ∂²F_structure -# end - -function dynamics_structure( - ∂f::Function, - μ∂²f::Function, - traj::NamedTrajectory, - dynamics_dim::Int; - verbose=false, - jacobian=true, - hessian=true -) - @assert hessian ? jacobian : true "if hessian is true, jacobian must be true" - - # getting inter knot point structure - if jacobian - if verbose - println(" computing jacobian sparsity...") - end - # getting symbolic variables - z1 = collect(Symbolics.@variables(z[1:traj.dim])...) - z2 = collect(Symbolics.@variables(z[1:traj.dim])...) - ∂f_structure = structure(sparse(∂f(z1, z2))) - else - if verbose - println(" computing full jacobian block...") - end - ∂f_structure = [(i, j) for i = 1:dynamics_dim, j = 1:2traj.dim] - end - - if hessian - if verbose - println(" computing hessian sparsity...") - end - μ = collect(Symbolics.@variables(μ[1:dynamics_dim])...) - μ∂²f_structure = structure(sparse(μ∂²f(z1, z2, μ)); upper_half=true) - else - if verbose - println(" computing full hessian block...") - end - μ∂²f_structure = [(i, j) for i = 1:2traj.dim, j = 1:2traj.dim if j ≥ i] - end - - if verbose - println(" creating full trajectory jacobian structure...") - end - ∂F_structure = Tuple{Int,Int}[] - ∂F_structure = Vector{Tuple{Int,Int}}(undef, length(∂f_structure) * (traj.T - 1)) - - @views Threads.@threads for t = 1:traj.T-1 - ∂fₜ_structure = [ - ( - i + index(t, 0, dynamics_dim), - j + index(t, 0, traj.dim) - ) for (i, j) ∈ ∂f_structure - ] - ∂F_structure[slice(t, length(∂f_structure))] .= ∂fₜ_structure - end - - μ∂²F_structure = Tuple{Int,Int}[] - - if verbose - println(" creating full trajectory hessian structure...") - end - - μ∂²F_structure = Vector{Tuple{Int,Int}}(undef, length(μ∂²f_structure) * (traj.T - 1)) - - @views Threads.@threads for t = 1:traj.T-1 - μ∂²fₜ_structure = [ij .+ index(t, 0, traj.dim) for ij ∈ μ∂²f_structure] - μ∂²F_structure[slice(t, length(μ∂²f_structure))] .= μ∂²fₜ_structure - end - - return ∂f_structure, ∂F_structure, μ∂²f_structure, μ∂²F_structure -end - - -function dynamics_structure( - ∂f::Function, - traj::NamedTrajectory, - dynamics_dim::Int; - verbose=false, - jacobian=true, -) - # getting inter knot point structure - if jacobian - if verbose - println(" computing jacobian sparsity...") - end - # getting symbolic variables - z1 = collect(Symbolics.@variables(z[1:traj.dim])...) - z2 = collect(Symbolics.@variables(z[1:traj.dim])...) - ∂f_structure = structure(sparse(∂f(z1, z2))) - else - if verbose - println(" computing full jacobian block...") - end - ∂f_structure = [(i, j) for i = 1:dynamics_dim, j = 1:2traj.dim] - end - - if verbose - println(" creating full trajectory jacobian structure...") - end - - length_∂f_structure = length(∂f_structure) - - ∂F_structure = Vector{Tuple{Int,Int}}(undef, length_∂f_structure * (traj.T - 1)) - - Threads.@threads for t = 1:traj.T-1 - ∂fₜ_structure = [ - ( - i + index(t, 0, dynamics_dim), - j + index(t, 0, traj.dim) - ) for (i, j) ∈ ∂f_structure - ] - ∂F_structure[slice(t, length_∂f_structure)] = ∂fₜ_structure - end - - return ∂f_structure, ∂F_structure -end - -function loss_hessian_structure(∂²l::Function, xdim::Int) - x = collect(Symbolics.@variables(x[1:xdim])...) - ∂²l_x = ∂²l(x) - return structure(sparse(∂²l_x); upper_half=true) -end - -end diff --git a/build/trajectory_initialization.jl b/build/trajectory_initialization.jl deleted file mode 100644 index cb0fe1af..00000000 --- a/build/trajectory_initialization.jl +++ /dev/null @@ -1,125 +0,0 @@ -module TrajectoryInitialization - -export unitary_linear_interpolation -export unitary_geodesic - -using LinearAlgebra - -using ..QuantumUtils -using ..EmbeddedOperators - -""" - unitary_linear_interpolation( - U_init::AbstractMatrix, - U_goal::AbstractMatrix, - samples::Int - ) - -Compute a linear interpolation of unitary operators with `samples` samples. -""" -function unitary_linear_interpolation( - U_init::AbstractMatrix{<:Number}, - U_goal::AbstractMatrix{<:Number}, - samples::Int -) - Ũ⃗_init = operator_to_iso_vec(U_init) - Ũ⃗_goal = operator_to_iso_vec(U_goal) - Ũ⃗s = [Ũ⃗_init + (Ũ⃗_goal - Ũ⃗_init) * t for t ∈ range(0, 1, length=samples)] - Ũ⃗ = hcat(Ũ⃗s...) - return Ũ⃗ -end - -""" - unitary_geodesic( - operator::EmbeddedOperator, - samples::Int; - kwargs... - ) - - unitary_geodesic( - U_goal::AbstractMatrix{<:Number}, - samples::Int; - kwargs... - ) - - unitary_geodesic( - U₀::AbstractMatrix{<:Number}, - U₁::AbstractMatrix{<:Number}, - samples::Number; - kwargs... - ) - - unitary_geodesic( - U₀::AbstractMatrix{<:Number}, - U₁::AbstractMatrix{<:Number}, - timesteps::AbstractVector{<:Number}; - return_generator=false - ) - -Compute a geodesic connecting two unitary operators. -""" -function unitary_geodesic end - -function unitary_geodesic( - operator::EmbeddedOperator, - samples::Int; - kwargs... -) - U_goal = unembed(operator) - U_init = Matrix{ComplexF64}(I(size(U_goal, 1))) - Ũ⃗ = unitary_geodesic(U_init, U_goal, samples; kwargs...) - return hcat([ - operator_to_iso_vec(EmbeddedOperators.embed(iso_vec_to_operator(Ũ⃗ₜ), operator)) - for Ũ⃗ₜ ∈ eachcol(Ũ⃗) - ]...) -end - -function unitary_geodesic( - U_goal::AbstractMatrix{<:Number}, - samples::Int; - kwargs... -) - N = size(U_goal, 1) - U₀ = Matrix{ComplexF64}(I(N)) - return unitary_geodesic(U₀, U_goal, samples; kwargs...) -end - -function unitary_geodesic( - U₀::AbstractMatrix{<:Number}, - U₁::AbstractMatrix{<:Number}, - samples::Number; - kwargs... -) - return unitary_geodesic(U₀, U₁, range(0, 1, samples); kwargs...) -end - -function unitary_geodesic( - U₀::AbstractMatrix{<:Number}, - U₁::AbstractMatrix{<:Number}, - timesteps::AbstractVector{<:Number}; - return_generator=false -) - """ - Compute the effective generator of the geodesic connecting U₀ and U₁. - U₁ = exp(-im * H * T) U₀ - log(U₁ * U₀') = -im * H * T - - Allow for the possibiltiy of unequal timesteps and ranges outside [0,1]. - - Returns the geodesic. - Optionally returns the effective Hamiltonian generating the geodesic. - """ - t₀ = timesteps[1] - T = timesteps[end] - t₀ - H = im * log(U₁ * U₀') / T - # -im prefactor is not included in H - U_geo = [exp(-im * H * (t - t₀)) * U₀ for t ∈ timesteps] - Ũ⃗_geo = stack(operator_to_iso_vec.(U_geo), dims=2) - if return_generator - return Ũ⃗_geo, H - else - return Ũ⃗_geo - end -end - -end diff --git a/docs/Manifest.toml b/docs/Manifest.toml deleted file mode 100644 index e4ae01dc..00000000 --- a/docs/Manifest.toml +++ /dev/null @@ -1,2174 +0,0 @@ -# This file is machine-generated - editing it directly is not advised - -julia_version = "1.11.1" -manifest_format = "2.0" -project_hash = "46fa82f4324d65b2cf462382aecded8067fca5f1" - -[[deps.ADTypes]] -git-tree-sha1 = "eea5d80188827b35333801ef97a40c2ed653b081" -uuid = "47edcb42-4c32-4615-8424-f2b9edc5f35b" -version = "1.9.0" - - [deps.ADTypes.extensions] - ADTypesChainRulesCoreExt = "ChainRulesCore" - ADTypesEnzymeCoreExt = "EnzymeCore" - - [deps.ADTypes.weakdeps] - ChainRulesCore = "d360d2e6-b24c-11e9-a2a3-2a2ae2dbcce4" - EnzymeCore = "f151be2c-9106-41f4-ab19-57ee4f262869" - -[[deps.ANSIColoredPrinters]] -git-tree-sha1 = "574baf8110975760d391c710b6341da1afa48d8c" -uuid = "a4c015fc-c6ff-483c-b24f-f7ea428134e9" -version = "0.0.1" - -[[deps.ASL_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl", "Pkg"] -git-tree-sha1 = "6252039f98492252f9e47c312c8ffda0e3b9e78d" -uuid = "ae81ac8f-d209-56e5-92de-9978fef736f9" -version = "0.1.3+0" - -[[deps.AbstractDifferentiation]] -deps = ["ExprTools", "LinearAlgebra", "Requires"] -git-tree-sha1 = "d29ce82ed1d4c37135095e1a4d799c93d7be2361" -uuid = "c29ec348-61ec-40c8-8164-b8c60e9d9f3d" -version = "0.6.2" - - [deps.AbstractDifferentiation.extensions] - AbstractDifferentiationChainRulesCoreExt = "ChainRulesCore" - AbstractDifferentiationFiniteDifferencesExt = "FiniteDifferences" - AbstractDifferentiationForwardDiffExt = ["DiffResults", "ForwardDiff"] - AbstractDifferentiationReverseDiffExt = ["DiffResults", "ReverseDiff"] - AbstractDifferentiationTrackerExt = "Tracker" - AbstractDifferentiationZygoteExt = "Zygote" - - [deps.AbstractDifferentiation.weakdeps] - ChainRulesCore = "d360d2e6-b24c-11e9-a2a3-2a2ae2dbcce4" - DiffResults = "163ba53b-c6d8-5494-b064-1a9d43ac40c5" - FiniteDifferences = "26cc04aa-876d-5657-8c51-4c34ba976000" - ForwardDiff = "f6369f11-7733-5829-9624-2563aa707210" - ReverseDiff = "37e2e3b7-166d-5795-8a7a-e32c996b4267" - Tracker = "9f7883ad-71c0-57eb-9f7f-b5c9e6d3789c" - Zygote = "e88e6eb3-aa80-5325-afca-941959d7151f" - -[[deps.AbstractFFTs]] -deps = ["LinearAlgebra"] -git-tree-sha1 = "d92ad398961a3ed262d8bf04a1a2b8340f915fef" -uuid = "621f4979-c628-5d54-868e-fcf4e3e8185c" -version = "1.5.0" -weakdeps = ["ChainRulesCore", "Test"] - - [deps.AbstractFFTs.extensions] - AbstractFFTsChainRulesCoreExt = "ChainRulesCore" - AbstractFFTsTestExt = "Test" - -[[deps.AbstractTrees]] -git-tree-sha1 = "2d9c9a55f9c93e8887ad391fbae72f8ef55e1177" -uuid = "1520ce14-60c1-5f80-bbc7-55ef81b5835c" -version = "0.4.5" - -[[deps.Accessors]] -deps = ["CompositionsBase", "ConstructionBase", "InverseFunctions", "LinearAlgebra", "MacroTools", "Markdown"] -git-tree-sha1 = "b392ede862e506d451fc1616e79aa6f4c673dab8" -uuid = "7d9f7c33-5ae7-4f3b-8dc6-eff91059b697" -version = "0.1.38" - - [deps.Accessors.extensions] - AccessorsAxisKeysExt = "AxisKeys" - AccessorsDatesExt = "Dates" - AccessorsIntervalSetsExt = "IntervalSets" - AccessorsStaticArraysExt = "StaticArrays" - AccessorsStructArraysExt = "StructArrays" - AccessorsTestExt = "Test" - AccessorsUnitfulExt = "Unitful" - - [deps.Accessors.weakdeps] - AxisKeys = "94b1ba4f-4ee9-5380-92f1-94cde586c3c5" - Dates = "ade2ca70-3891-5945-98fb-dc099432e06a" - IntervalSets = "8197267c-284f-5f27-9208-e0e47529a953" - Requires = "ae029012-a4dd-5104-9daa-d747884805df" - StaticArrays = "90137ffa-7385-5640-81b9-e52037218182" - StructArrays = "09ab397b-f2b6-538f-b94a-2f83cf4a842a" - Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40" - Unitful = "1986cc42-f94f-5a68-af5c-568840ba703d" - -[[deps.Adapt]] -deps = ["LinearAlgebra", "Requires"] -git-tree-sha1 = "50c3c56a52972d78e8be9fd135bfb91c9574c140" -uuid = "79e6a3ab-5dfb-504d-930d-738a2a938a0e" -version = "4.1.1" -weakdeps = ["StaticArrays"] - - [deps.Adapt.extensions] - AdaptStaticArraysExt = "StaticArrays" - -[[deps.AdaptivePredicates]] -git-tree-sha1 = "7e651ea8d262d2d74ce75fdf47c4d63c07dba7a6" -uuid = "35492f91-a3bd-45ad-95db-fcad7dcfedb7" -version = "1.2.0" - -[[deps.AliasTables]] -deps = ["PtrArrays", "Random"] -git-tree-sha1 = "9876e1e164b144ca45e9e3198d0b689cadfed9ff" -uuid = "66dad0bd-aa9a-41b7-9441-69ab47430ed8" -version = "1.1.3" - -[[deps.Animations]] -deps = ["Colors"] -git-tree-sha1 = "e81c509d2c8e49592413bfb0bb3b08150056c79d" -uuid = "27a7e980-b3e6-11e9-2bcd-0b925532e340" -version = "0.4.1" - -[[deps.Aqua]] -deps = ["Compat", "Pkg", "Test"] -git-tree-sha1 = "49b1d7a9870c87ba13dc63f8ccfcf578cb266f95" -uuid = "4c88cf16-eb10-579e-8560-4a9242c79595" -version = "0.8.9" - -[[deps.ArgTools]] -uuid = "0dad84c5-d112-42e6-8d28-ef12dabb789f" -version = "1.1.2" - -[[deps.ArrayInterface]] -deps = ["Adapt", "LinearAlgebra"] -git-tree-sha1 = "d60a1922358aa203019b7857a2c8c37329b8736c" -uuid = "4fba245c-0d91-5ea0-9b3e-6abc04ee57a9" -version = "7.17.0" - - [deps.ArrayInterface.extensions] - ArrayInterfaceBandedMatricesExt = "BandedMatrices" - ArrayInterfaceBlockBandedMatricesExt = "BlockBandedMatrices" - ArrayInterfaceCUDAExt = "CUDA" - ArrayInterfaceCUDSSExt = "CUDSS" - ArrayInterfaceChainRulesCoreExt = "ChainRulesCore" - ArrayInterfaceChainRulesExt = "ChainRules" - ArrayInterfaceGPUArraysCoreExt = "GPUArraysCore" - ArrayInterfaceReverseDiffExt = "ReverseDiff" - ArrayInterfaceSparseArraysExt = "SparseArrays" - ArrayInterfaceStaticArraysCoreExt = "StaticArraysCore" - ArrayInterfaceTrackerExt = "Tracker" - - [deps.ArrayInterface.weakdeps] - BandedMatrices = "aae01518-5342-5314-be14-df237901396f" - BlockBandedMatrices = "ffab5731-97b5-5995-9138-79e8c1846df0" - CUDA = "052768ef-5323-5732-b1bb-66c8b64840ba" - CUDSS = "45b445bb-4962-46a0-9369-b4df9d0f772e" - ChainRules = "082447d4-558c-5d27-93f4-14fc19e9eca2" - ChainRulesCore = "d360d2e6-b24c-11e9-a2a3-2a2ae2dbcce4" - GPUArraysCore = "46192b85-c4d5-4398-a991-12ede77f4527" - ReverseDiff = "37e2e3b7-166d-5795-8a7a-e32c996b4267" - SparseArrays = "2f01184e-e22b-5df5-ae63-d93ebab69eaf" - StaticArraysCore = "1e83bf80-4336-4d27-bf5d-d5a4f845583c" - Tracker = "9f7883ad-71c0-57eb-9f7f-b5c9e6d3789c" - -[[deps.ArrayLayouts]] -deps = ["FillArrays", "LinearAlgebra"] -git-tree-sha1 = "492681bc44fac86804706ddb37da10880a2bd528" -uuid = "4c555306-a7a7-4459-81d9-ec55ddd5c99a" -version = "1.10.4" -weakdeps = ["SparseArrays"] - - [deps.ArrayLayouts.extensions] - ArrayLayoutsSparseArraysExt = "SparseArrays" - -[[deps.Artifacts]] -uuid = "56f22d72-fd6d-98f1-02f0-08ddc0907c33" -version = "1.11.0" - -[[deps.Automa]] -deps = ["PrecompileTools", "SIMD", "TranscodingStreams"] -git-tree-sha1 = "a8f503e8e1a5f583fbef15a8440c8c7e32185df2" -uuid = "67c07d97-cdcb-5c2c-af73-a7f9c32a568b" -version = "1.1.0" - -[[deps.AxisAlgorithms]] -deps = ["LinearAlgebra", "Random", "SparseArrays", "WoodburyMatrices"] -git-tree-sha1 = "01b8ccb13d68535d73d2b0c23e39bd23155fb712" -uuid = "13072b0f-2c55-5437-9ae7-d433b7a33950" -version = "1.1.0" - -[[deps.AxisArrays]] -deps = ["Dates", "IntervalSets", "IterTools", "RangeArrays"] -git-tree-sha1 = "16351be62963a67ac4083f748fdb3cca58bfd52f" -uuid = "39de3d68-74b9-583c-8d2d-e117c070f3a9" -version = "0.4.7" - -[[deps.Base64]] -uuid = "2a0f44e3-6c83-55bd-87e4-b1978d98bd5f" -version = "1.11.0" - -[[deps.BenchmarkTools]] -deps = ["JSON", "Logging", "Printf", "Profile", "Statistics", "UUIDs"] -git-tree-sha1 = "f1dff6729bc61f4d49e140da1af55dcd1ac97b2f" -uuid = "6e4b80f9-dd63-53aa-95a3-0cdb28fa8baf" -version = "1.5.0" - -[[deps.Bijections]] -git-tree-sha1 = "d8b0439d2be438a5f2cd68ec158fe08a7b2595b7" -uuid = "e2ed5e7c-b2de-5872-ae92-c73ca462fb04" -version = "0.1.9" - -[[deps.BitFlags]] -git-tree-sha1 = "0691e34b3bb8be9307330f88d1a3c3f25466c24d" -uuid = "d1d4a3ce-64b1-5f1a-9ba4-7e7e69966f35" -version = "0.1.9" - -[[deps.BlockArrays]] -deps = ["ArrayLayouts", "FillArrays", "LinearAlgebra"] -git-tree-sha1 = "d434647f798823bcae510aee0bc0401927f64391" -uuid = "8e7c35d0-a365-5155-bbbb-fb81a777f24e" -version = "1.1.1" - - [deps.BlockArrays.extensions] - BlockArraysBandedMatricesExt = "BandedMatrices" - - [deps.BlockArrays.weakdeps] - BandedMatrices = "aae01518-5342-5314-be14-df237901396f" - -[[deps.Bzip2_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl", "Pkg"] -git-tree-sha1 = "8873e196c2eb87962a2048b3b8e08946535864a1" -uuid = "6e34b625-4abd-537c-b88f-471c36dfa7a0" -version = "1.0.8+2" - -[[deps.CEnum]] -git-tree-sha1 = "389ad5c84de1ae7cf0e28e381131c98ea87d54fc" -uuid = "fa961155-64e5-5f13-b03f-caf6b980ea82" -version = "0.5.0" - -[[deps.CRC32c]] -uuid = "8bf52ea8-c179-5cab-976a-9e18b702a9bc" -version = "1.11.0" - -[[deps.CRlibm_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl", "Pkg"] -git-tree-sha1 = "e329286945d0cfc04456972ea732551869af1cfc" -uuid = "4e9b3aee-d8a1-5a3d-ad8b-7d824db253f0" -version = "1.0.1+0" - -[[deps.Cairo]] -deps = ["Cairo_jll", "Colors", "Glib_jll", "Graphics", "Libdl", "Pango_jll"] -git-tree-sha1 = "7b6ad8c35f4bc3bca8eb78127c8b99719506a5fb" -uuid = "159f3aea-2a34-519c-b102-8c37f9878175" -version = "1.1.0" - -[[deps.CairoMakie]] -deps = ["CRC32c", "Cairo", "Cairo_jll", "Colors", "FileIO", "FreeType", "GeometryBasics", "LinearAlgebra", "Makie", "PrecompileTools"] -git-tree-sha1 = "c3161fbfe99d9d7ee121cf2017d49966b152857c" -uuid = "13f3f980-e62b-5c42-98c6-ff1f3baf88f0" -version = "0.12.16" - -[[deps.Cairo_jll]] -deps = ["Artifacts", "Bzip2_jll", "CompilerSupportLibraries_jll", "Fontconfig_jll", "FreeType2_jll", "Glib_jll", "JLLWrappers", "LZO_jll", "Libdl", "Pixman_jll", "Xorg_libXext_jll", "Xorg_libXrender_jll", "Zlib_jll", "libpng_jll"] -git-tree-sha1 = "009060c9a6168704143100f36ab08f06c2af4642" -uuid = "83423d85-b0ee-5818-9007-b63ccbeb887a" -version = "1.18.2+1" - -[[deps.ChainRulesCore]] -deps = ["Compat", "LinearAlgebra"] -git-tree-sha1 = "3e4b134270b372f2ed4d4d0e936aabaefc1802bc" -uuid = "d360d2e6-b24c-11e9-a2a3-2a2ae2dbcce4" -version = "1.25.0" -weakdeps = ["SparseArrays"] - - [deps.ChainRulesCore.extensions] - ChainRulesCoreSparseArraysExt = "SparseArrays" - -[[deps.CodeTracking]] -deps = ["InteractiveUtils", "UUIDs"] -git-tree-sha1 = "7eee164f122511d3e4e1ebadb7956939ea7e1c77" -uuid = "da1fd8a2-8d9e-5ec2-8556-3022fb5608a2" -version = "1.3.6" - -[[deps.CodecBzip2]] -deps = ["Bzip2_jll", "TranscodingStreams"] -git-tree-sha1 = "e7c529cc31bb85b97631b922fa2e6baf246f5905" -uuid = "523fee87-0ab8-5b00-afb7-3ecf72e48cfd" -version = "0.8.4" - -[[deps.CodecZlib]] -deps = ["TranscodingStreams", "Zlib_jll"] -git-tree-sha1 = "bce6804e5e6044c6daab27bb533d1295e4a2e759" -uuid = "944b1d66-785c-5afd-91f1-9de20f533193" -version = "0.7.6" - -[[deps.ColorBrewer]] -deps = ["Colors", "JSON", "Test"] -git-tree-sha1 = "61c5334f33d91e570e1d0c3eb5465835242582c4" -uuid = "a2cac450-b92f-5266-8821-25eda20663c8" -version = "0.4.0" - -[[deps.ColorSchemes]] -deps = ["ColorTypes", "ColorVectorSpace", "Colors", "FixedPointNumbers", "PrecompileTools", "Random"] -git-tree-sha1 = "c785dfb1b3bfddd1da557e861b919819b82bbe5b" -uuid = "35d6a980-a343-548e-a6ea-1d62b119f2f4" -version = "3.27.1" - -[[deps.ColorTypes]] -deps = ["FixedPointNumbers", "Random"] -git-tree-sha1 = "b10d0b65641d57b8b4d5e234446582de5047050d" -uuid = "3da002f7-5984-5a60-b8a6-cbb66c0b333f" -version = "0.11.5" - -[[deps.ColorVectorSpace]] -deps = ["ColorTypes", "FixedPointNumbers", "LinearAlgebra", "Requires", "Statistics", "TensorCore"] -git-tree-sha1 = "a1f44953f2382ebb937d60dafbe2deea4bd23249" -uuid = "c3611d14-8923-5661-9e6a-0046d554d3a4" -version = "0.10.0" -weakdeps = ["SpecialFunctions"] - - [deps.ColorVectorSpace.extensions] - SpecialFunctionsExt = "SpecialFunctions" - -[[deps.Colors]] -deps = ["ColorTypes", "FixedPointNumbers", "Reexport"] -git-tree-sha1 = "362a287c3aa50601b0bc359053d5c2468f0e7ce0" -uuid = "5ae59095-9a9b-59fe-a467-6f913c188581" -version = "0.12.11" - -[[deps.Combinatorics]] -git-tree-sha1 = "08c8b6831dc00bfea825826be0bc8336fc369860" -uuid = "861a8166-3701-5b0c-9a16-15d98fcdc6aa" -version = "1.0.2" - -[[deps.CommonSolve]] -git-tree-sha1 = "0eee5eb66b1cf62cd6ad1b460238e60e4b09400c" -uuid = "38540f10-b2f7-11e9-35d8-d573e4eb0ff2" -version = "0.2.4" - -[[deps.CommonSubexpressions]] -deps = ["MacroTools"] -git-tree-sha1 = "cda2cfaebb4be89c9084adaca7dd7333369715c5" -uuid = "bbf7d656-a473-5ed7-a52c-81e309532950" -version = "0.3.1" - -[[deps.CommonWorldInvalidations]] -git-tree-sha1 = "ae52d1c52048455e85a387fbee9be553ec2b68d0" -uuid = "f70d9fcc-98c5-4d4a-abd7-e4cdeebd8ca8" -version = "1.0.0" - -[[deps.Compat]] -deps = ["TOML", "UUIDs"] -git-tree-sha1 = "8ae8d32e09f0dcf42a36b90d4e17f5dd2e4c4215" -uuid = "34da2185-b29b-5c13-b0c7-acf172513d20" -version = "4.16.0" -weakdeps = ["Dates", "LinearAlgebra"] - - [deps.Compat.extensions] - CompatLinearAlgebraExt = "LinearAlgebra" - -[[deps.CompilerSupportLibraries_jll]] -deps = ["Artifacts", "Libdl"] -uuid = "e66e0078-7015-5450-92f7-15fbd957f2ae" -version = "1.1.1+0" - -[[deps.CompositeTypes]] -git-tree-sha1 = "bce26c3dab336582805503bed209faab1c279768" -uuid = "b152e2b5-7a66-4b01-a709-34e65c35f657" -version = "0.1.4" - -[[deps.CompositionsBase]] -git-tree-sha1 = "802bb88cd69dfd1509f6670416bd4434015693ad" -uuid = "a33af91c-f02d-484b-be07-31d278c5ca2b" -version = "0.1.2" -weakdeps = ["InverseFunctions"] - - [deps.CompositionsBase.extensions] - CompositionsBaseInverseFunctionsExt = "InverseFunctions" - -[[deps.ConcurrentUtilities]] -deps = ["Serialization", "Sockets"] -git-tree-sha1 = "ea32b83ca4fefa1768dc84e504cc0a94fb1ab8d1" -uuid = "f0e56b4a-5159-44fe-b623-3e5288b988bb" -version = "2.4.2" - -[[deps.ConstructionBase]] -git-tree-sha1 = "76219f1ed5771adbb096743bff43fb5fdd4c1157" -uuid = "187b0558-2788-49d3-abe0-74a17ed4e7c9" -version = "1.5.8" -weakdeps = ["IntervalSets", "LinearAlgebra", "StaticArrays"] - - [deps.ConstructionBase.extensions] - ConstructionBaseIntervalSetsExt = "IntervalSets" - ConstructionBaseLinearAlgebraExt = "LinearAlgebra" - ConstructionBaseStaticArraysExt = "StaticArrays" - -[[deps.Contour]] -git-tree-sha1 = "439e35b0b36e2e5881738abc8857bd92ad6ff9a8" -uuid = "d38c429a-6771-53c6-b99e-75d170b6e991" -version = "0.6.3" - -[[deps.DataAPI]] -git-tree-sha1 = "abe83f3a2f1b857aac70ef8b269080af17764bbe" -uuid = "9a962f9c-6df0-11e9-0e5d-c546b8b5ee8a" -version = "1.16.0" - -[[deps.DataStructures]] -deps = ["Compat", "InteractiveUtils", "OrderedCollections"] -git-tree-sha1 = "1d0a14036acb104d9e89698bd408f63ab58cdc82" -uuid = "864edb3b-99cc-5e75-8d2d-829cb0a9cfe8" -version = "0.18.20" - -[[deps.DataValueInterfaces]] -git-tree-sha1 = "bfc1187b79289637fa0ef6d4436ebdfe6905cbd6" -uuid = "e2d170a0-9d28-54be-80f0-106bbe20a464" -version = "1.0.0" - -[[deps.Dates]] -deps = ["Printf"] -uuid = "ade2ca70-3891-5945-98fb-dc099432e06a" -version = "1.11.0" - -[[deps.DelaunayTriangulation]] -deps = ["AdaptivePredicates", "EnumX", "ExactPredicates", "PrecompileTools", "Random"] -git-tree-sha1 = "89df54fbe66e5872d91d8c2cd3a375f660c3fd64" -uuid = "927a84f5-c5f4-47a5-9785-b46e178433df" -version = "1.6.1" - -[[deps.DiffResults]] -deps = ["StaticArraysCore"] -git-tree-sha1 = "782dd5f4561f5d267313f23853baaaa4c52ea621" -uuid = "163ba53b-c6d8-5494-b064-1a9d43ac40c5" -version = "1.1.0" - -[[deps.DiffRules]] -deps = ["IrrationalConstants", "LogExpFunctions", "NaNMath", "Random", "SpecialFunctions"] -git-tree-sha1 = "23163d55f885173722d1e4cf0f6110cdbaf7e272" -uuid = "b552c78f-8df3-52c6-915a-8e097449b14b" -version = "1.15.1" - -[[deps.Distributed]] -deps = ["Random", "Serialization", "Sockets"] -uuid = "8ba89e20-285c-5b6f-9357-94700520ee1b" -version = "1.11.0" - -[[deps.Distributions]] -deps = ["AliasTables", "FillArrays", "LinearAlgebra", "PDMats", "Printf", "QuadGK", "Random", "SpecialFunctions", "Statistics", "StatsAPI", "StatsBase", "StatsFuns"] -git-tree-sha1 = "3101c32aab536e7a27b1763c0797dba151b899ad" -uuid = "31c24e10-a181-5473-b8eb-7969acd0382f" -version = "0.25.113" - - [deps.Distributions.extensions] - DistributionsChainRulesCoreExt = "ChainRulesCore" - DistributionsDensityInterfaceExt = "DensityInterface" - DistributionsTestExt = "Test" - - [deps.Distributions.weakdeps] - ChainRulesCore = "d360d2e6-b24c-11e9-a2a3-2a2ae2dbcce4" - DensityInterface = "b429d917-457f-4dbc-8f4c-0cc954292b1d" - Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40" - -[[deps.DocStringExtensions]] -deps = ["LibGit2"] -git-tree-sha1 = "2fb1e02f2b635d0845df5d7c167fec4dd739b00d" -uuid = "ffbed154-4ef7-542d-bbb7-c09d3a79fcae" -version = "0.9.3" - -[[deps.Documenter]] -deps = ["ANSIColoredPrinters", "AbstractTrees", "Base64", "CodecZlib", "Dates", "DocStringExtensions", "Downloads", "Git", "IOCapture", "InteractiveUtils", "JSON", "LibGit2", "Logging", "Markdown", "MarkdownAST", "Pkg", "PrecompileTools", "REPL", "RegistryInstances", "SHA", "TOML", "Test", "Unicode"] -git-tree-sha1 = "5a1ee886566f2fa9318df1273d8b778b9d42712d" -uuid = "e30172f5-a6a5-5a46-863b-614d45cd2de4" -version = "1.7.0" - -[[deps.DomainSets]] -deps = ["CompositeTypes", "IntervalSets", "LinearAlgebra", "Random", "StaticArrays"] -git-tree-sha1 = "490392af2c7d63183bfa2c8aaa6ab981c5ba7561" -uuid = "5b8099bc-c8ec-5219-889f-1d9e522a28bf" -version = "0.7.14" -weakdeps = ["Makie"] - - [deps.DomainSets.extensions] - DomainSetsMakieExt = "Makie" - -[[deps.Downloads]] -deps = ["ArgTools", "FileWatching", "LibCURL", "NetworkOptions"] -uuid = "f43a241f-c20a-4ad4-852c-f6b1247861c6" -version = "1.6.0" - -[[deps.DynamicPolynomials]] -deps = ["Future", "LinearAlgebra", "MultivariatePolynomials", "MutableArithmetics", "Reexport", "Test"] -git-tree-sha1 = "bbf1ace0781d9744cb697fb856bd2c3f6568dadb" -uuid = "7c1d4256-1411-5781-91ec-d7bc3513ac07" -version = "0.6.0" - -[[deps.EarCut_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl", "Pkg"] -git-tree-sha1 = "e3290f2d49e661fbd94046d7e3726ffcb2d41053" -uuid = "5ae413db-bbd1-5e63-b57d-d24a61df00f5" -version = "2.2.4+0" - -[[deps.Einsum]] -deps = ["Compat"] -git-tree-sha1 = "4a6b3eee0161c89700b6c1949feae8b851da5494" -uuid = "b7d42ee7-0b51-5a75-98ca-779d3107e4c0" -version = "0.4.1" - -[[deps.EnumX]] -git-tree-sha1 = "bdb1942cd4c45e3c678fd11569d5cccd80976237" -uuid = "4e289a0a-7415-4d19-859d-a7e5c4648b56" -version = "1.0.4" - -[[deps.ExactPredicates]] -deps = ["IntervalArithmetic", "Random", "StaticArrays"] -git-tree-sha1 = "b3f2ff58735b5f024c392fde763f29b057e4b025" -uuid = "429591f6-91af-11e9-00e2-59fbe8cec110" -version = "2.2.8" - -[[deps.ExceptionUnwrapping]] -deps = ["Test"] -git-tree-sha1 = "dcb08a0d93ec0b1cdc4af184b26b591e9695423a" -uuid = "460bff9d-24e4-43bc-9d9f-a8973cb893f4" -version = "0.1.10" - -[[deps.Expat_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "1c6317308b9dc757616f0b5cb379db10494443a7" -uuid = "2e619515-83b5-522b-bb60-26c02a35a201" -version = "2.6.2+0" - -[[deps.ExponentialAction]] -deps = ["AbstractDifferentiation", "ChainRulesCore", "LinearAlgebra", "SparseArrays"] -git-tree-sha1 = "c8e96f985aa517c5b8413661c8c06e1021895639" -uuid = "e24c0720-ea99-47e8-929e-571b494574d3" -version = "0.2.10" - -[[deps.ExprTools]] -git-tree-sha1 = "27415f162e6028e81c72b82ef756bf321213b6ec" -uuid = "e2ba6199-217a-4e67-a87a-7c52f15ade04" -version = "0.1.10" - -[[deps.Expronicon]] -deps = ["MLStyle", "Pkg", "TOML"] -git-tree-sha1 = "fc3951d4d398b5515f91d7fe5d45fc31dccb3c9b" -uuid = "6b7a57c9-7cc1-4fdf-b7f5-e857abae3636" -version = "0.8.5" - -[[deps.Extents]] -git-tree-sha1 = "81023caa0021a41712685887db1fc03db26f41f5" -uuid = "411431e0-e8b7-467b-b5e0-f676ba4f2910" -version = "0.1.4" - -[[deps.FFMPEG_jll]] -deps = ["Artifacts", "Bzip2_jll", "FreeType2_jll", "FriBidi_jll", "JLLWrappers", "LAME_jll", "Libdl", "Ogg_jll", "OpenSSL_jll", "Opus_jll", "PCRE2_jll", "Zlib_jll", "libaom_jll", "libass_jll", "libfdk_aac_jll", "libvorbis_jll", "x264_jll", "x265_jll"] -git-tree-sha1 = "8cc47f299902e13f90405ddb5bf87e5d474c0d38" -uuid = "b22a6f82-2f65-5046-a5b2-351ab43fb4e5" -version = "6.1.2+0" - -[[deps.FFTW]] -deps = ["AbstractFFTs", "FFTW_jll", "LinearAlgebra", "MKL_jll", "Preferences", "Reexport"] -git-tree-sha1 = "4820348781ae578893311153d69049a93d05f39d" -uuid = "7a1cc6ca-52ef-59f5-83cd-3a7055c09341" -version = "1.8.0" - -[[deps.FFTW_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl", "Pkg"] -git-tree-sha1 = "4d81ed14783ec49ce9f2e168208a12ce1815aa25" -uuid = "f5851436-0d7a-5f13-b9de-f02708fd171a" -version = "3.3.10+1" - -[[deps.FileIO]] -deps = ["Pkg", "Requires", "UUIDs"] -git-tree-sha1 = "62ca0547a14c57e98154423419d8a342dca75ca9" -uuid = "5789e2e9-d7fb-5bc7-8068-2c6fae9b9549" -version = "1.16.4" - -[[deps.FilePaths]] -deps = ["FilePathsBase", "MacroTools", "Reexport", "Requires"] -git-tree-sha1 = "919d9412dbf53a2e6fe74af62a73ceed0bce0629" -uuid = "8fc22ac5-c921-52a6-82fd-178b2807b824" -version = "0.8.3" - -[[deps.FilePathsBase]] -deps = ["Compat", "Dates"] -git-tree-sha1 = "7878ff7172a8e6beedd1dea14bd27c3c6340d361" -uuid = "48062228-2e41-5def-b9a4-89aafe57970f" -version = "0.9.22" -weakdeps = ["Mmap", "Test"] - - [deps.FilePathsBase.extensions] - FilePathsBaseMmapExt = "Mmap" - FilePathsBaseTestExt = "Test" - -[[deps.FileWatching]] -uuid = "7b1f6079-737a-58dc-b8bc-7a2ca5c1b5ee" -version = "1.11.0" - -[[deps.FillArrays]] -deps = ["LinearAlgebra"] -git-tree-sha1 = "6a70198746448456524cb442b8af316927ff3e1a" -uuid = "1a297f60-69ca-5386-bcde-b61e274b549b" -version = "1.13.0" -weakdeps = ["PDMats", "SparseArrays", "Statistics"] - - [deps.FillArrays.extensions] - FillArraysPDMatsExt = "PDMats" - FillArraysSparseArraysExt = "SparseArrays" - FillArraysStatisticsExt = "Statistics" - -[[deps.FixedPointNumbers]] -deps = ["Statistics"] -git-tree-sha1 = "05882d6995ae5c12bb5f36dd2ed3f61c98cbb172" -uuid = "53c48c17-4a7d-5ca2-90c5-79b7896eea93" -version = "0.8.5" - -[[deps.Fontconfig_jll]] -deps = ["Artifacts", "Bzip2_jll", "Expat_jll", "FreeType2_jll", "JLLWrappers", "Libdl", "Libuuid_jll", "Zlib_jll"] -git-tree-sha1 = "db16beca600632c95fc8aca29890d83788dd8b23" -uuid = "a3f928ae-7b40-5064-980b-68af3947d34b" -version = "2.13.96+0" - -[[deps.Format]] -git-tree-sha1 = "9c68794ef81b08086aeb32eeaf33531668d5f5fc" -uuid = "1fa38f19-a742-5d3f-a2b9-30dd87b9d5f8" -version = "1.3.7" - -[[deps.ForwardDiff]] -deps = ["CommonSubexpressions", "DiffResults", "DiffRules", "LinearAlgebra", "LogExpFunctions", "NaNMath", "Preferences", "Printf", "Random", "SpecialFunctions"] -git-tree-sha1 = "a2df1b776752e3f344e5116c06d75a10436ab853" -uuid = "f6369f11-7733-5829-9624-2563aa707210" -version = "0.10.38" -weakdeps = ["StaticArrays"] - - [deps.ForwardDiff.extensions] - ForwardDiffStaticArraysExt = "StaticArrays" - -[[deps.FreeType]] -deps = ["CEnum", "FreeType2_jll"] -git-tree-sha1 = "907369da0f8e80728ab49c1c7e09327bf0d6d999" -uuid = "b38be410-82b0-50bf-ab77-7b57e271db43" -version = "4.1.1" - -[[deps.FreeType2_jll]] -deps = ["Artifacts", "Bzip2_jll", "JLLWrappers", "Libdl", "Zlib_jll"] -git-tree-sha1 = "5c1d8ae0efc6c2e7b1fc502cbe25def8f661b7bc" -uuid = "d7e528f0-a631-5988-bf34-fe36492bcfd7" -version = "2.13.2+0" - -[[deps.FreeTypeAbstraction]] -deps = ["ColorVectorSpace", "Colors", "FreeType", "GeometryBasics"] -git-tree-sha1 = "84dfe824bd6fdf2a5d73bb187ff31b5549b2a79c" -uuid = "663a7486-cb36-511b-a19d-713bb74d65c9" -version = "0.10.4" - -[[deps.FriBidi_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "1ed150b39aebcc805c26b93a8d0122c940f64ce2" -uuid = "559328eb-81f9-559d-9380-de523a88c83c" -version = "1.0.14+0" - -[[deps.FunctionWrappers]] -git-tree-sha1 = "d62485945ce5ae9c0c48f124a84998d755bae00e" -uuid = "069b7b12-0de2-55c6-9aab-29f3d0a68a2e" -version = "1.1.3" - -[[deps.FunctionWrappersWrappers]] -deps = ["FunctionWrappers"] -git-tree-sha1 = "b104d487b34566608f8b4e1c39fb0b10aa279ff8" -uuid = "77dc65aa-8811-40c2-897b-53d922fa7daf" -version = "0.1.3" - -[[deps.Future]] -deps = ["Random"] -uuid = "9fa8497b-333b-5362-9e8d-4d0656e87820" -version = "1.11.0" - -[[deps.GPUArraysCore]] -deps = ["Adapt"] -git-tree-sha1 = "ec632f177c0d990e64d955ccc1b8c04c485a0950" -uuid = "46192b85-c4d5-4398-a991-12ede77f4527" -version = "0.1.6" - -[[deps.GeoFormatTypes]] -git-tree-sha1 = "59107c179a586f0fe667024c5eb7033e81333271" -uuid = "68eda718-8dee-11e9-39e7-89f7f65f511f" -version = "0.4.2" - -[[deps.GeoInterface]] -deps = ["Extents", "GeoFormatTypes"] -git-tree-sha1 = "826b4fd69438d9ce4d2b19de6bc2f970f45f0f88" -uuid = "cf35fbd7-0cd7-5166-be24-54bfbe79505f" -version = "1.3.8" - -[[deps.GeometryBasics]] -deps = ["EarCut_jll", "Extents", "GeoInterface", "IterTools", "LinearAlgebra", "StaticArrays", "StructArrays", "Tables"] -git-tree-sha1 = "b62f2b2d76cee0d61a2ef2b3118cd2a3215d3134" -uuid = "5c1252a2-5f33-56bf-86c9-59e7332b4326" -version = "0.4.11" - -[[deps.Gettext_jll]] -deps = ["Artifacts", "CompilerSupportLibraries_jll", "JLLWrappers", "Libdl", "Libiconv_jll", "Pkg", "XML2_jll"] -git-tree-sha1 = "9b02998aba7bf074d14de89f9d37ca24a1a0b046" -uuid = "78b55507-aeef-58d4-861c-77aaff3498b1" -version = "0.21.0+0" - -[[deps.Giflib_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "0224cce99284d997f6880a42ef715a37c99338d1" -uuid = "59f7168a-df46-5410-90c8-f2779963d0ec" -version = "5.2.2+0" - -[[deps.Git]] -deps = ["Git_jll"] -git-tree-sha1 = "04eff47b1354d702c3a85e8ab23d539bb7d5957e" -uuid = "d7ba0133-e1db-5d97-8f8c-041e4b3a1eb2" -version = "1.3.1" - -[[deps.Git_jll]] -deps = ["Artifacts", "Expat_jll", "JLLWrappers", "LibCURL_jll", "Libdl", "Libiconv_jll", "OpenSSL_jll", "PCRE2_jll", "Zlib_jll"] -git-tree-sha1 = "ea372033d09e4552a04fd38361cd019f9003f4f4" -uuid = "f8c6e375-362e-5223-8a59-34ff63f689eb" -version = "2.46.2+0" - -[[deps.Glib_jll]] -deps = ["Artifacts", "Gettext_jll", "JLLWrappers", "Libdl", "Libffi_jll", "Libiconv_jll", "Libmount_jll", "PCRE2_jll", "Zlib_jll"] -git-tree-sha1 = "674ff0db93fffcd11a3573986e550d66cd4fd71f" -uuid = "7746bdde-850d-59dc-9ae8-88ece973131d" -version = "2.80.5+0" - -[[deps.Graphics]] -deps = ["Colors", "LinearAlgebra", "NaNMath"] -git-tree-sha1 = "a641238db938fff9b2f60d08ed9030387daf428c" -uuid = "a2bd30eb-e257-5431-a919-1863eab51364" -version = "1.1.3" - -[[deps.Graphite2_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl", "Pkg"] -git-tree-sha1 = "344bf40dcab1073aca04aa0df4fb092f920e4011" -uuid = "3b182d85-2403-5c21-9c21-1e1f0cc25472" -version = "1.3.14+0" - -[[deps.GridLayoutBase]] -deps = ["GeometryBasics", "InteractiveUtils", "Observables"] -git-tree-sha1 = "fc713f007cff99ff9e50accba6373624ddd33588" -uuid = "3955a311-db13-416c-9275-1d80ed98e5e9" -version = "0.11.0" - -[[deps.Grisu]] -git-tree-sha1 = "53bb909d1151e57e2484c3d1b53e19552b887fb2" -uuid = "42e2da0e-8278-4e71-bc24-59509adca0fe" -version = "1.0.2" - -[[deps.HTTP]] -deps = ["Base64", "CodecZlib", "ConcurrentUtilities", "Dates", "ExceptionUnwrapping", "Logging", "LoggingExtras", "MbedTLS", "NetworkOptions", "OpenSSL", "Random", "SimpleBufferStream", "Sockets", "URIs", "UUIDs"] -git-tree-sha1 = "1336e07ba2eb75614c99496501a8f4b233e9fafe" -uuid = "cd3eb016-35fb-5094-929b-558a96fad6f3" -version = "1.10.10" - -[[deps.HarfBuzz_jll]] -deps = ["Artifacts", "Cairo_jll", "Fontconfig_jll", "FreeType2_jll", "Glib_jll", "Graphite2_jll", "JLLWrappers", "Libdl", "Libffi_jll"] -git-tree-sha1 = "401e4f3f30f43af2c8478fc008da50096ea5240f" -uuid = "2e76f6c2-a576-52d4-95c1-20adfe4de566" -version = "8.3.1+0" - -[[deps.Hwloc_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "50aedf345a709ab75872f80a2779568dc0bb461b" -uuid = "e33a78d0-f292-5ffc-b300-72abe9b543c8" -version = "2.11.2+1" - -[[deps.HypergeometricFunctions]] -deps = ["LinearAlgebra", "OpenLibm_jll", "SpecialFunctions"] -git-tree-sha1 = "b1c2585431c382e3fe5805874bda6aea90a95de9" -uuid = "34004b35-14d8-5ef3-9330-4cdb6864b03a" -version = "0.3.25" - -[[deps.IOCapture]] -deps = ["Logging", "Random"] -git-tree-sha1 = "b6d6bfdd7ce25b0f9b2f6b3dd56b2673a66c8770" -uuid = "b5f81e59-6552-4d32-b1f0-c071b021bf89" -version = "0.2.5" - -[[deps.IfElse]] -git-tree-sha1 = "debdd00ffef04665ccbb3e150747a77560e8fad1" -uuid = "615f187c-cbe4-4ef1-ba3b-2fcf58d6d173" -version = "0.1.1" - -[[deps.ImageAxes]] -deps = ["AxisArrays", "ImageBase", "ImageCore", "Reexport", "SimpleTraits"] -git-tree-sha1 = "e12629406c6c4442539436581041d372d69c55ba" -uuid = "2803e5a7-5153-5ecf-9a86-9b4c37f5f5ac" -version = "0.6.12" - -[[deps.ImageBase]] -deps = ["ImageCore", "Reexport"] -git-tree-sha1 = "eb49b82c172811fd2c86759fa0553a2221feb909" -uuid = "c817782e-172a-44cc-b673-b171935fbb9e" -version = "0.1.7" - -[[deps.ImageCore]] -deps = ["Aqua", "BlockArrays", "ColorVectorSpace", "Colors", "FixedPointNumbers", "MappedArrays", "MosaicViews", "OffsetArrays", "PaddedViews", "PrecompileTools", "Reexport"] -git-tree-sha1 = "661ca04f8df633e8a021c55a22e96cf820220ede" -uuid = "a09fc81d-aa75-5fe9-8630-4744c3626534" -version = "0.10.4" - -[[deps.ImageIO]] -deps = ["FileIO", "IndirectArrays", "JpegTurbo", "LazyModules", "Netpbm", "OpenEXR", "PNGFiles", "QOI", "Sixel", "TiffImages", "UUIDs", "WebP"] -git-tree-sha1 = "696144904b76e1ca433b886b4e7edd067d76cbf7" -uuid = "82e4d734-157c-48bb-816b-45c225c6df19" -version = "0.6.9" - -[[deps.ImageMetadata]] -deps = ["AxisArrays", "ImageAxes", "ImageBase", "ImageCore"] -git-tree-sha1 = "2a81c3897be6fbcde0802a0ebe6796d0562f63ec" -uuid = "bc367c6b-8a6b-528e-b4bd-a4b897500b49" -version = "0.9.10" - -[[deps.Imath_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "0936ba688c6d201805a83da835b55c61a180db52" -uuid = "905a6f67-0a94-5f89-b386-d35d92009cd1" -version = "3.1.11+0" - -[[deps.IndirectArrays]] -git-tree-sha1 = "012e604e1c7458645cb8b436f8fba789a51b257f" -uuid = "9b13fd28-a010-5f03-acff-a1bbcff69959" -version = "1.0.0" - -[[deps.Inflate]] -git-tree-sha1 = "d1b1b796e47d94588b3757fe84fbf65a5ec4a80d" -uuid = "d25df0c9-e2be-5dd7-82c8-3ad0b3e990b9" -version = "0.1.5" - -[[deps.IntegerMathUtils]] -git-tree-sha1 = "b8ffb903da9f7b8cf695a8bead8e01814aa24b30" -uuid = "18e54dd8-cb9d-406c-a71d-865a43cbb235" -version = "0.1.2" - -[[deps.IntelOpenMP_jll]] -deps = ["Artifacts", "JLLWrappers", "LazyArtifacts", "Libdl"] -git-tree-sha1 = "10bd689145d2c3b2a9844005d01087cc1194e79e" -uuid = "1d5cc7b8-4909-519e-a0f8-d0f5ad9712d0" -version = "2024.2.1+0" - -[[deps.InteractiveUtils]] -deps = ["Markdown"] -uuid = "b77e0a4c-d291-57a0-90e8-8db25a27a240" -version = "1.11.0" - -[[deps.Interpolations]] -deps = ["Adapt", "AxisAlgorithms", "ChainRulesCore", "LinearAlgebra", "OffsetArrays", "Random", "Ratios", "Requires", "SharedArrays", "SparseArrays", "StaticArrays", "WoodburyMatrices"] -git-tree-sha1 = "88a101217d7cb38a7b481ccd50d21876e1d1b0e0" -uuid = "a98d9a8b-a2ab-59e6-89dd-64a1c18fca59" -version = "0.15.1" -weakdeps = ["Unitful"] - - [deps.Interpolations.extensions] - InterpolationsUnitfulExt = "Unitful" - -[[deps.IntervalArithmetic]] -deps = ["CRlibm_jll", "LinearAlgebra", "MacroTools", "RoundingEmulator"] -git-tree-sha1 = "24c095b1ec7ee58b936985d31d5df92f9b9cfebb" -uuid = "d1acc4aa-44c8-5952-acd4-ba5d80a2a253" -version = "0.22.19" -weakdeps = ["DiffRules", "ForwardDiff", "IntervalSets", "RecipesBase"] - - [deps.IntervalArithmetic.extensions] - IntervalArithmeticDiffRulesExt = "DiffRules" - IntervalArithmeticForwardDiffExt = "ForwardDiff" - IntervalArithmeticIntervalSetsExt = "IntervalSets" - IntervalArithmeticRecipesBaseExt = "RecipesBase" - -[[deps.IntervalSets]] -git-tree-sha1 = "dba9ddf07f77f60450fe5d2e2beb9854d9a49bd0" -uuid = "8197267c-284f-5f27-9208-e0e47529a953" -version = "0.7.10" -weakdeps = ["Random", "RecipesBase", "Statistics"] - - [deps.IntervalSets.extensions] - IntervalSetsRandomExt = "Random" - IntervalSetsRecipesBaseExt = "RecipesBase" - IntervalSetsStatisticsExt = "Statistics" - -[[deps.InverseFunctions]] -git-tree-sha1 = "a779299d77cd080bf77b97535acecd73e1c5e5cb" -uuid = "3587e190-3f89-42d0-90ee-14403ec27112" -version = "0.1.17" -weakdeps = ["Dates", "Test"] - - [deps.InverseFunctions.extensions] - InverseFunctionsDatesExt = "Dates" - InverseFunctionsTestExt = "Test" - -[[deps.Ipopt]] -deps = ["Ipopt_jll", "LinearAlgebra", "MathOptInterface", "OpenBLAS32_jll", "PrecompileTools"] -git-tree-sha1 = "76315a7100e9e901d959c25b6ab6d4a37e799132" -uuid = "b6b21f68-93f8-5de0-b562-5493be1d77c9" -version = "1.6.7" - -[[deps.Ipopt_jll]] -deps = ["ASL_jll", "Artifacts", "CompilerSupportLibraries_jll", "JLLWrappers", "Libdl", "MUMPS_seq_jll", "SPRAL_jll", "libblastrampoline_jll"] -git-tree-sha1 = "a0950d209a055b3adb6d29ade5cbdf005a6bd290" -uuid = "9cc047cb-c261-5740-88fc-0cf96f7bdcc7" -version = "300.1400.1600+0" - -[[deps.IrrationalConstants]] -git-tree-sha1 = "630b497eafcc20001bba38a4651b327dcfc491d2" -uuid = "92d709cd-6900-40b7-9082-c6be49f344b6" -version = "0.2.2" - -[[deps.Isoband]] -deps = ["isoband_jll"] -git-tree-sha1 = "f9b6d97355599074dc867318950adaa6f9946137" -uuid = "f1662d9f-8043-43de-a69a-05efc1cc6ff4" -version = "0.1.1" - -[[deps.IterTools]] -git-tree-sha1 = "42d5f897009e7ff2cf88db414a389e5ed1bdd023" -uuid = "c8e1da08-722c-5040-9ed9-7db0dc04731e" -version = "1.10.0" - -[[deps.IteratorInterfaceExtensions]] -git-tree-sha1 = "a3f24677c21f5bbe9d2a714f95dcd58337fb2856" -uuid = "82899510-4779-5014-852e-03e436cf321d" -version = "1.0.0" - -[[deps.JLD2]] -deps = ["FileIO", "MacroTools", "Mmap", "OrderedCollections", "PrecompileTools", "Requires", "TranscodingStreams"] -git-tree-sha1 = "ce5737c0d4490b0e0040b5dc77fbb6a351ddf188" -uuid = "033835bb-8acc-5ee8-8aae-3f567f8a3819" -version = "0.5.8" - -[[deps.JLLWrappers]] -deps = ["Artifacts", "Preferences"] -git-tree-sha1 = "be3dc50a92e5a386872a493a10050136d4703f9b" -uuid = "692b3bcd-3c85-4b1f-b108-f13ce0eb3210" -version = "1.6.1" - -[[deps.JSON]] -deps = ["Dates", "Mmap", "Parsers", "Unicode"] -git-tree-sha1 = "31e996f0a15c7b280ba9f76636b3ff9e2ae58c9a" -uuid = "682c06a0-de6a-54ab-a142-c8b1cf79cde6" -version = "0.21.4" - -[[deps.JpegTurbo]] -deps = ["CEnum", "FileIO", "ImageCore", "JpegTurbo_jll", "TOML"] -git-tree-sha1 = "fa6d0bcff8583bac20f1ffa708c3913ca605c611" -uuid = "b835a17e-a41a-41e7-81f0-2f016b05efe0" -version = "0.1.5" - -[[deps.JpegTurbo_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "25ee0be4d43d0269027024d75a24c24d6c6e590c" -uuid = "aacddb02-875f-59d6-b918-886e6ef4fbf8" -version = "3.0.4+0" - -[[deps.JuliaInterpreter]] -deps = ["CodeTracking", "InteractiveUtils", "Random", "UUIDs"] -git-tree-sha1 = "2984284a8abcfcc4784d95a9e2ea4e352dd8ede7" -uuid = "aa1ae85d-cabe-5617-a682-6adf51b2e16a" -version = "0.9.36" - -[[deps.KernelDensity]] -deps = ["Distributions", "DocStringExtensions", "FFTW", "Interpolations", "StatsBase"] -git-tree-sha1 = "7d703202e65efa1369de1279c162b915e245eed1" -uuid = "5ab0869b-81aa-558d-bb23-cbf5423bbe9b" -version = "0.6.9" - -[[deps.LAME_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "170b660facf5df5de098d866564877e119141cbd" -uuid = "c1c5ebd0-6772-5130-a774-d5fcae4a789d" -version = "3.100.2+0" - -[[deps.LERC_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "36bdbc52f13a7d1dcb0f3cd694e01677a515655b" -uuid = "88015f11-f218-50d7-93a8-a6af411a945d" -version = "4.0.0+0" - -[[deps.LLVMOpenMP_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "78211fb6cbc872f77cad3fc0b6cf647d923f4929" -uuid = "1d63c593-3942-5779-bab2-d838dc0a180e" -version = "18.1.7+0" - -[[deps.LZO_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "854a9c268c43b77b0a27f22d7fab8d33cdb3a731" -uuid = "dd4b983a-f0e5-5f8d-a1b7-129d4a5fb1ac" -version = "2.10.2+1" - -[[deps.LaTeXStrings]] -git-tree-sha1 = "dda21b8cbd6a6c40d9d02a73230f9d70fed6918c" -uuid = "b964fa9f-0449-5b57-a5c2-d3ea65f4040f" -version = "1.4.0" - -[[deps.Latexify]] -deps = ["Format", "InteractiveUtils", "LaTeXStrings", "MacroTools", "Markdown", "OrderedCollections", "Requires"] -git-tree-sha1 = "ce5f5621cac23a86011836badfedf664a612cee4" -uuid = "23fbe1c1-3f47-55db-b15f-69d7ec21a316" -version = "0.16.5" - - [deps.Latexify.extensions] - DataFramesExt = "DataFrames" - SparseArraysExt = "SparseArrays" - SymEngineExt = "SymEngine" - - [deps.Latexify.weakdeps] - DataFrames = "a93c6f00-e57d-5684-b7b6-d8193f3e46c0" - SparseArrays = "2f01184e-e22b-5df5-ae63-d93ebab69eaf" - SymEngine = "123dc426-2d89-5057-bbad-38513e3affd8" - -[[deps.LazilyInitializedFields]] -git-tree-sha1 = "0f2da712350b020bc3957f269c9caad516383ee0" -uuid = "0e77f7df-68c5-4e49-93ce-4cd80f5598bf" -version = "1.3.0" - -[[deps.LazyArtifacts]] -deps = ["Artifacts", "Pkg"] -uuid = "4af54fe1-eca0-43a8-85a7-787d91b784e3" -version = "1.11.0" - -[[deps.LazyModules]] -git-tree-sha1 = "a560dd966b386ac9ae60bdd3a3d3a326062d3c3e" -uuid = "8cdb02fc-e678-4876-92c5-9defec4f444e" -version = "0.3.1" - -[[deps.LibCURL]] -deps = ["LibCURL_jll", "MozillaCACerts_jll"] -uuid = "b27032c2-a3e7-50c8-80cd-2d36dbcbfd21" -version = "0.6.4" - -[[deps.LibCURL_jll]] -deps = ["Artifacts", "LibSSH2_jll", "Libdl", "MbedTLS_jll", "Zlib_jll", "nghttp2_jll"] -uuid = "deac9b47-8bc7-5906-a0fe-35ac56dc84c0" -version = "8.6.0+0" - -[[deps.LibGit2]] -deps = ["Base64", "LibGit2_jll", "NetworkOptions", "Printf", "SHA"] -uuid = "76f85450-5226-5b5a-8eaa-529ad045b433" -version = "1.11.0" - -[[deps.LibGit2_jll]] -deps = ["Artifacts", "LibSSH2_jll", "Libdl", "MbedTLS_jll"] -uuid = "e37daf67-58a4-590a-8e99-b0245dd2ffc5" -version = "1.7.2+0" - -[[deps.LibSSH2_jll]] -deps = ["Artifacts", "Libdl", "MbedTLS_jll"] -uuid = "29816b5a-b9ab-546f-933c-edad1886dfa8" -version = "1.11.0+1" - -[[deps.Libdl]] -uuid = "8f399da3-3557-5675-b5ff-fb832c97cbdb" -version = "1.11.0" - -[[deps.Libffi_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl", "Pkg"] -git-tree-sha1 = "0b4a5d71f3e5200a7dff793393e09dfc2d874290" -uuid = "e9f186c6-92d2-5b65-8a66-fee21dc1b490" -version = "3.2.2+1" - -[[deps.Libgcrypt_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl", "Libgpg_error_jll"] -git-tree-sha1 = "8be878062e0ffa2c3f67bb58a595375eda5de80b" -uuid = "d4300ac3-e22c-5743-9152-c294e39db1e4" -version = "1.11.0+0" - -[[deps.Libglvnd_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl", "Pkg", "Xorg_libX11_jll", "Xorg_libXext_jll"] -git-tree-sha1 = "6f73d1dd803986947b2c750138528a999a6c7733" -uuid = "7e76a0d4-f3c7-5321-8279-8d96eeed0f29" -version = "1.6.0+0" - -[[deps.Libgpg_error_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "c6ce1e19f3aec9b59186bdf06cdf3c4fc5f5f3e6" -uuid = "7add5ba3-2f88-524e-9cd5-f83b8a55f7b8" -version = "1.50.0+0" - -[[deps.Libiconv_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "61dfdba58e585066d8bce214c5a51eaa0539f269" -uuid = "94ce4f54-9a6c-5748-9c1c-f9c7231a4531" -version = "1.17.0+1" - -[[deps.Libmount_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "0c4f9c4f1a50d8f35048fa0532dabbadf702f81e" -uuid = "4b2f31a3-9ecc-558c-b454-b3730dcb73e9" -version = "2.40.1+0" - -[[deps.Libtiff_jll]] -deps = ["Artifacts", "JLLWrappers", "JpegTurbo_jll", "LERC_jll", "Libdl", "XZ_jll", "Zlib_jll", "Zstd_jll"] -git-tree-sha1 = "b404131d06f7886402758c9ce2214b636eb4d54a" -uuid = "89763e89-9b03-5906-acba-b20f662cd828" -version = "4.7.0+0" - -[[deps.Libuuid_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "5ee6203157c120d79034c748a2acba45b82b8807" -uuid = "38a345b3-de98-5d2b-a5d3-14cd9215e700" -version = "2.40.1+0" - -[[deps.LinearAlgebra]] -deps = ["Libdl", "OpenBLAS_jll", "libblastrampoline_jll"] -uuid = "37e2e46d-f89d-539d-b4ee-838fcccc9c8e" -version = "1.11.0" - -[[deps.Literate]] -deps = ["Base64", "IOCapture", "JSON", "REPL"] -git-tree-sha1 = "da046be6d63304f7ba9c1bb04820fb306ba1ab12" -uuid = "98b081ad-f1c9-55d3-8b20-4c87d4299306" -version = "2.20.1" - -[[deps.LiveServer]] -deps = ["HTTP", "LoggingExtras", "MIMEs", "Sockets", "Test"] -git-tree-sha1 = "564a436267fb1fc768f815dad64c4386c46623f8" -uuid = "16fef848-5104-11e9-1b77-fb7a48bbb589" -version = "1.4.0" - -[[deps.LogExpFunctions]] -deps = ["DocStringExtensions", "IrrationalConstants", "LinearAlgebra"] -git-tree-sha1 = "a2d09619db4e765091ee5c6ffe8872849de0feea" -uuid = "2ab3a3ac-af41-5b50-aa03-7779005ae688" -version = "0.3.28" - - [deps.LogExpFunctions.extensions] - LogExpFunctionsChainRulesCoreExt = "ChainRulesCore" - LogExpFunctionsChangesOfVariablesExt = "ChangesOfVariables" - LogExpFunctionsInverseFunctionsExt = "InverseFunctions" - - [deps.LogExpFunctions.weakdeps] - ChainRulesCore = "d360d2e6-b24c-11e9-a2a3-2a2ae2dbcce4" - ChangesOfVariables = "9e997f8a-9a97-42d5-a9f1-ce6bfc15e2c0" - InverseFunctions = "3587e190-3f89-42d0-90ee-14403ec27112" - -[[deps.Logging]] -uuid = "56ddb016-857b-54e1-b83d-db4d58db5568" -version = "1.11.0" - -[[deps.LoggingExtras]] -deps = ["Dates", "Logging"] -git-tree-sha1 = "f02b56007b064fbfddb4c9cd60161b6dd0f40df3" -uuid = "e6f89c97-d47a-5376-807f-9c37f3926c36" -version = "1.1.0" - -[[deps.LoweredCodeUtils]] -deps = ["JuliaInterpreter"] -git-tree-sha1 = "260dc274c1bc2cb839e758588c63d9c8b5e639d1" -uuid = "6f1432cf-f94c-5a45-995e-cdbf5db27b0b" -version = "3.0.5" - -[[deps.METIS_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl", "Pkg"] -git-tree-sha1 = "1fd0a97409e418b78c53fac671cf4622efdf0f21" -uuid = "d00139f3-1899-568f-a2f0-47f597d42d70" -version = "5.1.2+0" - -[[deps.MIMEs]] -git-tree-sha1 = "65f28ad4b594aebe22157d6fac869786a255b7eb" -uuid = "6c6e2e6c-3030-632d-7369-2d6c69616d65" -version = "0.1.4" - -[[deps.MKL_jll]] -deps = ["Artifacts", "IntelOpenMP_jll", "JLLWrappers", "LazyArtifacts", "Libdl", "oneTBB_jll"] -git-tree-sha1 = "f046ccd0c6db2832a9f639e2c669c6fe867e5f4f" -uuid = "856f044c-d86e-5d09-b602-aeab76dc8ba7" -version = "2024.2.0+0" - -[[deps.MLStyle]] -git-tree-sha1 = "bc38dff0548128765760c79eb7388a4b37fae2c8" -uuid = "d8e11817-5142-5d16-987a-aa16d5891078" -version = "0.4.17" - -[[deps.MUMPS_seq_jll]] -deps = ["Artifacts", "CompilerSupportLibraries_jll", "JLLWrappers", "Libdl", "METIS_jll", "libblastrampoline_jll"] -git-tree-sha1 = "85047ac569761e3387717480a38a61d2a67df45c" -uuid = "d7ed1dd3-d0ae-5e8e-bfb4-87a502085b8d" -version = "500.700.300+0" - -[[deps.MacroTools]] -deps = ["Markdown", "Random"] -git-tree-sha1 = "2fa9ee3e63fd3a4f7a9a4f4744a52f4856de82df" -uuid = "1914dd2f-81c6-5fcd-8719-6d5c9610ff09" -version = "0.5.13" - -[[deps.Makie]] -deps = ["Animations", "Base64", "CRC32c", "ColorBrewer", "ColorSchemes", "ColorTypes", "Colors", "Contour", "Dates", "DelaunayTriangulation", "Distributions", "DocStringExtensions", "Downloads", "FFMPEG_jll", "FileIO", "FilePaths", "FixedPointNumbers", "Format", "FreeType", "FreeTypeAbstraction", "GeometryBasics", "GridLayoutBase", "ImageBase", "ImageIO", "InteractiveUtils", "Interpolations", "IntervalSets", "InverseFunctions", "Isoband", "KernelDensity", "LaTeXStrings", "LinearAlgebra", "MacroTools", "MakieCore", "Markdown", "MathTeXEngine", "Observables", "OffsetArrays", "Packing", "PlotUtils", "PolygonOps", "PrecompileTools", "Printf", "REPL", "Random", "RelocatableFolders", "Scratch", "ShaderAbstractions", "Showoff", "SignedDistanceFields", "SparseArrays", "Statistics", "StatsBase", "StatsFuns", "StructArrays", "TriplotBase", "UnicodeFun", "Unitful"] -git-tree-sha1 = "5e4e0e027642293da251bf35dac408d692ccba8b" -uuid = "ee78f7c6-11fb-53f2-987a-cfe4a2b5a57a" -version = "0.21.16" - -[[deps.MakieCore]] -deps = ["ColorTypes", "GeometryBasics", "IntervalSets", "Observables"] -git-tree-sha1 = "ae4dbe0fcf1594ed98594e5f4ee685295a2a6f74" -uuid = "20f20a25-4f0e-4fdf-b5d1-57303727442b" -version = "0.8.10" - -[[deps.MappedArrays]] -git-tree-sha1 = "2dab0221fe2b0f2cb6754eaa743cc266339f527e" -uuid = "dbb5928d-eab1-5f90-85c2-b9b0edb7c900" -version = "0.4.2" - -[[deps.Markdown]] -deps = ["Base64"] -uuid = "d6f4376e-aef5-505a-96c1-9c027394607a" -version = "1.11.0" - -[[deps.MarkdownAST]] -deps = ["AbstractTrees", "Markdown"] -git-tree-sha1 = "465a70f0fc7d443a00dcdc3267a497397b8a3899" -uuid = "d0879d2d-cac2-40c8-9cee-1863dc0c7391" -version = "0.1.2" - -[[deps.MathOptInterface]] -deps = ["BenchmarkTools", "CodecBzip2", "CodecZlib", "DataStructures", "ForwardDiff", "JSON", "LinearAlgebra", "MutableArithmetics", "NaNMath", "OrderedCollections", "PrecompileTools", "Printf", "SparseArrays", "SpecialFunctions", "Test", "Unicode"] -git-tree-sha1 = "e065ca5234f53fd6f920efaee4940627ad991fb4" -uuid = "b8f27783-ece8-5eb3-8dc8-9495eed66fee" -version = "1.34.0" - -[[deps.MathTeXEngine]] -deps = ["AbstractTrees", "Automa", "DataStructures", "FreeTypeAbstraction", "GeometryBasics", "LaTeXStrings", "REPL", "RelocatableFolders", "UnicodeFun"] -git-tree-sha1 = "f45c8916e8385976e1ccd055c9874560c257ab13" -uuid = "0a4f8689-d25c-4efe-a92b-7142dfc1aa53" -version = "0.6.2" - -[[deps.MbedTLS]] -deps = ["Dates", "MbedTLS_jll", "MozillaCACerts_jll", "NetworkOptions", "Random", "Sockets"] -git-tree-sha1 = "c067a280ddc25f196b5e7df3877c6b226d390aaf" -uuid = "739be429-bea8-5141-9913-cc70e7f3736d" -version = "1.1.9" - -[[deps.MbedTLS_jll]] -deps = ["Artifacts", "Libdl"] -uuid = "c8ffd9c3-330d-5841-b78e-0817d7145fa1" -version = "2.28.6+0" - -[[deps.Missings]] -deps = ["DataAPI"] -git-tree-sha1 = "ec4f7fbeab05d7747bdf98eb74d130a2a2ed298d" -uuid = "e1d29d7a-bbdc-5cf2-9ac0-f12de2c33e28" -version = "1.2.0" - -[[deps.Mmap]] -uuid = "a63ad114-7e13-5084-954f-fe012c677804" -version = "1.11.0" - -[[deps.MosaicViews]] -deps = ["MappedArrays", "OffsetArrays", "PaddedViews", "StackViews"] -git-tree-sha1 = "7b86a5d4d70a9f5cdf2dacb3cbe6d251d1a61dbe" -uuid = "e94cdb99-869f-56ef-bcf0-1ae2bcbe0389" -version = "0.3.4" - -[[deps.MozillaCACerts_jll]] -uuid = "14a3606d-f60d-562e-9121-12d972cd8159" -version = "2023.12.12" - -[[deps.MultivariatePolynomials]] -deps = ["ChainRulesCore", "DataStructures", "LinearAlgebra", "MutableArithmetics"] -git-tree-sha1 = "8d39779e29f80aa6c071e7ac17101c6e31f075d7" -uuid = "102ac46a-7ee4-5c85-9060-abc95bfdeaa3" -version = "0.5.7" - -[[deps.MutableArithmetics]] -deps = ["LinearAlgebra", "SparseArrays", "Test"] -git-tree-sha1 = "90077f1e79de8c9c7c8a90644494411111f4e07b" -uuid = "d8a4904e-b15c-11e9-3269-09a3773c0cb0" -version = "1.5.2" - -[[deps.NaNMath]] -deps = ["OpenLibm_jll"] -git-tree-sha1 = "0877504529a3e5c3343c6f8b4c0381e57e4387e4" -uuid = "77ba4419-2d1f-58cd-9bb1-8ffee604a2e3" -version = "1.0.2" - -[[deps.NamedTrajectories]] -deps = ["CairoMakie", "JLD2", "LaTeXStrings", "Latexify", "OrderedCollections", "Random", "Reexport", "Unidecode"] -git-tree-sha1 = "8b72d6806501fd61684dcc6e9c336855acd5abe1" -uuid = "538bc3a1-5ab9-4fc3-b776-35ca1e893e08" -version = "0.2.2" - -[[deps.Netpbm]] -deps = ["FileIO", "ImageCore", "ImageMetadata"] -git-tree-sha1 = "d92b107dbb887293622df7697a2223f9f8176fcd" -uuid = "f09324ee-3d7c-5217-9330-fc30815ba969" -version = "1.1.1" - -[[deps.NetworkOptions]] -uuid = "ca575930-c2e3-43a9-ace4-1e988b2c1908" -version = "1.2.0" - -[[deps.Observables]] -git-tree-sha1 = "7438a59546cf62428fc9d1bc94729146d37a7225" -uuid = "510215fc-4207-5dde-b226-833fc4488ee2" -version = "0.5.5" - -[[deps.OffsetArrays]] -git-tree-sha1 = "1a27764e945a152f7ca7efa04de513d473e9542e" -uuid = "6fe1bfb0-de20-5000-8ca7-80f57d26f881" -version = "1.14.1" -weakdeps = ["Adapt"] - - [deps.OffsetArrays.extensions] - OffsetArraysAdaptExt = "Adapt" - -[[deps.Ogg_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl", "Pkg"] -git-tree-sha1 = "887579a3eb005446d514ab7aeac5d1d027658b8f" -uuid = "e7412a2a-1a6e-54c0-be00-318e2571c051" -version = "1.3.5+1" - -[[deps.OpenBLAS32_jll]] -deps = ["Artifacts", "CompilerSupportLibraries_jll", "JLLWrappers", "Libdl"] -git-tree-sha1 = "dd806c813429ff09878ea3eeb317818f3ca02871" -uuid = "656ef2d0-ae68-5445-9ca0-591084a874a2" -version = "0.3.28+3" - -[[deps.OpenBLAS_jll]] -deps = ["Artifacts", "CompilerSupportLibraries_jll", "Libdl"] -uuid = "4536629a-c528-5b80-bd46-f80d51c5b363" -version = "0.3.27+1" - -[[deps.OpenEXR]] -deps = ["Colors", "FileIO", "OpenEXR_jll"] -git-tree-sha1 = "97db9e07fe2091882c765380ef58ec553074e9c7" -uuid = "52e1d378-f018-4a11-a4be-720524705ac7" -version = "0.3.3" - -[[deps.OpenEXR_jll]] -deps = ["Artifacts", "Imath_jll", "JLLWrappers", "Libdl", "Zlib_jll"] -git-tree-sha1 = "8292dd5c8a38257111ada2174000a33745b06d4e" -uuid = "18a262bb-aa17-5467-a713-aee519bc75cb" -version = "3.2.4+0" - -[[deps.OpenLibm_jll]] -deps = ["Artifacts", "Libdl"] -uuid = "05823500-19ac-5b8b-9628-191a04bc5112" -version = "0.8.1+2" - -[[deps.OpenSSL]] -deps = ["BitFlags", "Dates", "MozillaCACerts_jll", "OpenSSL_jll", "Sockets"] -git-tree-sha1 = "38cb508d080d21dc1128f7fb04f20387ed4c0af4" -uuid = "4d8831e6-92b7-49fb-bdf8-b643e874388c" -version = "1.4.3" - -[[deps.OpenSSL_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "7493f61f55a6cce7325f197443aa80d32554ba10" -uuid = "458c3c95-2e84-50aa-8efc-19380b2a3a95" -version = "3.0.15+1" - -[[deps.OpenSpecFun_jll]] -deps = ["Artifacts", "CompilerSupportLibraries_jll", "JLLWrappers", "Libdl", "Pkg"] -git-tree-sha1 = "13652491f6856acfd2db29360e1bbcd4565d04f1" -uuid = "efe28fd5-8261-553b-a9e1-b2916fc3738e" -version = "0.5.5+0" - -[[deps.Opus_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "6703a85cb3781bd5909d48730a67205f3f31a575" -uuid = "91d4177d-7536-5919-b921-800302f37372" -version = "1.3.3+0" - -[[deps.OrderedCollections]] -git-tree-sha1 = "dfdf5519f235516220579f949664f1bf44e741c5" -uuid = "bac558e1-5e72-5ebc-8fee-abe8a469f55d" -version = "1.6.3" - -[[deps.PCRE2_jll]] -deps = ["Artifacts", "Libdl"] -uuid = "efcefdf7-47ab-520b-bdef-62a2eaa19f15" -version = "10.42.0+1" - -[[deps.PDMats]] -deps = ["LinearAlgebra", "SparseArrays", "SuiteSparse"] -git-tree-sha1 = "949347156c25054de2db3b166c52ac4728cbad65" -uuid = "90014a1f-27ba-587c-ab20-58faa44d9150" -version = "0.11.31" - -[[deps.PNGFiles]] -deps = ["Base64", "CEnum", "ImageCore", "IndirectArrays", "OffsetArrays", "libpng_jll"] -git-tree-sha1 = "67186a2bc9a90f9f85ff3cc8277868961fb57cbd" -uuid = "f57f5aa1-a3ce-4bc8-8ab9-96f992907883" -version = "0.4.3" - -[[deps.Packing]] -deps = ["GeometryBasics"] -git-tree-sha1 = "ec3edfe723df33528e085e632414499f26650501" -uuid = "19eb6ba3-879d-56ad-ad62-d5c202156566" -version = "0.5.0" - -[[deps.PaddedViews]] -deps = ["OffsetArrays"] -git-tree-sha1 = "0fac6313486baae819364c52b4f483450a9d793f" -uuid = "5432bcbf-9aad-5242-b902-cca2824c8663" -version = "0.5.12" - -[[deps.Pango_jll]] -deps = ["Artifacts", "Cairo_jll", "Fontconfig_jll", "FreeType2_jll", "FriBidi_jll", "Glib_jll", "HarfBuzz_jll", "JLLWrappers", "Libdl"] -git-tree-sha1 = "e127b609fb9ecba6f201ba7ab753d5a605d53801" -uuid = "36c8627f-9965-5494-a995-c6b170f724f3" -version = "1.54.1+0" - -[[deps.Parsers]] -deps = ["Dates", "PrecompileTools", "UUIDs"] -git-tree-sha1 = "8489905bcdbcfac64d1daa51ca07c0d8f0283821" -uuid = "69de0a69-1ddd-5017-9359-2bf0b02dc9f0" -version = "2.8.1" - -[[deps.Pixman_jll]] -deps = ["Artifacts", "CompilerSupportLibraries_jll", "JLLWrappers", "LLVMOpenMP_jll", "Libdl"] -git-tree-sha1 = "35621f10a7531bc8fa58f74610b1bfb70a3cfc6b" -uuid = "30392449-352a-5448-841d-b1acce4e97dc" -version = "0.43.4+0" - -[[deps.Pkg]] -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.11.0" -weakdeps = ["REPL"] - - [deps.Pkg.extensions] - REPLExt = "REPL" - -[[deps.PkgVersion]] -deps = ["Pkg"] -git-tree-sha1 = "f9501cc0430a26bc3d156ae1b5b0c1b47af4d6da" -uuid = "eebad327-c553-4316-9ea0-9fa01ccd7688" -version = "0.3.3" - -[[deps.PlotUtils]] -deps = ["ColorSchemes", "Colors", "Dates", "PrecompileTools", "Printf", "Random", "Reexport", "StableRNGs", "Statistics"] -git-tree-sha1 = "3ca9a356cd2e113c420f2c13bea19f8d3fb1cb18" -uuid = "995b91a9-d308-5afd-9ec6-746e21dbc043" -version = "1.4.3" - -[[deps.PolygonOps]] -git-tree-sha1 = "77b3d3605fc1cd0b42d95eba87dfcd2bf67d5ff6" -uuid = "647866c9-e3ac-4575-94e7-e3d426903924" -version = "0.1.2" - -[[deps.PrecompileTools]] -deps = ["Preferences"] -git-tree-sha1 = "5aa36f7049a63a1528fe8f7c3f2113413ffd4e1f" -uuid = "aea7be01-6a6a-4083-8856-8a6e6704d82a" -version = "1.2.1" - -[[deps.Preferences]] -deps = ["TOML"] -git-tree-sha1 = "9306f6085165d270f7e3db02af26a400d580f5c6" -uuid = "21216c6a-2e73-6563-6e65-726566657250" -version = "1.4.3" - -[[deps.Primes]] -deps = ["IntegerMathUtils"] -git-tree-sha1 = "cb420f77dc474d23ee47ca8d14c90810cafe69e7" -uuid = "27ebfcd6-29c5-5fa9-bf4b-fb8fc14df3ae" -version = "0.5.6" - -[[deps.Printf]] -deps = ["Unicode"] -uuid = "de0858da-6303-5e67-8744-51eddeeeb8d7" -version = "1.11.0" - -[[deps.Profile]] -uuid = "9abbd945-dff8-562f-b5e8-e1ebf5ef1b79" -version = "1.11.0" - -[[deps.ProgressMeter]] -deps = ["Distributed", "Printf"] -git-tree-sha1 = "8f6bc219586aef8baf0ff9a5fe16ee9c70cb65e4" -uuid = "92933f4c-e287-5a05-a399-4b506db050ca" -version = "1.10.2" - -[[deps.PtrArrays]] -git-tree-sha1 = "77a42d78b6a92df47ab37e177b2deac405e1c88f" -uuid = "43287f4e-b6f4-7ad1-bb20-aadabca52c3d" -version = "1.2.1" - -[[deps.QOI]] -deps = ["ColorTypes", "FileIO", "FixedPointNumbers"] -git-tree-sha1 = "8b3fc30bc0390abdce15f8822c889f669baed73d" -uuid = "4b34888f-f399-49d4-9bb3-47ed5cae4e65" -version = "1.0.1" - -[[deps.QuadGK]] -deps = ["DataStructures", "LinearAlgebra"] -git-tree-sha1 = "cda3b045cf9ef07a08ad46731f5a3165e56cf3da" -uuid = "1fd47b50-473d-5c70-9696-f719f8f3bcdc" -version = "2.11.1" - - [deps.QuadGK.extensions] - QuadGKEnzymeExt = "Enzyme" - - [deps.QuadGK.weakdeps] - Enzyme = "7da242da-08ed-463a-9acd-ee780be4f1d9" - -[[deps.QuantumCollocation]] -deps = ["BenchmarkTools", "CairoMakie", "Distributions", "Einsum", "ExponentialAction", "ForwardDiff", "Interpolations", "Ipopt", "JLD2", "Libdl", "LinearAlgebra", "MathOptInterface", "NamedTrajectories", "ProgressMeter", "Random", "Reexport", "SparseArrays", "Symbolics", "TestItemRunner", "TestItems", "TrajectoryIndexingUtils"] -path = ".." -uuid = "0dc23a59-5ffb-49af-b6bd-932a8ae77adf" -version = "0.3.2" - -[[deps.REPL]] -deps = ["InteractiveUtils", "Markdown", "Sockets", "StyledStrings", "Unicode"] -uuid = "3fa0cd96-eef1-5676-8a61-b3b8758bbffb" -version = "1.11.0" - -[[deps.Random]] -deps = ["SHA"] -uuid = "9a3f8284-a2c9-5f02-9a11-845980a1fd5c" -version = "1.11.0" - -[[deps.RangeArrays]] -git-tree-sha1 = "b9039e93773ddcfc828f12aadf7115b4b4d225f5" -uuid = "b3c3ace0-ae52-54e7-9d0b-2c1406fd6b9d" -version = "0.3.2" - -[[deps.Ratios]] -deps = ["Requires"] -git-tree-sha1 = "1342a47bf3260ee108163042310d26f2be5ec90b" -uuid = "c84ed2f1-dad5-54f0-aa8e-dbefe2724439" -version = "0.4.5" -weakdeps = ["FixedPointNumbers"] - - [deps.Ratios.extensions] - RatiosFixedPointNumbersExt = "FixedPointNumbers" - -[[deps.RecipesBase]] -deps = ["PrecompileTools"] -git-tree-sha1 = "5c3d09cc4f31f5fc6af001c250bf1278733100ff" -uuid = "3cdcf5f2-1ef4-517c-9805-6587b60abb01" -version = "1.3.4" - -[[deps.RecursiveArrayTools]] -deps = ["Adapt", "ArrayInterface", "DocStringExtensions", "GPUArraysCore", "IteratorInterfaceExtensions", "LinearAlgebra", "RecipesBase", "StaticArraysCore", "Statistics", "SymbolicIndexingInterface", "Tables"] -git-tree-sha1 = "6f4dca5fd8e97087a76b7ab8384d1c3086ace0b7" -uuid = "731186ca-8d62-57ce-b412-fbd966d074cd" -version = "3.27.3" - - [deps.RecursiveArrayTools.extensions] - RecursiveArrayToolsFastBroadcastExt = "FastBroadcast" - RecursiveArrayToolsForwardDiffExt = "ForwardDiff" - RecursiveArrayToolsMeasurementsExt = "Measurements" - RecursiveArrayToolsMonteCarloMeasurementsExt = "MonteCarloMeasurements" - RecursiveArrayToolsReverseDiffExt = ["ReverseDiff", "Zygote"] - RecursiveArrayToolsSparseArraysExt = ["SparseArrays"] - RecursiveArrayToolsTrackerExt = "Tracker" - RecursiveArrayToolsZygoteExt = "Zygote" - - [deps.RecursiveArrayTools.weakdeps] - FastBroadcast = "7034ab61-46d4-4ed7-9d0f-46aef9175898" - ForwardDiff = "f6369f11-7733-5829-9624-2563aa707210" - Measurements = "eff96d63-e80a-5855-80a2-b1b0885c5ab7" - MonteCarloMeasurements = "0987c9cc-fe09-11e8-30f0-b96dd679fdca" - ReverseDiff = "37e2e3b7-166d-5795-8a7a-e32c996b4267" - SparseArrays = "2f01184e-e22b-5df5-ae63-d93ebab69eaf" - Tracker = "9f7883ad-71c0-57eb-9f7f-b5c9e6d3789c" - Zygote = "e88e6eb3-aa80-5325-afca-941959d7151f" - -[[deps.Reexport]] -git-tree-sha1 = "45e428421666073eab6f2da5c9d310d99bb12f9b" -uuid = "189a3867-3050-52da-a836-e630ba90ab69" -version = "1.2.2" - -[[deps.RegistryInstances]] -deps = ["LazilyInitializedFields", "Pkg", "TOML", "Tar"] -git-tree-sha1 = "ffd19052caf598b8653b99404058fce14828be51" -uuid = "2792f1a3-b283-48e8-9a74-f99dce5104f3" -version = "0.1.0" - -[[deps.RelocatableFolders]] -deps = ["SHA", "Scratch"] -git-tree-sha1 = "ffdaf70d81cf6ff22c2b6e733c900c3321cab864" -uuid = "05181044-ff0b-4ac5-8273-598c1e38db00" -version = "1.0.1" - -[[deps.Requires]] -deps = ["UUIDs"] -git-tree-sha1 = "838a3a4188e2ded87a4f9f184b4b0d78a1e91cb7" -uuid = "ae029012-a4dd-5104-9daa-d747884805df" -version = "1.3.0" - -[[deps.Revise]] -deps = ["CodeTracking", "Distributed", "FileWatching", "JuliaInterpreter", "LibGit2", "LoweredCodeUtils", "OrderedCollections", "REPL", "Requires", "UUIDs", "Unicode"] -git-tree-sha1 = "7f4228017b83c66bd6aa4fddeb170ce487e53bc7" -uuid = "295af30f-e4ad-537b-8983-00126c2a3abe" -version = "3.6.2" - -[[deps.Rmath]] -deps = ["Random", "Rmath_jll"] -git-tree-sha1 = "852bd0f55565a9e973fcfee83a84413270224dc4" -uuid = "79098fc4-a85e-5d69-aa6a-4863f24498fa" -version = "0.8.0" - -[[deps.Rmath_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "58cdd8fb2201a6267e1db87ff148dd6c1dbd8ad8" -uuid = "f50d1b31-88e8-58de-be2c-1cc44531875f" -version = "0.5.1+0" - -[[deps.RoundingEmulator]] -git-tree-sha1 = "40b9edad2e5287e05bd413a38f61a8ff55b9557b" -uuid = "5eaf0fd0-dfba-4ccb-bf02-d820a40db705" -version = "0.2.1" - -[[deps.RuntimeGeneratedFunctions]] -deps = ["ExprTools", "SHA", "Serialization"] -git-tree-sha1 = "04c968137612c4a5629fa531334bb81ad5680f00" -uuid = "7e49a35a-f44a-4d26-94aa-eba1b4ca6b47" -version = "0.5.13" - -[[deps.SHA]] -uuid = "ea8e919c-243c-51af-8825-aaa63cd721ce" -version = "0.7.0" - -[[deps.SIMD]] -deps = ["PrecompileTools"] -git-tree-sha1 = "52af86e35dd1b177d051b12681e1c581f53c281b" -uuid = "fdea26ae-647d-5447-a871-4b548cad5224" -version = "3.7.0" - -[[deps.SPRAL_jll]] -deps = ["Artifacts", "CompilerSupportLibraries_jll", "Hwloc_jll", "JLLWrappers", "Libdl", "METIS_jll", "libblastrampoline_jll"] -git-tree-sha1 = "11f3da4b25efacd1cec8e263421f2a9003a5e8e0" -uuid = "319450e9-13b8-58e8-aa9f-8fd1420848ab" -version = "2024.5.8+0" - -[[deps.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 = "7527b9adb22904f0f51d8ab85d826f81ebb6f78d" -uuid = "0bca4576-84f4-4d90-8ffe-ffa030f20462" -version = "2.59.2" - - [deps.SciMLBase.extensions] - SciMLBaseChainRulesCoreExt = "ChainRulesCore" - SciMLBaseMakieExt = "Makie" - SciMLBasePartialFunctionsExt = "PartialFunctions" - SciMLBasePyCallExt = "PyCall" - SciMLBasePythonCallExt = "PythonCall" - SciMLBaseRCallExt = "RCall" - SciMLBaseZygoteExt = "Zygote" - - [deps.SciMLBase.weakdeps] - ChainRules = "082447d4-558c-5d27-93f4-14fc19e9eca2" - ChainRulesCore = "d360d2e6-b24c-11e9-a2a3-2a2ae2dbcce4" - Makie = "ee78f7c6-11fb-53f2-987a-cfe4a2b5a57a" - PartialFunctions = "570af359-4316-4cb7-8c74-252c00c2016b" - PyCall = "438e738f-606a-5dbb-bf0a-cddfbfd45ab0" - PythonCall = "6099a3de-0909-46bc-b1f4-468b9a2dfc0d" - RCall = "6f49c342-dc21-5d91-9882-a32aef131414" - Zygote = "e88e6eb3-aa80-5325-afca-941959d7151f" - -[[deps.SciMLOperators]] -deps = ["Accessors", "ArrayInterface", "DocStringExtensions", "LinearAlgebra", "MacroTools"] -git-tree-sha1 = "6149620767866d4b0f0f7028639b6e661b6a1e44" -uuid = "c0aeaf25-5076-4817-a8d5-81caf7dfa961" -version = "0.3.12" -weakdeps = ["SparseArrays", "StaticArraysCore"] - - [deps.SciMLOperators.extensions] - SciMLOperatorsSparseArraysExt = "SparseArrays" - SciMLOperatorsStaticArraysCoreExt = "StaticArraysCore" - -[[deps.SciMLStructures]] -deps = ["ArrayInterface"] -git-tree-sha1 = "25514a6f200219cd1073e4ff23a6324e4a7efe64" -uuid = "53ae85a6-f571-4167-b2af-e1d143709226" -version = "1.5.0" - -[[deps.Scratch]] -deps = ["Dates"] -git-tree-sha1 = "3bac05bc7e74a75fd9cba4295cde4045d9fe2386" -uuid = "6c6a2e73-6563-6170-7368-637461726353" -version = "1.2.1" - -[[deps.Serialization]] -uuid = "9e88b42a-f829-5b0c-bbe9-9e923198166b" -version = "1.11.0" - -[[deps.Setfield]] -deps = ["ConstructionBase", "Future", "MacroTools", "StaticArraysCore"] -git-tree-sha1 = "e2cc6d8c88613c05e1defb55170bf5ff211fbeac" -uuid = "efcf1570-3423-57d1-acb7-fd33fddbac46" -version = "1.1.1" - -[[deps.ShaderAbstractions]] -deps = ["ColorTypes", "FixedPointNumbers", "GeometryBasics", "LinearAlgebra", "Observables", "StaticArrays", "StructArrays", "Tables"] -git-tree-sha1 = "79123bc60c5507f035e6d1d9e563bb2971954ec8" -uuid = "65257c39-d410-5151-9873-9b3e5be5013e" -version = "0.4.1" - -[[deps.SharedArrays]] -deps = ["Distributed", "Mmap", "Random", "Serialization"] -uuid = "1a1011a3-84de-559e-8e89-a11a2f7dc383" -version = "1.11.0" - -[[deps.Showoff]] -deps = ["Dates", "Grisu"] -git-tree-sha1 = "91eddf657aca81df9ae6ceb20b959ae5653ad1de" -uuid = "992d4aef-0814-514b-bc4d-f2e9a6c4116f" -version = "1.0.3" - -[[deps.SignedDistanceFields]] -deps = ["Random", "Statistics", "Test"] -git-tree-sha1 = "d263a08ec505853a5ff1c1ebde2070419e3f28e9" -uuid = "73760f76-fbc4-59ce-8f25-708e95d2df96" -version = "0.4.0" - -[[deps.SimpleBufferStream]] -git-tree-sha1 = "f305871d2f381d21527c770d4788c06c097c9bc1" -uuid = "777ac1f9-54b0-4bf8-805c-2214025038e7" -version = "1.2.0" - -[[deps.SimpleTraits]] -deps = ["InteractiveUtils", "MacroTools"] -git-tree-sha1 = "5d7e3f4e11935503d3ecaf7186eac40602e7d231" -uuid = "699a6c99-e7fa-54fc-8d76-47d257e15c1d" -version = "0.9.4" - -[[deps.Sixel]] -deps = ["Dates", "FileIO", "ImageCore", "IndirectArrays", "OffsetArrays", "REPL", "libsixel_jll"] -git-tree-sha1 = "2da10356e31327c7096832eb9cd86307a50b1eb6" -uuid = "45858cf5-a6b0-47a3-bbea-62219f50df47" -version = "0.1.3" - -[[deps.Sockets]] -uuid = "6462fe0b-24de-5631-8697-dd941f90decc" -version = "1.11.0" - -[[deps.SortingAlgorithms]] -deps = ["DataStructures"] -git-tree-sha1 = "66e0a8e672a0bdfca2c3f5937efb8538b9ddc085" -uuid = "a2af1166-a08f-5f64-846c-94a0d3cef48c" -version = "1.2.1" - -[[deps.SparseArrays]] -deps = ["Libdl", "LinearAlgebra", "Random", "Serialization", "SuiteSparse_jll"] -uuid = "2f01184e-e22b-5df5-ae63-d93ebab69eaf" -version = "1.11.0" - -[[deps.SpecialFunctions]] -deps = ["IrrationalConstants", "LogExpFunctions", "OpenLibm_jll", "OpenSpecFun_jll"] -git-tree-sha1 = "2f5d4697f21388cbe1ff299430dd169ef97d7e14" -uuid = "276daf66-3868-5448-9aa4-cd146d93841b" -version = "2.4.0" -weakdeps = ["ChainRulesCore"] - - [deps.SpecialFunctions.extensions] - SpecialFunctionsChainRulesCoreExt = "ChainRulesCore" - -[[deps.StableRNGs]] -deps = ["Random"] -git-tree-sha1 = "83e6cce8324d49dfaf9ef059227f91ed4441a8e5" -uuid = "860ef19b-820b-49d6-a774-d7a799459cd3" -version = "1.0.2" - -[[deps.StackViews]] -deps = ["OffsetArrays"] -git-tree-sha1 = "46e589465204cd0c08b4bd97385e4fa79a0c770c" -uuid = "cae243ae-269e-4f55-b966-ac2d0dc13c15" -version = "0.1.1" - -[[deps.StaticArrays]] -deps = ["LinearAlgebra", "PrecompileTools", "Random", "StaticArraysCore"] -git-tree-sha1 = "777657803913ffc7e8cc20f0fd04b634f871af8f" -uuid = "90137ffa-7385-5640-81b9-e52037218182" -version = "1.9.8" -weakdeps = ["ChainRulesCore", "Statistics"] - - [deps.StaticArrays.extensions] - StaticArraysChainRulesCoreExt = "ChainRulesCore" - StaticArraysStatisticsExt = "Statistics" - -[[deps.StaticArraysCore]] -git-tree-sha1 = "192954ef1208c7019899fbf8049e717f92959682" -uuid = "1e83bf80-4336-4d27-bf5d-d5a4f845583c" -version = "1.4.3" - -[[deps.Statistics]] -deps = ["LinearAlgebra"] -git-tree-sha1 = "ae3bb1eb3bba077cd276bc5cfc337cc65c3075c0" -uuid = "10745b16-79ce-11e8-11f9-7d13ad32a3b2" -version = "1.11.1" -weakdeps = ["SparseArrays"] - - [deps.Statistics.extensions] - SparseArraysExt = ["SparseArrays"] - -[[deps.StatsAPI]] -deps = ["LinearAlgebra"] -git-tree-sha1 = "1ff449ad350c9c4cbc756624d6f8a8c3ef56d3ed" -uuid = "82ae8749-77ed-4fe6-ae5f-f523153014b0" -version = "1.7.0" - -[[deps.StatsBase]] -deps = ["DataAPI", "DataStructures", "LinearAlgebra", "LogExpFunctions", "Missings", "Printf", "Random", "SortingAlgorithms", "SparseArrays", "Statistics", "StatsAPI"] -git-tree-sha1 = "5cf7606d6cef84b543b483848d4ae08ad9832b21" -uuid = "2913bbd2-ae8a-5f71-8c99-4fb6c76f3a91" -version = "0.34.3" - -[[deps.StatsFuns]] -deps = ["HypergeometricFunctions", "IrrationalConstants", "LogExpFunctions", "Reexport", "Rmath", "SpecialFunctions"] -git-tree-sha1 = "b423576adc27097764a90e163157bcfc9acf0f46" -uuid = "4c63d2b9-4356-54db-8cca-17b64c39e42c" -version = "1.3.2" -weakdeps = ["ChainRulesCore", "InverseFunctions"] - - [deps.StatsFuns.extensions] - StatsFunsChainRulesCoreExt = "ChainRulesCore" - StatsFunsInverseFunctionsExt = "InverseFunctions" - -[[deps.StructArrays]] -deps = ["ConstructionBase", "DataAPI", "Tables"] -git-tree-sha1 = "f4dc295e983502292c4c3f951dbb4e985e35b3be" -uuid = "09ab397b-f2b6-538f-b94a-2f83cf4a842a" -version = "0.6.18" -weakdeps = ["Adapt", "GPUArraysCore", "SparseArrays", "StaticArrays"] - - [deps.StructArrays.extensions] - StructArraysAdaptExt = "Adapt" - StructArraysGPUArraysCoreExt = "GPUArraysCore" - StructArraysSparseArraysExt = "SparseArrays" - StructArraysStaticArraysExt = "StaticArrays" - -[[deps.StyledStrings]] -uuid = "f489334b-da3d-4c2e-b8f0-e476e12c162b" -version = "1.11.0" - -[[deps.SuiteSparse]] -deps = ["Libdl", "LinearAlgebra", "Serialization", "SparseArrays"] -uuid = "4607b0f0-06f3-5cda-b6b1-a6196a1729e9" - -[[deps.SuiteSparse_jll]] -deps = ["Artifacts", "Libdl", "libblastrampoline_jll"] -uuid = "bea87d4a-7f5b-5778-9afe-8cc45184846c" -version = "7.7.0+0" - -[[deps.SymbolicIndexingInterface]] -deps = ["Accessors", "ArrayInterface", "RuntimeGeneratedFunctions", "StaticArraysCore"] -git-tree-sha1 = "20cf607cafb31f922bce84d60379203e7a126911" -uuid = "2efcf032-c050-4f8e-a9bb-153293bab1f5" -version = "0.3.34" - -[[deps.SymbolicLimits]] -deps = ["SymbolicUtils"] -git-tree-sha1 = "fabf4650afe966a2ba646cabd924c3fd43577fc3" -uuid = "19f23fe9-fdab-4a78-91af-e7b7767979c3" -version = "0.2.2" - -[[deps.SymbolicUtils]] -deps = ["AbstractTrees", "ArrayInterface", "Bijections", "ChainRulesCore", "Combinatorics", "ConstructionBase", "DataStructures", "DocStringExtensions", "DynamicPolynomials", "IfElse", "LinearAlgebra", "MultivariatePolynomials", "NaNMath", "Setfield", "SparseArrays", "SpecialFunctions", "StaticArrays", "SymbolicIndexingInterface", "TermInterface", "TimerOutputs", "Unityper"] -git-tree-sha1 = "04e9157537ba51dad58336976f8d04b9ab7122f0" -uuid = "d1185830-fcd6-423d-90d6-eec64667417b" -version = "3.7.2" - - [deps.SymbolicUtils.extensions] - SymbolicUtilsLabelledArraysExt = "LabelledArrays" - SymbolicUtilsReverseDiffExt = "ReverseDiff" - - [deps.SymbolicUtils.weakdeps] - LabelledArrays = "2ee39098-c373-598a-b85f-a56591580800" - ReverseDiff = "37e2e3b7-166d-5795-8a7a-e32c996b4267" - -[[deps.Symbolics]] -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 = "0caef7687abf7094132fa3112bf5514c36a99226" -uuid = "0c5d862f-8b57-4792-8d23-62f2024744c7" -version = "6.18.3" - - [deps.Symbolics.extensions] - SymbolicsForwardDiffExt = "ForwardDiff" - SymbolicsGroebnerExt = "Groebner" - SymbolicsLuxExt = "Lux" - SymbolicsNemoExt = "Nemo" - SymbolicsPreallocationToolsExt = ["PreallocationTools", "ForwardDiff"] - SymbolicsSymPyExt = "SymPy" - - [deps.Symbolics.weakdeps] - ForwardDiff = "f6369f11-7733-5829-9624-2563aa707210" - Groebner = "0b43b601-686d-58a3-8a1c-6623616c7cd4" - Lux = "b2108857-7c20-44ae-9111-449ecde12c47" - Nemo = "2edaba10-b0f1-5616-af89-8c11ac63239a" - PreallocationTools = "d236fae5-4411-538c-8e31-a6e3d9e00b46" - SymPy = "24249f21-da20-56a4-8eb1-6a02cf4ae2e6" - -[[deps.TOML]] -deps = ["Dates"] -uuid = "fa267f1f-6049-4f14-aa54-33bafae1ed76" -version = "1.0.3" - -[[deps.TableTraits]] -deps = ["IteratorInterfaceExtensions"] -git-tree-sha1 = "c06b2f539df1c6efa794486abfb6ed2022561a39" -uuid = "3783bdb8-4a98-5b6b-af9a-565f29a5fe9c" -version = "1.0.1" - -[[deps.Tables]] -deps = ["DataAPI", "DataValueInterfaces", "IteratorInterfaceExtensions", "OrderedCollections", "TableTraits"] -git-tree-sha1 = "598cd7c1f68d1e205689b1c2fe65a9f85846f297" -uuid = "bd369af6-aec1-5ad0-b16a-f7cc5008161c" -version = "1.12.0" - -[[deps.Tar]] -deps = ["ArgTools", "SHA"] -uuid = "a4e569a6-e804-4fa4-b0f3-eef7a1d5b13e" -version = "1.10.0" - -[[deps.TensorCore]] -deps = ["LinearAlgebra"] -git-tree-sha1 = "1feb45f88d133a655e001435632f019a9a1bcdb6" -uuid = "62fd8b95-f654-4bbd-a8a5-9c27f68ccd50" -version = "0.1.1" - -[[deps.TermInterface]] -git-tree-sha1 = "d673e0aca9e46a2f63720201f55cc7b3e7169b16" -uuid = "8ea1fca8-c5ef-4a55-8b96-4e9afe9c9a3c" -version = "2.0.0" - -[[deps.Test]] -deps = ["InteractiveUtils", "Logging", "Random", "Serialization"] -uuid = "8dfed614-e22c-5e08-85e1-65c5234f0b40" -version = "1.11.0" - -[[deps.TestItemRunner]] -deps = ["Pkg", "TOML", "Test", "TestItems", "UUIDs"] -git-tree-sha1 = "29647c5398be04a1d697265ba385bdf3f623c993" -uuid = "f8b46487-2199-4994-9208-9a1283c18c0a" -version = "1.0.5" - -[[deps.TestItems]] -git-tree-sha1 = "42fd9023fef18b9b78c8343a4e2f3813ffbcefcb" -uuid = "1c621080-faea-4a02-84b6-bbd5e436b8fe" -version = "1.0.0" - -[[deps.TiffImages]] -deps = ["ColorTypes", "DataStructures", "DocStringExtensions", "FileIO", "FixedPointNumbers", "IndirectArrays", "Inflate", "Mmap", "OffsetArrays", "PkgVersion", "ProgressMeter", "SIMD", "UUIDs"] -git-tree-sha1 = "0248b1b2210285652fbc67fd6ced9bf0394bcfec" -uuid = "731e570b-9d59-4bfa-96dc-6df516fadf69" -version = "0.11.1" - -[[deps.TimerOutputs]] -deps = ["ExprTools", "Printf"] -git-tree-sha1 = "3a6f063d690135f5c1ba351412c82bae4d1402bf" -uuid = "a759f4b9-e2f1-59dc-863e-4aeb61b1ea8f" -version = "0.5.25" - -[[deps.TrajectoryIndexingUtils]] -git-tree-sha1 = "108da5f045005c9b57e6713ea84aca49d77fccaa" -uuid = "6dad8b7f-dd9a-4c28-9b70-85b9a079bfc8" -version = "0.1.0" - -[[deps.TranscodingStreams]] -git-tree-sha1 = "0c45878dcfdcfa8480052b6ab162cdd138781742" -uuid = "3bb67fe8-82b1-5028-8e26-92a6c54297fa" -version = "0.11.3" - -[[deps.TriplotBase]] -git-tree-sha1 = "4d4ed7f294cda19382ff7de4c137d24d16adc89b" -uuid = "981d1d27-644d-49a2-9326-4793e63143c3" -version = "0.1.0" - -[[deps.URIs]] -git-tree-sha1 = "67db6cc7b3821e19ebe75791a9dd19c9b1188f2b" -uuid = "5c2747f8-b7ea-4ff2-ba2e-563bfd36b1d4" -version = "1.5.1" - -[[deps.UUIDs]] -deps = ["Random", "SHA"] -uuid = "cf7118a7-6976-5b1a-9a39-7adc72f591a4" -version = "1.11.0" - -[[deps.Unicode]] -uuid = "4ec0a83e-493e-50e2-b9ac-8f72acf5a8f5" -version = "1.11.0" - -[[deps.UnicodeFun]] -deps = ["REPL"] -git-tree-sha1 = "53915e50200959667e78a92a418594b428dffddf" -uuid = "1cfade01-22cf-5700-b092-accc4b62d6e1" -version = "0.4.1" - -[[deps.Unidecode]] -deps = ["REPL", "Test", "Unicode"] -git-tree-sha1 = "2264362f72926965e708ee26f58824b929c72637" -uuid = "967fb449-e509-55aa-8007-234b4096b967" -version = "1.1.0" - -[[deps.Unitful]] -deps = ["Dates", "LinearAlgebra", "Random"] -git-tree-sha1 = "d95fe458f26209c66a187b1114df96fd70839efd" -uuid = "1986cc42-f94f-5a68-af5c-568840ba703d" -version = "1.21.0" -weakdeps = ["ConstructionBase", "InverseFunctions"] - - [deps.Unitful.extensions] - ConstructionBaseUnitfulExt = "ConstructionBase" - InverseFunctionsUnitfulExt = "InverseFunctions" - -[[deps.Unityper]] -deps = ["ConstructionBase"] -git-tree-sha1 = "25008b734a03736c41e2a7dc314ecb95bd6bbdb0" -uuid = "a7c27f48-0311-42f6-a7f8-2c11e75eb415" -version = "0.1.6" - -[[deps.WebP]] -deps = ["CEnum", "ColorTypes", "FileIO", "FixedPointNumbers", "ImageCore", "libwebp_jll"] -git-tree-sha1 = "aa1ca3c47f119fbdae8770c29820e5e6119b83f2" -uuid = "e3aaa7dc-3e4b-44e0-be63-ffb868ccd7c1" -version = "0.1.3" - -[[deps.WoodburyMatrices]] -deps = ["LinearAlgebra", "SparseArrays"] -git-tree-sha1 = "c1a7aa6219628fcd757dede0ca95e245c5cd9511" -uuid = "efce3f68-66dc-5838-9240-27a6d6f5f9b6" -version = "1.0.0" - -[[deps.XML2_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl", "Libiconv_jll", "Zlib_jll"] -git-tree-sha1 = "6a451c6f33a176150f315726eba8b92fbfdb9ae7" -uuid = "02c8fc9c-b97f-50b9-bbe4-9be30ff0a78a" -version = "2.13.4+0" - -[[deps.XSLT_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl", "Libgcrypt_jll", "Libgpg_error_jll", "Libiconv_jll", "XML2_jll", "Zlib_jll"] -git-tree-sha1 = "a54ee957f4c86b526460a720dbc882fa5edcbefc" -uuid = "aed1982a-8fda-507f-9586-7b0439959a61" -version = "1.1.41+0" - -[[deps.XZ_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "15e637a697345f6743674f1322beefbc5dcd5cfc" -uuid = "ffd25f8a-64ca-5728-b0f7-c24cf3aae800" -version = "5.6.3+0" - -[[deps.Xorg_libX11_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl", "Xorg_libxcb_jll", "Xorg_xtrans_jll"] -git-tree-sha1 = "afead5aba5aa507ad5a3bf01f58f82c8d1403495" -uuid = "4f6342f7-b3d2-589e-9d20-edeb45f2b2bc" -version = "1.8.6+0" - -[[deps.Xorg_libXau_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "6035850dcc70518ca32f012e46015b9beeda49d8" -uuid = "0c0b7dd1-d40b-584c-a123-a41640f87eec" -version = "1.0.11+0" - -[[deps.Xorg_libXdmcp_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "34d526d318358a859d7de23da945578e8e8727b7" -uuid = "a3789734-cfe1-5b06-b2d0-1dd0d9d62d05" -version = "1.1.4+0" - -[[deps.Xorg_libXext_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl", "Xorg_libX11_jll"] -git-tree-sha1 = "d2d1a5c49fae4ba39983f63de6afcbea47194e85" -uuid = "1082639a-0dae-5f34-9b06-72781eeb8cb3" -version = "1.3.6+0" - -[[deps.Xorg_libXrender_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl", "Xorg_libX11_jll"] -git-tree-sha1 = "47e45cd78224c53109495b3e324df0c37bb61fbe" -uuid = "ea2f1a96-1ddc-540d-b46f-429655e07cfa" -version = "0.9.11+0" - -[[deps.Xorg_libpthread_stubs_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "8fdda4c692503d44d04a0603d9ac0982054635f9" -uuid = "14d82f49-176c-5ed1-bb49-ad3f5cbd8c74" -version = "0.1.1+0" - -[[deps.Xorg_libxcb_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl", "XSLT_jll", "Xorg_libXau_jll", "Xorg_libXdmcp_jll", "Xorg_libpthread_stubs_jll"] -git-tree-sha1 = "bcd466676fef0878338c61e655629fa7bbc69d8e" -uuid = "c7cfdc94-dc32-55de-ac96-5a1b8d977c5b" -version = "1.17.0+0" - -[[deps.Xorg_xtrans_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "e92a1a012a10506618f10b7047e478403a046c77" -uuid = "c5fb5394-a638-5e4d-96e5-b29de1b5cf10" -version = "1.5.0+0" - -[[deps.Zlib_jll]] -deps = ["Libdl"] -uuid = "83775a58-1f1d-513f-b197-d71354ab007a" -version = "1.2.13+1" - -[[deps.Zstd_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "555d1076590a6cc2fdee2ef1469451f872d8b41b" -uuid = "3161d3a3-bdf6-5164-811a-617609db77b4" -version = "1.5.6+1" - -[[deps.isoband_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl", "Pkg"] -git-tree-sha1 = "51b5eeb3f98367157a7a12a1fb0aa5328946c03c" -uuid = "9a68df92-36a6-505f-a73e-abb412b6bfb4" -version = "0.2.3+0" - -[[deps.libaom_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "1827acba325fdcdf1d2647fc8d5301dd9ba43a9d" -uuid = "a4ae2306-e953-59d6-aa16-d00cac43593b" -version = "3.9.0+0" - -[[deps.libass_jll]] -deps = ["Artifacts", "Bzip2_jll", "FreeType2_jll", "FriBidi_jll", "HarfBuzz_jll", "JLLWrappers", "Libdl", "Zlib_jll"] -git-tree-sha1 = "e17c115d55c5fbb7e52ebedb427a0dca79d4484e" -uuid = "0ac62f75-1d6f-5e53-bd7c-93b484bb37c0" -version = "0.15.2+0" - -[[deps.libblastrampoline_jll]] -deps = ["Artifacts", "Libdl"] -uuid = "8e850b90-86db-534c-a0d3-1478176c7d93" -version = "5.11.0+0" - -[[deps.libfdk_aac_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "8a22cf860a7d27e4f3498a0fe0811a7957badb38" -uuid = "f638f0a6-7fb0-5443-88ba-1cc74229b280" -version = "2.0.3+0" - -[[deps.libpng_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl", "Zlib_jll"] -git-tree-sha1 = "b70c870239dc3d7bc094eb2d6be9b73d27bef280" -uuid = "b53b4c65-9356-5827-b1ea-8c7a1a84506f" -version = "1.6.44+0" - -[[deps.libsixel_jll]] -deps = ["Artifacts", "JLLWrappers", "JpegTurbo_jll", "Libdl", "Pkg", "libpng_jll"] -git-tree-sha1 = "7dfa0fd9c783d3d0cc43ea1af53d69ba45c447df" -uuid = "075b6546-f08a-558a-be8f-8157d0f608a5" -version = "1.10.3+1" - -[[deps.libvorbis_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl", "Ogg_jll", "Pkg"] -git-tree-sha1 = "490376214c4721cdaca654041f635213c6165cb3" -uuid = "f27f6e37-5d2b-51aa-960f-b287f2bc3b7a" -version = "1.3.7+2" - -[[deps.libwebp_jll]] -deps = ["Artifacts", "Giflib_jll", "JLLWrappers", "JpegTurbo_jll", "Libdl", "Libglvnd_jll", "Libtiff_jll", "libpng_jll"] -git-tree-sha1 = "ccbb625a89ec6195856a50aa2b668a5c08712c94" -uuid = "c5f90fcd-3b7e-5836-afba-fc50a0988cb2" -version = "1.4.0+0" - -[[deps.nghttp2_jll]] -deps = ["Artifacts", "Libdl"] -uuid = "8e850ede-7688-5339-a07c-302acd2aaf8d" -version = "1.59.0+0" - -[[deps.oneTBB_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "7d0ea0f4895ef2f5cb83645fa689e52cb55cf493" -uuid = "1317d2d5-d96f-522e-a858-c73665f53c3e" -version = "2021.12.0+0" - -[[deps.p7zip_jll]] -deps = ["Artifacts", "Libdl"] -uuid = "3f19e933-33d8-53b3-aaab-bd5110c3b7a0" -version = "17.4.0+2" - -[[deps.x264_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "35976a1216d6c066ea32cba2150c4fa682b276fc" -uuid = "1270edf5-f2f9-52d2-97e9-ab00b5d0237a" -version = "10164.0.0+0" - -[[deps.x265_jll]] -deps = ["Artifacts", "JLLWrappers", "Libdl"] -git-tree-sha1 = "dcc541bb19ed5b0ede95581fb2e41ecf179527d2" -uuid = "dfaa095f-4041-5dcd-9319-2fabd8486b76" -version = "3.6.0+0"