From 2316044fd02bf22b5b6c0f414874dada2c7603e4 Mon Sep 17 00:00:00 2001 From: Jaron Kent-Dobias Date: Thu, 7 Jan 2021 11:23:20 +0100 Subject: Implemented some lazy optimizations and C++17isms. --- stereographic.hpp | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'stereographic.hpp') diff --git a/stereographic.hpp b/stereographic.hpp index 8313f25..61d81c5 100644 --- a/stereographic.hpp +++ b/stereographic.hpp @@ -51,11 +51,7 @@ Matrix stereographicJacobian(const Vector& ζ) { } std::tuple stereographicHamGradHess(const Tensor& J, const Vector& ζ, const Vector& z) { - Scalar hamiltonian; - Vector gradZ; - Matrix hessZ; - std::tie(hamiltonian, gradZ, hessZ) = hamGradHess(J, z); - + auto [hamiltonian, gradZ, hessZ] = hamGradHess(J, z); Matrix jacobian = stereographicJacobian(ζ); Matrix metric = jacobian * jacobian.adjoint(); -- cgit v1.2.3-54-g00ecf