Maple für Professional
Maple für Akademiker
Maple für Studenten
Maple Personal Edition
Maple Player
Maple Player für iPad
MapleSim für Professional
MapleSim für Akademiker
Maple T.A. - Testen & beurteilen
Maple T.A. MAA Placement Test Suite
Möbius - Online-Courseware
Machine Design / Industrial Automation
Luft- und Raumfahrt
Fahrzeugtechnik
Robotics
Energiebranche
System Simulation and Analysis
Model development for HIL
Anlagenmodelle für den Regelungsentwurf
Robotics/Motion Control/Mechatronics
Other Application Areas
Mathematikausbildung
Technik
Allgemein- und berufsbildende Schulen
Testen und beurteilen
Studierende
Finanzmodelle
Betriebsforschung
Hochleistungsrechnen
Physik
Live-Webinare
Aufgezeichnete Webinare
Geplante Veranstaltungen
MaplePrimes
Maplesoft-Blog
Maplesoft-Mitgliedschaft
Maple Ambassador Program
MapleCloud
Technische Whitepapers
E-Mail Newsletters
Maple-Bücher
Math Matters
Anwendungs-Center
MapleSim Modell-Galerie
Anwenderberichte
Exploring Engineering Fundamentals
Lehrkonzepte mit Maple
Maplesoft Welcome-Center
Resource-Center für Lehrer
Help-Center für Studierende
StringTools[RegSplit] - split a string on a regular expression
Calling Sequence
RegSplit( pattern, text )
Parameters
pattern
-
string; regular expression
text
string; string to split
Description
The RegSplit(pattern, text) command splits a string text at substrings matching the regular expression pattern. The sequence of substrings of text that remain after substrings of text that match pattern have been elided is returned.
Splitting the empty string on any regular expression yields the expression sequence NULL.
If the regular expression pattern matches the empty string, an exception is raised.
Empty strings may result when adjacent matches to pattern occur within text. These can be removed as shown in the examples below.
Use StringTools[Split] to split a string at any of a set of characters. (See the examples, below.) Although this can be accomplished with RegSplit, StringTools[Split] is more efficient for this special case.
Examples
Error, (in StringTools:-RegSplit) empty string would match
You can remove unwanted empty strings as follows.
See Also
Regular_Expressions, string, StringTools, StringTools[RegMatch], StringTools[RegSubs], StringTools[Split]
Download Help Document