diff --git a/datafiting/datafit/entry/src/main/ets/common/commonValue.ets b/datafiting/datafit/entry/src/main/ets/common/commonValue.ets index 4de7aec..0de7c0c 100644 --- a/datafiting/datafit/entry/src/main/ets/common/commonValue.ets +++ b/datafiting/datafit/entry/src/main/ets/common/commonValue.ets @@ -1,3 +1,19 @@ +/* +Copyright 2026 LI Meng + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +*/ + export class COMMON_VALUE{ /** * 字体大小(大) @@ -27,4 +43,4 @@ export class COMMON_VALUE{ * 浅白 */ static readonly LIGHT_WHITE = '#F2F2F2' -} \ No newline at end of file +} diff --git a/datafiting/datafit/entry/src/main/ets/component/ControlBar.ets b/datafiting/datafit/entry/src/main/ets/component/ControlBar.ets index 47c0578..5511b19 100644 --- a/datafiting/datafit/entry/src/main/ets/component/ControlBar.ets +++ b/datafiting/datafit/entry/src/main/ets/component/ControlBar.ets @@ -1,3 +1,19 @@ +/* +Copyright 2026 LI Meng + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +*/ + import promptAction from '@ohos.promptAction' import { COMMON_VALUE } from '../common/commonValue' import { handle } from '../utils/algorithm/createPotGather' diff --git a/datafiting/datafit/entry/src/main/ets/component/FitFuncType.ets b/datafiting/datafit/entry/src/main/ets/component/FitFuncType.ets index 01c3b44..a3de178 100644 --- a/datafiting/datafit/entry/src/main/ets/component/FitFuncType.ets +++ b/datafiting/datafit/entry/src/main/ets/component/FitFuncType.ets @@ -1,3 +1,19 @@ +/* +Copyright 2026 LI Meng + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +*/ + import { COMMON_VALUE } from '../common/commonValue' import { funcInfo } from '../utils/FunctionUtil' diff --git a/datafiting/datafit/entry/src/main/ets/component/Header.ets b/datafiting/datafit/entry/src/main/ets/component/Header.ets index 8faa9a5..7ba15e8 100644 --- a/datafiting/datafit/entry/src/main/ets/component/Header.ets +++ b/datafiting/datafit/entry/src/main/ets/component/Header.ets @@ -1,3 +1,19 @@ +/* +Copyright 2026 LI Meng + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +*/ + import { COMMON_VALUE } from '../common/commonValue' import { BoardInfo } from '../utils/drawBoard/BoardType' import { IPoint, PointType } from '../utils/drawBoard/DrawPoint' @@ -62,4 +78,4 @@ export struct header { }) }.width('100%').height('100%').padding(5).backgroundColor(COMMON_VALUE.LIGHT_WHITE) } -} \ No newline at end of file +} diff --git a/datafiting/datafit/entry/src/main/ets/component/ImageShow.ets b/datafiting/datafit/entry/src/main/ets/component/ImageShow.ets index d8fc3ed..3380e55 100644 --- a/datafiting/datafit/entry/src/main/ets/component/ImageShow.ets +++ b/datafiting/datafit/entry/src/main/ets/component/ImageShow.ets @@ -1,3 +1,19 @@ +/* +Copyright 2026 LI Meng + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +*/ + import { BoardInfo, CONTEXT, FIT_CONTEXT } from '../utils/drawBoard/BoardType' import { IPoint } from '../utils/drawBoard/DrawPoint' import { funcInfo, functionUtilIns } from '../utils/FunctionUtil' @@ -28,4 +44,4 @@ export struct imageShow { } } } -} \ No newline at end of file +} diff --git a/datafiting/datafit/entry/src/main/ets/model/createDocumentModel.ets b/datafiting/datafit/entry/src/main/ets/model/createDocumentModel.ets index d536047..763dd24 100644 --- a/datafiting/datafit/entry/src/main/ets/model/createDocumentModel.ets +++ b/datafiting/datafit/entry/src/main/ets/model/createDocumentModel.ets @@ -1,3 +1,19 @@ +/* +Copyright 2026 LI Meng + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +*/ + import picker from '@ohos.file.picker'; import { BusinessError } from '@ohos.base'; import fs from '@ohos.file.fs'; diff --git a/datafiting/datafit/entry/src/main/ets/pages/Index.ets b/datafiting/datafit/entry/src/main/ets/pages/Index.ets index 868cf9e..84bcb2c 100644 --- a/datafiting/datafit/entry/src/main/ets/pages/Index.ets +++ b/datafiting/datafit/entry/src/main/ets/pages/Index.ets @@ -1,3 +1,19 @@ +/* +Copyright 2026 LI Meng + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +*/ + import { controlBar } from '../component/ControlBar' import { fitFuncType } from '../component/FitFuncType' import { header } from '../component/Header' diff --git a/datafiting/datafit/entry/src/main/ets/utils/FunctionUtil.ets b/datafiting/datafit/entry/src/main/ets/utils/FunctionUtil.ets index 89d9d5c..e8439ac 100644 --- a/datafiting/datafit/entry/src/main/ets/utils/FunctionUtil.ets +++ b/datafiting/datafit/entry/src/main/ets/utils/FunctionUtil.ets @@ -1,3 +1,19 @@ +/* +Copyright 2026 LI Meng + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +*/ + import { IPoint, PointType } from './drawBoard/DrawPoint' import { handle } from './algorithm/createPotGather' @@ -46,4 +62,4 @@ class FunctionUtil { } } -export let functionUtilIns = new FunctionUtil() \ No newline at end of file +export let functionUtilIns = new FunctionUtil() diff --git a/datafiting/datafit/entry/src/main/ets/utils/algorithm/createPotGather.ets b/datafiting/datafit/entry/src/main/ets/utils/algorithm/createPotGather.ets index 67d2ca4..873d624 100644 --- a/datafiting/datafit/entry/src/main/ets/utils/algorithm/createPotGather.ets +++ b/datafiting/datafit/entry/src/main/ets/utils/algorithm/createPotGather.ets @@ -1,3 +1,19 @@ +/* +Copyright 2026 LI Meng + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +*/ + import { mathjs } from './evaluate'; import {IPoint, PointType} from "../drawBoard/DrawPoint" import {FitRes} from "./fittingResult" @@ -156,4 +172,4 @@ class CreatePointGather { } } -export let handle: CreatePointGather = new CreatePointGather(); \ No newline at end of file +export let handle: CreatePointGather = new CreatePointGather(); diff --git a/datafiting/datafit/entry/src/main/ets/utils/algorithm/evaluate.ets b/datafiting/datafit/entry/src/main/ets/utils/algorithm/evaluate.ets index b95bac4..48349d8 100644 --- a/datafiting/datafit/entry/src/main/ets/utils/algorithm/evaluate.ets +++ b/datafiting/datafit/entry/src/main/ets/utils/algorithm/evaluate.ets @@ -1,3 +1,19 @@ +/* +Copyright 2026 LI Meng + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +*/ + interface replaceableVar { char: string, value: number diff --git a/datafiting/datafit/entry/src/main/ets/utils/algorithm/exponentialFit.ets b/datafiting/datafit/entry/src/main/ets/utils/algorithm/exponentialFit.ets index f307a02..4eb74f5 100644 --- a/datafiting/datafit/entry/src/main/ets/utils/algorithm/exponentialFit.ets +++ b/datafiting/datafit/entry/src/main/ets/utils/algorithm/exponentialFit.ets @@ -1,3 +1,19 @@ +/* +Copyright 2026 LI Meng + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +*/ + import {IPoint} from "../drawBoard/DrawPoint" export class Exponent { @@ -45,4 +61,4 @@ export class Exponent { return [a, b]; } -} \ No newline at end of file +} diff --git a/datafiting/datafit/entry/src/main/ets/utils/algorithm/fittingResult.ets b/datafiting/datafit/entry/src/main/ets/utils/algorithm/fittingResult.ets index dbff2b4..7a3135f 100644 --- a/datafiting/datafit/entry/src/main/ets/utils/algorithm/fittingResult.ets +++ b/datafiting/datafit/entry/src/main/ets/utils/algorithm/fittingResult.ets @@ -1,3 +1,19 @@ +/* +Copyright 2026 LI Meng + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +*/ + /** * 拟合结果接口类型,包含拟合的函数系数和协方差矩阵 */ @@ -6,4 +22,4 @@ export interface FitRes { covarianceMatrix?: number[][]; error?: number; R_squared?: number; -} \ No newline at end of file +} diff --git a/datafiting/datafit/entry/src/main/ets/utils/algorithm/least_square.ets b/datafiting/datafit/entry/src/main/ets/utils/algorithm/least_square.ets index f4776af..6b7ab73 100644 --- a/datafiting/datafit/entry/src/main/ets/utils/algorithm/least_square.ets +++ b/datafiting/datafit/entry/src/main/ets/utils/algorithm/least_square.ets @@ -1,3 +1,19 @@ +/* +Copyright 2026 LI Meng + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +*/ + import {IPoint} from "../drawBoard/DrawPoint" import {FitRes} from "./fittingResult" @@ -123,4 +139,4 @@ export class Matrix { return fitRes; } -} \ No newline at end of file +} diff --git a/datafiting/datafit/entry/src/main/ets/utils/algorithm/logarithmicFit.ets b/datafiting/datafit/entry/src/main/ets/utils/algorithm/logarithmicFit.ets index 29ff938..02cdfe4 100644 --- a/datafiting/datafit/entry/src/main/ets/utils/algorithm/logarithmicFit.ets +++ b/datafiting/datafit/entry/src/main/ets/utils/algorithm/logarithmicFit.ets @@ -1,3 +1,19 @@ +/* +Copyright 2026 LI Meng + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +*/ + import {IPoint} from "../drawBoard/DrawPoint" import {Matrix} from "./least_square" @@ -62,4 +78,4 @@ export class Logarithm { } return [ a, b, c ]; } -} \ No newline at end of file +} diff --git a/datafiting/datafit/entry/src/main/ets/utils/drawBoard/BoardType.ets b/datafiting/datafit/entry/src/main/ets/utils/drawBoard/BoardType.ets index 1d0a379..f73c79e 100644 --- a/datafiting/datafit/entry/src/main/ets/utils/drawBoard/BoardType.ets +++ b/datafiting/datafit/entry/src/main/ets/utils/drawBoard/BoardType.ets @@ -1,3 +1,19 @@ +/* +Copyright 2026 LI Meng + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +*/ + import { IPoint, PointType } from './DrawPoint'; //标准值 /** diff --git a/datafiting/datafit/entry/src/main/ets/utils/drawBoard/DrawPoint.ets b/datafiting/datafit/entry/src/main/ets/utils/drawBoard/DrawPoint.ets index e8b9fa2..a407c6d 100644 --- a/datafiting/datafit/entry/src/main/ets/utils/drawBoard/DrawPoint.ets +++ b/datafiting/datafit/entry/src/main/ets/utils/drawBoard/DrawPoint.ets @@ -1,3 +1,19 @@ +/* +Copyright 2026 LI Meng + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +*/ + export enum PointType{ DISCONTINUE = 0, CONTINUE = 1 @@ -12,4 +28,4 @@ export interface IPoint{ y:number pointType:PointType -} \ No newline at end of file +}