The Wayback Machine - https://web.archive.org/web/20170621081654/http://ja.cppreference.com/w/cpp/numeric/valarray
名前空間
変種
操作

std::valarray

提供: cppreference.com
< cpp‎ | numeric

 
 
ニューメリックスライブラリ
一般的な数学関数
浮動小数点環境
複素数
数値配列
擬似乱数生成
コンパイル時有理数演算(C++11)
汎用の数値演算
Original:
Generic numeric operations
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
iota(C++11)
accumulate
inner_product
adjacent_difference
partial_sum
 
 
Defined in header <valarray>
template<class T >
class valarray;
std::valarray値の配列を表現し、操作するためのクラスです。これは、スライスと間接アクセス、要素単位の数学演算と一般添字演算子の様々な形式をサポートしています.
Original:
std::valarray is the class for representing and manipulating arrays of values. It supports element-wise mathematical operations and various forms of generalized subscript operators, slicing and indirect access.
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

目次

[編集]ノート

std::valarrayおよびヘルパークラスは、このようにこれらのクラスの操作は、Cプログラミング言語のキーワードrestrictの効果と似て最適化できるように、エイリアシングの特定の形態の自由になるように定義されています。また、valarrayの引数を取る関数と演算子は、それが可能なコンパイラはv1 = a*v2 + v3;た一時または複数のパスを避けて実行する1つのループのようなv1[i]= a*v2[i]+ v3[i];として発現を最適化するために作るためにプロキシオブジェクトを返すことが許可されています。しかし、式テンプレートはC + +のコンテナに同じ最適化手法を利用できるようにし、数値ライブラリの大半は、柔軟性のためvalarraysに式テンプレートを好む。いくつかは、C + +標準ライブラリの実装はstd::valarray(例えば、GNU libstdc + +がとLLVMのlibc + +)とごくまれvalarraysは、例えば、それ以上に最適化された上で効率的なオペレーションを実現するために、式テンプレートを使用Intel Parallel Studioの.
Original:
std::valarray and helper classes are defined to be free of certain forms of aliasing, thus allowing operations on these classes to be optimized similar to the effect of the keyword restrict in the C programming language. In addition, functions and operators that take valarray arguments are allowed to return proxy objects to make it possible for the compiler to optimize an expression such as v1 = a*v2 + v3; as a single loop that executes v1[i]= a*v2[i]+ v3[i]; avoiding any temporaries or multiple passes. However, 式テンプレート make the same optimization technique available for any C++ container, and the majority of numeric libraries prefer expression templates to valarrays for flexibility. Some C++ standard library implementations use expression templates to implement efficient operations on std::valarray (e.g. GNU libstdc++ and LLVM libc++), and only rarely valarrays are optimized any further, e.g. in Intel Parallel Studio.
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

[編集]メンバータイプ

メンバー·タイプ
Original:
Member type
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
Definition
value_typeT

[編集]メンバ関数

新しい数値配列を構築します
Original:
constructs new numeric array
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(パブリックメンバ関数)[edit]
数値配列を破棄します
Original:
destructs the numeric array
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(パブリックメンバ関数)[edit]
内容が割り当てられます
Original:
assigns the contents
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(パブリックメンバ関数)[edit]
valarrayの要素、スライス、またはマスクを設定/取得する
Original:
get/set valarray element, slice, or mask
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(パブリックメンバ関数)[edit]
valarrayの各要素に単項算術演算子が適用されます
Original:
applies a unary arithmetic operator to each element of the valarray
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(パブリックメンバ関数)[edit]
valarrayの各要素に複合代入演算子を適用します
Original:
applies compound assignment operator to each element of the valarray
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(パブリックメンバ関数)[edit]
別のvalarrayとスワップ
Original:
swaps with another valarray
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(パブリックメンバ関数)[edit]
valarrayのサイズを返します
Original:
returns the size of valarray
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(パブリックメンバ関数)[edit]
valarrayのサイズを変更します
Original:
changes the size of valarray
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(パブリックメンバ関数)[edit]
すべての要素の合計を計算します
Original:
calculates the sum of all elements
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(パブリックメンバ関数)[edit]
最小の要素を返します
Original:
returns the smallest element
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(パブリックメンバ関数)[edit]
最大の要素を返します
Original:
returns the largest element
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(パブリックメンバ関数)[edit]
valarrayの要素をシフトゼロフィリング
Original:
zero-filling shift the elements of the valarray
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(パブリックメンバ関数)[edit]
valarrayの要素を循環的にシフトした
Original:
circular shift of the elements of the valarray
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(パブリックメンバ関数)[edit]
applies a function to every element of a valarray
(パブリックメンバ関数)[edit]

[編集]非メンバ関数

std::swap()アルゴリズムを専門としています
Original:
specializes the std::swap() algorithm
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(関数テンプレート)[edit]
std::beginを専門としています
Original:
specializes std::begin
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(関数テンプレート)[edit]
std::endを専門としています
Original:
specializes std::end
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(関数テンプレート)[edit]
2 valarrays、またはのvalarrayと値の各要素に二項演算子を適用します
Original:
applies binary operators to each element of two valarrays, or a valarray and a value
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(関数テンプレート)[edit]
2 valarraysまたは値を持つvalarrayを比較します
Original:
compares two valarrays or a valarray with a value
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(関数テンプレート)[edit]
valarrayの各要素に関数を適用しstd::abs
Original:
applies the function std::abs to each element of valarray
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(関数テンプレート)[edit]
指数関数
Original:
Exponential functions
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
valarrayの各要素に関数を適用しstd::exp
Original:
applies the function std::exp to each element of valarray
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(関数テンプレート)[edit]
valarrayの各要素に関数を適用しstd::log
Original:
applies the function std::log to each element of valarray
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(関数テンプレート)[edit]
valarrayの各要素に関数を適用しstd::log10
Original:
applies the function std::log10 to each element of valarray
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(関数テンプレート)[edit]
電源機能
Original:
Power functions
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
2 valarraysまたはvalarrayは、値への関数std::powを適用します
Original:
applies the function std::pow to two valarrays or a valarray and a value
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(関数テンプレート)[edit]
valarrayの各要素に関数を適用しstd::sqrt
Original:
applies the function std::sqrt to each element of valarray
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(関数テンプレート)[edit]
三角関数
Original:
Trigonometric functions
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
valarrayの各要素に関数を適用しstd::sin
Original:
applies the function std::sin to each element of valarray
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(関数テンプレート)[edit]
valarrayの各要素に関数を適用しstd::cos
Original:
applies the function std::cos to each element of valarray
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(関数テンプレート)[edit]
valarrayの各要素に関数を適用しstd::tan
Original:
applies the function std::tan to each element of valarray
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(関数テンプレート)[edit]
valarrayの各要素に関数を適用しstd::asin
Original:
applies the function std::asin to each element of valarray
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(関数テンプレート)[edit]
valarrayの各要素に関数を適用しstd::acos
Original:
applies the function std::acos to each element of valarray
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(関数テンプレート)[edit]
valarrayの各要素に関数を適用しstd::atan
Original:
applies the function std::atan to each element of valarray
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(関数テンプレート)[edit]
valarrayは、値への関数std::atan2を適用します
Original:
applies the function std::atan2 to a valarray and a value
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(関数テンプレート)[edit]
双曲線関数
Original:
Hyperbolic functions
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
valarrayの各要素に関数を適用しstd::sinh
Original:
applies the function std::sinh to each element of valarray
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(関数テンプレート)[edit]
valarrayの各要素に関数を適用しstd::cosh
Original:
applies the function std::cosh to each element of valarray
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(関数テンプレート)[edit]
valarrayの各要素に関数を適用しstd::tanh
Original:
applies the function std::tanh to each element of valarray
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(関数テンプレート)[edit]

[編集]ヘルパークラス

BLASのようなvalarrayのスライス:開始インデックス、長さ、ストライド
Original:
BLAS-like slice of a valarray: starting index, length, stride
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(クラス)[edit]
スライスを適用した後のvalarrayのサブセットへのプロキシ
Original:
proxy to a subset of a valarray after applying a slice
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(クラステンプレート)[edit]
valarrayの一般的なスライス:開始インデックス、長さのセットは、ストライドのセット
Original:
generalized slice of a valarray: starting index, set of lengths, set of strides
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(クラス)[edit]
gsliceを適用した後のvalarrayのサブセットへのプロキシ
Original:
proxy to a subset of a valarray after applying a gslice
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(クラステンプレート)[edit]
ブールマスク演算子[]を適用した後のvalarrayのサブセットへのプロキシ
Original:
proxy to a subset of a valarray after applying a boolean mask operator[]
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(クラステンプレート)[edit]
間接演算子[]を適用した後のvalarrayのサブセットへのプロキシ
Original:
proxy to a subset of a valarray after applying indirect operator[]
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(クラステンプレート)[edit]
close