|
Programacion Pregunta, consulta o ayuda a resolver los problemas o incógnitas que tengan los demás miembros de la comunidad sobre programación en general. |
Hola Invitado! Tómate un minuto para registrarte, es 100% GRATIS y no verás ninguna publicidad! ¿Qué estás esperando? Para Ingresa a Denunciando.com por medio de TapaTalk Clic ACA | Registrarse Ahora |
Programacion » Pregunta de Programacion - Urgente!!!!Participa en el tema Pregunta de Programacion - Urgente!!!! en el foro Programacion. |
Temas Similares | ||||
Tema | Autor | Foro | Respuestas | Último mensaje |
Ayuda Programacion Web PHP | El Guaje | Programacion | 5 | 06-04-2009 15:51:33 |
pregunta URGENTE | jose k | Problemas Tecnicos | 6 | 11-03-2009 19:46:58 |
pregunta sobre piercing en la ceja urgente ¡¡¡¡¡¡¡¡¡ | daniel5454 | Discusiones Generales | 10 | 26-01-2009 09:31:18 |
Pregunta urgente | River platense | Juegos y Consolas | 3 | 07-01-2009 21:59:22 |
programacion | dreyber | Programacion | 2 | 01-06-2007 18:05:31 |
18-10-2009 , 23:37:24 | #11 | |
Denunciante Dorado | Respuesta: Pregunta de Programacion - Urgente!!!!
no me sirvio, no consigo el codigo, ps le doy en block de notas para buscar la info de los codigos pero no dan, aparte esta en VB6 y no me sirve asi tenga muy pocas diferencias con el 2008 tiene que ser en ese. Para el que sepa o lo tenga ya hecho o algo se lo agradeceria mucho | |
Twittear Seguir a @denunciando
| |
No Calculado | #1.5 |
SponSor | Re: Respuesta: Pregunta de Programacion - Urgente!!!! |
18-10-2009 , 23:51:01 | #12 | |
Denunciante Mega | Respuesta: Pregunta de Programacion - Urgente!!!! Cita:
On Error Resume Next matriz1 = matriz vector_Ini1 = vector_Ini Error = 1000 Dim var As Double For i = 1 To Int(nroIteraciones.Text) var = 0 Jacobi.Rows = Jacobi.Rows + 1 Jacobi.TextMatrix(i, 0) = i For j = 0 To TamañoM - 1 var = vector_B(j) For k = 0 To TamañoM - 1 If j <> k Then var = var + ((-1) * matriz(j, k) * (vector_Ini(1, k))) End If Next k var = var / matriz(j, j) If Calc.Value = 0 Then var = Round(var, Val(nroCifras.Text)) Jacobi.TextMatrix(i, j + 1) = FormatNumber(var, Val(nroCifras.Text)) Else Jacobi.TextMatrix(i, j + 1) = FormatNumber(var, 16) End If vector_Ini(2, j) = var Next j Error = 0 For j = 0 To TamañoM - 1 Error = Error + (vector_Ini(2, j) - vector_Ini(1, j)) ^ 2 Next j Error = Error ^ 0.5 If Calc.Value = 0 Then Error = Round(Error, Val(nroCifras.Text)) Jacobi.TextMatrix(i + 1, TamañoM + 1) = FormatNumber(Error, Val(nroCifras.Text)) Else Jacobi.TextMatrix(i + 1, TamañoM + 1) = FormatNumber(Error, 16) End If For j = 0 To TamañoM - 1 vector_Ini(1, j) = vector_Ini(2, j) Next j If Flag Then Exit For If Error <= nroTolerancia.Text Then Flag = True Next i Jacobi.Rows = Jacobi.Rows - 1 End Sub Private Sub MGauss_Seidel() On Error Resume Next Error = 1000 Dim var As Double For i = 1 To Int(nroIteraciones.Text) Gauss_Seidel.Rows = Gauss_Seidel.Rows + 1 var = 0 Gauss_Seidel.TextMatrix(i, 0) = i For j = 0 To TamañoM - 1 var = vector_B(j) For k = 0 To TamañoM - 1 If j <> k Then var = var + ((-1) * matriz(j, k) * (vector_Ini(1, k))) End If Next k var = var / matriz(j, j) vector_Ini(1, j) = var If Calc.Value = 0 Then var = Round(var, Val(nroCifras.Text)) Gauss_Seidel.TextMatrix(i, j + 1) = FormatNumber(var, Val(nroCifras.Text)) Else Gauss_Seidel.TextMatrix(i, j + 1) = FormatNumber(var, 16) End If Next j Error = 0 For j = 0 To TamañoM - 1 Error = Error + (vector_Ini(2, j) - vector_Ini(1, j)) ^ 2 Next j Error = Error ^ 0.5 If Calc.Value = 0 Then Error = Round(Error, Val(nroCifras.Text)) Gauss_Seidel.TextMatrix(i + 1, TamañoM + 1) = FormatNumber(Error, Val(nroCifras.Text)) Else Gauss_Seidel.TextMatrix(i + 1, TamañoM + 1) = FormatNumber(Error, 16) End If If Flag Then Exit For If Error <= nroTolerancia.Text Then Flag = True Next i Gauss_Seidel.Rows = Gauss_Seidel.Rows - 1 End Sub Ese es el codigo de los dos metodos, a mi todas las clases, me abren con el bloc de notas. Abra el Metodos.frm, que ahi esta todo para calcular GS y jacobi. Aunque le quedaria mas facil, implementar los pseudocodigos de estos dos metodos, que hay varios ejemplos en internet. | |
19-10-2009 , 22:46:38 | #13 |
Denunciante Dorado | Respuesta: Pregunta de Programacion - Urgente!!!!
pero la vuelta es q no me da en vb2008
|
26-10-2009 , 09:55:29 | #14 |
Recien Registrado | Respuesta: Pregunta de Programacion - Urgente!!!!
Si no funciona en vb2008, entonces te toca revisar si ha cambiado la forma de llamar los métodos y la forma de operar las variables según el tipo. Esa vaina siempre pasa con el bendito microsoft.
|
Etiquetas |
pregunta, programacion, urgente |
|