@@ -370,46 +370,6 @@ For specifying Jacobians and mass matrices, see the
370370* `p`: The parameters for the problem. Defaults to `NullParameters`.
371371* `kwargs`: The keyword arguments passed on to the solvers.
372372"""
373- mutable struct SCCNonlinearProblem{uType, isinplace, P, F, K, PT} < :
374- AbstractNonlinearProblem{uType, isinplace}
375- f:: F
376- u0:: uType
377- p:: P
378- problem_type:: PT
379- kwargs:: K
380- @add_kwonly function SCCNonlinearProblem {iip} (f:: Union{AbstractVector,Tuple} ,
381- u0:: Union{AbstractVector,Tuple} ,
382- p = NullParameters (),
383- problem_type = StandardNonlinearProblem ();
384- kwargs... ) where {iip}
385- if ! (eltype (f) <: AbstractNonlinearFunction )
386- f = NonlinearFunction {iip} .(f)
387- end
388-
389- eltype (u0) <: AbstractVector || error (" !(eltype(u0) <: AbstractVector) detected. SCC states must be vector." )
390- length (f) != length (u0) && error (" Number of SCCs undefined. length(f) = $(length (f)) != $(length (u0)) == length(u0)" )
391-
392- if haskey (kwargs, :p )
393- error (" `p` specified as a keyword argument `p = $(kwargs[:p ]) ` to `NonlinearProblem`. This is not supported." )
394- end
395- warn_paramtype (p)
396- new{typeof (u0), iip, typeof (p), typeof (f),
397- typeof (kwargs), typeof (problem_type)}(f,
398- u0,
399- p,
400- problem_type,
401- kwargs)
402- end
373+ mutable struct SCCNonlinearProblem{P}
374+ probs:: P
403375end
404-
405- """
406- $(SIGNATURES)
407- """
408- function SCCNonlinearProblem (f:: Union{AbstractVector,Tuple} , u0:: Union{AbstractVector,Tuple} , p = NullParameters (); kwargs... )
409- if ! (eltype (f) <: AbstractNonlinearFunction )
410- f = NonlinearFunction .(f)
411- end
412- all (isinplace,f) || all (! inplace,f) || error (" All SCC Functions must match in-placeness" )
413- iip = isinplace (f[1 ])
414- SCCNonlinearProblem {iip} (f, u0, p; kwargs... )
415- end
0 commit comments