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
6 changes: 3 additions & 3 deletions lib/node_modules/@stdlib/strided/base/smap2/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -212,11 +212,11 @@ static float addf( const float x, const float y ) {
return x + y;
}

float X[] = { 1.0f, 2.0f, 3.0f, 4.0f, 5.0f, 6.0f };
float Y[] = { 1.0f, 2.0f, 3.0f, 4.0f, 5.0f, 6.0f };
const float X[] = { 1.0f, 2.0f, 3.0f, 4.0f, 5.0f, 6.0f };
const float Y[] = { 1.0f, 2.0f, 3.0f, 4.0f, 5.0f, 6.0f };
float Z[] = { 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f };

int64_t N = 6;
const int64_t N = 6;

stdlib_strided_smap2( N, X, 1, Y, 1, Z, 1, addf );
```
Expand Down
12 changes: 6 additions & 6 deletions lib/node_modules/@stdlib/strided/base/smap2/examples/c/example.c
Original file line number Diff line number Diff line change
Expand Up @@ -28,19 +28,19 @@ static float addf( const float x, const float y ) {

int main( void ) {
// Create input strided arrays:
float X[] = { 1.0f, 2.0f, 3.0f, 4.0f, 5.0f, 6.0f };
float Y[] = { 1.0f, 2.0f, 3.0f, 4.0f, 5.0f, 6.0f };
const float X[] = { 1.0f, 2.0f, 3.0f, 4.0f, 5.0f, 6.0f };
const float Y[] = { 1.0f, 2.0f, 3.0f, 4.0f, 5.0f, 6.0f };

// Create an output strided array:
float Z[] = { 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f };

// Specify the number of elements:
int64_t N = 6;
const int64_t N = 6;

// Define the strides:
int64_t strideX = 1;
int64_t strideY = -1;
int64_t strideZ = 1;
const int64_t strideX = 1;
const int64_t strideY = -1;
const int64_t strideZ = 1;

// Apply the callback:
stdlib_strided_smap2( N, X, strideX, Y, strideY, Z, strideZ, addf );
Expand Down
6 changes: 3 additions & 3 deletions lib/node_modules/@stdlib/strided/base/smap2/src/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -40,11 +40,11 @@
* return x + y;
* }
*
* float X[] = { 1.0f, 2.0f, 3.0f, 4.0f, 5.0f, 6.0f };
* const float X[] = { 1.0f, 2.0f, 3.0f, 4.0f, 5.0f, 6.0f };
* float Z[] = { 1.0f, 2.0f, 3.0f, 4.0f, 5.0f, 6.0f };
* float Y[] = { 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f };
* const float Y[] = { 0.0f, 0.0f, 0.0f, 0.0f, 0.0f, 0.0f };
*
* int64_t N = 6;
* const int64_t N = 6;
*
* stdlib_strided_smap2( N, X, 1, Y, 1, Z, 1, addf );
*/
Expand Down