+
    Y°³j·  ã                   óš   € R t ^ RIt^RIHt ^ RIHt ]]]P                  3t
]P                  ! ]P                  4      P                  tR tR# )a   
This module provides the _project function that attempts to project the initial guess
onto the feasible set.

Adapted from the corresponding function in the PDFO package (https://www.pdfo.net) by
Tom M. Ragonneau (https://ragonneau.github.io) and Zaikun Zhang (https://www.zhangzk.net).
N©ÚLinearConstraint)ÚOptimizeResultc           	     ó¸  a€ Rp\        V \        4      '       d   V .oM/\        V R4      '       d   V oM\        RP	                  V4      4      h \
        P                  ! S\
        P                  R7      o\        SP                  4      ^8w  d   \        RP	                  T4      4      hSP                  p\        T\        4      '       d   T.pM/\        TR4      '       d   TpM\        RP	                  T4      4      h \
        P                  ! T\
        P                  R7      p\        TP                  4      ^8w  g   TP                  T8w  d   \        RP	                  T4      4      h\        T\        4      '       d   T.pM/\        TR4      '       d   TpM\        R	P	                  T4      4      h \
        P                  ! T\
        P                  R7      p\        TP                  4      ^8w  g   TP                  T8w  d   \        RP	                  T4      4      h\        T\        4      '       dI   RR0\        TP                  4       4      8:  d)   \        TR,          \        4      '       g&   TR,          e   \        RP	                  T4      4      hRpTR,          f?   \
        P                  ! \
        P                   ! ST3^ R7      T3^ R7      p	\#        T	R7      # \%        \
        P&                  ! \
        P(                  ! TR,          P*                  TR,          P,                  ,
          4      \.        4      4      '       Ed   \
        P0                  ! T4      T) 8:  dè   \
        P2                  ! T4      T8¼  dÍ   TR,          P4                  p
TR,          P,                  TR,          P*                  ,           ^,          p\
        P6                  P9                  Y«\
        P:                  ! T
S4      ,
          RR7      w  p  p\
        P                  ! \
        P                   ! ST,           T3^ R7      T3^ R7      p	\#        T	R7      # TR,          Eeá    ^ RIHp ^ RIH p ^ RIHp TR,          p\        4       \        4       pp\
        P                  ! . .4      \
        P                  ! . .4      uTR&   TR&   TR,          PC                  ^ TP4                  P                  ^,          4      TR&   TR,          PC                  ^ TP4                  P                  ^,          4      TR&   \
        P                  ! . 4      \
        P                  ! . 4      uTR&   TR&   \
        P                  ! . 4      \
        P                  ! . 4      uTR&   TR&   \E        TP,                  P                  4       EF  pTP,                  T,          TP*                  T,          8w  d«   \
        PF                  ! TR,          TP4                  TT^,           1R3,          3^ R7      TR&   \
        PH                  TR,          TP,                  T,          3,          TR&   \
        PH                  TR,          TP*                  T,          3,          TR&   K×  \
        PF                  ! TR,          TP4                  TT^,           1R3,          3^ R7      TR&   \
        PH                  TR,          TP,                  T,          3,          TR&   \
        PH                  TR,          TP*                  T,          3,          TR&   EK‚  	  TR,          P                  ^ 8”  dB   TR,          P                  ^ 8”  d*   TR,          P                  ^ 8”  d   T! R/ TB T! R/ TB .pM\TR,          P                  ^ 8”  d"   TR,          P                  ^ 8”  d
   T! R/ TB pM#TR,          P                  ^ 8”  d
   T! R/ TB pMRp\
        P:                  ! TR,          S4      p\
        P:                  ! TR,          S4      p\
        PJ                  ! TTR,          4      PM                  4       '       g»   \
        PJ                  ! TR,          T4      PM                  4       '       g‰   \
        PN                  ! TTR,          4      PM                  4       '       gW   \
        PJ                  ! ST4      PM                  4       '       g,   \
        PJ                  ! TS4      PM                  4       '       d   T! T3R lST3R lT! Yg4      TR7      # \#        SR7      # \#        SR7      #   \         d    \        RP	                  T4      4      hi ; i  \         d    \        RP	                  T4      4      hi ; i  \         d    \        R
P	                  T4      4      hi ; i  \P         d    \#        SR7      u # i ; i)a(  Projection of the initial guess onto the feasible set.

Parameters
----------
x0: ndarray, shape (n,)
    The same as in prepdfo.
lb: ndarray, shape (n,)
    The same as in prepdfo.
ub: ndarray, shape (n,)
    The same as in prepdfo.
constraints: dict
    The general constraints of the problem, defined as a dictionary with
    fields:
        linear: LinearConstraint
            The linear constraints of the problem.
        nonlinear: dict
            The nonlinear constraints of the problem. When ``_project`` is called, the nonlinear constraints are
            None.

Returns
-------
result: OptimizeResult
    The result of the projection.

Authors
-------
Tom M. RAGONNEAU (ragonneau.github.io)
and Zaikun ZHANG (www.zhangzk.net)

Dedicated to the late Professor M. J. D. Powell FRS (1936--2015).
ÚprimaÚ__len__z,{}: UNEXPECTED ERROR: x0 should be a vector.)Údtypez5{}: UNEXPECTED ERROR: x0 should contain only scalars.z,{}: UNEXPECTED ERROR: lb should be a vector.z5{}: UNEXPECTED ERROR: lb should contain only scalars.z={}: UNEXPECTED ERROR: the size of lb is inconsistent with x0.z,{}: UNEXPECTED ERROR: ub should be a vector.z5{}: UNEXPECTED ERROR: ub should contain only scalars.z={}: UNEXPECTED ERROR: the size of ub is inconsistent with x0.ÚlinearÚ	nonlinearNz6{}: UNEXPECTED ERROR: The constraints are ill-defined.g@Œµx¯D)Úaxis)Úx)Úrcond)Úminimize)ÚBoundsr   ÚAÚlbÚub:NNNc                 ó\   <€ \         P                  ! V S,
          V S,
          4      ^,          # )é   )ÚnpÚdot©r   Úx0_cs   &€Úh/home/luca/screen-checking/.venv/lib/python3.14/site-packages/scipy/_external/pyprima/common/_project.pyÚ<lambda>Ú_project.<locals>.<lambda>¤   s   ø€ ¬"¯&ª&°°Tµ¸1¸t½8Ó*DÀqÖ*Hó    c                 ó   <€ V S,
          # )N© r   s   &€r   r   r   ¤   s   ø€ Ð_`ÐcgÖ_gr   )ÚjacÚboundsÚconstraintsr   ))Ú
