2017年2月14日火曜日

学習環境

数学読本〈4〉数列の極限,無限級数/順列・組合せ/確率/関数の極限と微分法(松坂 和夫(著)、岩波書店)の第14章(無限の世界への一歩 - 数列の極限、無限級数)、14.2(極限の計算)、無限等比数列{r^n}の極限、問19.を取り組んでみる。

問19


  1. a 1 > α a n > α a n+1 = 1 2 ( a n + α a n ) a n 2 α a n α a n a n+1 > a n · α a n >α a n > α a n a n+1 = a n 1 2 ( a n + α a n ) = 1 2 ( a n α a n ) = 1 2 a n ( a n 2 α ) >0 a n+1 α = 1 2 ( a n + α a n ) α = 1 2 a n ( a n 2 2 α a n +α ) = 1 2 a n ( a n α ) 2 a n+1 α < 1 2 α ( a n α ) 2 b n = a n α b n >0 b n+1 < 1 2 α b n 2 =2 α ( b n 2 α ) 2 n2 b n <2 α ( b 1 2 α ) 2 n 1 b 1 2 α = a 1 α 2 α a 1 <3 α b 1 2 α <1 lim n 0< lim n b n < lim n b 1 2 α b n =0 lim n a n = α

  2. α =
    n =
    a_1 =

コード(Emacs)

HTML5

α = <input id="alpha0" type="number" min="1" step="1" value="3">
<br>
n = <input id="n0" type="number" min="1" step="1" value="4">
<br>
a_1 = <input id="a0" type="number" min="0" step="1" value="2">
<div id="div0"></div>

<script src="sample19.js"></script>

コード(Emacs)

JavaScript

let input_a0 = document.querySelector('#a0'),
    input_alpha0 = document.querySelector('#alpha0'),
    input_n0 = document.querySelector('#n0'),
    inputs = [input_a0, input_alpha0, input_n0];    

let next = (a) => {
    let alpha = parseInt(input_alpha0.value, 10);
    
    return 1 / 2 * (a + alpha / a);
};

let output = () => {
    let a = parseInt(input_a0.value, 10),
        alpha = parseInt(input_alpha0.value, 10),
        n = parseInt(input_n0.value, 10),
        div0 = document.querySelector('#div0');

    div0.innerHTML = '';
    for (let i = 2; i <= n; i += 1) {
        a = next(a);
        div0.innerHTML += `a_${i} = ${a}<br>`;
    }
    div0.innerHTML += `Math.sqrt(${alpha}) = ${Math.sqrt(alpha)}`;
};

inputs.forEach((input) => input.onchange = output);

output();

0 コメント:

コメントを投稿

Comments on Google+: