New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@stdlib/math-base-special-cflipsignf

Package Overview
Dependencies
Maintainers
4
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@stdlib/math-base-special-cflipsignf - npm Package Compare versions

Comparing version 0.0.1 to 0.1.0

CITATION.cff

4

docs/types/index.d.ts

@@ -19,7 +19,7 @@ /*

// TypeScript Version: 2.0
// TypeScript Version: 4.1
/// <reference types="@stdlib/types"/>
import { Complex64 } from '@stdlib/types/object';
import { Complex64 } from '@stdlib/types/complex';

@@ -26,0 +26,0 @@ /**

@@ -23,5 +23,6 @@ /**

var Complex64 = require( '@stdlib/complex-float32' );
var isNegativeZerof = require( '@stdlib/math-base-assert-is-negative-zerof' );
var real = require( '@stdlib/complex-real' );
var imag = require( '@stdlib/complex-imag' );
var realf = require( '@stdlib/complex-realf' );
var imagf = require( '@stdlib/complex-imagf' );

@@ -40,4 +41,4 @@

* var Complex64 = require( '@stdlib/complex-float32' );
* var real = require( '@stdlib/complex-real' );
* var imag = require( '@stdlib/complex-imag' );
* var realf = require( '@stdlib/complex-realf' );
* var imagf = require( '@stdlib/complex-imagf' );
*

@@ -47,11 +48,11 @@ * var v = cflipsignf( new Complex64( -4.0, 5.0 ), -55.0 );

*
* var re = real( v );
* var re = realf( v );
* // returns 4.0
*
* var im = imag( v );
* var im = imagf( v );
* // returns -5.0
*/
function cflipsignf( z, y ) {
var re = real( z );
var im = imag( z );
var re = realf( z );
var im = imagf( z );
if ( y < 0 || isNegativeZerof( y ) ) {

@@ -61,3 +62,3 @@ re = -re;

}
return new z.constructor( re, im );
return new Complex64( re, im );
}

@@ -64,0 +65,0 @@

{
"name": "@stdlib/math-base-special-cflipsignf",
"version": "0.0.1",
"version": "0.1.0",
"description": "Return a single-precision complex floating-point number with the same magnitude as `z` and the sign of `y*z`.",

@@ -21,3 +21,5 @@ "license": "Apache-2.0",

"example": "./examples",
"include": "./include",
"lib": "./lib",
"src": "./src",
"test": "./test"

@@ -41,21 +43,23 @@ },

"dependencies": {
"@stdlib/complex-imag": "^0.0.x",
"@stdlib/complex-real": "^0.0.x",
"@stdlib/math-base-assert-is-negative-zerof": "^0.0.x",
"@stdlib/types": "^0.0.x",
"@stdlib/utils-library-manifest": "^0.0.x"
"@stdlib/complex-float32": "^0.1.0",
"@stdlib/complex-imagf": "^0.1.0",
"@stdlib/complex-realf": "^0.1.0",
"@stdlib/math-base-assert-is-negative-zerof": "^0.1.0",
"@stdlib/types": "^0.1.0",
"@stdlib/utils-library-manifest": "^0.1.0"
},
"devDependencies": {
"@stdlib/bench": "^0.0.x",
"@stdlib/complex-float32": "^0.0.x",
"@stdlib/constants-float32-eps": "^0.0.x",
"@stdlib/constants-float32-ninf": "^0.0.x",
"@stdlib/constants-float32-pinf": "^0.0.x",
"@stdlib/math-base-assert-is-nanf": "^0.0.x",
"@stdlib/math-base-assert-is-positive-zerof": "^0.0.x",
"@stdlib/math-base-special-abs": "^0.0.x",
"@stdlib/random-base-uniform": "^0.0.x",
"@stdlib/bench": "^0.1.0",
"@stdlib/complex-imag": "^0.1.0",
"@stdlib/complex-real": "^0.1.0",
"@stdlib/constants-float32-eps": "^0.1.0",
"@stdlib/constants-float32-ninf": "^0.1.0",
"@stdlib/constants-float32-pinf": "^0.1.0",
"@stdlib/math-base-assert-is-nanf": "^0.1.0",
"@stdlib/math-base-assert-is-positive-zerof": "^0.1.0",
"@stdlib/math-base-special-abs": "^0.0.6",
"@stdlib/random-base-uniform": "^0.0.6",
"tape": "git+https://github.com/kgryte/tape.git#fix/globby",
"istanbul": "^0.4.1",
"tap-spec": "5.x.x"
"tap-min": "git+https://github.com/Planeshifter/tap-min.git"
},

