The example below computes the two lines that meet four given lines in 3-spaces.
To verify the first intersection condition, we concatenate the first input plane with the first output plane. The determinant of the concatenated matrix should have real and imaginary parts of the same magnitude as the machine precision.
i1 : (ipt, otp) := PieriHomotopies(2,2); |
i2 : print ipt
{| -.5 .0789861+.337514ii |, | -.5 .100114+.522956ii |, | -.5 -.366779+.0616693ii |, | -.5 .520168+.433658ii |}
| -.384072+.320139ii -.78232+.0695621ii | | .420128+.271095ii -.440104-.164566ii | | .0588166+.496529ii -.282839+.118993ii | | -.485057+.121324ii -.392606+.0981598ii |
| -.289633-.407569ii -.0959645+.306554ii | | .495263-.0686602ii .0970034+.456215ii | | .363617+.343195ii -.31789-.754152ii | | -.474704-.157021ii -.355034-.170981ii |
| .437037+.242897ii -.396175-.0533282ii | | .455215-.206831ii .460994-.256248ii | | .211049-.453275ii .213401-.228417ii | | .383866-.320386ii .0339278+.470273ii |
|
i3 : print otp
{| 1 0 |, | 1 0 |}
| .460192+1.22303ii .686429+1.18891ii | | -1.33856-.184891ii 1.6443-.188318ii |
| .725722+1.15426ii 1 | | -.193176+.298252ii 1 |
| 0 .147669-.643236ii | | 0 -.717825+.459372ii |
|
i4 : in0 = ipt_0
o4 = | -.5 .0789861+.337514ii |
| -.384072+.320139ii -.78232+.0695621ii |
| -.289633-.407569ii -.0959645+.306554ii |
| .437037+.242897ii -.396175-.0533282ii |
4 2
o4 : Matrix CC <--- CC
53 53
|
i5 : out0 = otp_0
o5 = | 1 0 |
| .460192+1.22303ii .686429+1.18891ii |
| .725722+1.15426ii 1 |
| 0 .147669-.643236ii |
4 2
o5 : Matrix CC <--- CC
53 53
|
i6 : m = in0|out0
o6 = | -.5 .0789861+.337514ii 1
| -.384072+.320139ii -.78232+.0695621ii .460192+1.22303ii
| -.289633-.407569ii -.0959645+.306554ii .725722+1.15426ii
| .437037+.242897ii -.396175-.0533282ii 0
------------------------------------------------------------------------
0 |
.686429+1.18891ii |
1 |
.147669-.643236ii |
4 4
o6 : Matrix CC <--- CC
53 53
|
i7 : det m o7 = 2.58336551660451e-15+1.77395234202542e-16*ii o7 : CC (of precision 53) |
The object PieriHomotopies is a method function with options.