isinstanceÚscalar_typesÚhasattrÚ
ValueErrorÚformatr   ÚasarrayÚfloat64ÚlenÚshapeÚsizeÚdictÚsetÚkeysr   ÚnanminÚnanmaxr   ÚallÚ
less_equalÚabsr   r   ÚepsÚmaxÚminr   ÚlinalgÚlstsqr   Úscipy.optimizer   r   ÚreshapeÚrangeÚconcatenateÚr_ÚgreaterÚanyÚ	not_equalÚImportError)Úx0r   r   r!   ÚinvokerÚlenx0Úlb_cÚub_cÚmax_conÚx_projÚaÚbÚxiÚ_r   ÚScipyBoundsÚScipyLinearConstraintr	   Úpc_args_ineqÚ
pc_args_eqÚiÚproject_constraintsÚax_ineqÚax_eqr   s   &&&&                    @r   Ú_projectrU      sÀ  ø€ ð@ €Gô �"”l×#Ò#Øˆt‰Ü	��Y×	Ò	Ø‰äÐG×NÑNÈwÓWÓXÐXðbÜ�zŠz˜$¤b§j¡jÔ1ˆô ˆ4�:‰:ƒ˜!ÔÜÐG×NÑNÈwÓWÓXÐXØ�I‰I€Eô �"”l×#Ò#Øˆt‰Ü	��Y×	Ò	Ø‰äÐG×NÑNÈwÓWÓXÐXðbÜ�zŠz˜$¤b§j¡jÔ1ˆô ˆ4�:‰:ƒ˜!Ô˜tŸy™y¨EÔ1ÜÐX×_Ñ_Ð`gÓhÓiÐiô �"”l×#Ò#Øˆt‰Ü	��Y×	Ò	Ø‰äÐG×NÑNÈwÓWÓXÐXðbÜ�zŠz˜$¤b§j¡jÔ1ˆô ˆ4�:‰:ƒ˜!Ô˜tŸy™y¨EÔ1ÜÐX×_Ñ_Ð`gÓhÓiÐiô �k¤4×(Ò(°(¸KÐ1HÌCÐP[×P`ÑP`ÓPbÓLcÔ1cÜ˜K¨Õ1Ô3C×DÒDÈÐT\ÕH]ÒHeäÐQ×XÑXÐY`ÓaÓbÐbà€Gð �8ÕÒ$ä—’œBŸIšI t¨T l¸Ô;¸TÐBÈÔKˆÜ Ô'Ð'Ü	ŒR�]Š]œ2Ÿ6š6 +¨hÕ"7×":Ñ":¸[ÈÕ=R×=UÑ=UÕ"UÓVÔX[Ó\×	]Ó	]Ü�FŠF�4‹L˜W˜HÔ$¬¯ª°«¸Ô)@ð ˜Õ!×#Ñ#ˆØ˜Õ"×%Ñ%¨°HÕ(=×(@Ñ(@Õ@ÀAÕEˆÜ—i‘i—o‘o a¬R¯VªV°A°t«_Õ)<ÀD�oÓI‰ˆˆAˆq�!ô —’œBŸIšI t¨b¥y°$Ð&7¸aÔ@À$ÐGÈaÔPˆä Ô'Ð'à�8ÕÓ(ð1	*å/Ý<ÝPà  Õ*ˆFô (,£v¬t«v˜*ˆLÜ13·²¸R¸DÓ1AÄ2Ç:Â:ÈrÈdÓCSÐ.ˆL˜Ñ˜z¨#™Ø ,¨SÕ 1× 9Ñ 9¸!¸V¿X¹X¿^¹^ÈAÕ=NÓ OˆL˜ÑØ(¨�o×5Ñ5°a¸¿¹¿¹ÈÕ9JÓKˆJ�s‰OÜ35·:²:¸b³>Ä2Ç:Â:ÈbÃ>Ð0ˆL˜Ñ 
¨4Ñ 0Ü35·:²:¸b³>Ä2Ç:Â:ÈbÃ>Ð0ˆL˜Ñ 
¨4Ñ 0ä˜6Ÿ9™9Ÿ>™>×*�Ø—9‘9˜Q•< 6§9¡9¨Q¥<Ô/Ü(*¯ª¸ÀSÕ8IÈ6Ï8É8ÐTUÐVWÐXYÕVYÐTYÐ[\ÐT\ÕK]Ð7^ÐefÔ(g�L Ñ%Ü)+¯©¨|¸DÕ/AÀ6Ç9Á9ÈQÅ<Ð/OÕ)P�L Ñ&Ü)+¯©¨|¸DÕ/AÀ6Ç9Á9ÈQÅ<Ð/OÕ)P�L Ó&ä&(§n¢n°jÀµoÀvÇxÁxÐPQÐRSÐTUÕRUÐPUÐWXÐPXÕGYÐ5ZÐabÔ&c�J˜s‘OÜ')§u¡u¨Z¸Õ-=¸v¿y¹yÈ½|Ð-KÕ'L�J˜tÑ$Ü')§u¡u¨Z¸Õ-=¸v¿y¹yÈ½|Ð-KÕ'L�J˜tÔ$ñ +ð ˜CÕ ×%Ñ%¨Ô)¨l¸4Õ.@×.EÑ.EÈÔ.IÈjÐY]ÕN^×NcÑNcÐfgÔNgÙ'<Ñ'L¸|Ñ'LÑNcÑNqÐfpÑNqÐ&rÑ#Ø˜cÕ"×'Ñ'¨!Ô+°¸TÕ0B×0GÑ0GÈ!Ô0KÙ&;Ñ&K¸lÑ&KÑ#Ø˜C•×%Ñ%¨Ô)Ù&;Ñ&I¸jÑ&IÑ#à&(Ð#ô —f’f˜\¨#Õ.°Ó5ˆGÜ—F’F˜: c�?¨DÓ1ˆEÜ�zŠz˜' <°Õ#5Ó6×:Ñ:×<Ò<ÄÇ
Â
È<ÐX\ÕK]Ð_fÓ@g×@kÑ@k×@mÒ@mÜ—L’L ¨
°4Õ(8Ó9×=Ñ=×?Ò?Ü—J’J˜t TÓ*×.Ñ.×0Ò0´B·J²J¸tÀTÓ4J×4NÑ4N×4PÒ4PÙÔ HÈ$ÔThÙ'2°4Ó'>ÐL_ôað aô &¨Ô-Ð-ô
 ˜DÔ!Ð!øôc ô bÜÐP×WÑWÐX_Ó`ÓaÐaðbûô ô bÜÐP×WÑWÐX_Ó`ÓaÐaðbûô ô bÜÐP×WÑWÐX_Ó`ÓaÐaðbûôb ô 	*Ü! DÔ)Ò)ð	*ús[   Á&e Ã>&e- Æ3&f ÑO=f? á1f? â	1f? â;*f? ã&*f? äf? ä,f? å&e*å-&fæ&f<æ?gçg)Ú__doc__Únumpyr   Ú_linear_constraintsr   r9   r   ÚintÚfloatÚgenericr#   Úfinfor(   r4   rU   r   r   r   Ú<module>r]      sE   ðñó Ý 1Ý )ð �U˜BŸJ™JÐ'€Ø‡h‚hˆr�z‰zÓ×Ñ€ô\"r   