@@ -88,5 +92,5 @@ "engines": {

"funding": {
"type": "patreon",
"url": "https://www.patreon.com/athan"
"type": "opencollective",
"url": "https://opencollective.com/stdlib"
}
}

@@ -21,2 +21,13 @@ <!--

<details>
<summary>
About stdlib...
</summary>
<p>We believe in a future in which the web is a preferred environment for numerical computation. To help realize this future, we've built stdlib. stdlib is a standard library, with an emphasis on numerical and scientific computation, written in JavaScript (and C) for execution in browsers and in Node.js.</p>
<p>The library is fully decomposable, being architected in such a way that you can swap out and mix and match APIs and functionality to cater to your exact preferences and use cases.</p>
<p>When you use stdlib, you can be absolutely certain that you are using the most thorough, rigorous, well-written, studied, documented, tested, measured, and high-quality code out there.</p>
<p>To join us in bringing numerical computing to the web, get started by checking us out on <a href="https://github.com/stdlib-js/stdlib">GitHub</a>, and please consider <a href="https://opencollective.com/stdlib">financially supporting stdlib</a>. We greatly appreciate your continued support!</p>
</details>
# cflipsignf

@@ -185,4 +196,4 @@

int main() {
float complex x[] = { 3.14f+1.5f*I, -3.14f-1.5f*I, 0.0f+0.0f*I, 0.0f/0.0f+0.0f/0.0f*I };
int main( void ) {
const float complex x[] = { 3.14f+1.5f*I, -3.14f-1.5f*I, 0.0f+0.0f*I, 0.0f/0.0f+0.0f/0.0f*I };

@@ -250,3 +261,3 @@ float complex v;

Copyright &copy; 2016-2022. The Stdlib [Authors][stdlib-authors].
Copyright &copy; 2016-2023. The Stdlib [Authors][stdlib-authors].

@@ -264,4 +275,4 @@ </section>

[test-image]: https://github.com/stdlib-js/math-base-special-cflipsignf/actions/workflows/test.yml/badge.svg
[test-url]: https://github.com/stdlib-js/math-base-special-cflipsignf/actions/workflows/test.yml
[test-image]: https://github.com/stdlib-js/math-base-special-cflipsignf/actions/workflows/test.yml/badge.svg?branch=v0.1.0
[test-url]: https://github.com/stdlib-js/math-base-special-cflipsignf/actions/workflows/test.yml?query=branch:v0.1.0

@@ -278,2 +289,9 @@ [coverage-image]: https://img.shields.io/codecov/c/github/stdlib-js/math-base-special-cflipsignf/main.svg

[chat-image]: https://img.shields.io/gitter/room/stdlib-js/stdlib.svg
[chat-url]: https://app.gitter.im/#/room/#stdlib-js_stdlib:gitter.im
[stdlib]: https://github.com/stdlib-js/stdlib
[stdlib-authors]: https://github.com/stdlib-js/stdlib/graphs/contributors
[umd]: https://github.com/umdjs/umd

@@ -285,10 +303,4 @@ [es-module]: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Modules

[esm-url]: https://github.com/stdlib-js/math-base-special-cflipsignf/tree/esm
[branches-url]: https://github.com/stdlib-js/math-base-special-cflipsignf/blob/main/branches.md
[chat-image]: https://img.shields.io/gitter/room/stdlib-js/stdlib.svg
[chat-url]: https://gitter.im/stdlib-js/stdlib/
[stdlib]: https://github.com/stdlib-js/stdlib
[stdlib-authors]: https://github.com/stdlib-js/stdlib/graphs/contributors
[stdlib-license]: https://raw.githubusercontent.com/stdlib-js/math-base-special-cflipsignf/main/LICENSE

@@ -295,0 +307,0 @@

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc