Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
90 changes: 10 additions & 80 deletions lib/node_modules/@stdlib/lapack/base/crot/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,6 @@ Applies a plane rotation with real cosine and complex sine.
```javascript
var Complex64Array = require( '@stdlib/array/complex64' );
var Complex64 = require( '@stdlib/complex/float32/ctor' );
var realf = require( '@stdlib/complex/float32/real' );
var imagf = require( '@stdlib/complex/float32/imag' );

var cx = new Complex64Array( [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0 ] );
var cy = new Complex64Array( [ 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 ] );
Expand All @@ -47,22 +45,10 @@ var s = new Complex64( 0.0, 0.75 );
crot( cx.length, cx, 1, cy, 1, 1.25, s );

var z = cy.get( 0 );
// returns <Complex64>

var re = realf( z );
// returns ~-1.5

var im = imagf( z );
// returns ~0.75
// returns <Complex64>[ ~-1.5, ~0.75 ]

z = cx.get( 0 );
// returns <Complex64>

re = realf( z );
// returns ~1.25

im = imagf( z );
// returns ~2.5
// returns <Complex64>[ ~1.25, ~2.5 ]
```

The function has the following parameters:
Expand All @@ -78,8 +64,6 @@ The `N` and stride parameters determine how values from `cx` and `cy` are access
```javascript
var Complex64Array = require( '@stdlib/array/complex64' );
var Complex64 = require( '@stdlib/complex/float32/ctor' );
var realf = require( '@stdlib/complex/float32/real' );
var imagf = require( '@stdlib/complex/float32/imag' );

var cx = new Complex64Array( [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0 ] );
var cy = new Complex64Array( [ 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 ] );
Expand All @@ -88,22 +72,10 @@ var s = new Complex64( 0.0, 0.75 );
crot( 2, cx, 2, cy, 2, 1.25, s );

var z = cy.get( 0 );
// returns <Complex64>

var re = realf( z );
// returns ~-1.5

var im = imagf( z );
// returns ~0.75
// returns <Complex64>[ ~-1.5, ~0.75 ]

z = cx.get( 0 );
// returns <Complex64>

re = realf( z );
// returns ~1.25

im = imagf( z );
// returns ~2.5
// returns <Complex64>[ ~1.25, ~2.5 ]
```

