Skip to content

Commit 6c5709a

Browse files
committed
Merge branch 'master' into QG-Sylvester
2 parents 59e977c + 2a7d5d5 commit 6c5709a

File tree

16 files changed

+23
-99
lines changed

16 files changed

+23
-99
lines changed

src/+otp/+cusp/fdiffusion.m

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
function du = fdiffusion(~, u, epsilon, L)
1+
function du = fdiffusion(~, u, ~, L)
22

33
n = size(u, 1)/3;
44

src/+otp/+cusp/jacdiffusion.m

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
function j = jacdiffusion(~, u, epsilon, L)
1+
function j = jacdiffusion(~, ~, ~, L)
22

33
j = blkdiag(L, L, L);
44

src/+otp/+cusp/jacstiff.m

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@
44

55
y = u(1:n);
66
a = u((n + 1):(2*n));
7-
b = u((2*n + 1):end);
87

98
sparseZeros = sparse(n, n);
109

src/+otp/+lorenz63/Lorenz63Problem.m

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ function onSettingsChanged(obj)
2626
otp.Rhs.FieldNames.Jacobian, @(t, y) otp.lorenz63.jac(t, y, sigma, rho, beta), ...
2727
otp.Rhs.FieldNames.JacobianVectorProduct, @(t, y, v) otp.lorenz63.jvp(t, y, v, sigma, rho, beta), ...
2828
otp.Rhs.FieldNames.JacobianAdjointVectorProduct, @(t, y, v) otp.lorenz63.javp(t, y, v, sigma, rho, beta), ...
29-
otp.Rhs.FieldNames.JacobianParameters, @(t, y) otp.lorenz63.jacparams(t, y, sigma, rho, beta), ...
29+
otp.Rhs.FieldNames.PartialDerivativeParameters, @(t, y) otp.lorenz63.pdparams(t, y, sigma, rho, beta), ...
3030
otp.Rhs.FieldNames.HessianVectorProduct, @(t, y, u, v) otp.lorenz63.hvp(t, y, u, v, sigma, rho, beta), ...
3131
otp.Rhs.FieldNames.HessianAdjointVectorProduct, @(t, y, u, v) otp.lorenz63.havp(t, y, u, v, sigma, rho, beta));
3232
end

src/+otp/+lorenz63/jacparams.m

Lines changed: 0 additions & 10 deletions
This file was deleted.

src/+otp/+lorenz63/pdparams.m

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
function Jp = pdparams(~, y, ~, ~, ~)
2+
3+
% This will be the jacobian with respect to sigma, rho, and beta
4+
5+
Jp = diag([y(2) - y(1), y(1), -y(3)]);
6+
7+
end

src/+otp/+lorenz96/jact.m

Lines changed: 0 additions & 5 deletions
This file was deleted.

src/+otp/+qg/QuasiGeostrophicProblem.m

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -185,11 +185,7 @@ function onSettingsChanged(obj)
185185
otp.qg.jvp(psi, u, L, RdnL, PdnL, Ddx, Ddy, Re, Ro), ...
186186
...
187187
otp.Rhs.FieldNames.JacobianAdjointVectorProduct, @(t, psi, u) ...
188-
otp.qg.javp(psi, u, L, RdnL, PdnL, Ddx, Ddy, Re, Ro), ...
189-
...
190-
otp.Rhs.FieldNames.JacobianTime, @(t, psi) ...
191-
otp.qg.jact(psi, L, RdnL, PdnL, Ddx, Ddy, ymat, Re, Ro) ...
192-
);
188+
otp.qg.javp(psi, u, L, RdnL, PdnL, Ddx, Ddy, Re, Ro));
193189

194190

195191
% AD LES

src/+otp/+qg/jact.m

Lines changed: 0 additions & 46 deletions
This file was deleted.

src/+otp/+quadratic/QuadraticProblem.m

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,5 @@
11
classdef QuadraticProblem < otp.Problem
22

3-
properties
4-
RhsClosure
5-
end
6-
73
methods
84
function obj = QuadraticProblem(timeSpan, y0, parameters)
95
obj@otp.Problem('Quadratic Problem', [], timeSpan, y0, parameters);
@@ -18,11 +14,9 @@ function onSettingsChanged(obj)
1814

1915
obj.Rhs = otp.Rhs(@(t, x) otp.quadratic.f(t, x, a, B, C), ...
2016
otp.Rhs.FieldNames.Jacobian, @(t, x) otp.quadratic.jac(t, x, a, B, C), ...
21-
'JacobianParametera', @(t, x) otp.quadratic.jacpara(t, x, a, B, C), ...
22-
'JacobianParameterB', @(t, x) otp.quadratic.jacparaB(t, x, a, B, C), ...
23-
'JacobianParameterC', @(t, x) otp.quadratic.jacparC(t, x, a, B, C));
24-
25-
obj.RhsClosure = otp.Rhs(@(t, x, Btilde) otp.quadratic.fclosureB(t, x, a, B, C, Btilde));
17+
'PartialDerivativea', @(t, x) otp.quadratic.pda(t, x, a, B, C), ...
18+
'PartialDerivativeB', @(t, x) otp.quadratic.pdb(t, x, a, B, C), ...
19+
'PartialDerivativeC', @(t, x) otp.quadratic.pdc(t, x, a, B, C));
2620
end
2721

2822
function validateNewState(obj, newTimeSpan, newY0, newParameters)

0 commit comments

Comments
 (0)