funciona por favor

This commit is contained in:
Oscar Suescun Elizalde 2025-04-02 11:03:06 +02:00
parent 0536ee6550
commit b5f1482ec4
7 changed files with 14 additions and 4 deletions

View File

@ -19,8 +19,6 @@ if __name__ == '__main__':
E_obj, f_obj = gc.valores_objetivo(archivoEnsayos, material) E_obj, f_obj = gc.valores_objetivo(archivoEnsayos, material)
vTension = []
log(f"La tension inducida objetivo son {E_obj} V") log(f"La tension inducida objetivo son {E_obj} V")
offset = 0 offset = 0
@ -32,6 +30,8 @@ if __name__ == '__main__':
while flag == False: while flag == False:
vTension = []
gc.generar_curva(offset, archivoCurvas) gc.generar_curva(offset, archivoCurvas)
log("-----------------------") log("-----------------------")
@ -51,7 +51,11 @@ if __name__ == '__main__':
vTension.append(tension) vTension.append(tension)
error.append(tension/E_obj) vTension = np.array(vTension)
error = vTension/E_obj
print(error)
error = np.mean(error) error = np.mean(error)

View File

@ -1,4 +1,4 @@
Material BH characteristics 01/04/2025 17:43:17 17:43:17 Material BH characteristics 02/04/2025 11:02:32 11:02:32
Code:1 (Stator) Material: M800-50A Code:1 (Stator) Material: M800-50A
24 24
1 0 0 1 0 0

6
test.py Normal file
View File

@ -0,0 +1,6 @@
import numpy as np
e = [23.76, 35.6, 48.05, 60.08]
eObj = [28.4, 42.93, 57.61, 72.313]
print(e/eObj)