reserve AS for AffinSpace;
reserve A,K,M,X,Y,Z,X9,Y9 for Subset of AS;
reserve zz for Element of AS;
reserve x,y for set;
reserve x,y,z,t,u,w for Element of AS;
reserve K,X,Y,Z,X9,Y9 for Subset of AS;
reserve a,b,c,d,p,q,r,p9 for POINT of IncProjSp_of(AS);
reserve A for LINE of IncProjSp_of(AS);

theorem Th29:
  a=LDir(Y) & A=[PDir(X),2] & Y is being_line & X is being_plane
  implies (a on A iff Y '||' X)
proof
  assume that
A1: a=LDir(Y) and
A2: A=[PDir(X),2] and
A3: Y is being_line and
A4: X is being_plane;
A5: now
A6: now
      given K,X9 such that
A7:   K is being_line and
A8:   X9 is being_plane and
A9:   LDir(Y)=LDir(K) and
A10:  [PDir(X),2]=[PDir(X9),2] and
A11:  K '||' X9;
A12:  X9 in AfPlanes(AS) by A8;
A13:  Class(PlanesParallelity(AS),X9)= PDir(X9);
      PDir(X)=PDir(X9) by A10,XTUPLE_0:1;
      then X in Class(PlanesParallelity(AS),X9) by A12,EQREL_1:23;
      then
A14:  ex X99 being Subset of AS st X=X99 & X99 is being_plane & X9 '||'
      X99 by A8,A13,Th10;
      K in AfLines(AS) by A7;
      then
A15:  Y in Class(LinesParallelity(AS),K) by A9,EQREL_1:23;
      Class(LinesParallelity(AS),K)= LDir(K);
      then consider K9 being Subset of AS such that
A16:  Y=K9 and
A17:  K9 is being_line and
A18:  K '||' K9 by A7,A15,Th9;
      K // K9 by A7,A17,A18,AFF_4:40;
      then K9 '||' X9 by A11,AFF_4:56;
      hence Y '||' X by A8,A16,A14,AFF_4:59,60;
    end;
    assume a on A;
    then
A19: [a,A] in the Inc of IncProjSp_of(AS) by INCSP_1:def 1;
    (ex K st K is being_line & [PDir(X),2]=[K,1] & (LDir(Y) in the carrier
of AS & LDir(Y) in K or LDir(Y) = LDir(K))) implies contradiction by XTUPLE_0:1
;
    hence Y '||' X by A1,A2,A19,A6,Def11;
  end;
  now
    assume Y '||' X;
    then [LDir(Y),[PDir(X),2]] in Proj_Inc(AS) by A3,A4,Def11;
    hence a on A by A1,A2,INCSP_1:def 1;
  end;
  hence thesis by A5;
end;
