| 
8 | 8 | 
 
  | 
9 | 9 | GUIMetadata(type) = GUIMetadata(type, nothing)  | 
10 | 10 | 
 
  | 
11 |  | -"""  | 
12 |  | -```julia  | 
13 |  | -calculate_tgrad(sys::AbstractTimeDependentSystem)  | 
14 |  | -```  | 
15 |  | -
  | 
16 |  | -Calculate the time gradient of a system.  | 
17 |  | -
  | 
18 |  | -Returns a vector of [`Num`](@ref) instances. The result from the first  | 
19 |  | -call will be cached in the system object.  | 
20 |  | -"""  | 
21 |  | -function calculate_tgrad end  | 
22 |  | - | 
23 |  | -"""  | 
24 |  | -```julia  | 
25 |  | -calculate_gradient(sys::AbstractSystem)  | 
26 |  | -```  | 
27 |  | -
  | 
28 |  | -Calculate the gradient of a scalar system.  | 
29 |  | -
  | 
30 |  | -Returns a vector of [`Num`](@ref) instances. The result from the first  | 
31 |  | -call will be cached in the system object.  | 
32 |  | -"""  | 
33 |  | -function calculate_gradient end  | 
34 |  | - | 
35 |  | -"""  | 
36 |  | -```julia  | 
37 |  | -calculate_jacobian(sys::AbstractSystem)  | 
38 |  | -```  | 
39 |  | -
  | 
40 |  | -Calculate the Jacobian matrix of a system.  | 
41 |  | -
  | 
42 |  | -Returns a matrix of [`Num`](@ref) instances. The result from the first  | 
43 |  | -call will be cached in the system object.  | 
44 |  | -"""  | 
45 |  | -function calculate_jacobian end  | 
46 |  | - | 
47 |  | -"""  | 
48 |  | -```julia  | 
49 |  | -calculate_control_jacobian(sys::AbstractSystem)  | 
50 |  | -```  | 
51 |  | -
  | 
52 |  | -Calculate the Jacobian matrix of a system with respect to the system's controls.  | 
53 |  | -
  | 
54 |  | -Returns a matrix of [`Num`](@ref) instances. The result from the first  | 
55 |  | -call will be cached in the system object.  | 
56 |  | -"""  | 
57 |  | -function calculate_control_jacobian end  | 
58 |  | - | 
59 |  | -"""  | 
60 |  | -```julia  | 
61 |  | -calculate_factorized_W(sys::AbstractSystem)  | 
62 |  | -```  | 
63 |  | -
  | 
64 |  | -Calculate the factorized W-matrix of a system.  | 
65 |  | -
  | 
66 |  | -Returns a matrix of [`Num`](@ref) instances. The result from the first  | 
67 |  | -call will be cached in the system object.  | 
68 |  | -"""  | 
69 |  | -function calculate_factorized_W end  | 
70 |  | - | 
71 |  | -"""  | 
72 |  | -```julia  | 
73 |  | -calculate_hessian(sys::AbstractSystem)  | 
74 |  | -```  | 
75 |  | -
  | 
76 |  | -Calculate the hessian matrix of a scalar system.  | 
77 |  | -
  | 
78 |  | -Returns a matrix of [`Num`](@ref) instances. The result from the first  | 
79 |  | -call will be cached in the system object.  | 
80 |  | -"""  | 
81 |  | -function calculate_hessian end  | 
82 |  | - | 
83 |  | -"""  | 
84 |  | -```julia  | 
85 |  | -generate_tgrad(sys::AbstractTimeDependentSystem, dvs = unknowns(sys), ps = parameters(sys),  | 
86 |  | -               expression = Val{true}; kwargs...)  | 
87 |  | -```  | 
88 |  | -
  | 
89 |  | -Generates a function for the time gradient of a system. Extra arguments control  | 
90 |  | -the arguments to the internal [`build_function`](@ref) call.  | 
91 |  | -"""  | 
92 |  | -function generate_tgrad end  | 
93 |  | - | 
94 |  | -"""  | 
95 |  | -```julia  | 
96 |  | -generate_gradient(sys::AbstractSystem, dvs = unknowns(sys), ps = parameters(sys),  | 
97 |  | -                  expression = Val{true}; kwargs...)  | 
98 |  | -```  | 
99 |  | -
  | 
100 |  | -Generates a function for the gradient of a system. Extra arguments control  | 
101 |  | -the arguments to the internal [`build_function`](@ref) call.  | 
102 |  | -"""  | 
103 |  | -function generate_gradient end  | 
104 |  | - | 
105 |  | -"""  | 
106 |  | -```julia  | 
107 |  | -generate_jacobian(sys::AbstractSystem, dvs = unknowns(sys), ps = parameters(sys),  | 
108 |  | -                  expression = Val{true}; sparse = false, kwargs...)  | 
109 |  | -```  | 
110 |  | -
  | 
111 |  | -Generates a function for the Jacobian matrix of a system. Extra arguments control  | 
112 |  | -the arguments to the internal [`build_function`](@ref) call.  | 
113 |  | -"""  | 
114 |  | -function generate_jacobian end  | 
115 |  | - | 
116 |  | -"""  | 
117 |  | -```julia  | 
118 |  | -generate_hessian(sys::AbstractSystem, dvs = unknowns(sys), ps = parameters(sys),  | 
119 |  | -                 expression = Val{true}; sparse = false, kwargs...)  | 
120 |  | -```  | 
121 |  | -
  | 
122 |  | -Generates a function for the hessian matrix of a system. Extra arguments control  | 
123 |  | -the arguments to the internal [`build_function`](@ref) call.  | 
124 |  | -"""  | 
125 |  | -function generate_hessian end  | 
126 |  | - | 
127 |  | -"""  | 
128 |  | -```julia  | 
129 |  | -generate_function(sys::AbstractSystem, dvs = unknowns(sys), ps = parameters(sys),  | 
130 |  | -                  expression = Val{true}; kwargs...)  | 
131 |  | -```  | 
132 |  | -
  | 
133 |  | -Generate a function to evaluate the system's equations.  | 
134 |  | -"""  | 
135 |  | -function generate_rhs end  | 
136 |  | - | 
137 | 11 | """  | 
138 | 12 | ```julia  | 
139 | 13 | generate_custom_function(sys::AbstractSystem, exprs, dvs = unknowns(sys),  | 
 | 
0 commit comments