�
��g*i � �> � d Z ddlmZmZmZmZ ddlmZ ddlm Z m
Z
mZmZm
Z
ddlmZ ddlmZmZmZmZmZmZmZmZ ddlmZmZ dd lmZ dd
lmZ ddl m!Z!m"Z" ddl#m$Z$m%Z% dd
l&m'Z'm(Z(m)Z) ddl*m+Z+ ddl,Z,d� e-d� � D � � \ Z.Z/Z0Z1 G d� de� � Z2dS )z.Geometrical Planes.
Contains
========
Plane
� )�Dummy�Rational�S�Symbol)�_symbol)�cos�sin�acos�asin�sqrt� )�GeometryEntity)�Line�Ray�Segment�Line3D�LinearEntity�LinearEntity3D�Ray3D� Segment3D)�Point�Point3D)�Matrix)�cancel)�solve�linsolve)�uniq�is_sequence)�
filldedent� func_name�Undecidable)�prec_to_dpsNc �, � g | ]}t d � � ��S )�plane_dummy)r ��.0�is �d/home/asafur/pinokio/api/open-webui.git/app/env/lib/python3.11/site-packages/sympy/geometry/plane.py�
<listcomp>r) s � �
5�
5�
5�q�e�M�"�"�
5�
5�
5� � c �� � e Zd ZdZdd�Zd� Zdd�Zd� Zdd�Ze d � � � Z
d
� Zd� Zdd�Z
d
� Zd� Zd� Zd� Zed� � � Zed� � � Zd� Zd� Zd� Zd� Zd� Zdd�Zdd�Zed� � � ZdS )�Planea�
A plane is a flat, two-dimensional surface. A plane is the two-dimensional
analogue of a point (zero-dimensions), a line (one-dimension) and a solid
(three-dimensions). A plane can generally be constructed by two types of
inputs. They are:
- three non-collinear points
- a point and the plane's normal vector
Attributes
==========
p1
normal_vector
Examples
========
>>> from sympy import Plane, Point3D
>>> Plane(Point3D(1, 1, 1), Point3D(2, 3, 4), Point3D(2, 2, 2))
Plane(Point3D(1, 1, 1), (-1, 2, -1))
>>> Plane((1, 1, 1), (2, 3, 4), (2, 2, 2))
Plane(Point3D(1, 1, 1), (-1, 2, -1))
>>> Plane(Point3D(1, 1, 1), normal_vector=(1,4,7))
Plane(Point3D(1, 1, 1), (1, 4, 7))
Nc � � t |d�� � }|r�|r�t |d�� � }t |d�� � }t j |||� � rt d� � �|� |� � }|� |� � }t t
|� � � t
|� � � � � � }n�|� d|� � }|� dd� � }t |� � r,t |� � dk r|rt |� � j n|}nt t d� � � � �t d� |D � � � � rt d � � �t j | ||fi |��S )
N� ��dimz Enter three non-collinear points�
normal_vector�evaluateTz�
Either provide 3 3D points or a point with a
normal vector expressed as a sequence of length 3c 3 �$ K � | ]}|j V � �d S �N)�is_zero)r&