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
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
//
// GENERATED FILE
//
use super::*;
use crate::SpiceContext;
use f2rust_std::*;
/// Matrix equal to another, general dimension
///
/// Set one double precision matrix of arbitrary size equal to
/// another.
///
/// # Brief I/O
///
/// ```text
/// VARIABLE I/O DESCRIPTION
/// -------- --- --------------------------------------------------
/// M1 I Input matrix.
/// NR I Row dimension of M1 (and also MOUT).
/// NC I Column dimension of M1 (and also MOUT).
/// MOUT O Output matrix equal to M1.
/// ```
///
/// # Detailed Input
///
/// ```text
/// M1 is an arbitrary-sized double precision matrix.
/// There are no restrictions on what it may contain.
///
/// NR is the number of rows in the input matrix.
///
/// NC is the number of columns in the input matrix.
/// ```
///
/// # Detailed Output
///
/// ```text
/// MOUT is a NRxNC matrix set to be equal to M1.
/// ```
///
/// # Exceptions
///
/// ```text
/// Error free.
///
/// 1) If NR < 1 or NC < 1, the elements of the matrix MOUT are not
/// assigned any values.
/// ```
///
/// # Examples
///
/// ```text
/// If M1 = | 1.0D0 2.0D0 |
/// | |
/// | 2.0D0 4.0D0 |
/// | |
/// | 4.0D0 6.0D0 |
///
/// the call
///
/// CALL MEQUG ( M1, 3, 2, MOUT )
///
/// produces the matrix
///
/// MOUT = | 1.0D0 2.0D0 |
/// | |
/// | 2.0D0 4.0D0 |
/// | |
/// | 4.0D0 6.0D0 |
/// ```
///
/// # Author and Institution
///
/// ```text
/// J. Diaz del Rio (ODC Space)
/// W.M. Owen (JPL)
/// W.L. Taber (JPL)
/// ```
///
/// # Version
///
/// ```text
/// - SPICELIB Version 1.1.0, 04-JUL-2021 (JDR)
///
/// Edited the header to comply with NAIF standard.
///
/// - SPICELIB Version 1.0.1, 10-MAR-1992 (WLT)
///
/// Comment section for permuted index source lines was added
/// following the header.
///
/// - SPICELIB Version 1.0.0, 31-JAN-1990 (WMO)
/// ```
pub fn mequg(m1: &[f64], nr: i32, nc: i32, mout: &mut [f64]) {
MEQUG(m1, nr, nc, mout);
}
//$Procedure MEQUG ( Matrix equal to another, general dimension )
pub fn MEQUG(M1: &[f64], NR: i32, NC: i32, MOUT: &mut [f64]) {
let M1 = DummyArray2D::new(M1, 1..=NR, 1..=NC);
let mut MOUT = DummyArrayMut2D::new(MOUT, 1..=NR, 1..=NC);
MOVED(M1.as_slice(), (NR * NC), MOUT.as_slice_mut());
//
}