NumeRe v1.1.4
NumeRe: Framework für Numerische Rechnungen
|
#include "../datamanagement/memorymanager.hpp"
#include "../ParserLib/muParser.h"
#include "../settings.hpp"
#include "../commandlineparser.hpp"
#include "define.hpp"
#include <string>
#include <vector>
Go to the source code of this file.
Functions | |
bool | integrate (CommandLineParser &cmdParser) |
Calculate the integral of a function or a data set in a single dimension. More... | |
bool | integrate2d (CommandLineParser &cmdParser) |
Calculate the integral of a function in two dimensions. More... | |
bool | differentiate (CommandLineParser &cmdParser) |
Calculate the numerical differential of the passed expression or data set. More... | |
bool | findExtrema (CommandLineParser &cmdParser) |
This function is a wrapper to the actual extrema localisation function localizeExtremum() further below. More... | |
bool | findZeroes (CommandLineParser &cmdParser) |
This function is a wrapper to the actual zeros localisation function localizeZero() further below. More... | |
void | taylor (CommandLineParser &cmdParser) |
This function approximates the passed expression using Taylor's method. More... | |
bool | fitDataSet (std::string &sCmd, mu::Parser &_parser, MemoryManager &_data, FunctionDefinitionManager &_functions, const Settings &_option) |
bool | fastFourierTransform (CommandLineParser &cmdParser) |
This function calculates the fast fourier transform of the passed data set. More... | |
bool | fastWaveletTransform (CommandLineParser &cmdParser) |
This function calculates the fast wavelet transform of the passed data set. More... | |
bool | evalPoints (CommandLineParser &cmdParser) |
This function samples a defined expression in an array of discrete values. More... | |
bool | createDatagrid (CommandLineParser &cmdParser) |
This function calculates a datagrid from passed functions or (x-y-z) data values. More... | |
bool | writeAudioFile (CommandLineParser &cmdParser) |
This function creates a WAVE file from the selected data set. More... | |
bool | readAudioFile (CommandLineParser &cmdParser) |
Reads either the audio file meta information or the whole audio file to memory. More... | |
bool | seekInAudioFile (CommandLineParser &cmdParser) |
Seek a position in an audiofile and extract a length of samples from it. More... | |
bool | regularizeDataSet (CommandLineParser &cmdParser) |
This function regularizes the samples of a defined x-y-data array such that DeltaX is equal for every x. More... | |
bool | analyzePulse (CommandLineParser &cmdParser) |
This function performs a pulse analysis on the selected data set. More... | |
bool | shortTimeFourierAnalysis (CommandLineParser &cmdParser) |
This function performs the short-time fourier analysis on the passed data set. More... | |
void | boneDetection (CommandLineParser &cmdParser) |
This function is the implementation of the detect command. More... | |
bool | calculateSplines (CommandLineParser &cmdParser) |
This function approximates the passed data set using cubic splines. More... | |
void | rotateTable (CommandLineParser &cmdParser) |
This function rotates a table, an image or a datagrid around a specified angle. More... | |
void | particleSwarmOptimizer (CommandLineParser &cmdParser) |
This function implements a particle swarm optimizer in up to four dimensions (depending on the number of intervals defined). The optimizer has an adaptive velocity part, reducing the overall position variation of the particles over time. More... | |
void | urlExecute (CommandLineParser &cmdParser) |
This function implements the url command providing an interface to http(s) and (s)ftp URLs. More... | |
bool analyzePulse | ( | CommandLineParser & | cmdParser | ) |
This function performs a pulse analysis on the selected data set.
cmdParser | CommandLineParser& |
The function calculates the maximal amplitude, its position, the FWHM, the width near the maximal amplitude (which is different from the FWHM) and the energy in the pulse.
Definition at line 3915 of file command_implementations.cpp.
References _lang, extractRange(), Language::get(), CommandLineParser::getCommandLine(), DataAccessParser::getDataObject(), CommandLineParser::getExprAsDataObject(), NumeReKernel::getInstance(), make_hline(), VectorIndex::OPEN_END, NumeReKernel::print(), NumeReKernel::printPreFmt(), CommandLineParser::setReturnValue(), SyntaxError::TABLE_DOESNT_EXIST, NumeReKernel::toggleTableStatus(), toString(), and toUpperCase().
Referenced by cmd_pulse().
void boneDetection | ( | CommandLineParser & | cmdParser | ) |
This function is the implementation of the detect command.
cmdParser | CommandLineParser& |
Definition at line 4133 of file command_implementations.cpp.
References _lang, Indices::col, extractRange(), VectorIndex::front(), Language::get(), MemoryManager::getAppendedZeroes(), CommandLineParser::getCommandLine(), DataAccessParser::getDataObject(), MemoryManager::getElement(), CommandLineParser::getExprAsDataObject(), DataAccessParser::getIndices(), NumeReKernel::getInstance(), MemoryManager::getLines(), NumeReKernel::getMemoryManager(), CommandLineParser::getParameterValueAsNumericalValue(), CommandLineParser::getTargetTable(), interpolateToGrid(), mu::isnan(), VectorIndex::isOpenEnd(), min, VectorIndex::OPEN_END, NumeReKernel::print(), mu::real(), Indices::row, MemoryManager::setHeadLineElement(), VectorIndex::setOpenEndIndex(), VectorIndex::setRange(), VectorIndex::size(), VectorIndex::subidx(), SyntaxError::TABLE_DOESNT_EXIST, and MemoryManager::writeToTable().
Referenced by cmd_detect().
bool calculateSplines | ( | CommandLineParser & | cmdParser | ) |
This function approximates the passed data set using cubic splines.
cmdParser | CommandLineParser& |
The calculated spline polynomials are defined as new custom functions.
Definition at line 4253 of file command_implementations.cpp.
References _lang, NumeReKernel::bSupressAnswer, FunctionDefinitionManager::defineFunc(), extractRange(), Language::get(), CommandLineParser::getCommandLine(), DataAccessParser::getDataObject(), NumeReKernel::getDefinitions(), CommandLineParser::getExprAsDataObject(), NumeReKernel::getInstance(), NumeReKernel::getSettings(), FunctionDefinitionManager::isDefined(), NumeReKernel::issueWarning(), NumeReKernel::print(), Settings::systemPrints(), SyntaxError::TABLE_DOESNT_EXIST, SyntaxError::TOO_FEW_DATAPOINTS, and toString().
Referenced by cmd_spline().
bool createDatagrid | ( | CommandLineParser & | cmdParser | ) |
This function calculates a datagrid from passed functions or (x-y-z) data values.
cmdParser | CommandLineParser& |
Definition at line 3312 of file command_implementations.cpp.
References _defVars, date::abs(), CommandLineParser::clearReturnValue(), Indices::col, mu::ParserBase::Eval(), expandVectorToDatagrid(), CommandLineParser::exprContainsDataObjects(), VectorIndex::front(), MemoryManager::getColElements(), MemoryManager::getCols(), CommandLineParser::getCommandLine(), DataAccessParser::getDataObject(), MemoryManager::getElement(), CommandLineParser::getExprAsDataObject(), CommandLineParser::getExprAsMathExpression(), DataAccessParser::getIndices(), NumeReKernel::getInstance(), NumeReKernel::getMemoryManager(), CommandLineParser::getParameterValueAsNumericalValue(), NumeReKernel::getParser(), getSamplesForDatagrid(), CommandLineParser::getTargetTable(), CommandLineParser::hasParam(), intCast(), IntervalSet::intervals, VectorIndex::INVALID, SyntaxError::INVALID_INDEX, SyntaxError::invalid_position, DataAccessParser::isCluster(), VectorIndex::isOpenEnd(), isValidIndexSet(), CommandLineParser::parseIntervals(), Indices::row, mu::ParserBase::SetExpr(), MemoryManager::setHeadLineElement(), VectorIndex::setRange(), CommandLineParser::setReturnValue(), IntervalSet::size(), VectorIndex::size(), VectorIndex::subidx(), SyntaxError::TABLE_DOESNT_EXIST, VectorIndex::to_string(), SyntaxError::TOO_FEW_DATAPOINTS, toString(), DefaultVariables::vValue, and MemoryManager::writeToTable().
Referenced by cmd_datagrid().
bool differentiate | ( | CommandLineParser & | cmdParser | ) |
Calculate the numerical differential of the passed expression or data set.
cmdParser | CommandLineParser |
Definition at line 754 of file command_implementations.cpp.
References _lang, date::abs(), NumeRe::SavitzkyGolayDiffFilter::apply(), FunctionDefinitionManager::call(), Indices::col, MemoryManager::containsTablesOrClusters(), mu::Parser::Diff(), mu::ParserBase::Eval(), VectorIndex::front(), SyntaxError::FUNCTION_ERROR, Language::get(), CommandLineParser::getCommandLine(), getDataElements(), DataAccessParser::getDataObject(), NumeReKernel::getDefinitions(), MemoryManager::getElement(), CommandLineParser::getExprAsDataObject(), CommandLineParser::getExprAsMathExpression(), DataAccessParser::getIndices(), NumeReKernel::getInstance(), MemoryManager::getLines(), getMatchingParenthesis(), NumeReKernel::getMemoryManager(), getNextArgument(), CommandLineParser::getParameterList(), CommandLineParser::getParameterValueAsNumericalValue(), NumeReKernel::getParser(), getPointerToVariable(), NumeReKernel::getSettings(), CommandLineParser::hasParam(), intCast(), intPower(), SyntaxError::INVALID_INDEX, SyntaxError::invalid_position, mu::isinf(), mu::isnan(), isNotEmptyExpression(), VectorIndex::isOpenEnd(), NumeReKernel::issueWarning(), MemoryManager::isValidElement(), isValidIndexSet(), min, SyntaxError::NO_DIFF_OPTIONS, SyntaxError::NO_DIFF_VAR, Indices::row, mu::ParserBase::SetExpr(), VectorIndex::setRange(), CommandLineParser::setReturnValue(), VectorIndex::size(), MemoryManager::sortElements(), SyntaxError::STRINGS_MAY_NOT_BE_EVALUATED_WITH_CMD, StripSpaces(), VectorIndex::to_string(), and MemoryManager::writeToTable().
Referenced by cmd_diff().
bool evalPoints | ( | CommandLineParser & | cmdParser | ) |
This function samples a defined expression in an array of discrete values.
cmdParser | CommandLineParser& |
Definition at line 3175 of file command_implementations.cpp.
References MemoryManager::containsTablesOrClusters(), convertVectorToExpression(), mu::ParserBase::Eval(), SyntaxError::EVAL_VAR_NOT_FOUND, getAllIndices(), CommandLineParser::getAllParametersWithValues(), CommandLineParser::getCommandLine(), getDataElements(), CommandLineParser::getExprAsMathExpression(), NumeReKernel::getInstance(), NumeReKernel::getMemoryManager(), CommandLineParser::getParameterList(), CommandLineParser::getParameterValue(), CommandLineParser::getParameterValueAsNumericalValue(), NumeReKernel::getParser(), getPointerToVariable(), CommandLineParser::hasParam(), intCast(), IntervalSet::intervals, SyntaxError::invalid_position, mu::isinf(), mu::isnan(), isNotEmptyExpression(), min, CommandLineParser::parseIntervals(), mu::real(), mu::ParserBase::SetExpr(), CommandLineParser::setReturnValue(), IntervalSet::size(), and SyntaxError::WRONG_PLOT_INTERVAL_FOR_LOGSCALE.
Referenced by cmd_eval().
bool fastFourierTransform | ( | CommandLineParser & | cmdParser | ) |
This function calculates the fast fourier transform of the passed data set.
cmdParser | CommandLineParser& |
The user may switch between complex or phase- amplitude layout and whether an inverse transform shall be calculated.
Definition at line 2855 of file command_implementations.cpp.
References _lang, FFTData::bComplex, FFTData::bInverseTrafo, FFTData::bShiftAxis, calculate1dFFT(), calculate2dFFT(), FFTData::cols, FFTData::dFrequencyOffset, FFTData::dNyquistFrequency, FFTData::dTimeInterval, extractRange(), Language::get(), CommandLineParser::getCommand(), CommandLineParser::getCommandLine(), DataAccessParser::getDataObject(), CommandLineParser::getExpr(), CommandLineParser::getExprAsDataObject(), NumeReKernel::getInstance(), NumeReKernel::getMemoryManager(), NumeReKernel::getSettings(), getShiftedAxis(), CommandLineParser::getTargetTable(), CommandLineParser::hasParam(), mu::isnan(), LineBreak(), FFTData::lines, VectorIndex::OPEN_END, NumeReKernel::printPreFmt(), mu::real(), Settings::systemPrints(), SyntaxError::TABLE_DOESNT_EXIST, toString(), toSystemCodePage(), and SyntaxError::WRONG_DATA_SIZE.
Referenced by cmd_fft().
bool fastWaveletTransform | ( | CommandLineParser & | cmdParser | ) |
This function calculates the fast wavelet transform of the passed data set.
cmdParser | CommandLineParser& |
The user may select the wavelet type from a predefined set of wavelets and determine, whether an inverse transform shall be calculated.
Definition at line 3003 of file command_implementations.cpp.
References _lang, BSpline, calculateWavelet(), CenteredBSpline, CenteredDaubechies, CenteredHaar, Indices::col, Daubechies, decodeWaveletData(), extractRange(), VectorIndex::front(), Language::get(), NumeRe::Table::getCols(), CommandLineParser::getCommandLine(), DataAccessParser::getDataObject(), CommandLineParser::getExprAsDataObject(), NumeReKernel::getInstance(), NumeRe::Table::getLines(), NumeReKernel::getMemoryManager(), CommandLineParser::getParameterValue(), CommandLineParser::getParameterValueAsNumericalValue(), NumeReKernel::getSettings(), CommandLineParser::getTargetTable(), NumeRe::Table::getValue(), Haar, CommandLineParser::hasParam(), intCast(), VectorIndex::INVALID, VectorIndex::isOpenEnd(), LineBreak(), NumeReKernel::printPreFmt(), Indices::row, MemoryManager::setHeadLineElement(), VectorIndex::setRange(), Settings::systemPrints(), SyntaxError::TABLE_DOESNT_EXIST, toSystemCodePage(), and MemoryManager::writeToTable().
Referenced by cmd_fwt().
bool findExtrema | ( | CommandLineParser & | cmdParser | ) |
This function is a wrapper to the actual extrema localisation function localizeExtremum() further below.
cmdParser | CommandLineParser& |
Definition at line 1398 of file command_implementations.cpp.
References date::abs(), FunctionDefinitionManager::call(), MemoryManager::containsTablesOrClusters(), mu::Parser::Diff(), mu::ParserBase::Eval(), CommandLineParser::exprContainsDataObjects(), SyntaxError::EXTREMA_VAR_NOT_FOUND, findCommand(), findExtremaInData(), findExtremaInMultiResult(), findParameter(), findVariableInExpression(), getAllIndices(), getArgAtPos(), CommandLineParser::getCommandLine(), getDataElements(), NumeReKernel::getDefinitions(), CommandLineParser::getExpr(), NumeReKernel::getInstance(), getIntervalForSearchFunctions(), NumeReKernel::getMemoryManager(), CommandLineParser::getParameterList(), NumeReKernel::getParser(), getPointerToVariable(), Settings::getPrecision(), NumeReKernel::getSettings(), NumeReKernel::getStringParser(), intCast(), SyntaxError::invalid_position, mu::isinf(), mu::isnan(), isNotEmptyExpression(), NumeRe::StringParser::isStringExpression(), localizeExtremum(), SyntaxError::NO_EXTREMA_OPTIONS, SyntaxError::NO_EXTREMA_VAR, mu::real(), mu::ParserBase::SetExpr(), CommandLineParser::setReturnValue(), SyntaxError::STRINGS_MAY_NOT_BE_EVALUATED_WITH_CMD, StripSpaces(), and toString().
Referenced by cmd_extrema().
bool findZeroes | ( | CommandLineParser & | cmdParser | ) |
This function is a wrapper to the actual zeros localisation function localizeZero() further below.
cmdParser | CommandLineParser& |
Definition at line 1859 of file command_implementations.cpp.
References date::abs(), FunctionDefinitionManager::call(), MemoryManager::containsTablesOrClusters(), mu::ParserBase::Eval(), CommandLineParser::exprContainsDataObjects(), findParameter(), findVariableInExpression(), findZeroesInData(), findZeroesInMultiResult(), getAllIndices(), getArgAtPos(), CommandLineParser::getCommandLine(), getDataElements(), NumeReKernel::getDefinitions(), CommandLineParser::getExpr(), NumeReKernel::getInstance(), getIntervalForSearchFunctions(), NumeReKernel::getMemoryManager(), CommandLineParser::getParameterList(), NumeReKernel::getParser(), getPointerToVariable(), NumeReKernel::getSettings(), NumeReKernel::getStringParser(), intCast(), SyntaxError::invalid_position, mu::isinf(), mu::isnan(), isNotEmptyExpression(), NumeRe::StringParser::isStringExpression(), localizeExtremum(), localizeZero(), SyntaxError::NO_ZEROES_OPTIONS, SyntaxError::NO_ZEROES_VAR, mu::real(), mu::ParserBase::SetExpr(), CommandLineParser::setReturnValue(), SyntaxError::STRINGS_MAY_NOT_BE_EVALUATED_WITH_CMD, StripSpaces(), and SyntaxError::ZEROES_VAR_NOT_FOUND.
Referenced by cmd_zeroes().
bool fitDataSet | ( | std::string & | sCmd, |
mu::Parser & | _parser, | ||
MemoryManager & | _data, | ||
FunctionDefinitionManager & | _functions, | ||
const Settings & | _option | ||
) |
Definition at line 73 of file fitting.cpp.
References _lang, applyFitAlgorithm(), FittingData::b1DChiMap, FittingData::bNoParams, FittingData::bSaveErrors, FittingData::bUseErrors, calculateChiMap(), calculateCovarianceData(), calculatePercentageAvgAndCreateParserVariables(), SyntaxError::CANNOT_BE_A_FITTING_PARAM, SyntaxError::CANNOT_OPEN_FITLOG, constructCovarianceMatrix(), MemoryManager::containsTablesOrClusters(), createTeXExport(), FunctionDefinitionManager::defineFunc(), FittingData::dPrecision, mu::ParserBase::Eval(), evaluateFittingParams(), findCommand(), SyntaxError::FITFUNC_NOT_CONTAINS, Language::get(), Fitcontroller::getCovarianceMatrix(), getDataForFit(), FunctionDefinitionManager::getDefinitionString(), getFitAnalysis(), Fitcontroller::getFitChi(), Fitcontroller::getFitFunction(), getFitOptionsTable(), getFittingParameters(), FunctionDefinitionManager::getFunctionIndex(), getParameterTable(), getTimeStamp(), mu::ParserBase::GetUsedVar(), Settings::getWindow(), IntervalSet::intervals, SyntaxError::invalid_position, FunctionDefinitionManager::isDefined(), NumeReKernel::issueWarning(), FittingData::ivl, LineBreak(), make_hline(), FittingData::nDim, FittingData::nFitVars, FittingData::nMaxIterations, SyntaxError::NO_DATA_FOR_FIT, SyntaxError::NO_PARAMS_FOR_FIT, SyntaxError::OVERFITTING_ERROR, NumeReKernel::print(), NumeReKernel::printPreFmt(), reduceLogFilesize(), removeObsoleteParentheses(), FittingData::restricted, FittingData::sChiMap, FittingData::sChiMap_Vars, mu::ParserBase::SetExpr(), FittingData::sFitFunction, FittingData::sParams, FittingData::sRestrictions, strfill(), StripSpaces(), Settings::systemPrints(), NumeReKernel::toggleTableStatus(), toSystemCodePage(), toUpperCase(), FileSystem::ValidFileName(), FittingData::vx, FittingData::vy, FittingData::vz, and FittingData::vz_w.
Referenced by cmd_fit().
bool integrate | ( | CommandLineParser & | cmdParser | ) |
Calculate the integral of a function or a data set in a single dimension.
cmdParser | CommandLineParser& |
Definition at line 272 of file command_implementations.cpp.
References _defVars, _lang, date::abs(), mu::ParserBase::Eval(), Language::get(), NumeReKernel::GetAsyncCancelState(), CommandLineParser::getCommandLine(), CommandLineParser::getExprAsMathExpression(), NumeReKernel::getInstance(), getMatchingParenthesis(), NumeReKernel::getMemoryManager(), CommandLineParser::getParameterValue(), CommandLineParser::getParameterValueAsNumericalValue(), NumeReKernel::getParser(), NumeReKernel::getSettings(), CommandLineParser::hasParam(), intCast(), integrateSingleDimensionData(), integrationstep_simpson(), integrationstep_trapezoidal(), SyntaxError::INVALID_INTEGRATION_PRECISION, SyntaxError::INVALID_INTEGRATION_RANGES, SyntaxError::invalid_position, mu::isinf(), mu::isnan(), MemoryManager::isTable(), max, min, SyntaxError::NO_INTEGRATION_FUNCTION, SyntaxError::NO_INTEGRATION_RANGES, CommandLineParser::parseIntervals(), NumeReKernel::printPreFmt(), SyntaxError::PROCESS_ABORTED_BY_USER, mu::rint(), mu::ParserBase::SetExpr(), CommandLineParser::setReturnValue(), SIMPSON, IntervalSet::size(), SyntaxError::STRINGS_MAY_NOT_BE_EVALUATED_WITH_CMD, Settings::systemPrints(), toString(), TRAPEZOIDAL, and DefaultVariables::vValue.
Referenced by cmd_integrate().
bool integrate2d | ( | CommandLineParser & | cmdParser | ) |
Calculate the integral of a function in two dimensions.
cmdParser | CommandLineParser& |
Definition at line 481 of file command_implementations.cpp.
References _defVars, _lang, date::abs(), mu::ParserBase::Eval(), Language::get(), NumeReKernel::GetAsyncCancelState(), CommandLineParser::getCommandLine(), CommandLineParser::getExprAsMathExpression(), NumeReKernel::getInstance(), CommandLineParser::getParameterValue(), CommandLineParser::getParameterValueAsNumericalValue(), NumeReKernel::getParser(), NumeReKernel::getSettings(), intCast(), integrationstep_simpson(), integrationstep_trapezoidal(), IntervalSet::intervals, SyntaxError::INVALID_INTEGRATION_PRECISION, SyntaxError::INVALID_INTEGRATION_RANGES, SyntaxError::invalid_position, mu::isinf(), mu::isnan(), max, min, SyntaxError::NO_INTEGRATION_FUNCTION, SyntaxError::NO_INTEGRATION_RANGES, CommandLineParser::parseIntervals(), NumeReKernel::printPreFmt(), SyntaxError::PROCESS_ABORTED_BY_USER, refreshBoundaries(), mu::rint(), mu::ParserBase::SetExpr(), CommandLineParser::setReturnValue(), SIMPSON, DefaultVariables::sName, SyntaxError::STRINGS_MAY_NOT_BE_EVALUATED_WITH_CMD, Settings::systemPrints(), toString(), TRAPEZOIDAL, and DefaultVariables::vValue.
Referenced by cmd_integrate().
void particleSwarmOptimizer | ( | CommandLineParser & | cmdParser | ) |
This function implements a particle swarm optimizer in up to four dimensions (depending on the number of intervals defined). The optimizer has an adaptive velocity part, reducing the overall position variation of the particles over time.
cmdParser | CommandLineParser& |
Definition at line 4547 of file command_implementations.cpp.
References _defVars, mu::ParserBase::Eval(), CommandLineParser::getExprAsMathExpression(), NumeReKernel::getInstance(), CommandLineParser::getParameterValueAsNumericalValue(), NumeReKernel::getParser(), intCast(), IntervalSet::intervals, max, min, CommandLineParser::parseIntervals(), parser_Random(), mu::real(), mu::ParserBase::SetExpr(), CommandLineParser::setReturnValue(), IntervalSet::size(), and DefaultVariables::vValue.
Referenced by cmd_pso().
bool readAudioFile | ( | CommandLineParser & | cmdParser | ) |
Reads either the audio file meta information or the whole audio file to memory.
cmdParser | CommandLineParser& |
Definition at line 3690 of file command_implementations.cpp.
References Indices::col, VectorIndex::front(), g_logger, Audio::getAudioFileByType(), CommandLineParser::getExprAsFileName(), NumeReKernel::getInstance(), NumeReKernel::getMemoryManager(), MemoryManager::getTable(), CommandLineParser::getTargetTable(), DetachedLogger::info(), Audio::Sample::leftOrMono, Memory::markModified(), VectorIndex::max(), VectorIndex::min(), MemoryManager::resizeTable(), Audio::Sample::right, Indices::row, CommandLineParser::setReturnValue(), VectorIndex::size(), VectorIndex::subidx(), Memory::writeData(), and Memory::writeDataDirectUnsafe().
Referenced by cmd_audioread().
bool regularizeDataSet | ( | CommandLineParser & | cmdParser | ) |
This function regularizes the samples of a defined x-y-data array such that DeltaX is equal for every x.
CommandLineParser& | cmdParser |
Definition at line 3851 of file command_implementations.cpp.
References extractRange(), MemoryManager::getCols(), CommandLineParser::getCommandLine(), DataAccessParser::getDataObject(), CommandLineParser::getExprAsDataObject(), NumeReKernel::getInstance(), NumeReKernel::getMemoryManager(), CommandLineParser::getParameterValueAsNumericalValue(), intCast(), VectorIndex::OPEN_END, mu::real(), MemoryManager::setHeadLineElement(), SyntaxError::TABLE_DOESNT_EXIST, and MemoryManager::writeToTable().
Referenced by cmd_regularize().
void rotateTable | ( | CommandLineParser & | cmdParser | ) |
This function rotates a table, an image or a datagrid around a specified angle.
cmdParser | CommandLineParser& |
Definition at line 4336 of file command_implementations.cpp.
References _lang, date::ceil(), Indices::col, DetachedLogger::debug(), Memory::extractRange(), g_logger, Language::get(), Memory::getCols(), MemoryManager::getCols(), CommandLineParser::getCommand(), DataAccessParser::getDataObject(), MemoryManager::getElement(), CommandLineParser::getExprAsDataObject(), DataAccessParser::getIndices(), NumeReKernel::getInstance(), Memory::getLines(), MemoryManager::getLines(), NumeReKernel::getMemoryManager(), CommandLineParser::getParameterValueAsNumericalValue(), MemoryManager::getTable(), CommandLineParser::getTargetTable(), interpolateToGrid(), mu::isnan(), NumeReKernel::issueWarning(), M_PI, Memory::markModified(), VectorIndex::max(), max, min, NumeReKernel::print(), Memory::readMemInterpolated(), mu::real(), Memory::resizeMemory(), Point::rotate(), Indices::row, VectorIndex::setOpenEndIndex(), Memory::shrink(), MemoryManager::shrink(), VectorIndex::size(), VectorIndex::subidx(), Memory::writeDataDirect(), MemoryManager::writeToTable(), Point::x, and Point::y.
Referenced by cmd_rotate().
bool seekInAudioFile | ( | CommandLineParser & | cmdParser | ) |
Seek a position in an audiofile and extract a length of samples from it.
cmdParser | CommandLineParser& |
Definition at line 3779 of file command_implementations.cpp.
References Indices::col, VectorIndex::front(), g_logger, Audio::getAudioFileByType(), CommandLineParser::getFileParameterValue(), NumeReKernel::getInstance(), NumeReKernel::getMemoryManager(), MemoryManager::getTable(), CommandLineParser::getTargetTable(), DetachedLogger::info(), Audio::Sample::leftOrMono, Memory::markModified(), VectorIndex::max(), max, min, CommandLineParser::parseExprAsNumericalValues(), mu::real(), MemoryManager::resizeTable(), Audio::Sample::right, Indices::row, CommandLineParser::setReturnValue(), VectorIndex::size(), VectorIndex::subidx(), toString(), Memory::writeData(), and Memory::writeDataDirectUnsafe().
Referenced by cmd_seek().
bool shortTimeFourierAnalysis | ( | CommandLineParser & | cmdParser | ) |
This function performs the short-time fourier analysis on the passed data set.
cmdParser | CommandLineParser& |
Definition at line 3985 of file command_implementations.cpp.
References CommandLineParser::clearReturnValue(), Indices::col, DataAccessParser::evalIndices(), VectorIndex::front(), DataAccessParser::getDataObject(), MemoryManager::getElement(), CommandLineParser::getExprAsDataObject(), MemoryManager::getHeadLineElement(), DataAccessParser::getIndices(), NumeReKernel::getInstance(), NumeReKernel::getMemoryManager(), CommandLineParser::getParameterValueAsNumericalValue(), CommandLineParser::getTargetTable(), intCast(), VectorIndex::INVALID, VectorIndex::isOpenEnd(), VectorIndex::max(), max, MemoryManager::max(), MemoryManager::min(), MemoryManager::resizeTable(), Indices::row, MemoryManager::setHeadLineElement(), VectorIndex::setRange(), CommandLineParser::setReturnValue(), VectorIndex::size(), VectorIndex::subidx(), toString(), and MemoryManager::writeToTable().
Referenced by cmd_stfa().
void taylor | ( | CommandLineParser & | cmdParser | ) |
This function approximates the passed expression using Taylor's method.
cmdParser | CommandLineParser& |
The aproximated function is defined as a new custom function.
Definition at line 2305 of file command_implementations.cpp.
References _lang, date::abs(), NumeRe::SavitzkyGolayDiffFilter::apply(), containsStrings(), FunctionDefinitionManager::defineFunc(), mu::ParserBase::Eval(), findVariableInExpression(), Language::get(), CommandLineParser::getAllParametersWithValues(), CommandLineParser::getCommandLine(), NumeReKernel::getDefinitions(), CommandLineParser::getExpr(), CommandLineParser::getExprAsMathExpression(), NumeReKernel::getInstance(), CommandLineParser::getParameterList(), CommandLineParser::getParameterValueAsNumericalValue(), NumeReKernel::getParser(), getPointerToVariable(), Settings::getPrecision(), NumeReKernel::getSettings(), CommandLineParser::hasParam(), intCast(), integralFactorial(), SyntaxError::invalid_position, FunctionDefinitionManager::isDefined(), mu::isinf(), mu::isnan(), NumeReKernel::issueWarning(), LineBreak(), NumeReKernel::print(), mu::ParserBase::SetExpr(), CommandLineParser::setReturnValue(), SyntaxError::STRINGS_MAY_NOT_BE_EVALUATED_WITH_CMD, StripSpaces(), Settings::systemPrints(), and toString().
Referenced by cmd_taylor().
void urlExecute | ( | CommandLineParser & | cmdParser | ) |
This function implements the url command providing an interface to http(s) and (s)ftp URLs.
cmdParser | CommandLineParser& |
Definition at line 4700 of file command_implementations.cpp.
References SyntaxError::CANNOT_OPEN_TARGET, url::get(), CommandLineParser::getCommandLine(), CommandLineParser::getFileParameterValue(), CommandLineParser::getFileParameterValueForSaving(), CommandLineParser::getParameterValueAsString(), CommandLineParser::hasParam(), CommandLineParser::parseExprAsString(), url::put(), replaceAll(), CommandLineParser::setReturnValue(), toString(), date::detail::trunc(), SyntaxError::URL_ERROR, and url::Error::what().
Referenced by cmd_url().
bool writeAudioFile | ( | CommandLineParser & | cmdParser | ) |
This function creates a WAVE file from the selected data set.
cmdParser | CommandLineParser& |
Definition at line 3622 of file command_implementations.cpp.
References Indices::col, DataAccessParser::evalIndices(), VectorIndex::front(), Audio::getAudioFileByType(), DataAccessParser::getDataObject(), MemoryManager::getElement(), CommandLineParser::getExprAsDataObject(), CommandLineParser::getFileParameterValueForSaving(), DataAccessParser::getIndices(), NumeReKernel::getInstance(), NumeReKernel::getMemoryManager(), CommandLineParser::getParameterValueAsNumericalValue(), intCast(), VectorIndex::isOpenEnd(), max, MemoryManager::max(), MemoryManager::min(), Indices::row, VectorIndex::setRange(), and VectorIndex::size().
Referenced by cmd_audio().