lis_array_xpay(3)

πŸ“¦ version 2.1.11, in fedora 43, fedora 44, nixos 26.05, nixpkgs unstable

✨ NAME ✨

lis_array_xpay β€” okay bestie, this is the one that does vector math and gives you the sum of the vectors πŸ’–

It lives in the Lis Library Functions section of the manual, so if you're the kind of girl who reads man 3 pages for fun (me, hi 🫢), you're in the right place.


🌸 SYNOPSIS 🌸

#include "lis.h"

LIS_INT lis_array_xpay(LIS_INT n, LIS_SCALAR x[], LIS_SCALAR alpha,
LIS_SCALAR y[]);

That's the whole vibe check right there. Four args, one very cute little sum. ✨


πŸŽ€ DESCRIPTION πŸŽ€

Not me explaining the most iconic line of math ever, but here we are:

y = x + alpha * y

That's literally it. It calculates the sum of the vectors β€” you hand it two arrays and a scalar, and it does the thing. Slay. πŸ’…


πŸ¦‹ INPUT πŸ¦‹

  • n β€” the size of the vectors. Like, how many elements we're working with, bestie. Not one more, not one less. πŸ‘‘
  • alpha β€” the scalar value. She's just a single number, but she's doing a lot of heavy lifting in this equation. Main character energy fr fr.
  • x, y β€” the arrays that store the vectors. Two little array besties holding hands. 🫢

🌈 OUTPUT 🌈

  • y β€” the result: x + alpha * y

And yes, we need to talk about this: vector y is overwritten. Not me being dramatic, that's just what the page says. So if you needed the original y for literally anything else, she's gone, no cap. Save her somewhere else first. πŸ’€


πŸ“ EXIT STATUS πŸ“

The following exit values are returned:

  • 0 β€” the process is normally terminated. Everything ate, zero crumbs. βœ…
  • unspecified β€” an error occurred. The vibe check failed, bestie. Something went wrong and honestly the page is not telling us what. 😭

πŸ’œ SEE ALSO πŸ’œ


and that's the whole page, bestie πŸ’–βœ¨πŸŽ€πŸ¦‹πŸŒΈπŸ’…

Cute little sign-off time: this was the Lis Library Functions man page for lis_array_xpay(3), dated 3 Dec 2014, and it says Man Page right there in the corner like a little footer bow. πŸŽ€ Go forth and xpay, you gorgeous nerd. ⭐

πŸ“¦ where this page comes from