<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/"><channel><title>Math on Lin's Blog</title><link>https://coder.tw/ja/tags/math/</link><description>Recent content in Math on Lin's Blog</description><generator>Hugo</generator><language>ja-JP</language><lastBuildDate>Sun, 24 Jul 2011 08:25:37 +0000</lastBuildDate><atom:link href="https://coder.tw/ja/tags/math/index.xml" rel="self" type="application/rss+xml"/><item><title>パスカル（巴斯卡）の三角形の公式解！（滄海さんに感謝）</title><link>https://coder.tw/ja/posts/pascal-triangle-formula-solution/</link><pubDate>Sun, 24 Jul 2011 08:25:37 +0000</pubDate><guid>https://coder.tw/ja/posts/pascal-triangle-formula-solution/</guid><description>&lt;p&gt;&lt;a href="https://pub-6c026d2742d14927bfa2d850c31eac91.r2.dev/wp-content/uploads/2011/07/210px-PascalTriangleAnimated2.gif"&gt;&lt;img title="210px-PascalTriangleAnimated2" src="https://pub-6c026d2742d14927bfa2d850c31eac91.r2.dev/wp-content/uploads/2011/07/210px-PascalTriangleAnimated2.gif" alt="" width="210" height="194" /&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;上の図はウィキペディアから引用したもので、パスカルの三角形を説明するためのものです。&lt;/p&gt;
&lt;p&gt;今回取り上げるのは、いわゆるパスカルの三角形です。楊輝三角形、賈憲三角形とも呼ばれています。一番上の行の最初の数字は「1」で、その下の数字は「左上と右上の数字の和」になります。左上または右上に数字がない場合は、0とみなします。たとえば2行目には「1、1」の2つの数字があり、3行目は「1、2、1」になります。この三角形は無限に広がっていきます。&lt;/p&gt;</description></item><item><title>10進数を2進数に変換する方法は？</title><link>https://coder.tw/ja/posts/decimal-to-binary-conversion/</link><pubDate>Sat, 16 Apr 2011 19:38:38 +0000</pubDate><guid>https://coder.tw/ja/posts/decimal-to-binary-conversion/</guid><description>&lt;p&gt;&lt;a href="https://pub-6c026d2742d14927bfa2d850c31eac91.r2.dev/wp-content/uploads/2011/04/2011-04-16_185412.jpg"&gt;&lt;img title="2011-04-16_185412" src="https://pub-6c026d2742d14927bfa2d850c31eac91.r2.dev/wp-content/uploads/2011/04/2011-04-16_185412.jpg" alt="" width="205" height="237" /&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;del&gt;この記事を書き終えたら、また「簡単すぎる」と言う人が出てくるでしょうね……&lt;/del&gt; さて本題に入ります。今週、プログラミングの授業で先生からクラス全員に出された課題は、10進数を2進数に変換する方法でした。数学的に計算するなら難しくありません。割り算の余りを取っていく短除法を使えばいいだけです。&lt;/p&gt;
&lt;p&gt;</description></item><item><title>【C++】べき乗と平方根の計算方法（sqrt、pow）</title><link>https://coder.tw/ja/posts/c-power-and-square-root-sqrt-pow/</link><pubDate>Fri, 18 Mar 2011 15:05:05 +0000</pubDate><guid>https://coder.tw/ja/posts/c-power-and-square-root-sqrt-pow/</guid><description>&lt;p&gt;&lt;a href="https://pub-6c026d2742d14927bfa2d850c31eac91.r2.dev/wp-content/uploads/2011/03/2011-03-18_151805.jpg"&gt;&lt;img class="alignnone size-large wp-image-367" title="2011-03-18_151805" src="https://pub-6c026d2742d14927bfa2d850c31eac91.r2.dev/wp-content/uploads/2011/03/2011-03-18_151805-540x380.jpg" alt="" width="540" height="380" /&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;一部のプログラミング言語では、^ 演算子を使って直接べき乗を計算できます。しかし、ある問題を解いているときに、C++ ではべき乗の計算に pow 関数を使う必要があることに気づきました。この記事では、2 つの関数を紹介します。1 つは べき乗を計算してくれる pow、もう 1 つは平方根を求めてくれる sqrt です。&lt;/p&gt;</description></item></channel></rss>