1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
//! Metadata describing each problem in the corpus.
//!
//! Two layers:
//! - A flat [`ProblemSpec`] static per problem, aggregated into a slice
//! ([`crate::problems::ALL_SPECS`]) so callers (e.g. a web UI) can iterate
//! and filter the catalog without touching the math.
//! - A [`HasSpec`] trait, blanket-implemented for the wrapped problem types,
//! so generic code can recover a spec from a problem instance.
/// Bibliographic reference to the source defining a problem.
///
/// Strings are free-form to keep this lightweight; the web app just renders
/// them. `doi` and `url` are optional — pick whichever the source actually has.
/// Whether the problem has a fixed dimensionality or scales over `n`.
/// Boolean tags describing mathematical character. Each problem sets only the
/// fields that hold; defaults to all `false`. Used by the web UI for filtering.
///
/// Add fields here only when a new problem actually needs the distinction —
/// the field set is small on purpose.
/// Static description of a catalogued problem. The `Cost`/`Gradient` impls
/// live on the corresponding wrapper struct; this is just the metadata.
/// Recovers the [`ProblemSpec`] for a wrapped problem type at compile time.
/// Implemented blanket-style for the corpus types, e.g.
/// `impl<P> HasSpec for Rosenbrock<P>`.