Skip to content

Commit

Permalink
fmt
Browse files Browse the repository at this point in the history
  • Loading branch information
warisa-r committed Jun 24, 2024
1 parent 13ac6dc commit 516e95f
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion ext/TrixiNLsolveExt.jl
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ function Trixi.solve_a_unknown!(a_unknown, num_stages, monomial_coeffs, c_s2, c;
# Initialize initial guess
# The nonlinear system may have multiple valid solutions.
# For the sake of reproducibility, we use a seeded random initial guess
x0 = 0.1 .* rand(num_stages-2)
x0 = 0.1 .* rand(num_stages - 2)

sol = nlsolve(objective_function, x0, method = :trust_region,
ftol = 4e-16, # Enforce objective up to machine precision
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ function compute_PairedExplicitRK3_butcher_tableau(num_stages, tspan,
c = compute_c_coeffs_SSP33(num_stages, cS2)

# Initialize the array of our solution
a_unknown = zeros(num_stages-2)
a_unknown = zeros(num_stages - 2)

# Special case of e = 3
if num_stages == 3
Expand Down Expand Up @@ -113,7 +113,7 @@ function compute_PairedExplicitRK3_butcher_tableau(num_stages, tspan,
a_matrix[:, 1] = c[3:end]
a_matrix[:, 1] -= a_unknown
a_matrix[:, 2] = a_unknown

return a_matrix, c
end

Expand Down Expand Up @@ -210,10 +210,10 @@ end
function PairedExplicitRK3(num_stages, tspan, eig_vals::Vector{ComplexF64};
verbose = false, cS2 = 1)
a_matrix, c = compute_PairedExplicitRK3_butcher_tableau(num_stages,
tspan,
eig_vals;
verbose, cS2)
return PairedExplicitRK3(num_stages, a_matrix, c,)
tspan,
eig_vals;
verbose, cS2)
return PairedExplicitRK3(num_stages, a_matrix, c)
end

# This struct is needed to fake https://github.com/SciML/OrdinaryDiffEq.jl/blob/0c2048a502101647ac35faabd80da8a5645beac7/src/integrators/type.jl#L77
Expand Down

0 comments on commit 516e95f

Please sign in to comment.