Maple Professional
Maple Academic
Maple Student Edition
Maple Personal Edition
Maple Player
Maple Player for iPad
MapleSim Professional
MapleSim Academic
Maple T.A. - Testing & Assessment
Maple T.A. MAA Placement Test Suite
Möbius - Online Courseware
Machine Design / Industrial Automation
Aerospace
Vehicle Engineering
Robotics
Power Industries
System Simulation and Analysis
Model development for HIL
Plant Modeling for Control Design
Robotics/Motion Control/Mechatronics
Other Application Areas
Mathematics Education
Engineering Education
High Schools & Two-Year Colleges
Testing & Assessment
Students
Financial Modeling
Operations Research
High Performance Computing
Physics
Live Webinars
Recorded Webinars
Upcoming Events
MaplePrimes
Maplesoft Blog
Maplesoft Membership
Maple Ambassador Program
MapleCloud
Technical Whitepapers
E-Mail Newsletters
Maple Books
Math Matters
Application Center
MapleSim Model Gallery
User Case Studies
Exploring Engineering Fundamentals
Teaching Concepts with Maple
Maplesoft Welcome Center
Teacher Resource Center
Student Help Center
集合とリスト
使い方
{es}
[es]
パラメータ
es - 式列
説明
集合はブレース括弧で囲まれた別個の式の順序のない並びで、数学の意味での集合を表します。Maple はその実装に便利な順序付けを用いるので、ユーザは式が特定の順序で保持されていると想定するべきではありません。
リストはかぎ括弧で囲まれた順序付けられた式の並びです。式の順序は es の順序です。
es は空であっても構いません。空集合は {} 空のリストは [] により表されます。
集合またはリストの要素は選択演算子により抽出することができます。したがって、S が集合かリストとすると、S の i 番目から j番目の要素は S[i..j] により得ることができます。負のセレクタを用いることもできます。-1 番目の要素は最後の要素、-2 番目の要素は最後から2番目の要素、等々を表します。
リストと集合は入れ子にすることができます。その場合選択は S[i][j]..[n] または S[i,j,..n] の2通りの方法で行うことができます。
要素 x をリスト L に追加するには [op(L),x] とします。要素 x を集合 S に挿入するには、和集合演算子 S union {x} を用います。
リスト L の i 番目の要素を x で置き換えるには、subsop(i=x,L) とします。リスト L の i 番目の要素を削除するには。subsop(i=NULL,L) とします。集合 S から要素 x を取り除くには、マイナス演算子 S minus {x} を用います。
例
{x,y,y};
{y,x,y};
[x,y,y];
[y,x,y];
L := [seq(x[i],i=1..4)];
L[2];
L := [op(L),x[5]];
L[-3..-2];
L := subsop(2=NULL,L);
L := [1,[2,3],[4,[5,6],7],8,9];
L[3,2,1];
L[3][2][1];
参照
type[set],in, type[list], selection, op, nops, union, intersect, minus, member, convert, seq
Download Help Document