FunctionSpaceToUnivariatePowerSeries2(R, FE, Expon, UPS, TRAN, UTS, TEXP, coerce_Ex, x)ΒΆ
fs2ups.spad line 1 [edit on github]
R: Join(GcdDomain, Comparable, RetractableTo Integer, LinearlyExplicitOver Integer)
FE: Join(AlgebraicallyClosedField, TranscendentalFunctionCategory, Algebra Fraction Integer, FunctionSpace R)
Expon: Join(OrderedAbelianMonoid, OrderedRing)
UPS: Join(UnivariatePowerSeriesCategory(FE, Expon), Field, PowerSeriesCategory(FE, Expon, SingletonAsOrderedSet), TranscendentalFunctionCategory)
TRAN: PartialTranscendentalFunctions UPS
UTS: UnivariateTaylorSeriesCategory FE
TEXP: TaylorSeriesExpansion(FE, Expon, SingletonAsOrderedSet, UPS, UTS)
coerce_Ex: Expon -> FE
x: Symbol
This package converts expressions in some function space to power series in a variable x with coefficients in that function space. The function exprToUPS converts expressions to power series whose coefficients do not contain the variable x. The function exprToGenUPS converts functional expressions to power series whose coefficients may involve functions of log(x).
- atan1: UPS -> UPS
atan1 shouldbe local but conditional
- exprToGenUPS: (FE, Boolean, Union(complex, real: two sides, real: left side, real: right side, just do it)) -> Union(%series: UPS, %problem: Record(func: String, prob: String))
exprToGenUPS(fcn, posCheck?, atanFlag)converts the expressionfcnto a generalized power series. IfposCheck?istrue, log'sof negative numbers are not allowed nor arenth roots of negative numbers withneven. IfposCheck?isfalse, these are allowed.atanFlagdetermines how the caseatan(f(x)), wheref(x)has a pole, will be treated. The possible values ofatanFlagare"complex","real: two sides","real: left side","real: right side", and"just do it". IfatanFlagis"complex", then no series expansion will be computed because, viewed as a function of a complex variable,atan(f(x))has an essential singularity. Otherwise, the sign of the leading coefficient of the series expansion off(x)determines the constant coefficient in the series expansion ofatan(f(x)). If this sign cannot be determined, a series expansion is computed only whenatanFlagis"just do it". When the leading term in the series expansion off(x)is of odd degree (or is a rational degree with odd numerator), then the constant coefficient in the series expansion ofatan(f(x))for values to the left differs from that for values to the right. IfatanFlagis"real: two sides", no series expansion will be computed. IfatanFlagis"real: left side"the constant coefficient for values to the left will be used and ifatanFlag"real: right side"the constant coefficient for values to the right will be used. If there is a problem in converting the function to a power series, we return a record containing the name of the function that caused the problem and a brief description of the problem. When expanding the expression into a series it is assumed that the series is centered at 0. For a series centered at a, the user should perform the substitutionx -> x + abefore calling this function.
- exprToPS: (FE, Boolean, Union(complex, real: two sides, real: left side, real: right side, just do it), Boolean, FE) -> Union(%series: UPS, %problem: Record(func: String, prob: String))
exprToPS(fcn, posCheck?, atanFlag, log_flag, log_val)is like exprToUPS, but iflog_flagistrueit replaces logarithms of expansion variable bylog_val
- exprToPS: (FE, Boolean, Union(complex, real: two sides, real: left side, real: right side, just do it), Boolean, FE, FE -> Boolean, FE -> Boolean, FE -> Boolean) -> Union(%series: UPS, %problem: Record(func: String, prob: String))
exprToPS(
fcn, posCheck?, atanFlag, log_flag, log_val, coef_chk, inv_chk, zero_chk) is like exprToPS(fcn, posCheck?, atanFlag, log_flag, log_val), but fails ifcoef_chkisfalsefor some coefficient offcnor if expansion process needs to invert element ofFEfor whichinv_chkisfalse
- exprToUPS: (FE, Boolean, Union(complex, real: two sides, real: left side, real: right side, just do it)) -> Union(%series: UPS, %problem: Record(func: String, prob: String))
exprToUPS(fcn, posCheck?, atanFlag)converts the expressionfcnto a power series. IfposCheck?istrue, log'sof negative numbers are not allowed nor arenth roots of negative numbers withneven. IfposCheck?isfalse, these are allowed.atanFlagdetermines how the caseatan(f(x)), wheref(x)has a pole, will be treated. The possible values ofatanFlagare"complex","real: two sides","real: left side","real: right side", and"just do it". IfatanFlagis"complex", then no series expansion will be computed because, viewed as a function of a complex variable,atan(f(x))has an essential singularity. Otherwise, the sign of the leading coefficient of the series expansion off(x)determines the constant coefficient in the series expansion ofatan(f(x)). If this sign cannot be determined, a series expansion is computed only whenatanFlagis"just do it". When the leading term in the series expansion off(x)is of odd degree (or is a rational degree with odd numerator), then the constant coefficient in the series expansion ofatan(f(x))for values to the left differs from that for values to the right. IfatanFlagis"real: two sides", no series expansion will be computed. IfatanFlagis"real: left side"the constant coefficient for values to the left will be used and ifatanFlag"real: right side"the constant coefficient for values to the right will be used. If there is a problem in converting the function to a power series, a record containing the name of the function that caused the problem and a brief description of the problem is returned. When expanding the expression into a series it is assumed that the series is centered at 0. For a series centered at a, the user should perform the substitutionx -> x + abefore calling this function.
- integ: UPS -> UPS
integ shouldbe local but conditional
- integ_df: (UPS, UPS) -> UPS
integ_df shouldbe local but conditional
- integt: UTS -> UTS
integt shouldbe local but conditional
- localAbs: FE -> FE
localAbs(fcn)=abs(fcn)orsqrt(fcn^2)depending on whether or not FE has a functionabs. This should be a local function, but the compiler won'tallow it.
- my_digamma: FE -> FE
my_digamma shouldbe local but conditional
- powToUPS: (List FE, Record(pos_Check?: Boolean, atan_Flag: Union(complex, real: two sides, real: left side, real: right side, just do it), coeff_check?: Union(FE -> Boolean, none), inv_check?: Union(FE -> Boolean, none), zero_check?: Union(FE -> Boolean, none), log_x_replace: Boolean, log_x_val: FE, cache: List Record(ker: Kernel FE, ser: Union(%series: UPS, %problem: Record(func: String, prob: String))))) -> Union(%series: UPS, %problem: Record(func: String, prob: String))
powToUPS shouldbe local but conditional