Note that indexing is relative to the first index. To introduce an offset, use [`typed array`][mdn-typed-array] views.
Expand All @@ -113,8 +85,6 @@ Note that indexing is relative to the first index. To introduce an offset, use [
```javascript
var Complex64Array = require( '@stdlib/array/complex64' );
var Complex64 = require( '@stdlib/complex/float32/ctor' );
var realf = require( '@stdlib/complex/float32/real' );
var imagf = require( '@stdlib/complex/float32/imag' );

// Initial arrays...
var cx0 = new Complex64Array( [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0 ] );
Expand All @@ -129,22 +99,10 @@ var s = new Complex64( 0.0, 0.75 );
crot( 2, cx1, -2, cy1, 1, 1.25, s );

var z = cy0.get( 2 );
// returns <Complex64>

var re = realf( z );
// returns ~-6

var im = imagf( z );
// returns ~5.25
// returns <Complex64>[ ~-6, ~5.25 ]

z = cx0.get( 3 );
// returns <Complex64>

re = realf( z );
// returns ~8.75

im = imagf( z );
// returns ~10
// returns <Complex64>[ ~8.75, ~10 ]
```

#### crot.ndarray( N, cx, strideCX, offsetCX, cy, strideCY, offsetCY, c, s )
Expand All @@ -154,8 +112,6 @@ Applies a plane rotation with real cosine and complex sine using alternative ind
```javascript
var Complex64Array = require( '@stdlib/array/complex64' );
var Complex64 = require( '@stdlib/complex/float32/ctor' );
var realf = require( '@stdlib/complex/float32/real' );
var imagf = require( '@stdlib/complex/float32/imag' );

var cx = new Complex64Array( [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0 ] );
var cy = new Complex64Array( [ 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 ] );
Expand All @@ -164,22 +120,10 @@ var s = new Complex64( 0.0, 0.75 );
crot.ndarray( cx.length, cx, 1, 0, cy, 1, 0, 1.25, s );

var z = cy.get( 0 );
// returns <Complex64>

var re = realf( z );
// returns ~-1.5

var im = imagf( z );
// returns ~0.75
// returns <Complex64>[ ~-1.5, ~0.75 ]

z = cx.get( 0 );
// returns <Complex64>

re = realf( z );
// returns ~1.25

im = imagf( z );
// returns ~2.5
// returns <Complex64>[ ~1.25, ~2.5 ]
```

The function has the following additional parameters:
Expand All @@ -192,8 +136,6 @@ While [`typed array`][mdn-typed-array] views mandate a view offset based on the
```javascript
var Complex64Array = require( '@stdlib/array/complex64' );
var Complex64 = require( '@stdlib/complex/float32/ctor' );
var realf = require( '@stdlib/complex/float32/real' );
var imagf = require( '@stdlib/complex/float32/imag' );

var cx = new Complex64Array( [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0 ] );
var cy = new Complex64Array( [ 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 ] );
Expand All @@ -202,22 +144,10 @@ var s = new Complex64( 0.0, 0.75 );
crot.ndarray( 2, cx, 2, 1, cy, 2, 1, 1.25, s );

var z = cy.get( 3 );
// returns <Complex64>

var re = realf( z );
// returns ~-6.0

var im = imagf( z );
// returns ~5.25
// returns <Complex64>[ ~-6.0, ~5.25 ]

z = cx.get( 1 );
// returns <Complex64>

re = realf( z );
// returns ~3.75

im = imagf( z );
// returns ~5.0
// returns <Complex64>[ ~3.75, ~5.0 ]
```

</section>
Expand Down
70 changes: 20 additions & 50 deletions lib/node_modules/@stdlib/lapack/base/crot/docs/repl.txt
Original file line number Diff line number Diff line change
Expand Up @@ -45,32 +45,20 @@
> var cy = new {{alias:@stdlib/array/complex64}}( [ 0.0, 0.0, 0.0, 0.0 ] );
> var s = new {{alias:@stdlib/complex/float32/ctor}}( 0.3, 0.4 );
> {{alias}}( cx.length, cx, 1, cy, 1, 0.8, s );
> var z = cy.get( 0 );
> var re = {{alias:@stdlib/complex/float32/real}}( z )
~-1.1
> var im = {{alias:@stdlib/complex/float32/imag}}( z )
~-0.2
> z = cx.get( 0 );
> re = {{alias:@stdlib/complex/float32/real}}( z )
~0.8
> im = {{alias:@stdlib/complex/float32/imag}}( z )
~1.6
> var z = cy.get( 0 )
<Complex64>[ ~-1.1, ~-0.2 ]
> z = cx.get( 0 )
<Complex64>[ ~0.8, ~1.6 ]

// Advanced indexing:
> cx = new {{alias:@stdlib/array/complex64}}( [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0 ] );
> cy = new {{alias:@stdlib/array/complex64}}( [ 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 ] );
> var s = new {{alias:@stdlib/complex/float32/ctor}}( 0.3, 0.4 );
> {{alias}}( 2, cx, -2, cy, 1, 0.8, s );
> z = cy.get( 0 );
> re = {{alias:@stdlib/complex/float32/real}}( z )
~-3.9
> im = {{alias:@stdlib/complex/float32/imag}}( z )
~0.2
> z = cx.get( 2 );
> re = {{alias:@stdlib/complex/float32/real}}( z )
~4.0
> im = {{alias:@stdlib/complex/float32/imag}}( z )
~4.8
> z = cy.get( 0 )
<Complex64>[ ~-3.9, ~0.2 ]
> z = cx.get( 2 )
<Complex64>[ ~4.0, ~4.8 ]

// Using typed array views:
> var cx0 = new {{alias:@stdlib/array/complex64}}( [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0 ] );
Expand All @@ -79,16 +67,10 @@
> var cy1 = new {{alias:@stdlib/array/complex64}}( cy0.buffer, cy0.BYTES_PER_ELEMENT*2 );
> var s = new {{alias:@stdlib/complex/float32/ctor}}( 0.3, 0.4 );
> {{alias}}( 1, cx1, 1, cy1, 1, 0.8, s );
> z = cy0.get( 2 );
> re = {{alias:@stdlib/complex/float32/real}}( z )
~-2.5
> im = {{alias:@stdlib/complex/float32/imag}}( z )
~0.0
> z = cx0.get( 1 );
> re = {{alias:@stdlib/complex/float32/real}}( z )
~2.4
> im = {{alias:@stdlib/complex/float32/imag}}( z )
~3.2
> z = cy0.get( 2 )
<Complex64>[ ~-2.5, 0 ]
> z = cx0.get( 1 )
<Complex64>[ ~2.4, ~3.2 ]


{{alias}}.ndarray( N, cx, strideCX, offsetCX, cy, strideCY, offsetCY, c, s )
Expand Down Expand Up @@ -140,32 +122,20 @@
> var cy = new {{alias:@stdlib/array/complex64}}( [ 0.0, 0.0, 0.0, 0.0 ] );
> var s = new {{alias:@stdlib/complex/float32/ctor}}( 0.3, 0.4 );
> {{alias}}.ndarray( cx.length, cx, 1, 0, cy, 1, 0, 0.8, s );
> var z = cy.get( 0 );
> var re = {{alias:@stdlib/complex/float32/real}}( z )
~-1.1
> var im = {{alias:@stdlib/complex/float32/imag}}( z )
~-0.2
> z = cx.get( 0 );
> re = {{alias:@stdlib/complex/float32/real}}( z )
~0.8
> im = {{alias:@stdlib/complex/float32/imag}}( z )
~1.6
> var z = cy.get( 0 )
<Complex64>[ ~-1.1, ~-0.2 ]
> z = cx.get( 0 )
<Complex64>[ ~0.8, ~1.6 ]

// Advanced indexing:
> cx = new {{alias:@stdlib/array/complex64}}( [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0 ] );
> cy = new {{alias:@stdlib/array/complex64}}( [ 0.0, 0.0, 0.0, 0.0, 0.0, 0.0 ] );
> var s = new {{alias:@stdlib/complex/float32/ctor}}( 0.3, 0.4 );
> {{alias}}.ndarray( 1, cx, 2, 1, cy, 2, 1, 0.8, s );
> z = cy.get( 1 );
> re = {{alias:@stdlib/complex/float32/real}}( z )
~-2.5
> im = {{alias:@stdlib/complex/float32/imag}}( z )
~0.0
> z = cx.get( 1 );
> re = {{alias:@stdlib/complex/float32/real}}( z )
~2.4
> im = {{alias:@stdlib/complex/float32/imag}}( z )
~3.2
> z = cy.get( 1 )
<Complex64>[ ~-2.5, 0 ]
> z = cx.get( 1 )
<Complex64>[ ~2.4, ~3.2 ]

See Also
--------
Expand Down
Loading