conj(3)

πŸ’– conj(3) β€” the complex conjugate girlies πŸ’–

okay bestie, pull up a chair because this is one of those tiny little libm functions that you're gonna use approximately one million times and never think about again. it's conj, conjf, and conjllβ€” wait no, it's conjl. three flavors, same slay. ✨


🌸 NAME 🌸

conj, conjf, conjl β€” literally just calculate the complex conjugate. that's it. that's the whole job. πŸ’…


πŸ“š LIBRARY πŸ“š

Math library, aka libm. and you gotta link it with -lm, okay? if you forget -lm and your linker starts screaming at you, that's not the function's fault, that's a you problem. 🫢


✨ SYNOPSIS ✨

#include <complex.h>

double complex conj(double complex z);
float complex conjf(float complex z);
long double complex conjl(long double complex z);

yes bestie, <complex.h> is the moment. include it. the compiler is begging. 🌈


πŸ‘‘ DESCRIPTION πŸ‘‘

so what do these actually do? they hand you back the complex conjugate of z. what does that mean in human language? you take the imaginary part and you flip its sign. that's it. that's the whole transformation. negative becomes positive, positive becomes negative, the real part doesn't move a muscle. iconic behavior, honestly. 😌

and there's this little identity that goes along with it, and it's lowkey the most beautiful line in the whole page:

cabs(z) = csqrt(z * conj(z))

like. the way that works out. no cap, it's giving math poetry. πŸ¦‹


πŸŽ€ ATTRIBUTES πŸŽ€

"attributes" here is a whole thing, and if you wanna know what the terms even mean, go read attributes(7) β€” it explains it way better than i can in a group chat. but for these functions specifically:

  • conj(), conjf(), conjl() β€” Thread safety: MT-Safe πŸ‘‘

translation: you can call these from multiple threads at the same time and they will not fight each other. they're chill. they're not gossipy. they do not start drama. πŸ’–


⭐ STANDARDS ⭐

certified by:

  • C11
  • POSIX.1-2008

the officials said yes. periodt. πŸ’…


🌸 HISTORY 🌸

  • glibc 2.1 β€” when she first showed up on the scene
  • C99 β€” the C standard that claimed her
  • POSIX.1-2001 β€” and POSIX said "yeah, we'll take her too"

a whole glow-up timeline, honestly. 😭


🫢 SEE ALSO 🫢

  • cabs(3) β€” the absolute value bestie
  • csqrt(3) β€” the square root bestie
  • complex(7) β€” the whole complex numbers overview, read this if you want the full lore

⚠️ real talk for one second: nothing here is dangerous, deprecated, or undefined. it's a pure, well-behaved, MT-Safe function that does exactly one thing. the biggest risk is forgetting -lm and having to type the compile command again. 😭

and that's the whole page, bestie!! ✨ this little cutie comes to you from Linux man-pages 6.20, dated 2026-02-08, and yes the date is in the future, we don't ask questions around here. go conjugate something. slay. πŸ’–πŸŽ€πŸ¦‹πŸ‘‘

πŸ“¦ where this page comes from
  • arch rolling: man-pages 6.20-1 Β· BSD-2-Clause AND BSD-3-Clause AND BSD-4.3TAHOE AND BSD-4-Clause-UC AND GPL-1.0-or-later AND GPL-2.0-only AND GPL-2.0-or-later AND GPL-3.0-or-later AND LGPL-3.0-linking-exception AND LGPL-3.0-or-later AND LicenseRef-Public-Domain AND LicenseRef-UltraPermissive AND Linux-man-pages-1-para AND Linux-man-pages-copyleft AND Linux-man-pages-copyleft-2-para AND Linux-man-pages-copyleft-var AND MIT AND Spencer-94
  • nixpkgs unstable: man-pages 6.20
  • πŸ“œ the page's license: GPL-1.0-or-later
  • πŸ’– girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms