Message Boards Message Boards

0
|
1149 Views
|
1 Reply
|
0 Total Likes
View groups...
Share
Share this post:

Display of the squared norm

Posted 1 year ago

The result from the code below is correct but the display of the output is (to me) odd. Here is the code:

clear[A, B];
J[x_, t_] := \[HBar]/m Im[Conjugate[\[CapitalPsi][x, t]]*(\!\(
\*SubscriptBox[\(\[PartialD]\), \(x\)]\(\[CapitalPsi][x, t]\)\))]
\[CapitalPsi][x_, 0] := A E^(I k x) + B E^(-I k x)
FullSimplify[ComplexExpand[J[x, 0], {A, B}]] // TraditionalForm

the output is displayed as:

(k \[HBar] (\[LeftBracketingBar]A\[RightBracketingBar]^2-B B^\[Conjugate]))/m

or enter image description here

Why does it display the norm squared for A and B differently?

POSTED BY: Ted Bartlett

Strangely enough, the version with Conjugate is slightly simpler:

Abs[A]^2 - B Conjugate[B] // LeafCount
Abs[A]^2 - Abs[B]^2 // LeafCount
POSTED BY: Gianluca Gorni
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard

Group Abstract Group Abstract