2
0

複素平面できませんでした。「2024 秋田大学 前期【8】」をChatGPTとsympyでやってみたい。

Last updated at Posted at 2024-06-10

できませんでした。
 私は、複素平面がわかっていません。申し訳ありません。
 ???私の言い訳??? 私は、複素数の勉強開始予定です。

オリジナル

・T氏の数学日記 様

・大学入試数学問題集成 様>【8】テキスト

オリジナル様の方法で

・勉強中? 私はあきらめました。

ChatGPT-3.5先生へ

大学入試数学問題集成 様> 【3】テキスト

・ページのソースを表示です。MathMLです。
 省略しようと思いましたが、大学入試数学問題集成 様 の全文から必要部分の抜粋です。

<div class="refinfo">
<p>2024 秋田大学 前期</p></div>
<div class="refinfo2">
</div>
<div class="diff"><p>易□ 並□ 難□</p></div></div>
<div class="qbody">
<p class="slevel"><a name="q-0110" 
id="q-0110"></a><span 
class="qnum">【8】</span> 複素数平面において,<math>
<mi>i</mi><mspace width=".2em"></mspace>
</math>を虚数単位とするとき,次の問いに答えなさい.</p>
<p class="s1level">(&#8560;) <math>
<mrow><mi>z</mi><mo>+</mo><mi>i</mi><mo>&it;</mo><mover><mi>z</mi>
<mo>&OverBar;</mo></mover><mo>=</mo><mn>1</mn><mo>+</mo>
<mi>i</mi></mrow><mspace width=".2em"></mspace>
</math>を満たす複素数<math>
<mspace width=".2em"></mspace><mi>z</mi><mspace width=".2em"></mspace>
</math>の全体の集合と<math>
<mspace width=".2em"></mspace><mrow><mo rspace=".2em">|</mo><mi>z</mi>
<mo lspace=".2em">|</mo><mo>=</mo><mo rspace=".2em">|</mo><mi>z</mi>
<mo>-</mo><mi>&alpha;</mi><mo lspace=".2em" rspace=".2em">|</mo></mrow>
</math>を満たす複素数<math>
<mspace width=".2em"></mspace><mi>z</mi><mspace width=".2em"></mspace>
</math>の全体の集合が等しいとき,複素数<math>
<mspace width=".2em"></mspace><mi>&alpha;</mi><mspace width=".2em"></mspace>
</math>を求めなさい.</p>
<p class="s1level">(&#8561;) 複素数<math>
<mspace width=".2em"></mspace><mi>z</mi><mspace width=".2em"></mspace>
</math>が<math>
<mspace width=".2em"></mspace><mrow><mi>z</mi><mo>+</mo><mi>i</mi><mo>&it;</mo>
<mover><mi>z</mi><mo>&OverBar;</mo></mover><mo>=</mo><mn>1</mn><mo>+</mo>
<mi>i</mi></mrow><mspace width=".2em"></mspace>
</math>を満たすとき,<math>
<mn>3</mn><mspace width=".2em"></mspace>
</math>点<math>
<mspace width=".2em"></mspace><mrow><mn>0</mn><mspace width=".2em"></mspace>
<mtext>,</mtext></mrow>
</math><math>
<mrow><mstyle displaystyle="true"><mfrac><mn>1</mn><mi>z</mi></mfrac></mstyle>
<mspace width=".2em"></mspace><mtext>,</mtext></mrow>
</math><math>
<mstyle displaystyle="true"><mfrac><mrow><mn>1</mn><mo>+</mo><msqrt><mn>3</mn>
</msqrt><mo>&it;</mo><mi>i</mi></mrow><mrow><mn>2</mn><mo>&it;</mo>
<mi>z</mi></mrow></mfrac></mstyle><mspace width=".2em"></mspace>
</math>がつくる三角形の面積の最大値を求めなさい.</p>
<p class="s1level">(&#8562;) 複素数<math>
<mspace width=".2em"></mspace><mi>z</mi><mspace width=".2em"></mspace>
</math>が<math>
<mspace width=".2em"></mspace><mrow><mi>z</mi><mo>+</mo><mi>i</mi><mo>&it;</mo>
<mover><mi>z</mi><mo>&OverBar;</mo></mover><mo>=</mo><mn>1</mn><mo>+</mo>
<mi>i</mi></mrow><mspace width=".2em"></mspace>
</math>を満たすとき,<math>
<mn>3</mn><mspace width=".2em"></mspace>
</math>点<math>
<mspace width=".2em"></mspace><mrow><mn>3</mn><mspace width=".2em"></mspace>
<mtext>,</mtext></mrow>
</math><math>
<mrow><mstyle displaystyle="true"><mfrac><mn>1</mn><mi>z</mi></mfrac></mstyle>
<mspace width=".2em"></mspace><mtext>,</mtext></mrow>
</math><math>
<mrow><mstyle displaystyle="true"><mfrac><mn>1</mn><mi>z</mi></mfrac></mstyle>
<mo>+</mo><mn>1</mn><mo>+</mo><mi>i</mi></mrow><mspace width=".2em"></mspace>
</math>がつくる三角形の面積の最小値を求めなさい.
</p>
</div>
</div>
日本語で。
詳しい回答で

???あきらめました。

ChatGPT-3.5先生へ。sympyで

sympyのソースコードをお願いします。
from sympy import symbols, Eq, solve, I, sqrt, Abs, simplify, nsimplify, expand, re, im, conjugate, N
from sympy.geometry import Triangle, Point

# Define symbols
z = symbols('z')
alpha = symbols('alpha')

# Equation 1: z + conjugate(z) = 1 + I
eq1 = Eq(z + conjugate(z), 1 + I)

# Solve for z
z_sol = solve(eq1, z)
z_value = z_sol[0]  # Only one solution

# Equation 2: |z| = |z - alpha|
eq2 = Eq(Abs(z), Abs(z - alpha))

# Solve for alpha
alpha_sol = solve(eq2, alpha)
alpha_value = alpha_sol[0]  # Only one solution

# Equation 3: z + conjugate(z) = 1 + I
eq3 = eq1

# Points for triangle calculation
point1 = Point(0, 0)
point2 = Point(1 / z_value, 0)
point3 = Point((1 + sqrt(3)*I) / (2*z_value), 0)

# Calculate area of triangle
triangle = Triangle(point1, point2, point3)
area_max = triangle.area.evalf()  # Maximum area

# Points for minimum area triangle
point1_min = Point(3, 0)
point2_min = Point(1 / z_value, 0)
point3_min = Point(1 / z_value + 1 + I, 0)

# Calculate area of minimum triangle
triangle_min = Triangle(point1_min, point2_min, point3_min)
area_min = triangle_min.area.evalf()  # Minimum area

# Output results
print(f"alpha = {alpha_value}")
print(f"Maximum area of triangle: {area_max}")
print(f"Minimum area of triangle: {area_min}")

結果もお願いします

申し訳ありませんが、具体的な数値や解析結果を示すことはできません。...

vscodeで、エラー

    z_value = z_sol[0]  # Only one solution
              ~~~~~^^^
IndexError: list index out of range

私は、アキラメました。

いつもの? sympyの実行環境と 参考のおすすめです。

(テンプレート)

いつもと違うおすすめです。

2
0
1

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
2
0