mirror of
https://gitlab.com/scemama/QCaml.git
synced 2025-01-03 01:55:40 +01:00
Optimizations in localization
This commit is contained in:
parent
16658180f3
commit
158d149036
@ -21,6 +21,7 @@ let matrix_z t = t.(2)
|
|||||||
let matrix_x2 t = t.(3)
|
let matrix_x2 t = t.(3)
|
||||||
let matrix_y2 t = t.(4)
|
let matrix_y2 t = t.(4)
|
||||||
let matrix_z2 t = t.(5)
|
let matrix_z2 t = t.(5)
|
||||||
|
let matrix_r2 t = Mat.add t.(3) @@ Mat.add t.(4) t.(5)
|
||||||
let matrix_xy t = t.(6)
|
let matrix_xy t = t.(6)
|
||||||
let matrix_yz t = t.(7)
|
let matrix_yz t = t.(7)
|
||||||
let matrix_zx t = t.(8)
|
let matrix_zx t = t.(8)
|
||||||
@ -215,8 +216,8 @@ let of_basis basis =
|
|||||||
done;
|
done;
|
||||||
done;
|
done;
|
||||||
done;
|
done;
|
||||||
for k=0 to 14 do
|
for k=0 to Array.length result - 1 do
|
||||||
Mat.detri result.(k);
|
Mat.detri result.(k)
|
||||||
done;
|
done;
|
||||||
result
|
result
|
||||||
|
|
||||||
|
@ -31,6 +31,9 @@ val matrix_y2 : t -> Mat.t
|
|||||||
val matrix_z2 : t -> Mat.t
|
val matrix_z2 : t -> Mat.t
|
||||||
(** {% $$ \langle \chi_i | z^2 | \chi_j \rangle $$ %} *)
|
(** {% $$ \langle \chi_i | z^2 | \chi_j \rangle $$ %} *)
|
||||||
|
|
||||||
|
val matrix_r2 : t -> Mat.t
|
||||||
|
(** {% $$ \langle \chi_i | r^2 | \chi_j \rangle $$ %} *)
|
||||||
|
|
||||||
val matrix_x3 : t -> Mat.t
|
val matrix_x3 : t -> Mat.t
|
||||||
(** {% $$ \langle \chi_i | x^3 | \chi_j \rangle $$ %} *)
|
(** {% $$ \langle \chi_i | x^3 | \chi_j \rangle $$ %} *)
|
||||||
|
|
||||||
|
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue
Block a user