Re: Type coercion on Symbols to get symbolic complex conjugation

• To: mathgroup at smc.vnet.net
• Subject: [mg18098] Re: Type coercion on Symbols to get symbolic complex conjugation
• From: Jens-Peer Kuska <kuska at informatik.uni-leipzig.de>
• Date: Thu, 17 Jun 1999 12:26:36 -0400
• Organization: Universitaet Leipzig
• References: <7k4rb9\$d5k@smc.vnet.net>
• Sender: owner-wri-mathgroup at wolfram.com

```Hi Patrick,

The definition

will print the complex conjugate in the form you like.
Since Mathematica knows no types for symbols it has no information
about you assumption that some variables are complexes. In Mathematica 4
you can specify that Element[z,Complexes] for Simplify and
FullSimplify[]
but not more.

Regards
Jens

Patrick Reany wrote:
>
> I'm trying to mix complex conjugation on demonstrably complex numbers,
> like a + b I (which works fine), with conjugation on symbols, such as
> taking k -> k* ,which doesn't work because
>
> 1) it appears that in some cases Mathematica treats all symbols not
> demonstrably equal to a complex number as a noncomplex number, in which> case if I could coerce it to complex by something like
> > makeComplex[x_] := Complex[x]
> > (which doesn't work) I might have a chance; or
> > 2) in other cases that k -> Conjugate[k], which would be OK if I could
> get it to print out as k* or overbar k.
> > What follows are a couple things I've already tried:
> > Conjugate[a_] := a* /;  SymbolQ[a];
> Format[Conjugate[x_]]  :=x* /;  SymbolQ[x]
>
> In summary: I want to declare a symbol, say k, as having Head Symbol or
> Complex and then to print out (display) the Conjugate of k in the form
> of either k* or overbar k. (I use version 3.)
>
> Thanks.

```

• Prev by Date: Re: Early Results from Mathematica 4.0
• Next by Date: Re: Wanted: summer Internet intro Calculus w/ Mathematica
• Previous by thread: Type coercion on Symbols to get symbolic complex conjugation
• Next by thread: Re: Type coercion on Symbols to get symbolic complex conjugation